# How can I encrypt the data stored in indexes?

**URL:** https://discuss.elastic.co/t/how-can-i-encrypt-the-data-stored-in-indexes/315691
**Category:** Kibana
**Tags:** kibana-plugin-development
**Created:** [October 3, 2022, 2:05pm UTC](https://discuss.elastic.co/t/how-can-i-encrypt-the-data-stored-in-indexes/315691 "2022-10-03T14:05:06Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)
#### Post date: [October 4, 2022, 12:39pm UTC](https://discuss.elastic.co/t/how-can-i-encrypt-the-data-stored-in-indexes/315691/5 "2022-10-04T12:39:59Z")

</div>

> [@Sheereen](#):
>
> Data-in-transit encryption is there in ES

Yes, you have encrypted communications between elasticsearch nodes and clients.

> [@Sheereen](#):
>
> Data-at-rest encryption can be implemented in 2 ways:  
> a. Manually encrypting data before indexing and decrypting on retrieval  
> b. Using OS level encryption (dm-crypt)

That's right, if you want to store encrypted data in elasticsearch you will need to encrypt it before you store it or use a OS level encryption.

The OS level encryption is transparent for Elasticsearch and any other software in the system, so if you store a sensitive information in plain text, everyone who is authorized to query on that field will be able to see that information.

What that kind encryption do is to protect your data if your disk is powered off and removed from the system, while it is powered on and in the system, everyone with access to the system may be able to see it.

You can read more about it [here](https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/security_hardening/encrypting-block-devices-using-luks_security-hardening), [here](https://www.linux.com/training-tutorials/how-encrypt-linux-file-system-dm-crypt/#:~:text=The%20dm-crypt%20system%20sits,of%E2%80%9D%20the%20encrypted%20LUKS%20format.) and [here](https://discuss.elastic.co/t/how-should-i-encrypt-data-at-rest-with-elasticsearch/96).

---

_[View the full topic](https://discuss.elastic.co/t/how-can-i-encrypt-the-data-stored-in-indexes/315691)._
