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

feat: replace encryption with b64 encoding #289

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

arturshadnik
Copy link
Member

Issue

#281

Description

Since the purpose of encrypting secret values was simply to obfuscate, rather than truly encrypt, we can simplify the process by base64 encoding them instead.

This PR:

  • switches all secret encryption to base64 encoding
  • removes the now unused crypto pkg
  • updates integration tests to replace the encrypted values with encoded ones
  • alphabetizes integration test data template by plugin

@arturshadnik arturshadnik requested a review from a team as a code owner December 18, 2024 21:05
@dosubot dosubot bot added size:XL This PR changes 500-999 lines, ignoring generated files. new-feature Net-new feature labels Dec 18, 2024
Copy link

gitguardian bot commented Dec 18, 2024

⚠️ GitGuardian has uncovered 6 secrets following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secrets in your pull request
GitGuardian id GitGuardian status Secret Commit Filename
14909795 Triggered Generic High Entropy Secret 0c342cd tests/integration/validatorctl/testcases/data/validator.yaml View secret
14909796 Triggered Generic High Entropy Secret 0c342cd tests/integration/validatorctl/testcases/data/validator.yaml View secret
13388493 Triggered Generic High Entropy Secret 0c342cd tests/integration/validatorctl/testcases/data/validator.yaml View secret
14909797 Triggered Company Email Password 0c342cd hack/validator.tmpl View secret
14909798 Triggered Generic High Entropy Secret 0c342cd hack/validator.tmpl View secret
14909799 Triggered Generic Password 0c342cd hack/validator.tmpl View secret
🛠 Guidelines to remediate hardcoded secrets
  1. Understand the implications of revoking this secret by investigating where it is used in your code.
  2. Replace and store your secrets safely. Learn here the best practices.
  3. Revoke and rotate these secrets.
  4. If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.

To avoid such incidents in the future consider


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

Copy link

codecov bot commented Dec 18, 2024

Codecov Report

Attention: Patch coverage is 60.41667% with 38 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
pkg/components/validator.go 60.41% 25 Missing and 13 partials ⚠️
@@            Coverage Diff             @@
##             main     #289      +/-   ##
==========================================
+ Coverage   49.38%   49.70%   +0.31%     
==========================================
  Files          46       45       -1     
  Lines        8101     8004      -97     
==========================================
- Hits         4001     3978      -23     
+ Misses       3233     3183      -50     
+ Partials      867      843      -24     
Files with missing lines Coverage Δ
pkg/components/validator.go 58.61% <60.41%> (+9.09%) ⬆️

Continue to review full report in Codecov by Sentry.

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

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Dec 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm This PR has been approved by a maintainer new-feature Net-new feature size:XL This PR changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants