Java client for security APIs

Are the security APIs API - OpenSearch documentation exposed from the java client?

Specifically my use case is to enhance a custom monitoring plugin to check if the node certificate has expired - API - OpenSearch documentation

Also with OpenSearch 1.2.4, the get certs API does know return anything, e.g.
curl -XGET -k https://hostname:9200/_opendistro/_security/api/ssl/certs

Is this is a known issue?

@ronniepg You need to authenticate to talk with the OpenSearch cluster when the security plugin is enabled.
To retrieve SSL certificates you’ll need to use the admin certificate defined in plugins.security.authcz.admin_dn in opensearch.yml file.

image

@ronniepg Is that what you’re looking for?

@pablo thanks for confirming that the admin certificate is required to get the certificate details. yes i did use the authentication - removed the credentials before posting here.

Regarding the Java APIs for the security plugin, i was wondering of there was some similar to Security APIs | Java REST Client [7.17] | Elastic

@ronniepg As far as I can see in the docs, there is no Java high-Level REST client for the OpenSearch’s security module.

You can create a feature request in the OpenSearch GitHub.

1 Like