I've been able to reproduce and saw that a different certificates are being returned.

Building wolfSSL with

--enable-sni

should address this. This includes the server name in the Client Hello so the server will send the appropriate certificate.


Hope that addresses your issue.

Details
Using wireshark I captured the certificates when running

curl -vvI https://qnzthome.51110.com/ --tls-max 1.2
./examples/client/client -h qnzthome.51110.com -p 443 -A /etc/ssl/certs/DigiCert_Global_Root_CA.pem -m -v3

I saw the same certificate in gdb using the example program you had shared with TLS v1.3.

Note if you test with the example client you will need add -S

./examples/client/client -h qnzthome.51110.com -p 443 -A /etc/ssl/certs/DigiCert_Global_Root_CA.pem -m -v3 -S qnzthome.51110.com

Hi Joe,

It looks like you are using a current version of curl. wolfSSL is currently at version 4.5 (3.13 is 3 years old). Is it possible for you to try with a more recent version of wolfSSL?

Easy to make the mistake, the latter is hex and not base64 encoded. There are hex to base64 online (first one I found was https://base64.guru/converter/encode/hex). Putting `c8ed5e65713f8170b8d0769a8ed8c35740ba0b706d5856e22d709be1e001cf8c` in it generated the same base64 that you posted (`yO1eZXE/gXC40HaajtjDV0C6C3BtWFbiLXCb4eABz4w=`).

Hope that helps.