Buckets:

download
raw
3.97 kB
{
"role_mappings": [
{
"role": "Subject",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "No in-repo client posts email/password to POST /v1/users/login; searched codetether/, agents/, apps/, scripts/, examples/, docs/ and a2a_mcp_client.py (only a test and the public-route allowlist in a2a_server/policy_middleware.py:64 mention the path). The caller is outside the repo."
},
{
"role": "Enforcer",
"status": "present",
"symbol": "login",
"file": "a2a_server/user_auth.py",
"lines": "880",
"notes": "FastAPI route POST /v1/users/login (router mounted in a2a_server/server.py:727) receives LoginRequest(email, password) and raises HTTPException 401 when the user is unknown (line 889) or verify_password fails (line 891-892), so the token is issued only after successful verification. The same method also acts as Verification manager."
},
{
"role": "Verification manager",
"status": "present",
"symbol": "login",
"file": "a2a_server/user_auth.py",
"lines": "880",
"notes": "Inline in the Enforcer login (same method): it fetches the stored bcrypt hash via get_user_by_email at user_auth.py:886 and passes it with the submitted password to verify_password at user_auth.py:891. verify_password (user_auth.py:162) is only a thin wrapper forwarding to bcrypt.checkpw, so it is not cited as a separate role."
},
{
"role": "Password store",
"status": "present",
"symbol": "get_user_by_email",
"file": "a2a_server/user_auth.py",
"lines": "679",
"notes": "Called by login (Verification manager) at user_auth.py:886; runs 'SELECT * FROM users WHERE email = $1' on the asyncpg pool and returns the row including password_hash. Hashes are written by create_user (user_auth.py:703) using hash_password/bcrypt.hashpw."
},
{
"role": "Hasher",
"status": "external",
"symbol": "checkpw",
"file": "a2a_server/user_auth.py",
"lines": "164",
"notes": "Reached from login via verify_password (user_auth.py:891 -> 162); bcrypt.checkpw (bcrypt library, imported at user_auth.py:23) re-hashes the password with the salt embedded in the stored hash. One call covers both Hasher and Comparator; registration hashing uses bcrypt.hashpw/gensalt at user_auth.py:157."
},
{
"role": "Pepper store",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "No pepper on the login path: verify_password (user_auth.py:162) passes only the password and stored hash to bcrypt.checkpw, and hash_password (user_auth.py:155) uses only bcrypt.gensalt (a salt, not a pepper). A repo-wide grep for pepper found nothing."
},
{
"role": "Encrypter",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "The bcrypt hash is never encrypted with a key on the verification path (user_auth.py:162-166) or at registration (user_auth.py:155-159); no cipher/HMAC is applied to password hashes anywhere in a2a_server."
},
{
"role": "Comparator",
"status": "external",
"symbol": "checkpw",
"file": "a2a_server/user_auth.py",
"lines": "164",
"notes": "Reached from login (Verification manager) via verify_password at user_auth.py:891; bcrypt.checkpw (bcrypt library) compares the recomputed hash with the stored password_hash and returns the bool that login acts on. Same call as the Hasher."
},
{
"role": "System",
"status": "present",
"symbol": "create_access_token",
"file": "a2a_server/user_auth.py",
"lines": "179",
"notes": "Success branch of login calls create_access_token at user_auth.py:902 (after the status check), which issues an HS256 JWT via jose jwt.encode; login then calls update_user_login (user_auth.py:761) at line 905 and returns LoginResponse."
}
]
}

Xet Storage Details

Size:
3.97 kB
·
Xet hash:
e15a97420a81383bab10e4f1e05e6afd5e27f62309ee80d5ae0991b8399340b9

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