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

Using base64 encoded strings fails creating the secret #484

Open
AMecea opened this issue Mar 16, 2020 · 0 comments
Open

Using base64 encoded strings fails creating the secret #484

AMecea opened this issue Mar 16, 2020 · 0 comments

Comments

@AMecea
Copy link

AMecea commented Mar 16, 2020

tools version: 0.10.1

In the scheme.yaml

  dashboardOIDCClientID:
    type: string
    title: Auth0 Client ID
    x-google-marketplace:
      type: STRING
      string:
        generatedProperties:
          base64Encoded: dashboardOIDCClientIDEncoded

in the apptest/deployer/schema.yaml

properties:
  dashboardOIDCClientID:
    type: string
    title: Auth0 Client ID
    default: "test"
    x-google-marketplace:
      type: STRING
      string:
        generatedProperties:
          base64Encoded: dashboardOIDCClientIDEncoded

running mpdev verify
I'm getting:

Error from server (BadRequest): error when creating "/data/resources.yaml": Secret in version "v1" cannot be handled as a Secret: v1.Secret.Data: decode base64: illegal base64 data at input byte 1, error found in #10 byte of ...|dGVzdA=='","CLIENT_S|..., bigger context ...|apiVersion":"v1","data":{"CLIENT_ID":"b'dGVzdA=='","CLIENT_SECRET":"b'dGVzdA=='","ISSUER":"b'aHR0cHM|...

This is because the variable is replaced with b'<base64 encoded string>' instead of just the string, this is related to python3 byte string that is not decoded before serialization.

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

No branches or pull requests

1 participant