Lines Matching refs:type

59 asn_get_header(struct asn_buf *b, u_char *type, asn_len_t *len)  in asn_get_header()  argument
67 *type = *b->asn_cptr; in asn_get_header()
68 if ((*type & ASN_TYPE_MASK) > 0x1e) { in asn_get_header()
70 *type & ASN_TYPE_MASK); in asn_get_header()
162 asn_put_header(struct asn_buf *b, u_char type, asn_len_t len) in asn_put_header() argument
167 if ((type & ASN_TYPE_MASK) > 0x1e) { in asn_put_header()
169 type & ASN_TYPE_MASK); in asn_put_header()
175 *b->asn_ptr++ = type; in asn_put_header()
200 asn_put_temp_header(struct asn_buf *b, u_char type, u_char **ptr) in asn_put_temp_header() argument
207 if ((ret = asn_put_header(b, type, ASN_MAXLEN)) == ASN_ERR_OK) in asn_put_temp_header()
293 asn_put_real_integer(struct asn_buf *b, u_char type, int64_t ival) in asn_put_real_integer() argument
321 if ((ret = asn_put_header(b, type, OCTETS - i))) in asn_put_real_integer()
386 asn_put_real_unsigned(struct asn_buf *b, u_char type, uint64_t val) in asn_put_real_unsigned() argument
402 if ((ret = asn_put_header(b, type, OCTETS - i))) in asn_put_real_unsigned()
442 u_char type; in asn_get_integer() local
445 if ((err = asn_get_header(b, &type, &len)) != ASN_ERR_OK) in asn_get_integer()
447 if (type != ASN_TYPE_INTEGER) { in asn_get_integer()
448 asn_error(b, "bad type for integer (%u)", type); in asn_get_integer()
498 u_char type; in asn_get_octetstring() local
501 if ((err = asn_get_header(b, &type, &len)) != ASN_ERR_OK) in asn_get_octetstring()
503 if (type != ASN_TYPE_OCTETSTRING) { in asn_get_octetstring()
504 asn_error(b, "bad type for octetstring (%u)", type); in asn_get_octetstring()
550 u_char type; in asn_get_null() local
554 if ((err = asn_get_header(b, &type, &len)) != ASN_ERR_OK) in asn_get_null()
556 if (type != ASN_TYPE_NULL) { in asn_get_null()
557 asn_error(b, "bad type for NULL (%u)", type); in asn_get_null()
638 u_char type; in asn_get_objid() local
642 if ((err = asn_get_header(b, &type, &len)) != ASN_ERR_OK) in asn_get_objid()
644 if (type != ASN_TYPE_OBJID) { in asn_get_objid()
645 asn_error(b, "bad type for OBJID (%u)", type); in asn_get_objid()
746 u_char type; in asn_get_sequence() local
749 if ((err = asn_get_header(b, &type, len)) != ASN_ERR_OK) in asn_get_sequence()
751 if (type != (ASN_TYPE_SEQUENCE|ASN_TYPE_CONSTRUCTED)) { in asn_get_sequence()
752 asn_error(b, "bad sequence type %u", type); in asn_get_sequence()
795 u_char type; in asn_get_ipaddress() local
799 if ((err = asn_get_header(b, &type, &len)) != ASN_ERR_OK) in asn_get_ipaddress()
801 if (type != (ASN_CLASS_APPLICATION|ASN_APP_IPADDRESS)) { in asn_get_ipaddress()
802 asn_error(b, "bad type for ip-address %u", type); in asn_get_ipaddress()
848 asn_put_uint32(struct asn_buf *b, u_char type, uint32_t val) in asn_put_uint32() argument
852 return (asn_put_real_unsigned(b, ASN_CLASS_APPLICATION|type, v)); in asn_put_uint32()
880 u_char type; in asn_get_timeticks() local
883 if ((err = asn_get_header(b, &type, &len)) != ASN_ERR_OK) in asn_get_timeticks()
885 if (type != (ASN_CLASS_APPLICATION|ASN_APP_TIMETICKS)) { in asn_get_timeticks()
886 asn_error(b, "bad type for timeticks %u", type); in asn_get_timeticks()