Buckets:

download
raw
3.74 kB
{
"role_mappings": [
{
"role": "Entity",
"status": "missing",
"symbol": "",
"file": "",
"lines": "",
"notes": "The caller is an external WebAuthn browser/client hitting POST /auth/passkeys/authentication/start (pk-auth-dropwizard PkAuthCeremonyResource.java:63, also Spring/Micronaut adapters); no in-repo JS/HTML/SDK client exists outside tests."
},
{
"role": "Enforcer",
"status": "present",
"symbol": "startAuthentication",
"file": "pk-auth-core/src/main/java/com/codeheadsystems/pkauth/internal/DefaultPasskeyAuthenticationService.java",
"lines": "498",
"notes": "startAuthentication in DefaultPasskeyAuthenticationService takes the client IP (from HTTP adapters, e.g. PkAuthCeremonyResource.java:65 via CeremonyOrchestrator.java:65) and username, calls rateLimitedBucket at line 501 and returns StartAuthenticationResult.RateLimited (mapped to 429 by adapters) before any challenge is created. Same inline guard exists in startRegistration:224, finishRegistration:289, finishAuthentication:556."
},
{
"role": "Limiter",
"status": "present",
"symbol": "acquire",
"file": "pk-auth-core/src/main/java/com/codeheadsystems/pkauth/ceremony/InMemoryCeremonyRateLimiter.java",
"lines": "136",
"notes": "Reached from Enforcer via rateLimitedBucket (DefaultPasskeyAuthenticationService.java:913, calls tryAcquireForIp at 915 and tryAcquireForUsername at 926) -> InMemoryCeremonyRateLimiter.tryAcquireForIp:120 / tryAcquireForUsername:131 -> acquire, which increments the per-key counter and returns next <= limit. Default bean wiring: PkAuthAutoConfiguration.java:183 (Spring), PkAuthModule.java:123 (Dropwizard), PkAuthFactory.java:205 (Micronaut); rateLimitedBucket aggregates the two bucket decisions."
},
{
"role": "HistoryProvider",
"status": "external",
"symbol": "get",
"file": "pk-auth-core/src/main/java/com/codeheadsystems/pkauth/ceremony/InMemoryCeremonyRateLimiter.java",
"lines": "137",
"notes": "acquire (Limiter, line 136) calls Caffeine Cache.get on ipCounters/usernameCounters (fields at lines 62-63, built in constructor with expireAfterWrite(window) and maximumSize) to fetch the per-IP/per-username AtomicInteger counter, then incrementAndGet at line 138 updates it. The windowed history store is the Caffeine library cache; the repo only configures and calls it."
},
{
"role": "PolicyProvider",
"status": "present",
"symbol": "DEFAULT_PER_IP_LIMIT",
"file": "pk-auth-core/src/main/java/com/codeheadsystems/pkauth/ceremony/InMemoryCeremonyRateLimiter.java",
"lines": "38",
"notes": "No method retrieves the policy: the default constructor (line 70, used by the default beans) copies DEFAULT_PER_IP_LIMIT=30 / DEFAULT_PER_USERNAME_LIMIT=10 (line 41) and DEFAULT_WINDOW=1 min (line 44) into perIpLimit/perUsernameLimit fields (60-61), which tryAcquireForIp/tryAcquireForUsername pass as the limit to acquire (lines 127, 133). Hard-coded constants, not externally configurable by default."
},
{
"role": "System",
"status": "present",
"symbol": "generate",
"file": "pk-auth-core/src/main/java/com/codeheadsystems/pkauth/internal/ChallengeGenerator.java",
"lines": "31",
"notes": "After the Enforcer passes, startAuthentication proceeds with the protected ceremony work: user/credential lookup, challengeGenerator.generate() at DefaultPasskeyAuthenticationService.java:522 (SecureRandom challenge) and challengeStore.put, returning the Started options. generate is the named unit for that challenge issuance; the rest is inline in startAuthentication."
}
]
}

Xet Storage Details

Size:
3.74 kB
·
Xet hash:
c143bd47e0b4b8c719a8a062b7853edf4b74d8c30ee7a192028eefbef4a62608

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