Hi,
I’m running Opensearch v2.2.0 with self signed certs for the OS security plugin.
The configured ldap authc & authz in config.yml works fine and I’m able to run https REST API based querys, but since setting the “plugins.security.disabled: false” in opensearch.yml & installation of the OS dashboards security plugin - all dashboard logins fails with an
“[ConnectionError]: connect ECONNREFUSED 127.0.0.1:9200” error in /var/log/opensearch/opensearch-dashboard log.
If I set the “plugins.security.disabled: true” setting back and remove the /usr/opensearch-dashboards/plugins/securityDashboards plugin the OS Dashboards starts working again, but then REST API querys cannot run through https since it requires the security plugin
Do anyone know how to resolve this issue?
opensearch_dashboards.yml config. below,
server.host: “127.0.0.1”
opensearch.hosts: [http:/127.0.0.1:9200]
opensearch.ssl.verificationMode: none
opensearch.username: kibanaserver
opensearch.password: kibanaserver
opensearch.requestHeadersAllowlist: [authorization, securitytenant]
opensearch_security.multitenancy.enabled: false
opensearch_security.multitenancy.tenants.enable_global: true
opensearch_security.multitenancy.tenants.enable_private: true
opensearch_security.multitenancy.tenants.preferred: [“Private”, “Global”]
opensearch_security.multitenancy.enable_filter: false
opensearch_security.readonly_mode.roles: [kibana_read_only]
logging.dest: /var/log/opensearch/opensearch-dashboard.log
logging.quiet: false
server.ssl.enabled: false
opensearch.yml below,
plugins.security.ssl.transport.pemcert_filepath: ./cert/node1.pem
plugins.security.ssl.transport.pemkey_filepath: ./cert/node1-key.pem
plugins.security.ssl.transport.pemtrustedcas_filepath: ./cert/root-ca.pem
plugins.security.ssl.transport.enforce_hostname_verification: false
plugins.security.ssl.http.enabled: true
plugins.security.ssl.http.pemcert_filepath: ./cert/node1.pem
plugins.security.ssl.http.pemkey_filepath: ./cert/node1-key.pem
plugins.security.ssl.http.pemtrustedcas_filepath: ./cert/root-ca.pem
plugins.security.ssl.http.clientauth_mode: OPTIONAL
plugins.security.allow_default_init_securityindex: true
plugins.security.authcz.admin_dn:
‘CN=XX,OU=XX,O=XX,L=XX,ST=XX,C=SE’
plugins.security.nodes_dn:
‘CN=XX,OU=XX,O=XX,L=XX,ST=XX,C=SE’
plugins.security.audit.type: internal_opensearch
plugins.security.enable_snapshot_restore_privilege: true
plugins.security.check_snapshot_restore_write_privileges: true
plugins.security.restapi.roles_enabled: [“all_access”, “security_rest_api_access”]
plugins.security.system_indices.enabled: true
plugins.security.system_indices.indices: [“.plugins-ml-model”, “.plugins-ml-task”, “.opendistro-alerting-config”, “.opendistro-alerting-alert*”, “.opendistro-anomaly-results*”, “.opendistro-anomaly-detector*”, “.opendistro-anomaly-checkpoints”, “.opendistro-anomaly-detection-state”, “.opendistro-reports-", ".opensearch-notifications-”, “.opensearch-notebooks”, “.opensearch-observability”, “.opendistro-asynchronous-search-response*”, “.replication-metadata-store”]
node.max_local_storage_nodes: 3
plugins.security.disabled: false
parts of config.yml below,
basic_internal_auth_domain:
description: "Authenticate via HTTP Basic against internal users database"
http_enabled: true
transport_enabled: true
order: 0
http_authenticator:
type: basic
challenge: true
authentication_backend:
type: intern
ldap:
description: "Authenticate via LDAP or Active Directory"
http_enabled: true
transport_enabled: true
order: 4
http_authenticator:
type: basic
challenge: true
authz:
roles_from_myldap:
description: "Authorize via LDAP or Active Directory"
http_enabled: true
transport_enabled: true
authorization_backend:
type: ldap
config: