# Passing credential to the shield through the header of kibana

**URL:** <https://discuss.elastic.co/t/passing-credential-to-the-shield-through-the-header-of-kibana/42272>\
**Category:** Elasticsearch\
**Tags:** elastic-stack-security\
**Created:** [February 19, 2016, 7:53pm UTC](https://discuss.elastic.co/t/passing-credential-to-the-shield-through-the-header-of-kibana/42272 "2016-02-19T19:53:37Z")\
**Posts on this page:** 2\
**Page:** 1

<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:** [February 19, 2016, 7:53pm UTC](https://discuss.elastic.co/t/passing-credential-to-the-shield-through-the-header-of-kibana/42272/1 "2016-02-19T19:53:37Z")

</div>

Hi All,

It is very urgent. I'm looking of a mean to dynamically login into shield by passing the user credentials to the header of kibana as authorization basic.

I have given a try as follows:  
I configured a reverse proxy with apache2. That is to contact kibana user go to the url of apache2 and apache2 forward their requests to kibana. It works fine.  
I then use angularjs to call the url of apache2 by passing authorization basic as header.  
That is  
var token = $base64('jstar:password')  
$http({  
method : 'GET',  
url : 'url\_of\_apache2',  
headers : {  
'Authorization' : 'Basic ' + token  
}).success(function(response) {  
$scope.showLoading = false;  
$scope.showAPIFail = false;  
$scope.kibana = response;  
$scope.url = response;  
})

After doing that, I have nothing being display on the browser. But when I inspect the browser, I see that the call to kibana return 200, OK but not is being displayed. Furthermore I have the following my message Refused to display "some url" in a frame because it set 'X-Frame-Options' to 'DENY'.

Please any help will be welcoming.  
Thanks for the concern.

---

<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/passing-credential-to-the-shield-through-the-header-of-kibana/42272/2 "2017-07-06T13:46:40Z")

</div>


