Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Propagate username updates in tsh #5323

Merged
merged 1 commit into from
Jan 16, 2021
Merged

Conversation

fspmarshall
Copy link
Contributor

tsh was sometimes using the incorrect username when generating access requests from a fresh state (i.e. if no ~/.tsh previously existed). This is because some login methods (e.g. oidc) update the username, but the updated username was not being propagated back up to tsh's top-level configuration.

Fixes #5316

tool/tsh/tsh.go Outdated
@@ -610,6 +610,10 @@ func onLogin(cf *CLIConf) {
utils.FatalError(err)
}

// the login operation may update the username and should be considered the more
// "authoratative" source.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

authoritative (I think)

@fspmarshall fspmarshall force-pushed the fspmarshall/fix-username-prop branch from 9b066b7 to de36e89 Compare January 16, 2021 18:46
@fspmarshall fspmarshall merged commit ba5e94f into master Jan 16, 2021
@fspmarshall fspmarshall deleted the fspmarshall/fix-username-prop branch January 16, 2021 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants