Add projects
This commit is contained in:
parent
2d3a9ad623
commit
8b607dd700
1802 changed files with 503346 additions and 2 deletions
12
backend/sdk/cliproxy/auth/config_apikey.go
Normal file
12
backend/sdk/cliproxy/auth/config_apikey.go
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
package auth
|
||||
|
||||
// IsConfigAPIKeyAuth reports whether the auth entry is synthesized from config *-api-key lists.
|
||||
func IsConfigAPIKeyAuth(auth *Auth) bool {
|
||||
if auth == nil {
|
||||
return false
|
||||
}
|
||||
if auth.AuthKind() != AuthKindAPIKey {
|
||||
return false
|
||||
}
|
||||
return auth.AuthSourceKind() == AuthSourceConfig
|
||||
}
|
||||
Loading…
Reference in a new issue