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(oidc): Fixing OIDC encryption bug in v0.8.29 #4418

Merged

Conversation

jjoyce0510
Copy link
Collaborator

Summary
This PR fixes a recently released issue in version v0.8.29, where the encryption key used to sign session cookies for Pac4j (OIDC only) could be of invalid length depending on what value of DATAHUB_SECRET was used. This was due to a misalignment in the required number of bytes for an AES key (16 or 32) and the number of bytes we were resolving as this key. This PR fixes this.

Validation
Reproduced issue and tested the fix locally using Okta. Changed value of DATAHUB_SECRET to many things to confirm.

Checklist

  • The PR conforms to DataHub's Contributing Guideline (particularly Commit Message Format)
  • Links to related issues (if applicable)
  • Tests for the changes have been added/updated (if applicable)
  • Docs related to the changes have been added/updated (if applicable)

@github-actions
Copy link

Unit Test Results (build & test)

  92 files  ±0    92 suites  ±0   11m 53s ⏱️ - 5m 37s
673 tests ±0  614 ✔️ ±0  59 💤 ±0  0 ±0 

Results for commit 6d9f567. ± Comparison against base commit e8f6c4c.

@jjoyce0510 jjoyce0510 merged commit 86f2407 into datahub-project:master Mar 16, 2022
maggiehays pushed a commit to maggiehays/datahub that referenced this pull request Aug 1, 2022
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 participants