//
// PEM_write_bio_ASN1_stream from 0xe71b40 to 0xe71c34 (244 bytes)
//
// 2 xrefs:
// > PEM_write_bio_CMS_stream @ 0xe1ed1c
// > ??> @ 0x65c40
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall PEM_write_bio_ASN1_stream(__int64 a1, __int64 a2, __int64 a3, int a4, const char *a5, __int64 a6)
{
__int64 v11; // x0
__int64 v12; // x0
__int64 v13; // x0
_QWORD *v14; // x21
__int64 v15; // x23
unsigned int v16; // w19
v11 = BIO_printf(a1, "-----BEGIN %s-----\n", a5);
v12 = BIO_f_base64(v11);
v13 = BIO_new(v12);
v14 = (_QWORD *)v13;
if ( v13 )
{
v15 = BIO_push(v13, a1);
v16 = i2d_ASN1_bio_stream(v15, a2, a3, a4, a6);
BIO_ctrl(v15, 0xBu, 0, 0);
BIO_pop(v15);
BIO_free(v14);
}
else
{
v16 = 0;
ERR_put_error(13, 210, 65, (__int64)"crypto/asn1/asn_mime.c", 105);
}
BIO_printf(a1, "-----END %s-----\n", a5);
return v16;
}