asn1ber.h File Reference
#include "rtsrc/asn1type.h"
Go to the source code of this file.
Classes | |
struct | _Asn1BufLocDescr |
Defines | |
#define | ASN_K_INDEFLEN -9999 |
#define | XU_DUMP(msg) xu_dump(msg,0,0) |
#define | xd_resetp(pctxt) rtxResetContext(pctxt) |
#define | ASN1TAG2BYTE(tag) ((OSOCTET)(((tag)&TM_B_IDCODE)|((tag)>>ASN1TAG_LSHIFT))) |
#define | xd_utf8str(pctxt, object_p, tagging, length) xd_charstr (pctxt, (const char**)object_p, tagging, ASN_ID_UTF8String, length) |
#define | xd_indeflen(m) xd_indeflen_ex(m, INT_MAX) |
#define | xe_utf8str(pctxt, object_p, tagging) xe_charstr (pctxt, (const char*)object_p, tagging, ASN_ID_UTF8String) |
#define | xu_addTagErrParm berErrAddTagParm |
#define | xu_hex_dump(msg, numoct, hdr) rtxHexDump(msg,numoct) |
#define | XD_MEMCPY1(pctxt, object_p) |
#define | XD_FETCH1(pctxt) ((pctxt)->buffer.data[(pctxt)->buffer.byteIndex++]) |
#define | XD_PEEKTAG(pctxt, tag) (((pctxt)->buffer.data[(pctxt)->buffer.byteIndex] & (~0x20)) == (tag & (~0x20))) |
#define | XD_PEEKPC(pctxt) (((pctxt)->buffer.data[(pctxt)->buffer.byteIndex] & 0x20) == 0x20) |
#define | XD_MATCHEOC(pctxt) |
#define | XD_MATCHBYTES1(pctxt, b1) ((pctxt)->buffer.data[(pctxt)->buffer.byteIndex] == b1) |
#define | XD_MATCHBYTES2(pctxt, b1, b2) |
#define | XD_MATCHBYTES3(pctxt, b1, b2, b3) |
#define | XD_MATCHBYTES4(pctxt, b1, b2, b3, b4) |
#define | XD_MATCHBYTES5(pctxt, b1, b2, b3, b4, b5) |
#define | XD_BUMPIDX(pctxt, nbytes) ((pctxt)->buffer.byteIndex += nbytes) |
#define | XD_CHKBUFEND(pctxt) |
#define | XD_CHKDEFLEN(pctxt, len) |
#define | XD_CHKEOB(pctxt) |
#define | XD_CHKEND(pctxt, ccb_p) |
#define | XE_CHKBUF(pctxt, len) |
#define | XE_PUT1(pctxt, ch) (pctxt)->buffer.data[--(pctxt)->buffer.byteIndex] = ch; |
#define | XE_PUT2(pctxt, ch1, ch2) |
#define | XE_SAFEPUT1(pctxt, ch) XE_CHKBUF(pctxt,1); (pctxt)->buffer.data[--(pctxt)->buffer.byteIndex] = ch; |
Typedefs | |
typedef struct _Asn1BufLocDescr | Asn1BufLocDescr |
Functions | |
int | xd_tag (OSCTXT *pctxt, ASN1TAG *tag_p) |
int | xd_tag_len (OSCTXT *pctxt, ASN1TAG *tag_p, int *len_p, OSOCTET flags) |
int | xd_match (OSCTXT *pctxt, ASN1TAG tag, int *len_p, OSOCTET flags) |
int | xd_boolean (OSCTXT *pctxt, OSBOOL *object_p, ASN1TagType tagging, int length) |
int | xd_integer (OSCTXT *pctxt, OSINT32 *object_p, ASN1TagType tagging, int length) |
int | xd_int8 (OSCTXT *pctxt, OSINT8 *object_p, ASN1TagType tagging, int length) |
int | xd_int16 (OSCTXT *pctxt, OSINT16 *object_p, ASN1TagType tagging, int length) |
int | xd_unsigned (OSCTXT *pctxt, OSUINT32 *object_p, ASN1TagType tagging, int length) |
int | xd_uint8 (OSCTXT *pctxt, OSUINT8 *object_p, ASN1TagType tagging, int length) |
int | xd_uint16 (OSCTXT *pctxt, OSUINT16 *object_p, ASN1TagType tagging, int length) |
int | xd_int64 (OSCTXT *pctxt, OSINT64 *object_p, ASN1TagType tagging, int length) |
int | xd_uint64 (OSCTXT *pctxt, OSUINT64 *object_p, ASN1TagType tagging, int length) |
int | xd_bigint (OSCTXT *pctxt, const char **object_p, ASN1TagType tagging, int length) |
int | xd_bitstr_s (OSCTXT *pctxt, OSOCTET *object_p, OSUINT32 *numbits_p, ASN1TagType tagging, int length) |
int | xd_bitstr (OSCTXT *pctxt, const OSOCTET **object_p2, OSUINT32 *numbits_p, ASN1TagType tagging, int length) |
int | xd_octstr_s (OSCTXT *pctxt, OSOCTET *object_p, OSUINT32 *pnumocts, ASN1TagType tagging, int length) |
int | xd_octstr (OSCTXT *pctxt, const OSOCTET **object_p2, OSUINT32 *pnumocts, ASN1TagType tagging, int length) |
int | xd_charstr (OSCTXT *pctxt, const char **object_p, ASN1TagType tagging, ASN1TAG tag, int length) |
int | berDecCharArray (OSCTXT *pctxt, char *charArray, OSSIZE arraySize, ASN1TagType tagging, ASN1TAG tag, int length) |
int | xd_16BitCharStr (OSCTXT *pctxt, Asn116BitCharString *object_p, ASN1TagType tagging, ASN1TAG tag, int length) |
int | xd_32BitCharStr (OSCTXT *pctxt, Asn132BitCharString *object_p, ASN1TagType tagging, ASN1TAG tag, int length) |
int | xd_null (OSCTXT *pctxt, ASN1TagType tagging) |
int | xd_objid (OSCTXT *pctxt, ASN1OBJID *object_p, ASN1TagType tagging, int length) |
int | xd_oid64 (OSCTXT *pctxt, ASN1OID64 *object_p, ASN1TagType tagging, int length) |
int | xd_reloid (OSCTXT *pctxt, ASN1OBJID *object_p, ASN1TagType tagging, int length) |
int | xd_real (OSCTXT *pctxt, OSREAL *object_p, ASN1TagType tagging, int length) |
int | xd_enum (OSCTXT *pctxt, OSINT32 *object_p, ASN1TagType tagging, int length) |
int | xd_enumUnsigned (OSCTXT *pctxt, OSUINT32 *object_p, ASN1TagType tagging, int length) |
int | xd_OpenType (OSCTXT *pctxt, const OSOCTET **object_p2, OSUINT32 *pnumocts) |
int | xd_OpenTypeExt (OSCTXT *pctxt, ASN1CCB *ccb_p, ASN1TAG tag, OSRTDList *pElemList) |
int | xd_OpenTypeAppend (OSCTXT *pctxt, OSRTDList *pElemList) |
int | xd_real10 (OSCTXT *pctxt, const char **object_p, ASN1TagType tagging, int length) |
int | xd_setp (OSCTXT *pctxt, const OSOCTET *msg_p, int msglen, ASN1TAG *tag_p, int *len_p) |
int | xd_indeflen_ex (const OSOCTET *msg_p, int bufSize) |
int | xd_len (OSCTXT *pctxt, int *len_p) |
int | xd_chkend (OSCTXT *pctxt, ASN1CCB *ccb_p) |
int | xd_count (OSCTXT *pctxt, int length, int *count_p) |
int | xd_NextElement (OSCTXT *pctxt) |
int | xd_Tag1AndLen (OSCTXT *pctxt, OSINT32 *len_p) |
int | xd_memcpy (OSCTXT *pctxt, OSOCTET *object_p, int length) |
int | xd_match1 (OSCTXT *pctxt, OSOCTET tag, int *len_p) |
int | xdf_tag (FILE *fp, ASN1TAG *ptag, OSOCTET *buffer, int *pbufidx) |
int | xdf_len (FILE *fp, OSINT32 *plen, OSOCTET *buffer, int *pbufidx) |
int | xdf_TagAndLen (FILE *fp, ASN1TAG *ptag, OSINT32 *plen, OSOCTET *buffer, int *pbufidx) |
int | xdf_ReadPastEOC (FILE *fp, OSOCTET *buffer, int bufsiz, int *pbufidx) |
int | xdf_ReadContents (FILE *fp, int len, OSOCTET *buffer, int bufsiz, int *pbufidx) |
int | xe_tag_len (OSCTXT *pctxt, ASN1TAG tag, int length) |
int | xe_boolean (OSCTXT *pctxt, OSBOOL *object_p, ASN1TagType tagging) |
int | xe_integer (OSCTXT *pctxt, int *object_p, ASN1TagType tagging) |
int | xe_unsigned (OSCTXT *pctxt, OSUINT32 *object_p, ASN1TagType tagging) |
int | xe_int8 (OSCTXT *pctxt, OSINT8 *object_p, ASN1TagType tagging) |
int | xe_int16 (OSCTXT *pctxt, OSINT16 *object_p, ASN1TagType tagging) |
int | xe_int64 (OSCTXT *pctxt, OSINT64 *object_p, ASN1TagType tagging) |
int | xe_uint64 (OSCTXT *pctxt, OSUINT64 *object_p, ASN1TagType tagging) |
int | xe_uint8 (OSCTXT *pctxt, OSUINT8 *object_p, ASN1TagType tagging) |
int | xe_uint16 (OSCTXT *pctxt, OSUINT16 *object_p, ASN1TagType tagging) |
int | xe_bigint (OSCTXT *pctxt, const char *object_p, ASN1TagType tagging) |
int | xe_bitstr (OSCTXT *pctxt, const OSOCTET *object_p, OSUINT32 numbits, ASN1TagType tagging) |
int | xe_octstr (OSCTXT *pctxt, const OSOCTET *object_p, OSUINT32 numocts, ASN1TagType tagging) |
int | xe_charstr (OSCTXT *pctxt, const char *object_p, ASN1TagType tagging, ASN1TAG tag) |
int | xe_16BitCharStr (OSCTXT *pctxt, Asn116BitCharString *object_p, ASN1TagType tagging, ASN1TAG tag) |
int | xe_32BitCharStr (OSCTXT *pctxt, Asn132BitCharString *object_p, ASN1TagType tagging, ASN1TAG tag) |
int | xe_null (OSCTXT *pctxt, ASN1TagType tagging) |
int | xe_objid (OSCTXT *pctxt, ASN1OBJID *object_p, ASN1TagType tagging) |
int | xe_oid64 (OSCTXT *pctxt, ASN1OID64 *object_p, ASN1TagType tagging) |
int | xe_reloid (OSCTXT *pctxt, ASN1OBJID *object_p, ASN1TagType tagging) |
int | xe_enum (OSCTXT *pctxt, OSINT32 *object_p, ASN1TagType tagging) |
int | xe_enumUnsigned (OSCTXT *pctxt, OSUINT32 *object_p, ASN1TagType tagging) |
int | xe_real (OSCTXT *pctxt, OSREAL *object_p, ASN1TagType tagging) |
int | xe_OpenType (OSCTXT *pctxt, const OSOCTET *object_p, OSUINT32 numocts) |
int | xe_OpenTypeExt (OSCTXT *pctxt, OSRTDList *pElemList) |
int | xe_real10 (OSCTXT *pctxt, const char *object_p, ASN1TagType tagging) |
int | xe_derReal10 (OSCTXT *pctxt, const char *object_p, ASN1TagType tagging) |
int | xe_setp (OSCTXT *pctxt, OSOCTET *buf_p, int bufsiz) |
OSOCTET * | xe_getp (OSCTXT *pctxt) |
void | xe_free (OSCTXT *pctxt) |
int | xe_expandBuffer (OSCTXT *pctxt, size_t length) |
int | xe_memcpy (OSCTXT *pctxt, const OSOCTET *object_p, size_t length) |
int | xe_len (OSCTXT *pctxt, int length) |
int | xe_derCanonicalSort (OSCTXT *pctxt, OSRTSList *pList) |
int | xe_TagAndIndefLen (OSCTXT *pctxt, ASN1TAG tag, int length) |
void | xe_getBufLocDescr (OSCTXT *pctxt, OSUINT32 length, Asn1BufLocDescr *pDescr) |
int | derEncBitString (OSCTXT *pctxt, const OSOCTET *pvalue, OSUINT32 numbits, ASN1TagType tagging) |
int | berDefToIndefLen (OSCTXT *pSrcCtxt, OSCTXT *pDstCtxt) |
int | berIndefToDefLen (OSCTXT *pSrcCtxt, OSCTXT *pDstCtxt) |
OSBOOL | berErrAddTagParm (OSCTXT *pctxt, ASN1TAG tag) |
int | berErrUnexpTag (OSCTXT *pctxt, ASN1TAG exptag) |
int | berGetLibVersion () |
const char * | berGetLibInfo () |
int | berParseTagLen (const OSOCTET *buffer, size_t bufidx, size_t bufsize, ASN1TAG *ptag, size_t *plen) |
const char * | berTagToString (ASN1TAG tag, char *buffer, size_t bufsiz) |
const char * | berTagToDynStr (OSCTXT *pctxt, ASN1TAG tag) |
int | xu_verify_len (OSOCTET *msg_p) |
void * | xu_parse_mmbuf (OSOCTET **buf_p2, int *buflen_p, OSOCTET *start_p, int bufsiz) |
void | xu_alloc_array (OSCTXT *pctxt, ASN1SeqOf *seqOf_p, int recSize, int recCount) |
void | xu_octscpy_s (OSUINT32 *nocts_p, OSOCTET *data_p, char *cstr, char zterm) |
void | xu_octscpy_ss (ASN1OctStr *octStr_p, char *cstring, char zterm) |
void | xu_octscpy_d (OSCTXT *pctxt, OSUINT32 *nocts_p, const OSOCTET **data_p2, char *cstring, char zterm) |
void | xu_octscpy_ds (OSCTXT *pctxt, ASN1DynOctStr *octStr_p, char *cstring, char zterm) |
void | xu_octmcpy_s (ASN1OctStr *octStr_p, void *data_p, int datalen) |
void | xu_octmcpy_d (OSCTXT *pctxt, ASN1DynOctStr *octStr_p, void *data_p, int datalen) |
char * | xu_fetchstr (int numocts, char *data) |
int | xu_hexstrcpy (char *data, char *hstring) |
int | xu_binstrcpy (char *data, char *bstring) |
int | xu_dump (const OSOCTET *msgptr, ASN1DumpCbFunc cb, void *cbArg_p) |
int | xu_fdump (FILE *file_p, const OSOCTET *msgptr) |
int | xu_dump2 (OSCTXT *pctxt, const OSOCTET *msgptr) |
void | xu_fmt_tag (ASN1TAG *tag_p, char *class_p, char *form_p, char *id_code) |
char * | xu_fmt_contents (OSCTXT *pctxt, int len, int *count) |
int | xu_fread (FILE *fp, OSOCTET *bufp, int bufsiz) |
void | xu_SaveBufferState (OSCTXT *pCtxt, OSRTBufSave *pSavedInfo) |
void | xu_RestoreBufferState (OSCTXT *pCtxt, OSRTBufSave *pSavedInfo) |
Detailed Description
ASN.1 runtime constants, data structure definitions, and functions to support the Basic Encoding Rules (BER) and Distinguished Encoding Rules (DER) as defined in the ITU-T X.690 standard.