# Security for multiple users accessing the same index

**URL:** https://discuss.elastic.co/t/security-for-multiple-users-accessing-the-same-index/317736
**Category:** Elasticsearch
**Tags:** elastic-stack-security
**Created:** [October 29, 2022, 10:21pm UTC](https://discuss.elastic.co/t/security-for-multiple-users-accessing-the-same-index/317736 "2022-10-29T22:21:59Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![HockeyFan0000](https://avatars.discourse-cdn.com/v4/letter/h/b4bc9f/32.png) [@HockeyFan0000](https://discuss.elastic.co/u/HockeyFan0000)
#### Post date: [October 29, 2022, 10:21pm UTC](https://discuss.elastic.co/t/security-for-multiple-users-accessing-the-same-index/317736/1 "2022-10-29T22:21:59Z")

</div>

We have multiple users creating indexes for very few documents. One index has one document they update daily and another has 2-3 documents indexed every two weeks. We would like to combine all these minimal-use cases into one index. These people are on the same large team so they have access to the same indexes. I don't think field-level security would work for us because we would have to specify the fields and we don't know what they'll use. Is there a way we can have the sub-teams access the same index but only have access to the fields they create?

---

<div class="post-metadata">

### Author: ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)
#### Post date: [October 29, 2022, 11:03pm UTC](https://discuss.elastic.co/t/security-for-multiple-users-accessing-the-same-index/317736/2 "2022-10-29T23:03:01Z")

</div>

Seems Like perhaps you are describing [Document Level Security.](https://www.elastic.co/guide/en/elasticsearch/reference/8.4/document-level-security.html)

If you have a way to define who can access / read / write documents by type, term etc you could use that, So users with "Role A" would only see the documents they have access to by "type" (not `_type` which is always `_doc`) I mean by some pre-defined field that maps to "Role A" etc.

But perhaps I don't understand

---

<div class="post-metadata">

### Author: ![HockeyFan0000](https://avatars.discourse-cdn.com/v4/letter/h/b4bc9f/32.png) [@HockeyFan0000](https://discuss.elastic.co/u/HockeyFan0000)
#### Post date: [October 29, 2022, 11:12pm UTC](https://discuss.elastic.co/t/security-for-multiple-users-accessing-the-same-index/317736/3 "2022-10-29T23:12:25Z")

</div>

There's only one problem with that...now I feel like an idiot for not thinking of it. 🙂

That sounds like a great idea. I think that will work for us. Thank you so much.

---

<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: [November 26, 2022, 11:12pm UTC](https://discuss.elastic.co/t/security-for-multiple-users-accessing-the-same-index/317736/4 "2022-11-26T23:12:42Z")

</div>

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