[Samba] Spotlight with Elasticsearch backend authentication support?
samba-list at awen.io
Tue Mar 16 04:16:52 UTC 2021
I was looking into setting up the spotlight support with the elasticsearch backend, and I couldn't find any mention of if it might be possible to set it up with the security plugins available for elasticsearch (either elastic's x-pack  or amazon's opendistro  security). Is this supported at all and I'm just not seeing it?
If we could set the basic-auth headers with any of the requests that samba is sending off to ES, that would probably be good enough. Ideally, we could set any auth headers we wanted with those requests (say a bearer token etc). That would make it possible for me to run the ES server locally on my machine (or elsewhere) without exposing the index of all my files to anyone who could get access to the ES rest interface (like a low-priv shell user).
I think the relevant code is in mdssvc_es.c within mds_es_search_send(), but I'm not really a C developer, and I have little familiarity with the Samba codebase, so I'm not totally sure. If anyone else is interested, I'm fairly confident it would be a simple patch.
More information about the samba