# How to get the current logged in user in my kibana plugin server side

**URL:** https://discuss.elastic.co/t/how-to-get-the-current-logged-in-user-in-my-kibana-plugin-server-side/230166
**Category:** Kibana
**Created:** [April 28, 2020, 12:24pm UTC](https://discuss.elastic.co/t/how-to-get-the-current-logged-in-user-in-my-kibana-plugin-server-side/230166 "2020-04-28T12:24:38Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![sudosu](https://avatars.discourse-cdn.com/v4/letter/s/cab0a1/32.png) [@sudosu](https://discuss.elastic.co/u/sudosu)
#### Post date: [April 28, 2020, 12:24pm UTC](https://discuss.elastic.co/t/how-to-get-the-current-logged-in-user-in-my-kibana-plugin-server-side/230166/1 "2020-04-28T12:24:38Z")

</div>

Hi,  
I am writing a kibana plugin and I would like to get the current logged in user infos such as username from my plugin server.  
I have tried server.plugins.security.getuser but nothing.  
Any idea?  
thanks

---

<div class="post-metadata">

### Author: ![azasypkin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/azasypkin/32/42216_2.png) [@azasypkin](https://discuss.elastic.co/u/azasypkin)
#### Post date: [May 5, 2020, 7:00am UTC](https://discuss.elastic.co/t/how-to-get-the-current-logged-in-user-in-my-kibana-plugin-server-side/230166/2 "2020-05-05T07:00:29Z")

</div>

Hi @sudosu,

1. What version of Kibana are you using?
2. What type of plugin are you writing (legacy or [new/current](https://github.com/elastic/kibana/blob/7.6/src/core/MIGRATION.md#migrating-legacy-plugins-to-the-new-platform))?
3. Is security plugin enabled?

Best,  
Oleg

---

<div class="post-metadata">

### Author: ![sudosu](https://avatars.discourse-cdn.com/v4/letter/s/cab0a1/32.png) [@sudosu](https://discuss.elastic.co/u/sudosu)
#### Post date: [May 5, 2020, 11:46am UTC](https://discuss.elastic.co/t/how-to-get-the-current-logged-in-user-in-my-kibana-plugin-server-side/230166/3 "2020-05-05T11:46:45Z")

</div>

1. the version is 7.4.2
2. I guess it's legacy. What's the difference ?
3. No it's not.  
I just used the open source kibana version like recommended on the github page.  
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: [June 2, 2020, 11:46am UTC](https://discuss.elastic.co/t/how-to-get-the-current-logged-in-user-in-my-kibana-plugin-server-side/230166/4 "2020-06-02T11:46:50Z")

</div>

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