-
Notifications
You must be signed in to change notification settings - Fork 275
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
[FEATURE] Improve error message when a node with an incorrectly configured certificate attempts to connect #4601
Comments
[Triage] Hi @ArranDengate-Netapp, thanks for filing this issue. This sounds like a good idea. Since you have already put time into investigating this issue perhaps you would like to open a pull request with the proposed change? Thank you. |
@stephen-crawford sorry, I don't have capacity at the moment! However, my colleague may create a PR for this later. |
@stephen-crawford Can you please assign this bug to me. I will work on this |
…ificate attempts to connect Updated the error message to understand what is the exact reason and renamed the API name to match the intention of API. Resolves opensearch-project#4601 Signed-off-by: Abdul Muneer Kolarkunnu <muneer.kolarkunnu@netapp.com>
…ificate attempts to connect Updated the error message to understand what is the exact reason and renamed the API name to match the intention of API. Resolves opensearch-project#4601 Signed-off-by: Abdul Muneer Kolarkunnu <muneer.kolarkunnu@netapp.com>
…ificate attempts to connect Updated the error message to understand what is the exact reason and renamed the API name to match the intention of API. Resolves opensearch-project#4601 Signed-off-by: Abdul Muneer Kolarkunnu <muneer.kolarkunnu@netapp.com>
…ificate attempts to connect Updated the error message to understand what is the exact reason and renamed the API name to match the intention of API. Resolves opensearch-project#4601 Signed-off-by: Abdul Muneer Kolarkunnu <muneer.kolarkunnu@netapp.com>
Problem
When setting up a cluster, if a node tries to join with a certificate that is not configured correctly in plugins.security.nodes_dn, OpenSearch provides an error message - "Transport client authentication no longer supported".
This is a misleading error - under this circumstance, the problem has nothing to do with the transport client.
Context of the error message
My understanding of this error message is as follows.
OpenSearch clusters have two different ports:
In the early days of Elasticsearch, there was a popular application client, the transport client, that connected on the internode port. This old method of connecting has been deprecated since ES 7.0 in 2019. It was removed in OpenSearch 2.0 (#1701). Modern application clients connect on the REST API port.
From the perspective of OpenSearch, an incoming connection on port 9300 could be coming from a node, or it could be coming from a transport client.
There is some discussion of this in issue #4401 and the linked forum posts https://forum.opensearch.org/t/transport-client-authentication-no-longer-supported-error-when-deploying-cluster-with-security-plugin-enabled/9814/5 / https://forum.opensearch.org/t/transport-client-authentication-no-longer-supported-error-while-implementing-third-party-ca-cert-for-transport-layer/19694 .
Proposed solution
I would like to make this error message clearer.
If we could distinguish between a node joining and a transport client connecting, and provide different error messages for each, that would be ideal.
If it is not easy to tell the difference from the server side, we could still add more information to the error message - something like:
"A connection was attempted on this cluster's internode communication port, but it was refused. If you are attempting to join a node to this cluster, please confirm the Distinguished Name of the new node's certificate is configured in this node's plugins.security.nodes_dn setting. If you are attempting to connect to this cluster with a transport client, please note that transport clients are no longer supported."
It would be nice to also mention the DN that was rejected - for example:
"The distinguished name of the node certificate provided was: 'CN=node.other.com,OU=SSL,O=Test,L=Test,C=DE'"
This would help the user work out what needs to be configured in plugins.security.nodes_dn .
The text was updated successfully, but these errors were encountered: