Buckets:

download
raw
3.85 kB
{
"role_mappings": [
{
"role": "Subject",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "The caller of POST /auth/token is an external client (frontend lives in another repo). The only in-repo sender is _default_auth_headers in packages/opencloning-cli/src/opencloning_cli/lifecycle.py:190, which uses a FastAPI TestClient to record test stubs, so it is test tooling and does not count."
},
{
"role": "Enforcer",
"status": "present",
"symbol": "login_for_access_token",
"file": "packages/opencloning-db/src/opencloning_db/routers/auth.py",
"lines": "62",
"notes": "Login route POST /auth/token (router included at packages/opencloning-db/src/opencloning_db/api.py:28). It reads username/password from OAuth2PasswordRequestForm, looks up the user (line 69), calls verify_password (line 76) and raises 401 on failure, otherwise issues a token."
},
{
"role": "Verification manager",
"status": "present",
"symbol": "verify_password",
"file": "packages/opencloning-db/src/opencloning_db/auth/security.py",
"lines": "18",
"notes": "Called by the Enforcer at routers/auth.py:76 with the submitted password and the stored hash; it forwards both to pwdlib PasswordHash.verify. Collecting the stored hash (step 3) is done inline in login_for_access_token (routers/auth.py:69)."
},
{
"role": "Password store",
"status": "present",
"symbol": "User",
"file": "packages/opencloning-db/src/opencloning_db/models.py",
"lines": "107",
"notes": "SQLAlchemy model User with column password_hash (models.py:119); queried inline in login_for_access_token at routers/auth.py:69 via session.scalar(select(User)...). No dedicated repository method exists, so the model class is cited."
},
{
"role": "Hasher",
"status": "external",
"symbol": "verify",
"file": "packages/opencloning-db/src/opencloning_db/auth/security.py",
"lines": "19",
"notes": "Reached from verify_password (security.py:18). pwdlib PasswordHash.verify (configured as PasswordHash.recommended(), i.e. Argon2, at security.py:11) re-hashes the password with the salt from the stored hash; the same call also serves as Comparator."
},
{
"role": "Pepper store",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "No pepper is used: verify_password (security.py:18) passes only the plain password and stored hash to pwdlib; grep for pepper/hmac/encrypt in packages/opencloning-db/src found nothing. The Argon2 salt is not a pepper."
},
{
"role": "Encrypter",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "No encryption of the hash with a pepper key on the verification path (security.py:11-19); only Argon2 hashing via pwdlib. The JWT secret in config is for token signing, not password encryption."
},
{
"role": "Comparator",
"status": "external",
"symbol": "verify",
"file": "packages/opencloning-db/src/opencloning_db/auth/security.py",
"lines": "19",
"notes": "Reached from verify_password (security.py:18). The single pwdlib PasswordHash.verify call both hashes and compares against the stored hash, returning a bool that login_for_access_token checks at routers/auth.py:76; same call as Hasher."
},
{
"role": "System",
"status": "present",
"symbol": "create_access_token",
"file": "packages/opencloning-db/src/opencloning_db/auth/security.py",
"lines": "22",
"notes": "Success branch of login_for_access_token calls create_access_token at routers/auth.py:83, which issues the JWT (PyJWT jwt.encode) returned to the client as Token."
}
]
}

Xet Storage Details

Size:
3.85 kB
·
Xet hash:
b015a97f6fc8c6ff7cbbd0d5965139276312e57ce5fcaaa4e38383820d58786a

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.