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

Read-only notification of GnuTLS library development activities gnutls-devel at lists.gnutls.org
Mon Feb 19 01:53:14 CET 2024

Daiki Ueno commented on a discussion: https://gitlab.com/gnutls/gnutls/-/merge_requests/1812#note_1778295377

I suspect `out->size = strlen(byte_array)` might be the cause, as `strlen` only works with NUL terminated string and the decoded `byte_array` may contain a NUL byte (`\0`).

gnutls_datum_t hex, der = { NULL, 0 };

hex.data = "3059301306072a8648ce3d020106082a8648ce3d0301070342000462d5bd3372af75fe85a040715d0f502428e07046868b0bfdfa61d731afe44f26ac333a93a9e70a81cd5a95b5bf8d13990eb741c8c38872b4a07d275a014e30cf";
hex.size = strlen(hex.data);

gnutls_hex_decode2(&hex, &der);

Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1812#note_1778295377
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/20240219/4e7c790e/attachment.html>

More information about the Gnutls-devel mailing list