Skip to content

test(s3): cover anonymous admin signing#214

Merged
overtrue merged 1 commit into
mainfrom
test-gap-20260524
May 24, 2026
Merged

test(s3): cover anonymous admin signing#214
overtrue merged 1 commit into
mainfrom
test-gap-20260524

Conversation

@overtrue
Copy link
Copy Markdown
Contributor

Related issue(s)

None. Automation found a recent test gap.

Background

Recent mTLS and anonymous alias support added an admin client branch that skips SigV4 signing when an alias is anonymous. Existing admin route tests used credentialed aliases, so they did not prove anonymous admin requests omit the Authorization header.

Solution

Add a focused rc-s3 admin regression test that sends an anonymous heal status request through the local admin test server and asserts the request has no Authorization header.

Validation

  • cargo test -p rc-s3 anonymous_admin_requests_skip_authorization_header --lib
  • cargo fmt --all --check
  • git diff --check
  • make pre-commit

@overtrue overtrue marked this pull request as ready for review May 23, 2026 21:12
Copilot AI review requested due to automatic review settings May 23, 2026 21:12
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a regression test in the rc-s3 admin client test suite to ensure that when an alias is marked anonymous, admin requests are sent without SigV4 Authorization headers (covering a previously untested branch introduced by anonymous alias support).

Changes:

  • Extend the admin test server request capture to include raw request headers.
  • Add a helper to construct an anonymous AdminClient for a given endpoint.
  • Add a #[tokio::test] asserting anonymous heal_status() requests do not include an Authorization header.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread crates/s3/src/admin.rs Outdated
Comment thread crates/s3/src/admin.rs
@overtrue overtrue force-pushed the test-gap-20260524 branch from 4f478f6 to 9b2f8c8 Compare May 23, 2026 21:18
@overtrue overtrue merged commit 3dce0cc into main May 24, 2026
15 checks passed
@overtrue overtrue deleted the test-gap-20260524 branch May 24, 2026 04:25
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.

2 participants