I tried to use elasticsearch-certutil for making a ssl key and cert file, but it's failed. can't make a key and cert file using elasticsearch-certutil command. So I used openssl command.
Could you give me an example of ealsticsearch-certutil for making a key and a cert file? I tried to do several times. can't make it.
I tried to do like this
$ ./elasticsearch-certutil ca
Please enter the desired output file [elastic-stack-ca.p12]: elastic-stack-ca.p12
Enter password for elastic-stack-ca.p12 :
$ ls /home/phil/elasticsearch-7.1.1/elastic-stack-ca.p12
/home/phil/elasticsearch-7.1.1/elastic-stack-ca.p12
$ ./elasticsearch-certutil cert --ca /home/phil/elasticsearch-7.1.1/elastic-stack-ca.p12
Enter password for CA (/home/phil/elasticsearch-7.1.1/elastic-stack-ca.p12) :
Please enter the desired output file [elastic-certificates.p12]:
Enter password for elastic-certificates.p12 :
$ bin/kibana
log [01:13:06.046] [fatal][root] Error: error:0906D06C:PEM routines:PEM_read_bio:no start line
at Object.createSecureContext (_tls_common.js:113:17)
at Server (_tls_wrap.js:870:27)
at new Server (https.js:62:14)
at Object.createServer (https.js:85:10)
at module.exports.internals.Core._createListener (/home/phil/kibana-7.1.1-linux-x86_64/node_modules/hapi/lib/core.js:491:79)
at new module.exports.internals.Core (/home/phil/kibana-7.1.1-linux-x86_64/node_modules/hapi/lib/core.js:112:30)
at new module.exports (/home/phil/kibana-7.1.1-linux-x86_64/node_modules/hapi/lib/server.js:25:18)
at Object.createServer (/home/phil/kibana-7.1.1-linux-x86_64/src/core/server/http/http_tools.js:75:20)
at HttpServer.start (/home/phil/kibana-7.1.1-linux-x86_64/src/core/server/http/http_server.js:40:36)
at HttpService.start (/home/phil/kibana-7.1.1-linux-x86_64/src/core/server/http/http_service.js:46:38)
FATAL Error: error:0906D06C:PEM routines:PEM_read_bio:no start line
I found useful information at the Elasticsearch blog page above.
Publicly trusted authorities have very strict standards and auditing practices to ensure that a certificate is not created without validating proper identity ownership. For the purpose of this blog post, we will create a self-signed certificate for Kibana (meaning the generated certificate was signed by using its own private key). Due to clients(Web Browsers) not trusting self-signed Kibana certificates, you will see a message similar to the following in your Kibana logs, until proper trust is established by using certificates generated by an enterprise or public CA (here's the link to the issue in the Kibana repo). This issue does not affect your ability to work in Kibana:
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.