From 5deae884c252662a008156586840b501f2b175ba Mon Sep 17 00:00:00 2001 From: cristianzsh Date: Thu, 15 Dec 2022 12:07:39 -0300 Subject: [PATCH] Update libraries --- freki/app/__init__.py | 2 +- freki/app/api/__init__.py | 2 +- freki/app/api/general.py | 2 +- freki/app/api/pe.py | 2 +- freki/app/api/report.py | 2 +- freki/app/api/user.py | 4 ++-- freki/app/models.py | 2 +- freki/app/web/user.py | 2 +- freki/requirements.txt | 14 +++++++------- 9 files changed, 16 insertions(+), 16 deletions(-) diff --git a/freki/app/__init__.py b/freki/app/__init__.py index d82bd81..46022c3 100644 --- a/freki/app/__init__.py +++ b/freki/app/__init__.py @@ -30,7 +30,7 @@ from flask_limiter import Limiter from flask_limiter.util import get_remote_address from werkzeug.exceptions import RequestEntityTooLarge -from werkzeug.contrib.fixers import ProxyFix +from werkzeug.middleware.proxy_fix import ProxyFix from sqlalchemy import create_engine from sqlalchemy.exc import OperationalError diff --git a/freki/app/api/__init__.py b/freki/app/api/__init__.py index a0a8303..61ac2fd 100644 --- a/freki/app/api/__init__.py +++ b/freki/app/api/__init__.py @@ -22,7 +22,7 @@ from functools import wraps from flask import Blueprint, request from werkzeug.datastructures import FileStorage -from flask_restplus import Api +from flask_restx import Api from app import db from app.models import User diff --git a/freki/app/api/general.py b/freki/app/api/general.py index ac7c2ee..bc4621e 100644 --- a/freki/app/api/general.py +++ b/freki/app/api/general.py @@ -17,7 +17,7 @@ along with this program. If not, see . """ -from flask_restplus import Resource +from flask_restx import Resource from app.core.yaraanalysis import YaraAnalysis from app.core.hashes import Hashes diff --git a/freki/app/api/pe.py b/freki/app/api/pe.py index c2d2b9a..6885e1b 100644 --- a/freki/app/api/pe.py +++ b/freki/app/api/pe.py @@ -19,7 +19,7 @@ from subprocess import CalledProcessError from pefile import PEFormatError -from flask_restplus import Resource +from flask_restx import Resource from app.core.utils import save_file from app.core.pe import PE diff --git a/freki/app/api/report.py b/freki/app/api/report.py index 18d3825..7fc345f 100644 --- a/freki/app/api/report.py +++ b/freki/app/api/report.py @@ -19,7 +19,7 @@ import json -from flask_restplus import Resource +from flask_restx import Resource from flask import request, send_from_directory try: diff --git a/freki/app/api/user.py b/freki/app/api/user.py index 55e7a03..0fb38a7 100644 --- a/freki/app/api/user.py +++ b/freki/app/api/user.py @@ -17,8 +17,8 @@ along with this program. If not, see . """ -from flask_restplus import Resource -from werkzeug import check_password_hash +from flask_restx import Resource +from werkzeug.security import check_password_hash from app.models import User diff --git a/freki/app/models.py b/freki/app/models.py index 55d819d..3604350 100644 --- a/freki/app/models.py +++ b/freki/app/models.py @@ -36,7 +36,7 @@ class User(Base, UserMixin, db.Model): id = db.Column(db.Integer, primary_key=True) email = db.Column(db.String(255), unique=True, nullable=False) username = db.Column(db.String(50), unique=True, nullable=False) - password = db.Column(db.String(80), nullable=False) + password = db.Column(db.String(90), nullable=False) vt_key = db.Column(db.String(64), nullable=True) freki_key = db.Column(db.String(255), nullable=False) diff --git a/freki/app/web/user.py b/freki/app/web/user.py index 0f8942c..3d62250 100644 --- a/freki/app/web/user.py +++ b/freki/app/web/user.py @@ -24,7 +24,7 @@ from flask_login import login_user, logout_user, login_required, current_user from flask import render_template, redirect, request, url_for, flash -from werkzeug import generate_password_hash, check_password_hash +from werkzeug.security import generate_password_hash, check_password_hash from sqlalchemy.exc import DataError from sqlalchemy import or_ diff --git a/freki/requirements.txt b/freki/requirements.txt index ecafa10..1ee3410 100644 --- a/freki/requirements.txt +++ b/freki/requirements.txt @@ -1,18 +1,18 @@ apscheduler==3.7.0 -flask==1.1.2 -flask-restplus==0.13.0 +flask==2.1.0 +flask-restx==1.0.3 flask-sqlalchemy==2.5.1 -flask-login==0.5.0 -flask-limiter==1.3.1 +flask-login==0.6.2 +flask-limiter==2.8.1 gunicorn==20.0.4 mysqlclient pefile==2019.4.18 pydeep==0.4 -PyJWT==1.6.4 -pyminizip==0.2.4 +PyJWT==2.6.0 +pyminizip==0.2.6 pyopenssl==19.1.0 python-magic==0.4.18 requests==2.24.0 sqlalchemy-utils -werkzeug==0.16.1 +werkzeug==2.0 yara-python==4.0.2