I have coded a REST api which basically inserts, gets and updates the data from Elasticsearch. After implementing the basic security when I pass a curl command to the api providing credentials along with it (using -u), I get the following error:
[type=security_exception, reason=unable to authenticate user [a] for REST request]
Any idea how to pass the credentials to the REST api so that the same can pass it to Elasticsearch?
I am using version 6.8.16.
@dadoonet The code is there in many files and is very long. So I don't think it will be feasible to share the code.
Basically the api builds the query from the curl command which is passed to it in some manner. After building the query it calls Elasticsearch with the built query.
I hope it helps in some way.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.