Back to Checks
Pending Claude organization invitation is within the documented maximum age
identity_pending_invites_not_stale
Service: identitySeverity: low
OfficialVerifiedPrivate
Categories:gen-aiidentity-access
Resource Type:ClaudeInvite
Unaccepted invitations are revoked rather than left open. A long-open invitation is a standing offer of membership to a mailbox nobody is watching.
Risk
A long-open invitation is a standing offer of membership to a mailbox nobody is watching.
Run this check with Prowler
Run in Prowler CloudInstall
pip install --extra-index-url https://__token__:${PROWLER_REGISTRY_DOWNLOAD_API_KEY}@registry.prowler.com/simple/ "prowler-provider-claude[runtime]"Run
prowler claude --checks identity_pending_invites_not_staleRecommendation
Revoke invitations that were not accepted promptly and re-issue them when needed.
Remediation
Other
1Revoke invitations that were not accepted promptly and re-issue them when needed.
Check Code
from prowler.lib.check.models import Check
from prowler_provider_claude.lib.dates import age_in_days
from prowler_provider_claude.lib.report import CheckReportClaude
from prowler_provider_claude.services.identity.identity_client import identity_client
class identity_pending_invites_not_stale(Check):
"""Unaccepted invitations are revoked rather than left open."""
def execute(self) -> list[CheckReportClaude]:
maximum = identity_client.audit_config.get("claude_max_invite_age_days", 7)
findings = []
for invite in [i for i in identity_client.invites if i.status == "pending"]:
age = age_in_days(invite.invited_at)
if age is None:
continue
report = CheckReportClaude(metadata=self.metadata(), resource=invite)
if age <= maximum:
report.status = "PASS"
report.status_extended = (
f"Invitation to {invite.email} has been pending for {age} day(s), within "
f"the documented maximum of {maximum}."
)
else:
report.status = "FAIL"
report.status_extended = (
f"Invitation to {invite.email} has been pending for {age} day(s), longer "
f"than the documented maximum of {maximum}."
)
findings.append(report)
return findings