fix(config): refuse a token over non-loopback http on every config request #606
No reviewers
Labels
No labels
breaking
bug
documentation
enhancement
epic
good first issue
help wanted
refactoring
resolution/duplicate
resolution/invalid
resolution/wontfix
security
severity/critical
severity/high
severity/low
severity/medium
status/abandoned
status/blocked
status/needs-decision
status/needs-info
status/needs-verification
testing
upstream
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
sixfold-space/madtea!606
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/scheme-check-authed-request"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
doAuthedRequestnow runsRequireSecureSchemebefore it attaches the token, so every token-bearing request ininternal/configrefuses a non-loopbackhttp://URL. The environment rung ofGetCredentialsWithSourceskipped the check, soauth whoamisent an env token over cleartext. Token-less requests,https, and loopbackhttpstill go out. A test proves the refusal comes before any request is sent, and it fails with the guard removed.The refusal text named
gitea.url, a key madtea does not read. It now namesMADTEA_URLandmadtea.url.ADR 0041 records the rule: no token over non-loopback http, no opt-out, loopback exempt.
Closes #605
Closes #605