llnl / llnl/elastic-stacker

Use API tokens everywhere

Open
#10 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
7
Forks
1
PR merge metrics
No merged PRs in 30d

Description

In PR #6, changes were made to the handling of mutual TLS authentication. With this change, Stacker could be configured to authenticate with an X.509 client certificate, using the PKI authentication realm. However, this is tricky to get working correctly with the Kibana API. The documentation on the PKI authentication realm for the Kibana API is somewhat sparse, and seems to depend on the Elasticsearch PKI realm being configured correctly as well.

This is also true of username/password auth -- not all Kibana instances necessarily allow basic auth (some only allow OAuth, for example), so it is impossible to dump e.g. saved objects using this authentication method.

The most foolproof way to make this work is to use the user-specified authentication method just once to communicate with Elasticsearch, in order to get a short-lived API key. API key authentication works easily out of the box on both Elasticsearch and Kibana, and can be set up using only calls to the Elasticsearch API. Doing things this way will make the handling of Kibana API endpoints much smoother.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the existing authentication flow and the Elasticsearch and Kibana API calls involved in configuration dumps. Define completion as using the configured authentication method once to obtain a short-lived API key, then using API-key authentication for subsequent Elasticsearch and Kibana communication.

Written by the indexing model from the issue text.

Assessment

Tech stack
elasticsearch, python
Domain
api, authentication, backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.