Skip to content

crypto/x509: cert from google fails to parse #8387

Description

@gopherbot

by mo.dejong@dena.jp:

Before filing a bug, please check whether it has been fixed since the
latest release. Search the issue tracker and check that you're running the
latest version of Go:

> go version
go version go1.3 darwin/amd64

What steps reproduce the problem?
If possible, include a link to a program on play.golang.org.

1. http://play.golang.org/p/MM0F8aYf99
2. See error "asn1: structure error: tags don't match (16 vs {class:0 tag:13
length:45 isCompound:true}) {optional:false explicit:false application:false
defaultValue:<nil> tag:<nil> stringType:0 set:false omitEmpty:false}
certificate @2"

What happened?

Go fails to parse the google cert (it is in pem format)

What should have happened instead?

It should have parsed the cert.

Please provide any additional information below.

Note that this exact same cert works properly with the google provided Ruby Gem :
https://rubygems.org/gems/google-id-token

Attachments:

  1. x509_test.go (1201 bytes)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions