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

stacklok / toolhive / 21410526608 / 1
61%
main: 61%

Build:
DEFAULT BRANCH: main
Ran 27 Jan 2026 07:18PM UTC
Files 477
Run time 10s
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

27 Jan 2026 07:11PM UTC coverage: 60.178% (-0.04%) from 60.215%
21410526608.1

push

github

web-flow
Add configurable UserInfo field mapping and UserInfo support for authserver's OAuth provider (#3466)

Add configurable UserInfo field mapping and UserInfo support for OAuth2 provider

Enhance UserInfoFieldMapping to support ordered fallback field chains,
enabling compatibility with non-standard OAuth providers like GitHub that
use different claim names (e.g., "id" instead of "sub").

Changes:
- Replace single field names with ordered lists (SubjectFields, NameFields, EmailFields)
- Add ResolveField() helper with support for numeric ID conversion
- Add ResolveSubject/ResolveName/ResolveEmail methods with defaults
- Implement UserInfoProvider interface on BaseOAuth2Provider
- Support additional headers for provider-specific requirements (e.g., GitHub API versioning)
- Add JSON/YAML struct tags for file-based configuration support

Example YAML configuration for GitHub:
```
upstream:
  client_id: "my-app"
  client_secret: "secret"
  redirect_uri: "http://localhost:8080/callback"
  authorization_endpoint: "https://github.com/login/oauth/authorize"
  token_endpoint: "https://github.com/login/oauth/access_token"
  scopes:
    - user:email
  userinfo:
    endpoint_url: "https://api.github.com/user"
    additional_headers:
      X-GitHub-Api-Version: "2022-11-28"
    field_mapping:
      subject_fields: ["id", "login"]
      name_fields: ["name", "login"]
      email_fields: ["email"]
```

38421 of 63846 relevant lines covered (60.18%)

78.05 hits per line

Source Files on job 21410526608.1
  • Tree
  • List 477
  • Changed 7
  • Source Changed 2
  • Coverage Changed 7
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 21410526608
  • 2df1a150 on github
  • Prev Job for on main (#21409738390.1)
  • Next Job for on main (#21428413335.1)
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

© 2026 Coveralls, Inc