Resolution
The Client Secret for the Octopus app registration in Microsoft EntraID may have expired and you will need to generate a new one and re-enter that in Octopus to allow users to logon again.
Symptom
Note - This article only applies if multiple Octopus users try to logon with Microsoft EntraID and all of them are presented with the error below. If this is only happening to one user, please contact support@octopus.com, and we can investigate the issue for that one user.
Could not authenticate against identity provider. Please check your configuration
If you are on our self-hosted Octopus Server version you will see this in your Octopus Server Logs (to find if it is in your logs, you can perform a search on the latest server log and check for AADSTS7000222):
Authentication error from identity provider. Status Code: 401. Message: {"error":"invalid_client","error_description":"AADSTS7000222: The provided client secret keys for app '<APP_ID>' are expired. Visit the Azure portal to create new keys for your app: https://aka.ms/NewClientSecret, or consider using certificate credentials for added security: https://aka.ms/certCreds. Trace ID: <id> Correlation ID: <id> Timestamp: <timestamp>","error_codes":[7000222],"timestamp":"<timestamp>","trace_id":"<id>","correlation_id":"<id>","error_uri":"https://login.microsoftonline.com/error?code=7000222"}
You will not see the second error in the logs if you are on our Octopus Cloud subscription, as you are unable to see your Cloud server logs. If you are seeing the first error and you are on our Octopus Cloud offering please email support@octopus.com and we can check your Octopus Server logs to see if the second error message is shown.
Scope: when this is the right article
If multiple Octopus users try to log in to Octopus with Microsoft EntraID and all of them are presented with this error: Could not authenticate against identity provider. Please check your configuration. If this is only happening to one user please contact support@octopus.com and we can investigate the issue for that one user.
Cause
The Client Secret for the Octopus app registration in Microsoft EntraID may have expired and you will need to generate a new one and re-enter that in Octopus to allow users to logon again.
Diagnosis and fix
For Octopus Server Customers:
-
Identify if the error is related to an expired Client secret by checking your Octopus Server Logs for the error
AADSTS7000222. -
If that error is in your Octopus Server logs you will need to generate a new client secret for the app registration setup for Octopus in Microsoft Azure.
-
Once you have that generated, you have one of two options to apply the new client secret into Octopus:
-
The first option is to use the
Octopus.Server.exe configurecommand in our documentation on Setting the Client ID, Client secret and Issuer in Octopus Deploy (which is shown in the box in that section). To perform that command you will need to have access to the machine hosting Octopus, be able to run the command prompt and be able to access the folder where you installed Octopus - by default that isC:\Program Files\Octopus Deploy\Octopuson Windows. For Linux you will need the ability toDocker Execinto the Octopus container and run a terminal. -
The second option is you will need to log in to the Octopus UI using a local administrator account.
-
If you do not have a local administrator account you will need to:
-
If it is not enabled already, ensure you have enabled username and password authentication in Octopus. Our documentation here goes into detail on how to do that.
- Once username and password authentication is enabled in Octopus, you can then follow our documentation on how to reset and re-enable the local Administrator account in Octopus. The
octopus.server.exefile can be found in the folder where you installed Octopus (by default, on Windows that isC:\Program Files\Octopus Deploy\Octopus) so you will need to ensure your command line or terminal points to that folder when you execute the commands. - Once you have reset and re-enabled the Local Octopus Administrator account, you should then be able to navigate to your Octopus UI and type in the administrator's username and password that you used in the bullet point above when you ran the command.
- Once you are logged in you can then re-enter the new Client Secret into Octopus from the Configuration ➜ Settings ➜ Azure AD menu and save the changes.
-
For Octopus Cloud Customers:
If you see the Could not authenticate against identity provider. Please check your configuration error when logging into Octopus Cloud please contact Support@octopus.com and we can verify if the issue is related to the client secret having expired. Once Octopus Support have confirmed that, you will need to:
- Generate a new client secret for the app registration setup for Octopus in Microsoft Azure.
- Logon to Octopus with an administrator account using the OctopusID button. If you are unsure of who has an Administrator account using OctopusID please ask Support and we can point you to who your administrators are.
- Once you are logged in you can then re-enter the new Client Secret into Octopus from the Configuration ➜ Settings ➜ Azure AD menu and save the changes.
Verify
Once you have renewed your Client Secret in Azure, inputted that into Octopus and saved the new Client Secret you should be able to logon again using Microsoft EntraID. Please contact support@octopus.com if you still are unable to logon.