Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
X509_ATTRIBUTE_GET0... FreeBSD Library Functions Manual	X509_ATTRIBUTE_GET0...

NAME
     X509_ATTRIBUTE_get0_object, X509_ATTRIBUTE_count,
     X509_ATTRIBUTE_get0_type, X509_ATTRIBUTE_get0_data	-- X.501 Attribute
     read accessors

SYNOPSIS
     #include <openssl/x509.h>

     ASN1_OBJECT *
     X509_ATTRIBUTE_get0_object(X509_ATTRIBUTE *attr);

     int
     X509_ATTRIBUTE_count(const	X509_ATTRIBUTE *attr);

     ASN1_TYPE *
     X509_ATTRIBUTE_get0_type(X509_ATTRIBUTE *attr, int	index);

     void *
     X509_ATTRIBUTE_get0_data(X509_ATTRIBUTE *attr, int	index, int type,
	 void *data);

DESCRIPTION
     These functions provide read access to the	X.501 Attribute	object attr.

     For X509_ATTRIBUTE_get0_data(), the type argument usually is one of the
     V_ASN1_* constants	defined	in <openssl/asn1.h>.  For example, if a	return
     value of the type ASN1_OCTET_STRING is expected, pass V_ASN1_OCTET_STRING
     as	the type argument.  The	data argument is ignored; passing NULL is rec-
     ommended.

RETURN VALUES
     X509_ATTRIBUTE_get0_object() returns an internal pointer to the type of
     attr or NULL if attr is NULL or if	its type is not	set.

     X509_ATTRIBUTE_count() returns the	number of values stored	in attr	or 0
     if	no value or values are set.

     X509_ATTRIBUTE_get0_type()	returns	an internal pointer to the ASN.1 ANY
     object representing the value with	the given zero-based index or NULL if
     attr is NULL, if the index	is larger than or equal	to the number of val-
     ues stored	in attr, or if no value	or values are set.

     X509_ATTRIBUTE_get0_data()	returns	an internal pointer to the data	con-
     tained in the value with the given	zero-based index or NULL if attr is
     NULL, if the index	is larger than or equal	to the number of values	stored
     in	attr, if no value or values are	set, or	if the ASN.1 ANY object	repre-
     senting the value with the	given index is not of the requested type.

SEE ALSO
     ASN1_OBJECT_new(3), ASN1_TYPE_new(3), OPENSSL_sk_new(3),
     X509_ATTRIBUTE_new(3), X509_ATTRIBUTE_set1_object(3)

HISTORY
     These functions first appeared in OpenSSL 0.9.5 and have been available
     since OpenBSD 2.7.

FreeBSD	13.0		       October 21, 2021			  FreeBSD 13.0

NAME | SYNOPSIS | DESCRIPTION | RETURN VALUES | SEE ALSO | HISTORY

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=X509_ATTRIBUTE_get0_object&sektion=3&manpath=FreeBSD+13.1-RELEASE+and+Ports>

home | help