From d56dfae9b883c57f150201bfaf913525f785a3fe Mon Sep 17 00:00:00 2001 From: Evgenii Date: Sun, 4 Aug 2024 21:31:43 +0100 Subject: [PATCH] Offer only Device Code Flow on FreeBSD (#2389) --- client/internal/auth/oauth.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/client/internal/auth/oauth.go b/client/internal/auth/oauth.go index 7467584a3..c9f10ca86 100644 --- a/client/internal/auth/oauth.go +++ b/client/internal/auth/oauth.go @@ -69,6 +69,11 @@ func NewOAuthFlow(ctx context.Context, config *internal.Config, isLinuxDesktopCl return authenticateWithDeviceCodeFlow(ctx, config) } + // On FreeBSD we currently do not support desktop environments and offer only Device Code Flow (#2384) + if runtime.GOOS == "freebsd" { + return authenticateWithDeviceCodeFlow(ctx, config) + } + pkceFlow, err := authenticateWithPKCEFlow(ctx, config) if err != nil { // fallback to device code flow