# Docoment level Security not working

**URL:** <https://forum.opensearch.org/t/docoment-level-security-not-working/4898>\
**Category:** Security\
**Created:** [February 7, 2021, 8:45pm UTC](https://forum.opensearch.org/t/docoment-level-security-not-working/4898 "2021-02-07T20:45:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![HeiDri](https://avatars.discourse-cdn.com/v4/letter/h/7ba0ec/32.png) [@HeiDri](https://forum.opensearch.org/u/HeiDri)\
**Post date:** [February 7, 2021, 8:45pm UTC](https://forum.opensearch.org/t/docoment-level-security-not-working/4898/1 "2021-02-07T20:45:58Z")

</div>

Hi opendistro community , lately i’ve tried implementing the document level security feature in my dashboards but i’m stuck , i’m using the default admin user, when i configure dls it gives me this error

> [data] [elasticsearch] [version\_conflict\_engine\_exception]: [config:7.10.2]: version conflict, document already exists (current version [4])

this is my dls query :

> {  
> “bool”: {  
> “must”: { “match”: { “host.hostname”: “\*\*\*\*\*\*”}}  
> }  
> }

i’ve posted another topic about this([Document Level Security version conflict error](https://forum.opensearch.org/t/document-level-security-version-conflict-error/4840)) but nothing yet , i’m really stuck and i’ve tried a lot of things and nothing worked , any help would be appreciated guys  
thanks in advance.  
PS: i’m using the latest version of OD and ELK 7.10.2.

---

<div class="post-metadata">

**Author:** ![Anthony](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/anthony/32/9939_2.png) [@Anthony](https://forum.opensearch.org/u/Anthony)\
**Post date:** [February 10, 2021, 12:42pm UTC](https://forum.opensearch.org/t/docoment-level-security-not-working/4898/2 "2021-02-10T12:42:49Z")

</div>

@HeiDri The latest version supported by ODFE is 7.10.0, please refer to this [link](https://opendistro.github.io/for-elasticsearch-docs/version-history/)  
Therefore the plugin (assuming 1.12.0 / 7.10.0) will not be able to work with 7.10.2. Hope this answers your question

---

<div class="post-metadata">

**Author:** ![HeiDri](https://avatars.discourse-cdn.com/v4/letter/h/7ba0ec/32.png) [@HeiDri](https://forum.opensearch.org/u/HeiDri)\
**Post date:** [February 10, 2021, 12:44pm UTC](https://forum.opensearch.org/t/docoment-level-security-not-working/4898/3 "2021-02-10T12:44:23Z")

</div>

@Anthony i’ve rebuilt the plugin to make it work on ELK 7.10.2

---

<div class="post-metadata">

**Author:** ![Anthony](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/anthony/32/9939_2.png) [@Anthony](https://forum.opensearch.org/u/Anthony)\
**Post date:** [February 10, 2021, 1:22pm UTC](https://forum.opensearch.org/t/docoment-level-security-not-working/4898/4 "2021-02-10T13:22:50Z")

</div>

@HeiDri I don’t think you will be able to get the answer you are looking for as you now made a custom plugin, but the error you are getting is exactly what mismatched version of plugin would complain about.

---

<div class="post-metadata">

**Author:** ![HeiDri](https://avatars.discourse-cdn.com/v4/letter/h/7ba0ec/32.png) [@HeiDri](https://forum.opensearch.org/u/HeiDri)\
**Post date:** [February 10, 2021, 1:29pm UTC](https://forum.opensearch.org/t/docoment-level-security-not-working/4898/5 "2021-02-10T13:29:51Z")

</div>

@Anthony , thanks for the response , i found my error , it was that when setting up DLS for all indices (“\*” ), this also affects the Kibana index , as the Kibana index most probably does not have the attribute i’m using in DLS , Kibana cannot read/write anything from this index. So, the login fails ,So, the solution would be using a more specific index pattern for the DLS rule.
