[openssl/openssl] 4863df: Fix key2ms_newctx() pointer type mismatch in MSBLO...

"'007bsd' via openssl-commits" <[email protected]>
Newsgroups gmane.comp.encryption.openssl.cvs
Message-ID <openssl/openssl/push/refs/heads/openssl-3.6/[email protected]>
  Branch: refs/heads/openssl-3.6
  Home:   https://github.com/openssl/openssl
  Commit: 4863dff2d44320ebae30247d55b8747fd5e85daa
      https://github.com/openssl/openssl/commit/4863dff2d44320ebae30247d55b8747fd5e85daa
  Author: 007bsd <[email protected]>
  Date:   2026-06-23 (Tue, 23 Jun 2026)

  Changed paths:
    M providers/implementations/encode_decode/encode_key2ms.c.in

  Log Message:
  -----------
  Fix key2ms_newctx() pointer type mismatch in MSBLOB/PVK key encoder

key2ms_newctx() returned struct key2ms_ctx_st *, but is registered
as OSSL_FUNC_ENCODER_NEWCTX and called through OSSL_FUNC_encoder_newctx_fn
(void *(*)(void *)), which is a case of undefined behavior, flagged
by -fsanitize=function.  Same class as [1], missed there.

Give it the correct signature and add the self-check forward
declaration, as key2ms_freectx() already has.

[1] https://github.com/openssl/openssl/pull/31078

CLA: trivial
Fixes: 0cc0164d193f "PROV: Add MSBLOB and PVK encoders"

Reviewed-by: Frederik Wedel-Heinen <[email protected]>
Reviewed-by: Viktor Dukhovni <[email protected]>
Reviewed-by: Eugene Syromiatnikov <[email protected]>
Reviewed-by: Tomas Mraz <[email protected]>
Reviewed-by: Paul Dale <[email protected]>
MergeDate: Tue Jun 23 14:45:54 2026
(Merged from https://github.com/openssl/openssl/pull/31189)

(cherry picked from commit 8d0f837db83586b6e4b12a24ee68c5e2ea643d75)



To unsubscribe from these emails, change your notification settings at https://github.com/openssl/openssl/settings/notifications

-- 
You received this message because you are subscribed to the Google Groups "openssl-commits" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion visit https://groups.google.com/a/openssl.org/d/msgid/openssl-commits/openssl/openssl/push/refs/heads/openssl-3.6/5206e3-4863df%40github.com.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.