2

I intend to run an Elasticsearch index to store a persistent copy of data retrieved from an external service. My plan is to host the Elasticsearch index on AWS, and have it listen on 127.0.0.1 only. I was then intending to use a reverse proxy (nginx) to only allow search-type requests, and reject any others (e.g., updates, cluster management/stats, etc).

As I understand it, I could then do all updates locally on the box itself, and the reverse proxy would be enough security to prevent someone stomping all over my data.

So, my question is this: would a simple reverse proxy allowing/denying access based on URI be secure? What problems could I face with regards to malicious editing of data? Are there attack vectors on such a setup that I have not considered?

Note: I intend to tighten the firewall to only allow access to the proxy port, etc. The focus of this question is on the security of the reverse-proxy idea!

  • I'm not too familiar with Elasticsearch, but what kind of reverse proxy are you using? Is it something you're making / defining yourself? – James Mishra Feb 13 '15 at 13:24
  • I was planning to use Nginx. – shearn89 Feb 13 '15 at 14:01
1

Reverse proxy is one way to do it. There are some other plugins that you could put on your elasticsearch cluster that are a bit more robust:

  1. Shield - Commercial license only, elastic.co

    Shield is a plugin for Elasticsearch that enables you to easily secure a cluster. With Shield, you can password-protect your data as well as implement more advanced security measures such as encrypting communications, role-based access control, IP filtering, and auditing. This guide describes how to install Shield, configure the security features you need, and interact with your secured cluster.

  2. SearchGuard - Commercial and Free licenses, from floragunn

    Search Guard offers the same functionality as Shield, adds additional features on top, at a much lower price point and with a more flexible licensing schema. Additional features include:

    OpenSSL support Kerberos support HTTP Proxy Authentication support JSON Web token support Source code available – run your own security audits Licenses for Search Guard are based on production clusters, not nodes. That means that you can scale your cluster up- and down as necessary, without affecting the license costs. Development-, staging-, integration- and QA/AUT-systems are covered by the license as well at no additional cost.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.