Elasticsearch Elasticsearch Disable SSL: Securing Your Cluster Without SSL/TLS

By Opster Team

Updated: Jun 22, 2023

| 2 min read

Before you dig into the details of this technical guide, have you tried asking OpsGPT?

You'll receive concise answers that will help streamline your Elasticsearch/OpenSearch operations.


Try OpsGPT now for step-by-step guidance and tailored insights into your Elasticsearch/ OpenSearch operation.

To manage all aspects of your Elasticsearch operation, you can use Opster’s Management Console (OMC). The OMC makes it easy to orchestrate and manage Elasticsearch in any K8 environment. Using the OMC you can deploy multiple clusters, configure node roles, scale cluster resources, manage certificates and more – all from a single interface, for free. Check it out here.

You can also try AutoOps for Elasticsearch. It will detect issues and improve your Elasticsearch performance by analyzing your shard sizes, threadpools, memory, snapshots, disk watermarks and more. Try it for free.

Introduction

While SSL/TLS is a widely recommended security measure for Elasticsearch clusters, there might be situations where you need to disable it temporarily or permanently. This article will guide you through the process of disabling SSL/TLS in Elasticsearch, as well as provide alternative security measures to ensure your cluster remains protected.

Disabling SSL/TLS in Elasticsearch

To disable SSL/TLS in Elasticsearch, you need to modify the configuration settings in the `elasticsearch.yml` file. Follow these steps:

1. Locate the `elasticsearch.yml` file in your Elasticsearch installation directory. The default location is `/etc/elasticsearch` on Linux systems and `%ES_HOME%\config` on Windows systems.

2. Open the `elasticsearch.yml` file in a text editor.

3. Find the following lines related to SSL/TLS configuration:

xpack.security.transport.ssl.enabled: true
xpack.security.http.ssl.enabled: true

4. Change the values from `true` to `false`:

xpack.security.transport.ssl.enabled: false
xpack.security.http.ssl.enabled: false

5. Save the changes and close the file.

6. Restart the Elasticsearch service for the changes to take effect. On Linux systems, use the following command:

sudo systemctl restart elasticsearch

On Windows systems, restart the Elasticsearch service from the Services management console.

7. Verify that SSL/TLS is disabled by checking the Elasticsearch logs or by attempting to access the Elasticsearch API without HTTPS.

Alternative Security Measures

Disabling SSL/TLS can expose your Elasticsearch cluster to potential security risks. To maintain a secure environment, consider implementing the following alternative security measures:

  1. Network Security: Restrict access to your Elasticsearch cluster by configuring firewall rules and security groups. Allow only trusted IP addresses and networks to access the cluster.
  1. Authentication and Authorization: Enable Elasticsearch’s built-in security features, such as role-based access control (RBAC), to restrict access to specific indices, documents, and API endpoints. Create user accounts with appropriate permissions and use strong, unique passwords.
  1. Encryption at Rest: Protect your data on disk by enabling encryption at rest. This can be achieved using third-party tools like dm-crypt for Linux or BitLocker for Windows.
  1. Monitoring and Auditing: Regularly monitor your Elasticsearch cluster for signs of unauthorized access or suspicious activity. Enable auditing to track user actions and detect potential security breaches.
  1. Regular Updates: Keep your Elasticsearch installation up-to-date with the latest security patches and updates. Regularly review the Elasticsearch release notes and security advisories to stay informed about potential vulnerabilities and fixes.

Conclusion

Disabling SSL/TLS in Elasticsearch can be necessary in certain situations, but it is essential to implement alternative security measures to protect your cluster. By following the steps outlined in this article, you can disable SSL/TLS and maintain a secure Elasticsearch environment. Always consider the potential risks and weigh them against the benefits before making any changes to your cluster’s security configuration.

How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?


Get expert answers on Elasticsearch/OpenSearch