[gnutls-devel] GnuTLS | Draft: Work on issue #1475 (!1812)

Read-only notification of GnuTLS library development activities gnutls-devel at lists.gnutls.org
Sun Feb 18 07:59:13 CET 2024




Daiki Ueno commented: https://gitlab.com/gnutls/gnutls/-/merge_requests/1812#note_1778077934

I think you could use regular API, such as `gnutls_pubkey_import` to deal with that format, as certtool can decode it properly:

```console
$ echo 3059301306072a8648ce3d020106082a8648ce3d0301070342000462d5bd3372af75fe85a040715d0f502428e07046868b0bfdfa61d731afe44f26ac333a93a9e70a81cd5a95b5bf8d13990eb741c8c38872b4a07d275a014e30cf | sed 's/../\\\\x\0/g' | xargs printf | certtool --pubkey-info --inder
Public Key Information:
	Public Key Algorithm: EC/ECDSA
	Algorithm Security Level: High (256 bits)
		Curve:	SECP256R1
		X:
			62:d5:bd:33:72:af:75:fe:85:a0:40:71:5d:0f:50:24
			28:e0:70:46:86:8b:0b:fd:fa:61:d7:31:af:e4:4f:26
		Y:
			00:ac:33:3a:93:a9:e7:0a:81:cd:5a:95:b5:bf:8d:13
			99:0e:b7:41:c8:c3:88:72:b4:a0:7d:27:5a:01:4e:30
			cf

Public Key ID:
	sha1:cc558fb828759c01bb7066093f52ecd29cbe6a43
	sha256:a49d5e91410cec8881d7847d9de258b3fedddb71bf37d6ab8509354be06ce215
Public Key PIN:
	pin-sha256:pJ1ekUEM7IiB14R9neJYs/7d23G/N9arhQk1S+Bs4hU=


-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEYtW9M3Kvdf6FoEBxXQ9QJCjgcEaG
iwv9+mHXMa/kTyasMzqTqecKgc1albW/jROZDrdByMOIcrSgfSdaAU4wzw==
```

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1812#note_1778077934
You're receiving this email because of your account on gitlab.com.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20240218/26aa98b0/attachment.html>


More information about the Gnutls-devel mailing list