Back to list
maronnjapan

userinfo-endpoint-reviewer

by maronnjapan

0🍴 0📅 Jan 6, 2026

SKILL.md


name: userinfo-endpoint-reviewer description: Review test cases for UserInfo Endpoint. Covers access token validation, Bearer token handling, sub claim consistency, scope-based claims, and signed responses per OIDC Core 1.0 Section 5.3.

UserInfo Endpoint Test Case Reviewer

Review test cases for UserInfo Endpoint in OpenID Connect Basic OP.

Scope

  • Feature: UserInfo Endpoint
  • Specifications: OIDC Core 1.0 Section 5.3, 5.4
  • Profile: Basic OP

Review Process

  1. Identify which UserInfo requirement the test targets
  2. Check against the checklist below
  3. Verify both success and error scenarios
  4. Ensure scope-based claim filtering is tested
  5. Report gaps with specific spec section references

Basic Requirements

CheckRequirementSpec Reference
[ ]Accept access token via Authorization header (Bearer)OIDC Core 5.3.1
[ ]Support GET methodOIDC Core 5.3.1
[ ]Support POST methodOIDC Core 5.3.1
[ ]Return sub claim (REQUIRED)OIDC Core 5.3.2
[ ]sub matches ID Token subOIDC Core 5.3.2
[ ]Return claims based on granted scopesOIDC Core 5.4

Request Format

GET Request

GET /userinfo HTTP/1.1
Host: server.example.com
Authorization: Bearer SlAV32hkKG

POST Request

POST /userinfo HTTP/1.1
Host: server.example.com
Authorization: Bearer SlAV32hkKG
Content-Type: application/x-www-form-urlencoded

Response Format

JSON Response (Default)

HTTP/1.1 200 OK
Content-Type: application/json

{
  "sub": "248289761001",
  "name": "Jane Doe",
  "given_name": "Jane",
  "family_name": "Doe",
  "email": "janedoe@example.com",
  "email_verified": true,
  "picture": "http://example.com/janedoe/me.jpg"
}

Signed Response (JWT)

CheckRequirementSpec Reference
[ ]Support RS256 signed response when requestedOIDC Core 5.3.2
[ ]Honor userinfo_signed_response_alg registrationOIDC Core 5.3.2

Subject Identifier Consistency

CheckRequirementSpec Reference
[ ]sub claim MUST be presentOIDC Core 5.3.2
[ ]sub value MUST match ID Token subOIDC Core 5.3.2
[ ]sub is stable for the userOIDC Core 5.3.2

Access Token Validation

CheckRequirementSpec Reference
[ ]Validate access tokenOIDC Core 5.3.1
[ ]Return 401 for invalid/expired tokenRFC 6750
[ ]Return 403 for insufficient scopeRFC 6750

Error Response

HTTP/1.1 401 Unauthorized
WWW-Authenticate: Bearer error="invalid_token",
  error_description="The access token expired"

Test Case Categories

Access Token Tests

  • Valid: Bearer token in Authorization header
  • Invalid: Missing Authorization header
  • Invalid: Expired access token
  • Invalid: Revoked access token
  • Invalid: Malformed token

HTTP Method Tests

  • Valid: GET request with Bearer token
  • Valid: POST request with Bearer token
  • Invalid: Other HTTP methods (PUT, DELETE, etc.)

Sub Claim Tests

  • Valid: sub present in response
  • Valid: sub matches ID Token sub
  • Invalid: sub missing from response

Scope-Based Claims Tests

  • Valid: Only requested scope claims returned
  • Valid: openid scope returns sub only
  • Valid: profile scope returns profile claims
  • Valid: email scope returns email claims
  • Valid: phone scope returns phone claims
  • Valid: address scope returns address claim

Signed Response Tests (Optional)

  • Valid: RS256 signed JWT response
  • Valid: Signature verifiable with OP's key
  • Valid: Honors registered userinfo_signed_response_alg

Scope to Claims Mapping

ScopeClaims
openidsub
profilename, family_name, given_name, middle_name, nickname, preferred_username, profile, picture, website, gender, birthdate, zoneinfo, locale, updated_at
emailemail, email_verified
addressaddress
phonephone_number, phone_number_verified

Error Responses

ConditionHTTP StatusWWW-Authenticate
Missing token401Bearer
Invalid token401Bearer error="invalid_token"
Expired token401Bearer error="invalid_token"
Insufficient scope403Bearer error="insufficient_scope"

Conformance Test IDs

Test IDFeature
OP-UserInfo-EndpointBasic UserInfo functionality
OP-UserInfo-RS256Signed UserInfo response
OP-UserInfo-HeaderBearer token in header

Review Output Format

## Test Case: [Name]
### Target Feature: UserInfo Endpoint - [specific aspect]
### Test ID: OP-UserInfo-[xxx]
### Spec Compliance:
- [x] Covers required behavior per [spec section]
- [ ] Missing: [specific requirement]
### Sub Consistency:
- [x/blank] sub matches ID Token
### Verdict: PASS / FAIL / PARTIAL
### Recommendations: [if any]

Score

Total Score

40/100

Based on repository quality metrics

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

Reviews

💬

Reviews coming soon