Skip to content

Commit 3e496c7

Browse files
docs: update README to reflect correct API behavior
Updated documentation to accurately reflect that the GitHub organization membership API works for both public and private members: - Removed outdated 'public membership only' limitations - Updated API behavior section with correct HTTP 204 response - Removed instructions for making membership public (not needed) - Updated security considerations to reflect broader member support The implementation now correctly works for all dotCMS organization members without requiring any configuration changes. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent c360528 commit 3e496c7

File tree

1 file changed

+9
-17
lines changed
  • .github/actions/security/org-membership-check

1 file changed

+9
-17
lines changed

.github/actions/security/org-membership-check/README.md

Lines changed: 9 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ This composite action checks if a GitHub user is a member of the dotCMS organiza
55
## Security Features
66

77
- **Hardcoded Organization**: The organization name "dotCMS" is hardcoded and cannot be overridden
8-
- **Public Membership Only**: Only detects public organization members for security
9-
- **Clear Instructions**: Provides guidance for private members to make membership public
8+
- **All Organization Members**: Detects both public and private organization members
9+
- **Simple Token Usage**: Uses default GITHUB_TOKEN without additional secrets
1010
- **Graceful Error Handling**: Returns clear status without exposing internal API details
1111

1212
## Inputs
@@ -40,27 +40,19 @@ This composite action checks if a GitHub user is a member of the dotCMS organiza
4040
4141
The action uses the GitHub CLI (`gh`) with the repository's `GITHUB_TOKEN` to check organization membership via the GitHub API endpoint `GET /orgs/dotCMS/members/{username}`.
4242

43-
**Important Limitation: Public Membership Only**
43+
**API Behavior**
4444

45-
This approach only detects users with **public** organization membership:
45+
The GitHub organization membership API works for both public and private members:
4646

47-
- **HTTP 200 + user object**: User is a PUBLIC member → **AUTHORIZED**
48-
- **HTTP 404**: User has private membership OR is not a member → **BLOCKED**
47+
- **HTTP 204 No Content**: User is a member (public or private) → **AUTHORIZED**
48+
- **HTTP 404 Not Found**: User is not a member → **BLOCKED**
4949

50-
**For dotCMS Team Members with Private Membership:**
51-
52-
If you are a dotCMS organization member but have private membership visibility, you must make your membership public to access Claude workflows:
53-
54-
1. Visit: https://github.com/orgs/dotCMS/people
55-
2. Find your username in the list
56-
3. Click "Make public" next to your name
57-
58-
This ensures the security gate can detect your organization membership without requiring additional API tokens.
50+
This approach successfully detects all dotCMS organization members regardless of their membership visibility setting, using only the default GITHUB_TOKEN without requiring additional secrets or configuration.
5951

6052
## Security Considerations
6153

6254
- Only checks membership in the dotCMS organization (hardcoded)
63-
- Only authorizes users with public organization membership
55+
- Authorizes all organization members (both public and private)
6456
- Logs authorization results without sensitive details
6557
- Uses default GITHUB_TOKEN (no additional secrets required)
66-
- Provides clear instructions for private members to become public
58+
- No configuration or setup required for team members

0 commit comments

Comments
 (0)