Buckets:
AnonymousSpottedToad/candidate_bucket / preliminary /mappings /python /authentication_pwd /theonlyamos_runit-server.json
| { | |
| "role_mappings": [ | |
| { | |
| "role": "Subject", | |
| "status": "missing", | |
| "symbol": "", | |
| "file": "", | |
| "lines": "", | |
| "notes": "The caller of the web login POST /login (runit_server/routers/public.py:214) is an outside browser; the login.html template is not in the repo. The CLI helper Account.login (runit_server/modules/account.py:49) posts to /api/login/, which matches neither the traced web enforcer nor the real API route /api/v1/login, and it is not wired into cli.py." | |
| }, | |
| { | |
| "role": "Enforcer", | |
| "status": "present", | |
| "symbol": "login", | |
| "file": "runit_server/routers/public.py", | |
| "lines": "214", | |
| "notes": "The FastAPI route handler POST /login (router 'public', included at runit_server/app.py:135) receives the email and password via OAuth2PasswordRequestForm. It calls authenticate at public.py:228 and refuses with an 'Invalid Login Credentials' page if that returns None; it also applies rate limiting and a CSRF check. Alternative: api_login at runit_server/routers/api/public.py:55 uses the same authenticate." | |
| }, | |
| { | |
| "role": "Verification manager", | |
| "status": "present", | |
| "symbol": "authenticate", | |
| "file": "runit_server/common/security.py", | |
| "lines": "29", | |
| "notes": "Reached from Enforcer login (runit_server/routers/public.py:228). It fetches the user via User.get_by_email (security.py:37), passes the password and stored hash to Utils.check_hashed_password (security.py:39), and returns the user or None." | |
| }, | |
| { | |
| "role": "Password store", | |
| "status": "present", | |
| "symbol": "get_by_email", | |
| "file": "runit_server/models/user.py", | |
| "lines": "144", | |
| "notes": "Called by authenticate at runit_server/common/security.py:37. It looks up the user document by email in the users table via DBMS.Database.find_one (with a 60s cache); the record holds the passlib pbkdf2_sha512 hash produced by Utils.hash_password at registration (models/user.py:83)." | |
| }, | |
| { | |
| "role": "Hasher", | |
| "status": "external", | |
| "symbol": "verify", | |
| "file": "runit_server/common/utils.py", | |
| "lines": "183", | |
| "notes": "Reached from authenticate (security.py:39) through the wrapper Utils.check_hashed_password (utils.py:172). passlib's pbkdf2_sha512.verify re-hashes the password with the stored salt and compares it, so one call covers both Hasher and Comparator. If passlib cannot be imported, the fallback uses hashlib.pbkdf2_hmac at utils.py:188." | |
| }, | |
| { | |
| "role": "Pepper store", | |
| "status": "missing", | |
| "symbol": "", | |
| "file": "", | |
| "lines": "", | |
| "notes": "No pepper on the verification path: authenticate (security.py:29) and check_hashed_password (utils.py:172) use only the per-hash salt. A grep for pepper/hmac found only the salted pbkdf2_hmac fallback." | |
| }, | |
| { | |
| "role": "Encrypter", | |
| "status": "missing", | |
| "symbol": "", | |
| "file": "", | |
| "lines": "", | |
| "notes": "The PBKDF2 hash is not encrypted or HMAC'd with a key anywhere in check_hashed_password (runit_server/common/utils.py:172) or hash_password (utils.py:150)." | |
| }, | |
| { | |
| "role": "Comparator", | |
| "status": "external", | |
| "symbol": "verify", | |
| "file": "runit_server/common/utils.py", | |
| "lines": "183", | |
| "notes": "The same passlib pbkdf2_sha512.verify call as the Hasher, reached via authenticate (security.py:39) -> check_hashed_password (utils.py:172); one call covers hashing and comparison. Its boolean result decides authenticate's return value. The fallback branch compares with secrets.compare_digest at utils.py:194." | |
| }, | |
| { | |
| "role": "System", | |
| "status": "present", | |
| "symbol": "create_access_token", | |
| "file": "runit_server/common/security.py", | |
| "lines": "43", | |
| "notes": "On success, Enforcer login (runit_server/routers/public.py:234) calls create_access_token, which issues a python-jose JWT. login then stores user_id/name/email/access_token in request.session (public.py:235-238) and redirects to user_home." | |
| } | |
| ] | |
| } | |
Xet Storage Details
- Size:
- 4.09 kB
- Xet hash:
- 772179f72f9c167232f60cf5abe867707c0beccc7deadcbd109cb7126c6fd9e9
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.