10 s2i_ASN1_OCTET_STRING,
12 i2s_ASN1_ENUMERATED_TABLE,
15 - convert objects from/to ASN.1/string representation
19 #include <openssl/x509v3.h>
21 char *i2s_ASN1_IA5STRING(X509V3_EXT_METHOD *method, ASN1_IA5STRING *ia5);
22 ASN1_IA5STRING *s2i_ASN1_IA5STRING(X509V3_EXT_METHOD *method,
23 X509V3_CTX *ctx, const char *str);
24 char *i2s_ASN1_INTEGER(X509V3_EXT_METHOD *method, const ASN1_INTEGER *a);
25 ASN1_INTEGER *s2i_ASN1_INTEGER(X509V3_EXT_METHOD *method, const char *value);
26 char *i2s_ASN1_OCTET_STRING(X509V3_EXT_METHOD *method,
27 const ASN1_OCTET_STRING *oct);
28 ASN1_OCTET_STRING *s2i_ASN1_OCTET_STRING(X509V3_EXT_METHOD *method,
29 X509V3_CTX *ctx, const char *str);
30 char *i2s_ASN1_ENUMERATED(X509V3_EXT_METHOD *method, const ASN1_ENUMERATED *a);
31 char *i2s_ASN1_ENUMERATED_TABLE(X509V3_EXT_METHOD *method,
32 const ASN1_ENUMERATED *e);
34 char *i2s_ASN1_UTF8STRING(X509V3_EXT_METHOD *method,
35 ASN1_UTF8STRING *utf8);
36 ASN1_UTF8STRING *s2i_ASN1_UTF8STRING(X509V3_EXT_METHOD *method,
37 X509V3_CTX *ctx, const char *str);
41 These functions convert OpenSSL objects to and from their ASN.1/string
42 representation. This function is used for B<X509v3> extensions.
46 The letters B<i> and B<s> in B<i2s> and B<s2i> stand for
47 "internal" (that is, an internal C structure) and string respectively.
48 So B<i2s_ASN1_IA5STRING>() converts from internal to string.
50 It is the caller's responsibility to free the returned string.
51 In the B<i2s_ASN1_IA5STRING>() function the string is copied and
52 the ownership of the original string remains with the caller.
56 B<i2s_ASN1_IA5STRING>() returns the pointer to a IA5 string
57 or NULL if an error occurs.
59 B<s2i_ASN1_IA5STRING>() return a valid
60 B<ASN1_IA5STRING> structure or NULL if an error occurs.
62 B<i2s_ASN1_INTEGER>() return a valid
63 string or NULL if an error occurs.
65 B<s2i_ASN1_INTEGER>() returns the pointer to a B<ASN1_INTEGER>
66 structure or NULL if an error occurs.
68 B<i2s_ASN1_OCTET_STRING>() returns the pointer to a OCTET_STRING string
69 or NULL if an error occurs.
71 B<s2i_ASN1_OCTET_STRING>() return a valid
72 B<ASN1_OCTET_STRING> structure or NULL if an error occurs.
74 B<i2s_ASN1_ENUMERATED>() return a valid
75 string or NULL if an error occurs.
77 B<s2i_ASN1_ENUMERATED>() returns the pointer to a B<ASN1_ENUMERATED>
78 structure or NULL if an error occurs.
80 B<s2i_ASN1_UTF8STRING>() return a valid
81 B<ASN1_UTF8STRING> structure or NULL if an error occurs.
83 B<i2s_ASN1_UTF8STRING>() returns the pointer to a UTF-8 string
84 or NULL if an error occurs.
88 i2s_ASN1_UTF8STRING() and s2i_ASN1_UTF8STRING() were made public in OpenSSL 3.0.
92 Copyright 2020-2021 The OpenSSL Project Authors. All Rights Reserved.
94 Licensed under the Apache License 2.0 (the "License"). You may not use
95 this file except in compliance with the License. You can obtain a copy
96 in the file LICENSE in the source distribution or at
97 L<https://www.openssl.org/source/license.html>.