• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stacklok / toolhive / 19029892023
51%

Build:
DEFAULT BRANCH: main
Ran 03 Nov 2025 09:34AM UTC
Jobs 1
Files 336
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

03 Nov 2025 09:29AM UTC coverage: 47.74% (+0.2%) from 47.58%
19029892023

push

github

web-flow
Implement core authentication infrastructure for vMCP (#2393)

* Add context helpers for Identity propagation in vmcp auth

Adds several context-related helpers that will be used to propagate
Identity through vMCP.

Related: #2377

* Add OIDC incoming authenticator for vmcp

Implement IncomingAuthenticator interface using existing TokenValidator from
pkg/auth. This adapter validates JWT tokens from clients connecting to the
Virtual MCP Server and extracts identity information.

Related: #2377

* Add a registry of outgoing auth strategies with a stub of AuthenticateRequest()

Implement OutgoingAuthenticator interface with pluggable authentication
strategies for backend MCP server connections.

The actual strategies will be implemented in a follow-up commit.

Fixes: #2377

* Add token redaction to Identity serialization

Implement String() and MarshalJSON() methods on the Identity struct to
prevent accidental token leakage when logging or serializing identities.

* Document Groups field design decision

Add concise documentation explaining why Identity.Groups is intentionally
not populated by OIDCIncomingAuthenticator. This clarifies that group
extraction is an authorization concern handled via the Claims map, as
different OIDC providers use different claim names.

* Document thread-safety guarantees for outgoing auth

Add explicit documentation that RegisterStrategy and AuthenticateRequest
are safe for concurrent use, and that Strategy implementations must be
thread-safe.

* Add metadata validation to AuthenticateRequest

Call strategy.Validate() before strategy.Authenticate() to catch invalid
or malicious metadata early. This prevents type confusion, injection
attacks, and panics from invalid metadata in strategy implementations.

Changes:
- Add Validate() call in AuthenticateRequest()
- Proper error wrapping with strategy name
- Add test verifying validation is enforced
- Update existing tests to expect Validate() calls

* Add Claims-to-Identity conv... (continued)

189 of 278 new or added lines in 11 files covered. (67.99%)

21029 of 44049 relevant lines covered (47.74%)

38.12 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
2
94.12
pkg/vmcp/auth/auth.go
4
35.67
1.26% pkg/transport/proxy/transparent/transparent_proxy.go
6
65.18
-0.86% pkg/vmcp/server/server.go
15
0.0
0.0% cmd/vmcp/app/commands.go
24
62.5
pkg/vmcp/auth/incoming_factory.go
38
0.0
pkg/vmcp/auth/mocks/mock_strategy.go
Jobs
ID Job ID Ran Files Coverage
1 19029892023.1 03 Nov 2025 09:34AM UTC 336
47.74
GitHub Action Run
Source Files on build 19029892023
  • Tree
  • List 336
  • Changed 7
  • Source Changed 4
  • Coverage Changed 7
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #19029892023
  • db9a6f5c on github
  • Prev Build on main (#19029085415)
  • Next Build on main (#19029992771)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc