Docs/SSO Configuration/Okta (OIDC)

Okta (OIDC) Setup

Step-by-step guide to configure Single Sign-On with Okta using OpenID Connect.

Prerequisites

  • Okta admin account
  • SecureCodingHub org admin account

Step 1 — Create an Okta Application

1

Go to Okta Admin ConsoleApplicationsCreate App Integration

2

Sign-in method: OIDC

3

Application type: Web Application

4

App name: SecureCodingHub

5

Sign-in redirect URI: https://api.securecodinghub.com/api/sch/auth/sso/callback/oidc

6

Assignments: Assign to your users/groups

Step 2 — Copy Credentials

Collect the following values from your Okta application:

SettingWhere to Find
Client IDGeneral → Client Credentials
Client SecretGeneral → Client Credentials
Okta DomainYour Okta URL (e.g. dev-12345.okta.com)
Discovery URLhttps://{okta-domain}/.well-known/openid-configuration

Step 3 — Configure SSO in SecureCodingHub

1

Log in as Org Admin → SSO Settings

2

Protocol: OIDC

3

Entity ID / Client ID: paste your Okta Client ID

4

Discovery / Metadata URL: paste your Okta OpenID configuration URL

5

Client Secret: paste the secret

6

Enable SSO

7

Click Save

app.securecodinghub.com/admin/sso
SSO Configuration
OIDC
0oa1b2c3d4e5f6g7h8i9
https://dev-12345.okta.com/.well-known/openid-configuration
••••••••••••••••
Save

Step 4 — Test

1

Open an incognito/private browser window

2

Go to SecureCodingHub login

3

Enter an email address with your organization's domain

4

You should be redirected to Okta login

5

After authentication, you should be logged into SecureCodingHub

Tip: If you use Okta groups, you can assign the SecureCodingHub app to a group so all members get access automatically. Combined with JIT provisioning, new group members are created in SecureCodingHub on first login.

Common Okta SAML pitfalls

Although this guide focuses on OIDC, many Okta tenants run SecureCodingHub over SAML, and the same Okta-specific issues recur. The first is an audience URI mismatch. Okta calls this field Audience URI (SP Entity ID) in the SAML General Settings, and the value must match exactly what SecureCodingHub publishes as its entity ID. A common mistake is to enter the SecureCodingHub website URL rather than the API entity ID. Verify the value against the SP Entity ID field in the SecureCodingHub SSO Settings page before saving the Okta application.

The second pitfall is the Okta app sign-on policy. Okta applies an application-level policy that can require additional factors, restrict by network zone, or deny access entirely based on group membership. If an end user reports that SSO redirects them to Okta and then bounces back with an access-denied error, the cause is almost always an app sign-on policy rule that does not match the user. Check Sign On Policy under the application and confirm the rule that applies to the test user. The third common pitfall is mismatched Name ID format. Okta defaults to Unspecified, but SecureCodingHub expects emailAddress format. Set Name ID format to EmailAddress in the application settings and confirm the source attribute is user.email or user.login.

How to verify SSO is working end-to-end

Verification starts in an incognito browser session to avoid any cookies from prior logins. Navigate to the SecureCodingHub login page, enter a corporate email address with your verified domain, and confirm the browser redirects to your Okta tenant. After authenticating at Okta, the redirect should land you in SecureCodingHub on the dashboard for the correct organization. If you land on a generic landing page or a 404, the most likely cause is that the user does not yet exist in SecureCodingHub and JIT provisioning is disabled or rejected the create event.

Second, verify role and seat assignment. The JIT-provisioned user lands with the default Learner role. If your tenant uses role mapping from Okta group claims, validate that the expected groups appear in the user profile. Third, sign out, then sign back in. The second login should be near-silent thanks to the Okta session cookie. If the second login forces a full re-authentication, the Okta session lifetime is set too short for normal use; adjust the global session policy or the application sign-on policy accordingly. For protocol-level details, see the SAML setup guide.