Flask-ACSecure-0.1.2
توضیحات
Access Secure Flask Middleware
| ویژگی | مقدار |
|---|---|
| سیستم عامل | OS Independent |
| نام فایل | Flask-ACSecure-0.1.2 |
| نام | Flask-ACSecure |
| نسخه کتابخانه | 0.1.2 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Xin Jin |
| ایمیل نویسنده | opposcript@gmail.com |
| آدرس صفحه اصلی | https://github.com/TrentaIcedCoffee/access-secure |
| آدرس اینترنتی | https://pypi.org/project/Flask-ACSecure/ |
| مجوز | MIT |
[](https://badge.fury.io/py/Flask-ACSecure)
# Flask-ACSecure
Access Secure middleware for Flask, for logging, anti-spamming and black/white list...
## Install
- Go to [https://logsecure.io](https://www.logsecure.io/), create an account and project. Remember project ID and keep project token in secret. (See [images below for details](#images))
- pip install Flask-ACSecure
- Config and Usage
```python
from flask_acsecure import ACSecure
app.config.update({
'ACSECURE_APP_ID': 'my_app_id',
'ACSECURE_APP_TOKEN': 'my_app_token',
})
ACSecure(app)
@app.errorhandler(403)
def forbidden(e):
return { 'message': 'forbidden' }
@app.route('/')
def index():
return { 'message': 'ok' }
```
## Images
### register
<img alt="register.JPG" src="https://raw.githubusercontent.com/TrentaIcedCoffee/access-secure/master/images/register.JPG" width="600" />
### create project
<img alt="create-project.JPG" src="https://raw.githubusercontent.com/TrentaIcedCoffee/access-secure/master/images/create-project.JPG" width="600" />
### project ID and Token
<img alt="console.JPG" src="https://raw.githubusercontent.com/TrentaIcedCoffee/access-secure/master/images/console.JPG" width="600" />
نیازمندی
| مقدار | نام |
|---|---|
| ==2019.11.28 | certifi |
| ==3.0.4 | chardet |
| ==7.0 | Click |
| ==1.1.1 | Flask |
| ==2.8 | idna |
| ==1.1.0 | itsdangerous |
| ==2.11.1 | Jinja2 |
| ==1.1.1 | MarkupSafe |
| ==2.22.0 | requests |
| ==1.25.8 | urllib3 |
| ==1.0.0 | Werkzeug |
زبان مورد نیاز
| مقدار | نام |
|---|---|
| >=3.5 | Python |
نحوه نصب
نصب پکیج whl Flask-ACSecure-0.1.2:
pip install Flask-ACSecure-0.1.2.whl
نصب پکیج tar.gz Flask-ACSecure-0.1.2:
pip install Flask-ACSecure-0.1.2.tar.gz