mirror of
https://github.com/netbirdio/dex.git
synced 2026-05-22 18:43:53 -07:00
Allow public clients created with API to have no client_secret (#1871)
Signed-off-by: Steffen Pøhner Henriksen <str3sses@gmail.com>
This commit is contained in:
+1
-1
@@ -50,7 +50,7 @@ func (d dexAPI) CreateClient(ctx context.Context, req *api.CreateClientReq) (*ap
|
||||
if req.Client.Id == "" {
|
||||
req.Client.Id = storage.NewID()
|
||||
}
|
||||
if req.Client.Secret == "" {
|
||||
if req.Client.Secret == "" && !req.Client.Public {
|
||||
req.Client.Secret = storage.NewID() + storage.NewID()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user