Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):
2.15.0
Describe the issue:
I’m using openID to integrate azure entra id login with opensearch dashboards. Login works fine but after 1 hour I get 401 unathorized and I’m returned to opensearch dashboards login screen. After I click “Log in with single sign-on” I’m instantly logged in back without typing password or anything which means my azure session didn’t expire but opensearch one did.
E.g. request that get 401 unauthorized:
- POST https://example.com/api/ism/accountInfo gets 401 Unauthorized
I tried chaning various configs like plugins.security.cache.ttl_minutes to 180 and 0 but nothing helped.
I also checked [FEATURE] Support custom SAML headers for expiry time · Issue #4046 · opensearch-project/security · GitHub and it looks like issue is fixed but I just can’t make it work.
Any suggestions would be great.
Configuration:
opensearch_dashboards.yml:
opensearch_security.cookie.secure: false
opensearch_security.cookie.ttl: 86400000
opensearch_security.session.ttl: 86400000
opensearch_security.session.keepalive: true
opensearch_security.openid.refresh_tokens: true
opensearch.requestHeadersWhitelist: ["Authorization", "securitytenant"]
opensearch_security.auth.multiple_auth_enabled: true
opensearch_security.auth.type: ["openid", "basicauth"]
opensearch_security.openid.connect_url: "https://login.microsoftonline.com/REDACTED/v2.0/.well-known/openid-configuration"
opensearch_security.openid.client_id: "REDACTED"
opensearch_security.openid.client_secret: "REDACTED"
opensearch_security.openid.base_redirect_url: "https://example.com"
opensearch-security/config.yml
openid_auth_domain:
http_enabled: true
transport_enabled: true
order: 0
http_authenticator:
type: openid
challenge: false
config:
enable_ssl: true
pemtrustedcas_filepath: /etc/opensearch/ssl/DigiCertGlobalRootCA.crt.pem
verify_hostnames: false
subject_key: preferred_username
roles_key: roles
openid_connect_url: https://login.microsoftonline.com/REDACTED/v2.0/.well-known/openid-configuration
authentication_backend:
type: noop
opensearch.yml
plugins.security.cache.ttl_minutes: 0