Skip to content

fix(auth): compare basic auth passwords in constant time - #54

Merged
alshdavid merged 2 commits into
mainfrom
agent/auto-flash/5a04aad0811b
Oct 19, 2026
Merged

alshdavid merged 2 commits into
mainfrom
agent/auto-flash/5a04aad0811b

Conversation

@alshdavid

Copy link
Copy Markdown
Collaborator

Basic auth compared the supplied password with ==, which short-circuits on the first differing byte. This uses subtle's constant-time equality instead.

Fixes #28

# Conflicts:
#	Cargo.toml
#	src/cmd/serve/handler.rs
@alshdavid
alshdavid merged commit fb87814 into main Oct 19, 2026
6 checks passed
@alshdavid
alshdavid deleted the agent/auto-flash/5a04aad0811b branch October 19, 2026 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Basic auth comparison is plaintext and not constant-time

1 participant