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

Sealed Secret in Kubernetes Challenge #1452

Merged
merged 44 commits into from
Jul 7, 2024

Conversation

Shubham-Patel07
Copy link
Contributor

@Shubham-Patel07 Shubham-Patel07 commented Jun 21, 2024

What kind of changes does this PR include?

  • Fixes or refactors
  • A new challenge
  • Additional documentation
  • Something else

Relation

Fixes part of #858

Description

Added new challenge Related to Bitnami Sealed Secrets

Checklist:

  • All the contributions made are solely the work of me and my co-authors
  • I tested the changes in this PR (if applicable)
  • I added unit tests to ensure my change works (when change in Java or on front-end code)
  • I added UI tests to ensure my UI changes work (when change in the overall UI, not needed if just adding a challenge)
  • The PR passes pre-commit hooks and automated tests

@Shubham-Patel07
Copy link
Contributor Author

Shubham-Patel07 commented Jun 21, 2024

@commjoen Please Guide me further in which File i need to mention ACTUAL_ANSWER_CHALLENGE48 variable
What are the further things i need to figure out

@Shubham-Patel07 Shubham-Patel07 marked this pull request as ready for review June 21, 2024 16:34
@commjoen
Copy link
Collaborator

Great start! let's go to the next steps!

  1. would you please write the challenge texts common tests and add a challenge configuration as in https://github.com/OWASP/wrongsecrets/blob/master/CONTRIBUTING.md#how-to-add-a-challenge. ?
  2. the SEALED_SECRET_ANSWER needs to be the env-var in https://github.com/OWASP/wrongsecrets/pull/1452/files#diff-3295830e52e2c56ac68ea925b7cc6ec7892a1b4f8401c27ff14345ef4a0129a2R9 so it will override the application.properties value.
  3. last but not least: can you extend the end2end tests in https://github.com/OWASP/wrongsecrets/tree/master/src/test/K8s-tests/cypress/e2e please? it needs to check whether your challenge shows the default value you gave it here in application.properties, or actually shows the data you defined in the sealed secret (so the test only needs to check that the appliction.properties value is not present in /spoil/ for your challenge.

@Shubham-Patel07
Copy link
Contributor Author

Shubham-Patel07 commented Jun 22, 2024

So i did what you said sir @commjoen , but still the challenge is not visible when i run using k8s-vault-minikubw-start.sh
What else i need to figure out

@commjoen
Copy link
Collaborator

We will have to build a new container to show it in k8s. I can do that tomorrow. If you run it locally: is the challenge then visible?

@Shubham-Patel07
Copy link
Contributor Author

Shubham-Patel07 commented Jun 22, 2024

Hi @commjoen
I abruptly faced this error and not able to troubleshoot it

image

I even tried to run mvn clean install and got this error

image

these occurred so abruptly, even without changing anything

@commjoen
Copy link
Collaborator

Hi @commjoen

I abruptly faced this error and not able to troubleshoot it

image

I even tried to run mvn clean install and got this error

image

these occurred so abruptly, even without changing anything

It looks like you have the wrong JDK version: can you upgrade to the latest please?🙏

@Shubham-Patel07
Copy link
Contributor Author

Hi @commjoen
I abruptly faced this error and not able to troubleshoot it
image
I even tried to run mvn clean install and got this error
image
these occurred so abruptly, even without changing anything

It looks like you have the wrong JDK version: can you upgrade to the latest please?🙏

image

im using latest openJDK 22 version

… made reccomended changes in challenge manifests to override the env-var in application.properties
@commjoen
Copy link
Collaborator

commjoen commented Jun 25, 2024

The javacode is fixed, now all we need is the correct override of the env var SEALED_SECRET_ANSWER by means of the sealed secret. Alternatively we can make the javacode load a file injected by the controler (CC @bendehaan).
Once this is done there are a few items left, let's enumerate them here:

@commjoen commjoen merged commit 89e8c8a into OWASP:master Jul 7, 2024
16 checks passed
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