Skip to content

fix: redact session identities and quote callback logs - #16

Merged
linkdata merged 2 commits into
mainfrom
fix/11-auth-logging
Oct 5, 2026
Merged

linkdata merged 2 commits into
mainfrom
fix/11-auth-logging

Conversation

@linkdata

@linkdata linkdata commented Oct 4, 2026 •

Copy link
Copy Markdown
Owner

Merge order: #16, #17, #18, then #19.

Auth debug logs use session_prefix, the first four characters of the JaWS session cookie, to correlate sessions with browser cookies. Cookies shorter than 12 characters have no logged prefix, leaving at least eight base-32 characters undisclosed. The prefix exposes up to 20 bits of the 64-bit random session ID.

OAuth2 callback error fields remain untrusted browser input and preserve the provider's text. The demo quotes errors when logging, and FailedFunc documentation tells applications to quote logged errors and escape rendered output.

Validation: go test -race ./..., go vet ./..., go build ./..., golangci-lint run, and gosec ./... in both Go modules. Local staticcheck ./... reported matched no packages in both modules.

Closes #11
Closes #13

@linkdata
linkdata merged commit 5c7316b into main Oct 5, 2026
3 checks passed
@linkdata
linkdata deleted the fix/11-auth-logging branch October 5, 2026 06:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OAuth2 callback error parameters can inject lines into LoginFailed logs Debug logs contain the JaWS session ID, which is the session cookie value

1 participant