/security-tooling-skills:enterprise-sso-and-idp-federation-configurationfrom security-tooling-skills
Guides configuring SAML 2.0 and OIDC federation between enterprise identity providers (Okta, Azure AD/Entra ID, Keycloak) and downstream applications, including metadata exchange, attribute mapping, group-to-role provisioning (SCIM), and multi-IdP trust.
Ships in security-tooling-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Enterprise single sign-on lets a workforce authenticate once against a
central identity provider (IdP) and reach every downstream application
(a SaaS tool, an internal admin console, a Kubernetes dashboard) without
a separate password for each — but that convenience only holds up if the
federation trust between IdP and service provider (SP) is configured
correctly. A SAML assertion with the wrong NameID format, an OIDC
client with an overly permissive redirect URI, or a group-to-role
mapping that silently defaults new joiners to an admin role are not
cosmetic mistakes: they are authentication and authorization bypasses
hiding behind a working login screen. This skill covers configuring
SAML 2.0 and OIDC federation with the three IdPs most enterprises
actually run (Okta, Azure AD/Entra ID, Keycloak for self-hosted/hybrid
needs), exchanging and validating metadata, mapping IdP groups/claims to
application roles, provisioning via SCIM, and trusting a second IdP
(common after an acquisition or a multi-tenant B2B scenario). It is
distinct from cloud-iam-hardening,
which covers a cloud provider's own IAM for workload/service identity —
this skill is squarely about workforce identity reaching applications
via SSO, not machine-to-machine or cloud-resource authorization.
admin in a downstream
tool), including deciding a safe default role for unmapped users.NameID/sub mismatch, or users landing with the wrong
(or no) application role after a successful login.AuthnRequests) and the IdP's
metadata XML (SSO URL, Entity ID, IdP signing certificate) — exchanged
before either side can validate the other.${OIDC_CLIENT_ID} /
${OIDC_CLIENT_SECRET}, or a public client with PKCE and no secret)
at the IdP, and clarity on which flow — Authorization Code with
PKCE for anything with a backend or a public client (SPA/mobile);
never the deprecated Implicit flow for new integrations.Exchange metadata rather than hand-typing endpoint URLs for SAML
— metadata XML captures the Entity ID, SSO/ACS URLs, NameID format,
and signing certificate in one machine-readable document, and manual
transcription is a common source of subtly wrong URLs:
<!-- IdP metadata excerpt (Okta/Azure AD/Keycloak all expose this) -->
<EntityDescriptor entityID="https://idp.example.com/app/exkabc123/sso/saml/metadata">
<IDPSSODescriptor protocolSupportEnumeration="urn:oasis:names:tc:SAML:2.0:protocol">
<KeyDescriptor use="signing">
<ds:X509Certificate>MIIDpDCCAoygAwIBAgIGAX...(truncated)</ds:X509Certificate>
</KeyDescriptor>
<SingleSignOnService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect"
Location="https://idp.example.com/app/exkabc123/sso/saml"/>
</IDPSSODescriptor>
</EntityDescriptor>
Upload this directly into the SP's "IdP metadata" field where supported, rather than copying individual fields by hand.
Configure the SP-side application in the IdP with the exact Assertion Consumer Service (ACS) URL and Entity ID/Audience the downstream application expects — a mismatched Audience is the single most common cause of a rejected assertion. Okta example (Application → SAML Settings):
Single sign-on URL (ACS): https://app.example.com/saml/acs
Audience URI (SP Entity ID): https://app.example.com/saml/metadata
Name ID format: EmailAddress
Application username: Email
Map IdP groups/attributes to application roles explicitly, and decide a safe default for anyone not matched — never default to an admin or broad-access role:
# Okta SAML attribute statements
Name: groups
Name format: Unspecified
Filter: Matches regex ^(app-admin|app-viewer|app-editor)$
# Downstream application's role-mapping config (illustrative)
role_mapping:
app-admin: admin
app-editor: editor
app-viewer: viewer
default_role: viewer # never "admin" — least privilege for unmapped users
Warning: a default role of
admin(or an implicit fallback when no group matches) silently grants elevated access to any user the IdP directory hasn't been explicitly and correctly grouped for yet — including a new-joiner whose group assignment hasn't propagated, or an off-boarded contractor whose group was removed but who still authenticates successfully. Always default new/ unmapped users to the least-privileged role, or to no access with an explicit request-access flow.
For OIDC, register the client with a tightly scoped redirect URI and Authorization Code + PKCE, not the Implicit flow:
# Azure AD / Entra ID app registration
Redirect URI: https://app.example.com/auth/callback # exact match, no wildcard
Supported account types: Single tenant (unless deliberate multi-tenant)
Allow public client flows: No # confidential client with a backend
# Token request (Authorization Code + PKCE)
POST /oauth2/v2.0/token
grant_type=authorization_code
code=<AUTH_CODE>
redirect_uri=https://app.example.com/auth/callback
client_id=${OIDC_CLIENT_ID}
client_secret=${OIDC_CLIENT_SECRET}
code_verifier=<PKCE_VERIFIER>
A redirect URI with a wildcard or an overly broad path (e.g.
https://app.example.com/*) lets an attacker who can host content
under that domain redirect the authorization code to a page they
control — scope it to the exact callback path.
Validate claims/attributes the application actually receives before trusting the integration — decode a real ID token or inspect a real SAML assertion rather than assuming the IdP config maps as expected:
# Decode an OIDC ID token's payload (no verification, inspection only)
echo "<JWT_PAYLOAD_SEGMENT>" | base64 -d | jq .
{
"sub": "00u1a2b3c4d5e6f7g8h9",
"email": "[email protected]",
"groups": ["app-editor"],
"iss": "https://idp.example.com/oauth2/default",
"aud": "0oa1a2b3c4d5e6f7g8h9",
"exp": 1735689600
}
Confirm iss/aud (OIDC) or Issuer/Audience (SAML) match exactly
what the application validates against — a same-looking but
trailing-slash-different issuer URL is a real, easy-to-miss mismatch.
Set up SCIM provisioning so directory changes (new hire, role change, termination) propagate automatically instead of relying on someone remembering to update the downstream app manually:
POST /scim/v2/Users
Authorization: Bearer ${SCIM_BEARER_TOKEN}
Content-Type: application/scim+json
{
"schemas": ["urn:ietf:params:scim:schemas:core:2.0:User"],
"userName": "[email protected]",
"active": true,
"emails": [{ "value": "[email protected]", "primary": true }],
"groups": [{ "value": "app-editor" }]
}
Confirm the IdP is configured to push a deactivation (active: false via PATCH) on termination, not just creation on hire — SCIM
deprovisioning is the half of the integration most often left
untested until an offboarding audit finds a terminated employee still
able to log in.
Federate a second IdP without disrupting the first, scoping each IdP's trust to a specific domain/tenant or Identity Provider Routing Rule rather than a single ambiguous trust anyone could authenticate through:
# Okta: Identity Provider Routing Rule
IF user's email domain = "acquired-co.com"
THEN route to IdP: acquired-co-azuread
ELSE route to IdP: primary-okta
Test the routing rule against both domains before rollout — an incorrectly ordered or overlapping rule can silently route a subset of the existing workforce to the wrong (or a not-yet-fully- provisioned) IdP.
Rotate signing certificates on a scheduled, non-emergency basis and support certificate rollover without an outage — both the IdP and SP-side certificates expire, and most protocols have no automatic graceful failover:
# Configure the SP to accept two valid signing certs during rollover
# (old + new), then remove the old one only after confirming the new
# one is live and validating successfully.
Warning: letting a SAML IdP signing certificate expire unnoticed breaks every SSO login for every application trusting that IdP simultaneously — track certificate expiry as a monitored, alerted date, not something discovered when login volume drops to zero.
Symptom: A SAML login redirects back from the IdP but the application rejects the assertion with an audience/issuer mismatch error, even though "everything looks right" in the console. Fix: Compare the exact string values — including trailing slashes and http vs. https — of the SP's configured Audience/Entity ID against what the IdP actually sends in the assertion (inspect the raw SAML response, e.g. via a browser SAML-tracer extension or the application's debug log), rather than assuming visually-similar values are identical.
Symptom: A newly onboarded contractor logs in successfully and
immediately has full admin access to the application, despite never
being added to the "app-admin" IdP group.
Fix: The role-mapping configuration has a default/fallback role
set to admin (or the group filter/regex is too permissive and
unintentionally matches an unrelated group name). Set the default
role to the least-privileged option and tighten the group-matching
filter, then audit any other user currently authenticated under the
same broad default.
Symptom: An employee is terminated and removed from the IdP
directory, but can still successfully log in to a downstream
SaaS application weeks later.
Fix: SCIM deprovisioning either isn't configured for that
application, or the IdP is only pushing group/attribute updates
and not the active: false deactivation event. Verify the
application's SCIM endpoint actually receives and acts on PATCH .../Users/{id} with active: false, and add offboarding
verification as a routine, tested step — not an assumption.
Symptom: SSO for every application trusting a given IdP breaks simultaneously, all at the same time, for no apparent configuration change. Fix: The IdP's SAML signing certificate expired. This is preventable by tracking certificate expiry as a monitored date well in advance and rotating with an overlap period (both old and new certs trusted) rather than reactively after every login starts failing.
Symptom: After federating a second IdP for an acquired company, a subset of existing employees (not the acquired company's users) unexpectedly get routed to the new IdP and can't log in. Fix: The IdP routing rule's domain/condition match is too broad or ordered incorrectly (e.g. a catch-all rule evaluated before the more specific one). Test routing rules against representative emails from both populations before rollout, and order rules from most to least specific.
Scenario: Configure Okta as the primary IdP for an internal
app.example.com service via SAML, mapping Okta groups to application
roles, and adding SCIM provisioning — then federate a second IdP
(the acquired acquired-co.com's Azure AD tenant) without disrupting
existing users.
Okta SAML application setup:
Single sign-on URL (ACS): https://app.example.com/saml/acs
Audience URI (SP Entity ID): https://app.example.com/saml/metadata
Name ID format: EmailAddress
Attribute statement: groups → filter matches ^(app-admin|app-editor|app-viewer)$
Application-side role mapping (config/sso-roles.yaml):
role_mapping:
app-admin: admin
app-editor: editor
app-viewer: viewer
default_role: viewer
SCIM provisioning enabled in Okta pointed at the app's SCIM endpoint:
SCIM connector base URL: https://app.example.com/scim/v2
Bearer token: ${SCIM_BEARER_TOKEN}
Provisioning: Create, Update, Deactivate users — all three enabled
A test termination in Okta (deactivating a test user) is verified to
send a PATCH with active: false, and the application confirms the
corresponding account is locked out, before enabling this for the
full directory.
Six months later, acquired-co.com is acquired and its Azure AD
tenant needs federated access to the same application without
disrupting existing Okta-authenticated users. An Identity Provider
Routing Rule is added:
IF user's email domain = "acquired-co.com"
THEN route to IdP: acquired-co-azuread (OIDC)
ELSE route to IdP: primary-okta (SAML)
Tested against [email protected] (routes to Okta, unaffected)
and [email protected] (routes to the new Azure AD OIDC
integration, using Authorization Code + PKCE), confirming both
populations authenticate correctly before the rule goes live for all
users.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub selvarajmurugesan90/ops-engineering-skills --plugin security-tooling-skills15 skills in this plugin
/certificate-lifecycle-management-at-scaleGuides managing TLS/mTLS certificate lifecycle across many services and environments beyond a single Kubernetes cluster — enterprise CA integration (ACME private CA, Microsoft AD CS, cloud-managed private CAs), cross-service rotation automation, expiry monitoring/alerting, and CA hierarchy/trust-chain management for a mixed fleet of VMs, on-prem servers, and multiple clusters. Use when the user asks to "automate cert rotation across our whole fleet," "integrate with our enterprise CA," "why do we keep having certificate expiry outages," "design a CA hierarchy for the org," "track every certificate's expiry date across environments," or "cert-manager only covers our Kubernetes clusters, what about everything else." Distinct from cert-manager's Kubernetes-native scope — see `../../../kubernetes-platform/skills/cert-manager-tls-automation/SKILL.md`.
/falco-configuration-validationValidates Falco runtime detection rules for false-positive rate and actual firing correctness before trusting them in a channel that pages a human — running new/changed rules in log-only mode against real traffic, measuring alert volume and content, and confirming a rule fires on a deliberate positive-control trigger before promoting it to a higher-severity, paging-routed configuration. Use when the user asks to "validate this Falco rule before enabling it," "why is Falco so noisy," "test our Falco rules don't false-positive on real traffic," "review this rule set before it pages on-call," or "make sure Falco rules aren't about to be enabled in enforce/blocking mode without an audit period." Pairs with falco-runtime-threat-detection-configuration.
/falco-runtime-threat-detection-configurationGuides authoring and deploying Falco runtime threat detection rules — the eBPF/kernel-module-based syscall event stream, Falco's rule syntax (condition/output/priority), writing custom rules for a specific workload's known-good behavior, tuning noisy default rules, and wiring alerts to Falcosidekick outputs. Use when the user asks to "write a Falco rule to detect X," "why is Falco alerting on normal behavior," "detect a shell spawned inside a container at runtime," "set up Falco with eBPF instead of the kernel module," "send Falco alerts to Slack/PagerDuty," or "what's the difference between Falco and admission-control policy engines like OPA/Kyverno." Pairs with falco-configuration-validation for pre-enforcement false-positive testing.
/fortify-static-analysisGuides deep, tool-specific use of OpenText (formerly Micro Focus) Fortify Static Code Analyzer (SCA) and Fortify Audit Workbench for enterprise, on-premises static analysis — the translate/scan build workflow, Fortify Security Rulepacks, audit workbench triage (Not an Issue / Reliability / Suspicious), and how Fortify's on-prem, build-integrated model differs operationally from cloud-native SAST. Use when the user asks to "run a Fortify scan", "configure sourceanalyzer for a build", "triage findings in Fortify Audit Workbench", "integrate Fortify with Jenkins/Azure DevOps", "reduce Fortify SCA false positives", or "compare Fortify against SonarQube/Semgrep for enterprise compliance". Fortify-specific depth on the translate/scan model and enterprise workflow; for the general SAST concept see sast-integration in the devsecops domain.
/kubewarden-admission-policy-configurationGuides configuring Kubewarden as a WASM-based Kubernetes admission policy engine — installing the policy-server and controller, writing or reusing WebAssembly policies from the Kubewarden Policy Hub, ClusterAdmissionPolicy/AdmissionPolicy resources, monitor-mode rollout before enforce, and multi-language policy authoring (Rego, Rust, Go via the SDKs) as an alternative to OPA/Gatekeeper or Kyverno. Use when the user asks to "set up Kubewarden," "write a WASM admission policy," "why use Kubewarden instead of OPA/Kyverno," "reuse a policy from the Kubewarden Policy Hub," "run an admission policy in monitor mode before enforcing it," or "author a Kubernetes admission policy without writing Rego."
/owasp-zap-dast-configurationGuides deep, tool-specific configuration of OWASP ZAP (Zed Attack Proxy) for automated dynamic scanning — baseline vs. full active scan selection, the ZAP Automation Framework YAML plan, authenticated scanning via authentication scripts/contexts, and API-driven scans seeded from an OpenAPI spec. Use when the user asks to "configure a ZAP automation framework plan", "write a ZAP context file for authenticated scanning", "tune ZAP alert thresholds", "run zap-baseline vs zap-full-scan", "script ZAP login for a scan", or "seed a ZAP scan from an OpenAPI/Swagger spec". ZAP-specific depth on scan types, automation YAML, and auth scripting; for the general DAST concept and tool-agnostic workflow see dast-integration in the devsecops domain.
Other plugins' skills for the same job