# Can Kibana use the encrypted private key for SSL?

**URL:** https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090
**Category:** Kibana
**Created:** [May 9, 2018, 3:06am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090 "2018-05-09T03:06:58Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![nxthuong](https://avatars.discourse-cdn.com/v4/letter/n/3d9bf3/32.png) [@nxthuong](https://discuss.elastic.co/u/nxthuong)
#### Post date: [May 9, 2018, 3:06am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/1 "2018-05-09T03:06:58Z")

</div>

Hi all,

Is there any ways to use the encrypted private key for SSL in Kibana? Encrypted private key can be stored in Windows Certificate Store, then Kibana can retrieve the key from that to use.  
Currently, I use the decrypted private key. But my system admin don't want it because private key can be stolen and use to fake our site by attacker.

Thanks

---

<div class="post-metadata">

### Author: ![Dvikas](https://avatars.discourse-cdn.com/v4/letter/d/a9adbd/32.png) [@Dvikas](https://discuss.elastic.co/u/Dvikas)
#### Post date: [May 9, 2018, 6:20am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/2 "2018-05-09T06:20:59Z")

</div>

Do you want to create ssl layer between user and kibana?I mean [https://localhost:5601](https://localhost:5601)

---

<div class="post-metadata">

### Author: ![nxthuong](https://avatars.discourse-cdn.com/v4/letter/n/3d9bf3/32.png) [@nxthuong](https://discuss.elastic.co/u/nxthuong)
#### Post date: [May 9, 2018, 6:23am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/3 "2018-05-09T06:23:39Z")

</div>

Yes, SSL for client access.

---

<div class="post-metadata">

### Author: ![Dvikas](https://avatars.discourse-cdn.com/v4/letter/d/a9adbd/32.png) [@Dvikas](https://discuss.elastic.co/u/Dvikas)
#### Post date: [May 9, 2018, 12:45pm UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/4 "2018-05-09T12:45:36Z")

</div>

you can very well do that.create two certificates one certificate and other its key.and provide the path-the below config lines are already in kibana.server.ssl.enabled: true  
server.ssl.key: /path/to/your/server.key  
server.ssl.certificate: /path/to/your/server.crt

##if you want some already generated certificates

1. check for openssl version  
cmd to run= openssl version
2. cmd to run = keytool  
Which should print a list of available keytool commands. If this is not the case, check your JDK installation and make sure the keytool is on your PATH.  
3)go to this path and download it : [https://github.com/floragunncom/search-guard-ssl/tree/es-6.0.0](https://github.com/floragunncom/search-guard-ssl/tree/es-6.0.0)  
4)The script to execute is ./example.sh, located in the folder example-pki-scripts.  
5)If for any reason you need to re-execute the script, execute ./clean.sh in the same directory first. This will remove all generated files automatically.
3. there you can find kibana certificates.copy kibana.pem and kibana.key and keep it in kibana directory.Provide the path in the above config lines mentioned.I am sure you can do this.It will work very well.

---

<div class="post-metadata">

### Author: ![nxthuong](https://avatars.discourse-cdn.com/v4/letter/n/3d9bf3/32.png) [@nxthuong](https://discuss.elastic.co/u/nxthuong)
#### Post date: [May 10, 2018, 12:33am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/5 "2018-05-10T00:33:33Z")

</div>

I'm able to enable SSL for Kibana, but I must use the decrypted key.  
Is your solution can use encrypted key?

---

<div class="post-metadata">

### Author: ![Dvikas](https://avatars.discourse-cdn.com/v4/letter/d/a9adbd/32.png) [@Dvikas](https://discuss.elastic.co/u/Dvikas)
#### Post date: [May 10, 2018, 6:19am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/6 "2018-05-10T06:19:23Z")

</div>

yup sure

---

<div class="post-metadata">

### Author: ![nxthuong](https://avatars.discourse-cdn.com/v4/letter/n/3d9bf3/32.png) [@nxthuong](https://discuss.elastic.co/u/nxthuong)
#### Post date: [May 10, 2018, 8:31am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/7 "2018-05-10T08:31:19Z")

</div>

Great. I will try it.

Thanks Vikas 🙂

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [June 7, 2018, 8:31am UTC](https://discuss.elastic.co/t/can-kibana-use-the-encrypted-private-key-for-ssl/131090/8 "2018-06-07T08:31:25Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
