Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SAML Metadata URL did not connect and pull data successfully #27072

Open
jianlinz opened this issue May 20, 2024 · 6 comments
Open

SAML Metadata URL did not connect and pull data successfully #27072

jianlinz opened this issue May 20, 2024 · 6 comments
Labels
Awaiting Submitter Action Blocked on the author

Comments

@jianlinz
Copy link

jianlinz commented May 20, 2024

Summary

The SAML integrated Keycloak Identity Provider Metadata URL authentication fails

Steps to reproduce

  • Configure keycloak and mattermost based on the following addresses

  • get keycloak /realm-settings->SAML 2.0 Identity Provider Metadata URL

  • mattermost/admin_console/authentication/saml ->Identity Provider Metadata URL-> SAML 2.0 Identity Provider Metadata URL

  • click button 'Get SAML Metadata From IdP'

  • show error message - > SAML Metadata URL did not connect and pull data successfully

  • mattermost log

{"timestamp":"2024-05-20 15:16:16.491 Z","level":"debug","msg":"Failed to obtain metadata from Identity Provider URL.","caller":"web/context.go:113","path":"/api/v4/saml/metadatafromidp","request_id":"fenypptth3ytbn4gnw3b7bmjxw","ip_addr":"172.31.0.4","user_id":"ir6wr7fpo38ytyhuo8xrw7uy9y","method":"POST","err_where":"getSamlMetadataFromIdp","http_code":400,"error":"getSamlMetadataFromIdp: Failed to obtain metadata from Identity Provider URL., FetchSamlMetadataFromIdp: Could not read the response received from the Identity Provider., Get \"https://***/realms/mattermost/protocol/saml/descriptor\": address forbidden, you may need to set AllowedUntrustedInternalConnections to allow an integration access to your internal network"}

Expected behavior

successfully

Observed behavior (that appears unintentional)

SAML Metadata URL did not connect and pull data successfully

Possible fixes

Since these Settings are the most basic Settings, can you tell me if I did something wrong and I understand that success should be displayed at least in this step.
The SAML 2.0 Identity Provider Metadata URL is accessible from a browser.

@amyblais
Copy link
Member

@jianlinz What Mattermost server version are you on?

@jianlinz
Copy link
Author

jianlinz commented May 22, 2024

@jianlinz What Mattermost server version are you on?
Hi
mattermost 8.1.9
keycloak 22.0.5

Thanks

@amyblais
Copy link
Member

Thank you, given that v8.1 has gone out of support on May 15th, would you be open to upgrading to v9.5 or a newer version to see if the issue still reproduces?

@amyblais amyblais added the Awaiting Submitter Action Blocked on the author label May 22, 2024
@jianlinz
Copy link
Author

Thank you, given that v8.1 has gone out of support on May 15th, would you be open to upgrading to v9.5 or a newer version to see if the issue still reproduces?

ok ,I'll switch to version 9.8 and try it out

@jianlinz
Copy link
Author

jianlinz commented May 23, 2024

mattermost 9.8
keycloak 22.0.5
Still reporting the same anomaly

I also tried to integrate keycloak with OpenId.
The exception is -> tls: failed to verify certificate: x509: certificate signed by unknown authority
I confirm that all my certificates are tls certificates issued by ca

I also tried to integrate openId with gitlab
The exception is -> tls: failed to verify certificate: x509: certificate signed by unknown authority

integrate openId with keycloak4.5
The exception is -> invalid character '<' looking for beginning of value

Can you tell me what I did wrong?
@amyblais

@amyblais
Copy link
Member

Would you be open to posting about this on one of our troubleshooting forums, either at https://community.mattermost.com/core/channels/peer-to-peer-help or at https://forum.mattermost.com/?

@amyblais amyblais added Awaiting Submitter Action Blocked on the author and removed Awaiting Submitter Action Blocked on the author labels May 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Submitter Action Blocked on the author
Projects
None yet
Development

No branches or pull requests

2 participants