1 =pod 2 3 =head1 NAME 4 5 ossl_print_attribute_value 6 - Print an X.500 directory attribute value 7 8 =head1 SYNOPSIS 9 10 #include <crypto/x509.h> 11 12 int ossl_print_attribute_value(BIO *out, int obj_nid, const ASN1_TYPE *av, int indent); 13 14 =head1 DESCRIPTION 15 16 ossl_print_attribute_value() prints an X.500 directory value, which is an 17 ASN.1 value and an associated attribute type that informs its interpretation, 18 syntax, display characteristics, comparison, sorting, and substring searching 19 behaviors, among other things. This attribute type is identified by an ASN.1 20 object identifier. 21 22 X.500 directory values are used in the relative distinguished names in a 23 distinguished name, as seen in the C<subject> and C<issuer> fields of an X.509 24 public key certificate. They also appear in the attributes of an X.509 25 attribute certificate, as well as in the subjectDirectoryAttributes or 26 associatedInformation X.509v3 extensions. 27 28 The I<out> argument is a B<BIO> pointer for printing the output. The I<obj_nid> 29 argument is the NID of the attribute type object identifier. The ASN.1 value 30 itself is passed in I<av> and the level of desired indentation in terms of the 31 number of spaces is specified in I<indent>. 32 33 This function generally prints values in such a way as to keep them on a single 34 line, but this is not always the case. Unrecognized attribute types whose syntax 35 is a C<SET> or C<SEQUENCE> will be printed on multiple lines, for instance. Not 36 all ASN.1 syntaxes are currently supported, and there is no guarantee for what 37 printed values will look like in future versions. 38 39 =head1 RETURN VALUES 40 41 Returns 1 if it succeeds in printing, and 0 if it failed. 42 43 =head1 COPYRIGHT 44 45 Copyright 2024 The OpenSSL Project Authors. All Rights Reserved. 46 47 Licensed under the Apache License 2.0 (the "License"). You may not use 48 this file except in compliance with the License. You can obtain a copy 49 in the file LICENSE in the source distribution or at 50 L<https://www.openssl.org/source/license.html>. 51 52 =cut 53