# Kibana with Shield won't work

**URL:** <https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507>\
**Category:** Kibana\
**Created:** [October 7, 2016, 4:13pm UTC](https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507 "2016-10-07T16:13:12Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![lekshmi](https://avatars.discourse-cdn.com/v4/letter/l/9e8a1a/32.png) [@lekshmi](https://discuss.elastic.co/u/lekshmi)\
**Post date:** [October 7, 2016, 4:13pm UTC](https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507/1 "2016-10-07T16:13:12Z")

</div>

Hi,

In our app , we were trying to use kibana with shield. We are trying to embed the dashboard in an iframe. Following is what we are doing to pass the authorization header:

On click of dashboard name in UI ,we make an ajax request to one of our controllers (Spring Rest Controller). Controller will create the Authorization header and make a request to Kibana.

Kibana returns an html page with script to execute . I tried numerous ways to load that html page to display the dashboard, it simply won't work.

May be I am doing something wrong. Is there a better way to auto authenticate kibana from iframe?

Note: If I directly provide kibana url in iframe src, it prompts for authentication and once i give the credentials it loads the dasboard. What I am trying to avoid is that prompt.

---

<div class="post-metadata">

**Author:** ![lukas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lukas/32/6812_2.png) [@lukas](https://discuss.elastic.co/u/lukas)\
**Post date:** [October 7, 2016, 11:55pm UTC](https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507/2 "2016-10-07T23:55:21Z")

</div>

Which version of Kibana/Elasticsearch/Shield are you using? Also, are you using the Shield plugin for Kibana?

---

<div class="post-metadata">

**Author:** ![lekshmi](https://avatars.discourse-cdn.com/v4/letter/l/9e8a1a/32.png) [@lekshmi](https://discuss.elastic.co/u/lekshmi)\
**Post date:** [October 8, 2016, 12:04pm UTC](https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507/3 "2016-10-08T12:04:58Z")

</div>

We use: Kibana -4.6.1, Elastic search - 2.4.0, Shield-2.4.0

Yes, I am using Shield plugin for kibana.

---

<div class="post-metadata">

**Author:** ![lekshmi](https://avatars.discourse-cdn.com/v4/letter/l/9e8a1a/32.png) [@lekshmi](https://discuss.elastic.co/u/lekshmi)\
**Post date:** [October 10, 2016, 3:43pm UTC](https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507/4 "2016-10-10T15:43:17Z")

</div>

The easiest way to replicate this issue is, if you have the shield enabled, try accessing Kibana URL with the authorization header using postman.

You will be stuck in loading page forever.

---

<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:37pm UTC](https://discuss.elastic.co/t/kibana-with-shield-wont-work/62507/5 "2017-07-06T13:37:08Z")

</div>


