libp2p / cpp-libp2p

C++17 implementation of libp2p
Apache License 2.0
346 stars 97 forks source link

fix: use the correct x509 version #196

Closed MarcoPolo closed 1 year ago

MarcoPolo commented 1 year ago

Since we want to use version 3, we actually need to pass 2 here. I know it's confusing. Without this you will fail to interop with go-libp2p nodes since they have no idea how to parse an unknown version of x509.

Sources:

Note it might be better to use the defined constant X509_VERSION_3, but I haven't compiled the project so I knew s/3/2 was a safe change.