# Shield with Kibana Passing Login Credentials through URL

**URL:** <https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482>\
**Category:** Elasticsearch\
**Tags:** elastic-stack-security\
**Created:** [June 11, 2015, 3:01pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482 "2015-06-11T15:01:29Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![John](https://avatars.discourse-cdn.com/v4/letter/j/a3d4f5/32.png) [@John](https://discuss.elastic.co/u/John)\
**Post date:** [June 11, 2015, 3:01pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/1 "2015-06-11T15:01:29Z")

</div>

Hi,

I was wondering if there was a way with Kibana and Shield to pass through the login details through a url?

For example that way I can click a link which brings me to KIbana and Logs me in through Shield?

---

<div class="post-metadata">

**Author:** ![skearns](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/skearns/32/125945_2.png) [@skearns](https://discuss.elastic.co/u/skearns)\
**Post date:** [June 11, 2015, 6:17pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/2 "2015-06-11T18:17:49Z")

</div>

Hi John,

There is no easy way to do that today. I wonder if allowing anonymous access would address your current needs? That way, any user could access Kibana, but you could control what data they would be able to see, and what they were allowed to do (e.g. read-only except the .kibana index).

If anonymous access doesn't sound like the right fit, can you share a bit more about your needs?

---

<div class="post-metadata">

**Author:** ![John](https://avatars.discourse-cdn.com/v4/letter/j/a3d4f5/32.png) [@John](https://discuss.elastic.co/u/John)\
**Post date:** [June 12, 2015, 1:17pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/3 "2015-06-12T13:17:05Z")

</div>

Hey, Thanks Steve. I will have to look into anonymous access to see if that helps. Basically I was looking to create a portal type link from a different members area and not want the user to login twice when they try to go to the dashboards but still making sure the dashboards are protected behind a login.

---

<div class="post-metadata">

**Author:** ![skearns](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/skearns/32/125945_2.png) [@skearns](https://discuss.elastic.co/u/skearns)\
**Post date:** [June 12, 2015, 2:25pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/4 "2015-06-12T14:25:53Z")

</div>

Hi John,

Thanks for sharing, I now see what you are trying to do. The anonymous access trick may work for showing the "data everyone can see," but won't personalize the view for every user. Hopefully anonymous access is enough in this case.

Longer, term it sounds like what you really want/need is user impersonation, which is an important feature on our roadmap.

Let us know how you make out.

---

<div class="post-metadata">

**Author:** ![John](https://avatars.discourse-cdn.com/v4/letter/j/a3d4f5/32.png) [@John](https://discuss.elastic.co/u/John)\
**Post date:** [June 17, 2015, 1:46pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/5 "2015-06-17T13:46:44Z")

</div>

I may have to do that for now and when the user management features on the roadmap get complete to update it to use that.

And to confirm is there no way I can say use curl even to authenticate with shield (which creates a session?) and then access kibana the same way which should see the session and then not show the login box?

---

<div class="post-metadata">

**Author:** ![jstar](https://avatars.discourse-cdn.com/v4/letter/j/ba8739/32.png) [@jstar](https://discuss.elastic.co/u/jstar)\
**Post date:** [January 7, 2016, 2:55pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/6 "2016-01-07T14:55:38Z")

</div>

Hi John,

Oh I also have the same problem as you. If you manage to get that done please can you share your solution.

Thanks.

---

<div class="post-metadata">

**Author:** ![jstar](https://avatars.discourse-cdn.com/v4/letter/j/ba8739/32.png) [@jstar](https://discuss.elastic.co/u/jstar)\
**Post date:** [January 8, 2016, 12:43am UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/7 "2016-01-08T00:43:57Z")

</div>

Hi all,

I finally managed to address the problem. I used basic authentication on the api of my platform which was doing the call to my elk. That is supposed on my platform, I sign in with the following credentials  
username:jstar  
paswword:mysecret

To access my elk simply call used "jstar:mysecret@localhost:5601" as such jstar will login to kibana without displaying the dislog box of shield.

Hope that helps some body in the future.

---

<div class="post-metadata">

**Author:** ![Tyler\_Child](https://avatars.discourse-cdn.com/v4/letter/t/9fc29f/32.png) [@Tyler\_Child](https://discuss.elastic.co/u/Tyler_Child)\
**Post date:** [March 9, 2016, 1:27pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/8 "2016-03-09T13:27:51Z")

</div>

I've also been working on a better solution to authenticate a user with our ELK stack without manually plugging in a username password. Similar to Josh I am embedding visualizations in iframes on a custom developed site and in order to authenticate with the ELK stack I have to embed the username and password into the URL as Josh explained. Its a bit dirty seeing the credentials in clear text, in dev tools console, but is what it is.

Has their been any headway in providing a means to authenticate a user, perhaps via a token, or at the very least allow us to encode the username and password.

Thanks!

---

<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:** [July 6, 2017, 1:46pm UTC](https://discuss.elastic.co/t/shield-with-kibana-passing-login-credentials-through-url/2482/9 "2017-07-06T13:46:18Z")

</div>


