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

Getting "Error exporting secret asn1: structure error" #65

Open
ab250 opened this issue Jan 15, 2021 · 2 comments
Open

Getting "Error exporting secret asn1: structure error" #65

ab250 opened this issue Jan 15, 2021 · 2 comments

Comments

@ab250
Copy link

ab250 commented Jan 15, 2021

I'm using label sector method for discovering two of the secrets, but only one is getting discovered and in the cert-exporter pod log I am seeing the below error. What can be the issue?

I0115 10:34:26.082742       1 periodicSecretChecker.go:89] Reviewing secret tls-secret in dev
I0115 10:34:26.082751       1 periodicSecretChecker.go:106] Annotations matched. Parsing Secret.
I0115 10:34:26.082756       1 periodicSecretChecker.go:138] Publishing tls-secret/dev metrics tls.crt
I0115 10:34:26.083061       1 periodicSecretChecker.go:138] Publishing tls-secret/dev metrics tls.key
E0115 10:34:26.083084       1 periodicSecretChecker.go:141] Error exporting secret asn1: structure error: tags don't match (16 vs {class:0 tag:2 length:1 isCompound:false}) {optional:false explicit:false application:false private:false defaultValue:<nil> tag:<nil> stringType:0 timeType:0 set:false omitEmpty:false} tbsCertificate @2
@joe-elliott
Copy link
Owner

It appears that you are trying to parse the tls.key as a cert which will not work.

Refer to discussion here: #19

@gustonator
Copy link

Thank you Joe for the hint. I had the same issue :)

for new folks:
just add - --secrets-include-glob=*.crt to deployment config

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

3 participants