crossplane-contrib / crossplane-contrib/provider-http

Add ability to use service account token

Open
#142 0 comments 5 reactions 0 assignees View on GitHub
enhancement
Dominant language
Go
Stars
74
Forks
42
Avg merge
1d 2h
Merged PRs (30d)
5

Description

### What problem are you facing?

Some target APIs support JWT auth from a foreign issuer. We could use that to configure the API to accept tokens from the cluster OIDC issuer. A pod can get such a token provided by the cluster in the form of attaching a service account. The token is then mounted as a file into the pod /var/run/secrets/kubernetes.io/token (amonst other tokens, such as e.g. Azure workload identity tokens) .Having the ability to use that mounted token file content in http calls would allow us to not rely on API secrets maintained separately.

### How could Crossplane help solve your problem?

Create a syntax similar to secret refs that i can include in headers/body that inlines file contents from the provider-http pod to be able to use service account tokens (or e.g. azure workload identity tokens).

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating provider-http's request configuration and the existing secret-reference handling for headers and bodies. Trace how request values are assembled in the provider pod, then define how a mounted service-account token file would be referenced and verify that both header and body use cases are covered.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes
Domain
api, authentication
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.