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

[app] Use generics for jwt package #420

Merged
merged 1 commit into from
Aug 27, 2022

Conversation

ricoberger
Copy link
Member

We are now using generics for the jwt package, so that we can reuse the
logic for cookies which are generated in plugins.

We use the jwt package now in the GitHub and Jira plugin. This has the
advantage that the cookies are more secure now. Before this change we
only used a base64 encoded representation of the auth credentials. Now
we generating a signed JWT token to store the auth info.

@ricoberger ricoberger force-pushed the app-use-generics-for-jwt-package branch from 63f55ab to dd1142b Compare August 27, 2022 09:54
We are now using generics for the jwt package, so that we can reuse the
logic for cookies which are generated in plugins.

We use the jwt package now in the GitHub and Jira plugin. This has the
advantage that the cookies are more secure now. Before this change we
only used a base64 encoded representation of the auth credentials. Now
we generating a signed JWT token to store the auth info.
@ricoberger ricoberger force-pushed the app-use-generics-for-jwt-package branch from 94e80c3 to 635a0e1 Compare August 27, 2022 10:14
@codecov-commenter
Copy link

Codecov Report

Merging #420 (635a0e1) into main (9408dec) will decrease coverage by 0.25%.
The diff coverage is 36.66%.

@@            Coverage Diff             @@
##             main     #420      +/-   ##
==========================================
- Coverage   45.85%   45.60%   -0.26%     
==========================================
  Files         141      139       -2     
  Lines       11906    11888      -18     
==========================================
- Hits         5459     5421      -38     
- Misses       6306     6328      +22     
+ Partials      141      139       -2     
Impacted Files Coverage Δ
plugins/plugin-jira/pkg/instance/instance.go 0.00% <0.00%> (ø)
plugins/plugin-github/pkg/instance/instance.go 35.71% <27.27%> (-23.02%) ⬇️
pkg/hub/auth/auth.go 72.15% <100.00%> (ø)
pkg/hub/auth/jwt/jwt.go 96.42% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@ricoberger ricoberger merged commit 3a1e4ed into main Aug 27, 2022
@ricoberger ricoberger deleted the app-use-generics-for-jwt-package branch August 27, 2022 10:42
@ricoberger ricoberger added the changelog: changed Something was changed or updated label Sep 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog: changed Something was changed or updated
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants