# Skip xpack authentication for a specific endpoint

**URL:** <https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122>\
**Category:** Elasticsearch\
**Tags:** elastic-stack-security\
**Created:** [December 13, 2022, 11:52am UTC](https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122 "2022-12-13T11:52:07Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![smiley\_tamy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/smiley_tamy/32/113375_2.png) [@smiley\_tamy](https://discuss.elastic.co/u/smiley_tamy)\
**Post date:** [December 13, 2022, 11:52am UTC](https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122/1 "2022-12-13T11:52:08Z")

</div>

I have enabled x-pack and all the requests are expected to provide the credentials to access Elasticsearch.  
I have a scenario where for certain endpoints, I must be able to access without providing credentials. It means authentication must be skipped.  
I do not want to authenticate when I check for cluster health or Elasticsearch availability  
localhost:9200/\_cluster/health  
localhost:9200

I didnot come across a way to do that  
Is there any such option to skip authentication for required endpoints

---

<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:** [December 13, 2022, 12:27pm UTC](https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122/2 "2022-12-13T12:27:46Z")

</div>

> [@smiley\_tamy](#):
>
> Is there any such option to skip authentication for required endpoints

No, this is not possible, with security enabled all requests needs to be authenticated.

---

<div class="post-metadata">

**Author:** ![smiley\_tamy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/smiley_tamy/32/113375_2.png) [@smiley\_tamy](https://discuss.elastic.co/u/smiley_tamy)\
**Post date:** [December 13, 2022, 5:33pm UTC](https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122/3 "2022-12-13T17:33:56Z")

</div>

Thank you for the information

---

<div class="post-metadata">

**Author:** ![defalt](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/defalt/32/71379_2.png) [@defalt](https://discuss.elastic.co/u/defalt)\
**Post date:** [December 14, 2022, 11:34am UTC](https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122/4 "2022-12-14T11:34:54Z")

</div>

You could write some sort of script that authenticates the requests and shows you the response. That would "disable" the need for authentication but is only a workaround.

---

<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:** [January 11, 2023, 11:35am UTC](https://discuss.elastic.co/t/skip-xpack-authentication-for-a-specific-endpoint/321122/5 "2023-01-11T11:35:43Z")

</div>

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