cloudflare / cloudflare/cfssl

Implement a custom auth provider

Open
#833 0 comments 2 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
9.5k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

As per the doc `authentication.txt`:
```The standard authenticator provided as a reference implementation uses
HMAC-SHA-256 to compute the HMAC of the request, with the hex-encoded
authentication key specified in the configuration file. The key may be
specified in one of three ways:

* hex-encoded string (e.g. "000102030405060708")
* an environment variable prefixed with "env:"
(e.g. "env:AUTH_KEY") that contains a hex-encoded string.
* a path to a file containing the hex-encoded key, prefixed with
"file:" (e.g. "file:/path/to/auth.key")
```

If one had to implement a custom auth provider, one updates the `authTypes` map for calling the right auth provider in `cfssl_provider.go`.

What I do not seem to understand is how do I update this private, non-global map to include a custom auth provider?

The use case is to provide a dynamic auth provider for clients, which ensure we do not change CFSSL configs repeatedly (but can easily change some internal systems to do so).

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.