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

fix: get correct username from jwt token subject (#5836) #5848

Merged
merged 3 commits into from Mar 24, 2021

Conversation

kshamajain99
Copy link
Contributor

@kshamajain99 kshamajain99 commented Mar 23, 2021

fixes #5836

Adapt change

fmt.Sprintf("%s:%s", q.Username, settings.AccountCapabilityLogin),

Checklist:

  • Either (a) I've created an enhancement proposal and discussed it with the community, (b) this is a bug fix, or (c) this does not need to be in the release notes.
  • The title of the PR states what changed and the related issues number (used for the release note).
  • I've included "Closes [ISSUE #]" or "Fixes [ISSUE #]" in the description to automatically close the associated issue.
  • I've updated both the CLI and UI to expose my feature, or I plan to submit a second PR with them.
  • Does this PR require documentation updates?
  • I've updated documentation as required by this PR.
  • Optional. My organization is added to USERS.md.
  • I have signed off all my commits as required by DCO
  • I have written unit and/or e2e tests for my change. PRs without these are unlikely to be merged.
  • My build is green (troubleshooting builds).

Signed-off-by: kshamajain99 <kshamajain99@gmail.com>
Signed-off-by: kshamajain99 <kshamajain99@gmail.com>
@kshamajain99 kshamajain99 changed the title fix: get correct username from jwt token subject fix: get correct username from jwt token subject (#5836) Mar 23, 2021
@codecov
Copy link

codecov bot commented Mar 23, 2021

Codecov Report

Merging #5848 (bb959c2) into master (bde4ad4) will decrease coverage by 0.13%.
The diff coverage is 42.85%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5848      +/-   ##
==========================================
- Coverage   41.01%   40.88%   -0.14%     
==========================================
  Files         146      147       +1     
  Lines       19630    19617      -13     
==========================================
- Hits         8052     8021      -31     
- Misses      10464    10491      +27     
+ Partials     1114     1105       -9     
Impacted Files Coverage Δ
cmd/argocd/commands/account.go 0.00% <0.00%> (ø)
cmd/argocd/commands/relogin.go 0.00% <0.00%> (ø)
util/localconfig/localconfig.go 3.09% <75.00%> (ø)
server/application/application.go 30.55% <0.00%> (-0.04%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bde4ad4...bb959c2. Read the comment docs.

Copy link
Contributor

@sbose78 sbose78 left a comment

Choose a reason for hiding this comment

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

Looks good to me, a unit test would be nice.

util/localconfig/localconfig.go Show resolved Hide resolved
Signed-off-by: kshamajain99 <kshamajain99@gmail.com>
@kshamajain99 kshamajain99 merged commit 6cc8ab0 into argoproj:master Mar 24, 2021
alexmt pushed a commit that referenced this pull request Mar 29, 2021
* fix: get correct username from jwt token subject

Signed-off-by: kshamajain99 <kshamajain99@gmail.com>
shubhamagarwal19 pushed a commit to shubhamagarwal19/argo-cd that referenced this pull request Apr 15, 2021
…oproj#5848)

* fix: get correct username from jwt token subject

Signed-off-by: kshamajain99 <kshamajain99@gmail.com>
@jannfis jannfis added the needs-verification PR requires pre-release verification label Jun 25, 2021
@mayzhang2000 mayzhang2000 removed the needs-verification PR requires pre-release verification label Aug 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[2.0.0-rc1] ArgoCD update-password causes immediate fatal error after successful update
4 participants