ContainerImage.Pinniped/pkg/oidcclient
Matt Moyer 1e32530d7b
Fix broken TTY after manual auth code prompt.
This may be a temporary fix. It switches the manual auth code prompt to use `promptForValue()` instead of `promptForSecret()`. The `promptForSecret()` function no longer supports cancellation (the v0.9.2 behavior) and the method of cancelling in `promptForValue()` is now based on running the blocking read in a background goroutine, which is allowed to block forever or leak (which is not important for our CLI use case).

This means that the authorization code is now visible in the user's terminal, but this is really not a big deal because of PKCE and the limited lifetime of an auth code.

The main goroutine now correctly waits for the "manual prompt" goroutine to clean up, which now includes printing the extra newline that would normally have been entered by the user in the manual flow.

The text of the manual login prompt is updated to be more concise and less scary (don't use the word "fail").

Signed-off-by: Matt Moyer <moyerm@vmware.com>
2021-07-30 12:45:44 -05:00
..
filesession Fix missing normalization in pkg/oidcclient/filesession. 2021-04-08 14:12:34 -05:00
nonce Upgrade to github.com/coreos/go-oidc v3.0.0. 2021-01-21 12:08:14 -06:00
oidctypes Add validated ID token claims to the oidctypes.Token structure. 2020-12-04 15:18:41 -06:00
pkce Move ./internal/oidcclient to ./pkg/oidcclient. 2020-11-17 14:53:32 -06:00
state Move ./internal/oidcclient to ./pkg/oidcclient. 2020-11-17 14:53:32 -06:00
login_test.go Fix broken TTY after manual auth code prompt. 2021-07-30 12:45:44 -05:00
login.go Fix broken TTY after manual auth code prompt. 2021-07-30 12:45:44 -05:00