ASN1 custom primitives in 4.x

"'Sands, Daniel N.' via openssl-users" <[email protected]> Mon, 1 Jun 2026 18:03:44 +0000
Newsgroups gmane.comp.encryption.openssl.user
Message-ID <SA9PR09MB530901555E7D8458782D764ADB152@SA9PR09MB5309.namprd09.prod.outlook.com>
--_000_SA9PR09MB530901555E7D8458782D764ADB152SA9PR09MB5309namp_
Content-Type: text/plain; charset="UTF-8"

With the move to make ASN1 structures opaque, I'd like to ask:  Will the following facility still be supported in 4.x?  Of course I mean for providing a custom native interface to an existing ASN1 primitive.

static ASN1_PRIMITIVE_FUNCS xxxx_pf = {
    NULL, 0,
    xxxx_new,
    xxxx_free,
    xxxx_clear,
    xxxx_c2i,
    xxxx_i2c,
    xxxx_print
};

ASN1_ITEM_start(XXXX)
    ASN1_ITYPE_PRIMITIVE,
    V_ASN1_XXPRIMITIVEXX, NULL, 0, &xxxx_pf,
    0, "XXPRIMITIVEXX" ASN1_ITEM_end(XXXX)

-- 
You received this message because you are subscribed to the Google Groups "openssl-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openssl-users+unsubscribe-MCmKBN63+Bmbup2nOX2J7Q@public.gmane.org
To view this discussion visit https://groups.google.com/a/openssl.org/d/msgid/openssl-users/SA9PR09MB530901555E7D8458782D764ADB152%40SA9PR09MB5309.namprd09.prod.outlook.com.

--_000_SA9PR09MB530901555E7D8458782D764ADB152SA9PR09MB5309namp_
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<html xmlns:o=3D"urn:schemas-microsoft-com:office:office" xmlns:w=3D"urn:sc=
hemas-microsoft-com:office:word" xmlns:m=3D"http://schemas.microsoft.com/of=
fice/2004/12/omml" xmlns=3D"http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Dus-ascii"=
>
<meta name=3D"Generator" content=3D"Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
	{font-family:"Cambria Math";
	panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
	{font-family:Aptos;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	font-size:12.0pt;
	font-family:"Aptos",sans-serif;
	mso-ligatures:standardcontextual;}
span.EmailStyle17
	{mso-style-type:personal-compose;
	font-family:"Aptos",sans-serif;
	color:windowtext;}
.MsoChpDefault
	{mso-style-type:export-only;}
@page WordSection1
	{size:8.5in 11.0in;
	margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
	{page:WordSection1;}
--></style>
</head>
<body lang=3D"EN-US" link=3D"#467886" vlink=3D"#96607D" style=3D"word-wrap:=
break-word">
<div class=3D"WordSection1">
<p class=3D"MsoNormal">With the move to make ASN1 structures opaque, I&#821=
7;d like to ask:&nbsp; Will the following facility still be supported in 4.=
x?&nbsp; Of course I mean for providing a custom native interface to an exi=
sting ASN1 primitive.<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">static ASN1_PRIMITIVE_FUNCS xxxx_pf =3D {<o:p></o:p>=
</p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; NULL, 0,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; xxxx_new,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; xxxx_free,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; xxxx_clear,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; xxxx_c2i,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; xxxx_i2c,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; xxxx_print<o:p></o:p></p>
<p class=3D"MsoNormal">};<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">ASN1_ITEM_start(XXXX)<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; ASN1_ITYPE_PRIMITIVE,<o:p></o:p><=
/p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; V_ASN1_XXPRIMITIVEXX, NULL, 0, &a=
mp;xxxx_pf,<o:p></o:p></p>
<p class=3D"MsoNormal">&nbsp;&nbsp;&nbsp; 0, &quot;XXPRIMITIVEXX&quot; ASN1=
_ITEM_end(XXXX)<o:p></o:p></p>
</div>
</body>
</html>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;openssl-users&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:openssl-users+unsubscribe-MCmKBN63+BlAfugRpC6u6w@public.gmane.org">openssl-us=
[email protected]</a>.<br />
To view this discussion visit <a href=3D"https://groups.google.com/a/openss=
l.org/d/msgid/openssl-users/SA9PR09MB530901555E7D8458782D764ADB152%40SA9PR0=
9MB5309.namprd09.prod.outlook.com?utm_medium=3Demail&utm_source=3Dfooter">h=
ttps://groups.google.com/a/openssl.org/d/msgid/openssl-users/SA9PR09MB53090=
1555E7D8458782D764ADB152%40SA9PR09MB5309.namprd09.prod.outlook.com</a>.<br =
/>

--_000_SA9PR09MB530901555E7D8458782D764ADB152SA9PR09MB5309namp_--