MCPcopy
hub / github.com/dosco/graphjin / basicAuth

Struct basicAuth

core/openapi/auth.go:95–97  ·  view source on GitHub ↗

basicAuth produces a base64-encoded "Authorization: Basic ..." header. Both username and password are taken straight from configuration — this scheme doesn't support per-request credentials because real-world basic auth setups use a single service identity.

Source from the content-addressed store, hash-verified

93// this scheme doesn't support per-request credentials because real-world
94// basic auth setups use a single service identity.
95type basicAuth struct {
96 cfg AuthConfig
97}
98
99func (b *basicAuth) Apply(_ context.Context, req *http.Request, _ http.Header) error {
100 if b.cfg.Username == "" {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected