<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
How to Generate 2 Year SAML Signing Certificate
Single Sign-On
Okta Classic Engine
Okta Identity Engine
Overview

This guide illustrates utilizing the Okta Postman API collection to generate a 2-year SAML Signing Certificate, an alternative to the standard 10-year SAML Signing Certificate. 

Applies To
  • Security Assertion Markup Language (SAML)
  • Signing Certificate
Solution

Prerequisites

Steps

  1. Run the List Apps request from the Okta Postman Apps collection.
    1. Navigate to Apps > Feature Operations > Get List Apps.
    2. Use the below call:
      GET {{url}}/api/v1/apps  > Send

API Call to get the appid

NOTE: Find the AppId in the response body and record it, or collect the AppId from accessing the app in the Okta Admin UI and copying it out of the browser URL.

  1. Run the Generate Certificate request from the Okta Postman Apps collection.
    1. Navigate to Apps > Certificate Operations > Post Generate Certificate.
    2. Use the below API call, making sure to insert the AppId from the record above in {{appId}}, and enter years in {{validityYears}}.
      POST {{url}}/api/v1/apps/{{appId}}/credentials/keys/generate?validityYears={{validityYears}} 
    1. Click Send.

Api Call to generate certificate

  1. Go to Okta Admin UI > Specific App > Sign On > Activate the new SAML Signing Certificate.
  2. Upload new SAML Signing Certificate to App \ Service Provider, which can be done in multiple ways:
    • By viewing the SAML Setup Instructions under the Sign On tab and then downloading the certificate.
    • By providing the IdP metadata to the SP provider, saved as an XML file.
    • Download the new certificate from Okta Admin App UI > SAML Signing Certificates > Actions > Download Certificate or View IdP metadata and save it as an XML file.

 

NOTE: If the "errorSummary": "Validity years out of range. It should be 2 - 10 years" error is encountered, keep in mind this is hardcoded.

 

Related References

 

Loading
How to Generate 2 Year SAML Signing Certificate