2022-01-19 23:45:15 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2023-02-02 18:25:31 +00:00
|
|
|
, pythonOlder
|
2023-11-16 04:20:00 +00:00
|
|
|
, setuptools
|
2024-01-13 08:15:51 +00:00
|
|
|
, pydantic
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
# extras: babel
|
2022-05-18 14:49:53 +00:00
|
|
|
, babel
|
2022-04-27 09:35:20 +00:00
|
|
|
, flask-babel
|
|
|
|
|
|
|
|
# extras: common
|
|
|
|
, bcrypt
|
|
|
|
, bleach
|
2022-09-30 11:47:45 +00:00
|
|
|
, flask-mailman
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
# extras: fsqla
|
2022-08-12 12:06:08 +00:00
|
|
|
, flask-sqlalchemy
|
2022-04-27 09:35:20 +00:00
|
|
|
, sqlalchemy
|
|
|
|
, sqlalchemy-utils
|
|
|
|
|
|
|
|
# extras: mfa
|
|
|
|
, cryptography
|
|
|
|
, phonenumbers
|
2023-11-16 04:20:00 +00:00
|
|
|
, webauthn
|
|
|
|
, qrcode
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
# propagates
|
2022-06-26 10:26:21 +00:00
|
|
|
, email-validator
|
2022-04-27 09:35:20 +00:00
|
|
|
, flask
|
2022-10-21 18:38:19 +00:00
|
|
|
, flask-login
|
2023-10-09 19:29:22 +00:00
|
|
|
, flask-principal
|
2022-06-16 17:23:12 +00:00
|
|
|
, flask-wtf
|
2022-04-27 09:35:20 +00:00
|
|
|
, passlib
|
2023-11-16 04:20:00 +00:00
|
|
|
, importlib-resources
|
|
|
|
, wtforms
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
# tests
|
2022-05-18 14:49:53 +00:00
|
|
|
, argon2-cffi
|
2022-04-27 09:35:20 +00:00
|
|
|
, mongoengine
|
|
|
|
, mongomock
|
2022-01-19 23:45:15 +00:00
|
|
|
, peewee
|
|
|
|
, pony
|
2022-04-27 09:35:20 +00:00
|
|
|
, pytestCheckHook
|
2022-09-30 11:47:45 +00:00
|
|
|
, python-dateutil
|
2022-01-19 23:45:15 +00:00
|
|
|
, zxcvbn
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "flask-security-too";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "5.3.3";
|
2023-11-16 04:20:00 +00:00
|
|
|
pyproject = true;
|
2023-02-02 18:25:31 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2022-01-19 23:45:15 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
pname = "Flask-Security-Too";
|
|
|
|
inherit version;
|
2024-01-02 11:29:13 +00:00
|
|
|
hash = "sha256-we2TquU28qP/ir4eE67J0Nlft/8IL8w7Ny3ypSE5cNk=";
|
2022-01-19 23:45:15 +00:00
|
|
|
};
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools
|
|
|
|
];
|
2023-10-09 19:29:22 +00:00
|
|
|
|
2022-01-19 23:45:15 +00:00
|
|
|
propagatedBuildInputs = [
|
2022-06-26 10:26:21 +00:00
|
|
|
email-validator
|
2022-01-19 23:45:15 +00:00
|
|
|
flask
|
2022-10-21 18:38:19 +00:00
|
|
|
flask-login
|
2023-10-09 19:29:22 +00:00
|
|
|
flask-principal
|
2022-06-16 17:23:12 +00:00
|
|
|
flask-wtf
|
2022-01-19 23:45:15 +00:00
|
|
|
passlib
|
2023-11-16 04:20:00 +00:00
|
|
|
importlib-resources
|
|
|
|
wtforms
|
2022-01-19 23:45:15 +00:00
|
|
|
];
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
passthru.optional-dependencies = {
|
2022-04-27 09:35:20 +00:00
|
|
|
babel = [
|
2022-05-18 14:49:53 +00:00
|
|
|
babel
|
2022-04-27 09:35:20 +00:00
|
|
|
flask-babel
|
|
|
|
];
|
|
|
|
common = [
|
|
|
|
bcrypt
|
|
|
|
bleach
|
2022-09-30 11:47:45 +00:00
|
|
|
flask-mailman
|
2022-04-27 09:35:20 +00:00
|
|
|
];
|
|
|
|
fsqla = [
|
2022-08-12 12:06:08 +00:00
|
|
|
flask-sqlalchemy
|
2022-04-27 09:35:20 +00:00
|
|
|
sqlalchemy
|
|
|
|
sqlalchemy-utils
|
|
|
|
];
|
|
|
|
mfa = [
|
|
|
|
cryptography
|
|
|
|
phonenumbers
|
2023-11-16 04:20:00 +00:00
|
|
|
webauthn
|
|
|
|
qrcode
|
2022-04-27 09:35:20 +00:00
|
|
|
];
|
|
|
|
};
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-05-18 14:49:53 +00:00
|
|
|
argon2-cffi
|
2022-04-27 09:35:20 +00:00
|
|
|
mongoengine
|
|
|
|
mongomock
|
2022-01-19 23:45:15 +00:00
|
|
|
peewee
|
|
|
|
pony
|
2022-04-27 09:35:20 +00:00
|
|
|
pytestCheckHook
|
2022-09-30 11:47:45 +00:00
|
|
|
python-dateutil
|
2022-01-19 23:45:15 +00:00
|
|
|
zxcvbn
|
2022-04-27 09:35:20 +00:00
|
|
|
]
|
2022-06-16 17:23:12 +00:00
|
|
|
++ passthru.optional-dependencies.babel
|
|
|
|
++ passthru.optional-dependencies.common
|
|
|
|
++ passthru.optional-dependencies.fsqla
|
|
|
|
++ passthru.optional-dependencies.mfa;
|
2022-04-27 09:35:20 +00:00
|
|
|
|
2022-01-19 23:45:15 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
disabledTests = [
|
|
|
|
# needs /etc/resolv.conf
|
|
|
|
"test_login_email_whatever"
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"flask_security"
|
|
|
|
];
|
2022-01-19 23:45:15 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
2023-02-02 18:25:31 +00:00
|
|
|
changelog = "https://github.com/Flask-Middleware/flask-security/blob/${version}/CHANGES.rst";
|
|
|
|
homepage = "https://github.com/Flask-Middleware/flask-security";
|
2022-01-19 23:45:15 +00:00
|
|
|
description = "Simple security for Flask apps (fork)";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ gador ];
|
2024-01-13 08:15:51 +00:00
|
|
|
# https://github.com/Flask-Middleware/flask-security/pull/851
|
|
|
|
broken = versionAtLeast pydantic.version "2";
|
2022-01-19 23:45:15 +00:00
|
|
|
};
|
|
|
|
}
|