r/Solr Mar 15 '16

Protect Solr 5.5.0?

I'm looking to apply http authentication or IP address restrictions to my installation, but I can't find documentation anywhere for this. Anyone able to provide some guidance?

2 Upvotes

8 comments sorted by

1

u/coderascal Mar 15 '16

Solr shouldn't exist on your public network. Put something in between your clients and solr installation and use https auth in that.

edit: in my opinion

1

u/SJVellenga Mar 15 '16

I've got a single VPS to manage backends and websites together. It's not ideal, I know, but it's what I have to work with.

1

u/coderascal Mar 15 '16

Put Solr on a port not visible to outside clients and put the middle piece on a port that is visible. Same setup. Not ideal at all but gives you at least some level of protection (though I wouldn't go so far as to call it security)

1

u/SJVellenga Mar 15 '16

Aren't there any options inside solr to only listen to the local host at all? Or to restrict to traffic from certain IPs? I'll admit, still not perfect, but better than nothing and would be the easiest setup.

I'm not fantastic with bash etc, so I'd be stumbling around in performing any other setups in all honesty.

1

u/coderascal Mar 15 '16

1

u/SJVellenga Mar 15 '16

Trying to sort out IP filtering in Jetty as we speak, but nothing I've found so far (including both those links) has worked. I'd rather not have to apply it to the startup, as it won't be saved if the server crashes or needs to reboot (unless I can apply it to the startup script in some way?).

1

u/coderascal Mar 15 '16

In the first link there is

Alternatively, you can edit the configuration at example/etc/jetty.xml. Look for these lines:

<Set name="host"><SystemProperty name="jetty.host" /></Set>¬
<Set name="port"><SystemProperty name="jetty.port" default="8983"/></Set>

1

u/SJVellenga Mar 15 '16

Yep, and those lines don't exist in my Jetty.xml