# How should a plugin authenticate with X-Pack?

**URL:** https://discuss.elastic.co/t/how-should-a-plugin-authenticate-with-x-pack/108300
**Category:** Elasticsearch
**Created:** [November 19, 2017, 10:24pm UTC](https://discuss.elastic.co/t/how-should-a-plugin-authenticate-with-x-pack/108300 "2017-11-19T22:24:52Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![dnault](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dnault/32/24449_2.png) [@dnault](https://discuss.elastic.co/u/dnault)
#### Post date: [November 19, 2017, 10:24pm UTC](https://discuss.elastic.co/t/how-should-a-plugin-authenticate-with-x-pack/108300/1 "2017-11-19T22:24:52Z")

</div>

Users of the Couchbase transport plugin have reported the plugin is not compatible with X-Pack security. The plugin performs no special authentication, and interacts directly with the auto-injected `org.elasticsearch.client.Client` instance and the associated `org.elasticsearch.client.IndicesAdminClient`.

Here's a stack trace showing the auth failure:

> <https://github.com/couchbaselabs/elasticsearch-transport-couchbase/issues/170#issuecomment-324339659>

The plugin appears to be acting as the `_system` user, which apparently does not have sufficient privileges.

What should an Elasticsearch plugin do in order to authenticate properly with X-Pack?

Thanks,

David Nault  
Database Connector Developer  
Couchbase, Inc.

---

<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: [December 17, 2017, 10:25pm UTC](https://discuss.elastic.co/t/how-should-a-plugin-authenticate-with-x-pack/108300/2 "2017-12-17T22:25:21Z")

</div>

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