Changeset 64864 in vbox
- Timestamp:
- Dec 14, 2016 1:38:16 PM (8 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/asn1.h
r64820 r64864 187 187 RTDECL(PRTASN1ALLOCATION) RTAsn1MemInitAllocation(PRTASN1ALLOCATION pAllocation, PCRTASN1ALLOCATORVTABLE pAllocator); 188 188 189 /** Pointer to a core ASN.1 encoding info structure. */ 190 typedef struct RTASN1CORE *PRTASN1CORE; 191 /** Pointer to a const core ASN.1 encoding info structure. */ 192 typedef struct RTASN1CORE const *PCRTASN1CORE; 193 189 194 RTDECL(int) RTAsn1ContentAllocZ(struct RTASN1CORE *pAsn1Core, size_t cb, PCRTASN1ALLOCATORVTABLE pAllocator); 190 195 RTDECL(int) RTAsn1ContentDup(struct RTASN1CORE *pAsn1Core, void const *pvSrc, size_t cbSrc, PCRTASN1ALLOCATORVTABLE pAllocator); … … 192 197 RTDECL(void) RTAsn1ContentFree(struct RTASN1CORE *pAsn1Core); 193 198 194 195 196 /** Pointer to a core ASN.1 encoding info structure. */197 typedef struct RTASN1CORE *PRTASN1CORE;198 /** Pointer to a const core ASN.1 encoding info structure. */199 typedef struct RTASN1CORE const *PCRTASN1CORE;200 199 201 200 … … 1001 1000 RTASN1_IMPL_GEN_SEQ_OF_TYPEDEFS_AND_PROTOS(RTASN1SEQOFOBJIDS, RTASN1OBJID, RTDECL, RTAsn1SeqOfObjIds); 1002 1001 RTASN1_IMPL_GEN_SET_OF_TYPEDEFS_AND_PROTOS(RTASN1SETOFOBJIDS, RTASN1OBJID, RTDECL, RTAsn1SetOfObjIds); 1002 RTASN1_IMPL_GEN_SET_OF_TYPEDEFS_AND_PROTOS(RTASN1SETOFOBJIDSEQS, RTASN1SEQOFOBJIDS, RTDECL, RTAsn1SetOfObjIdSeqs); 1003 1003 1004 1004 … … 1064 1064 /** Core ASN.1 encoding details. */ 1065 1065 RTASN1CORE Asn1Core; 1066 /** Pointer to user structure encapsulated in this string, if dynamically 1067 * allocated the EncapsulatedAllocation member can be used to track it and 1068 * trigger automatic cleanup on object destruction. If EncapsulatedAllocation 1069 * is zero, any object pointed to will only be deleted. */ 1066 /** Pointer to user structure encapsulated in this string. 1067 * 1068 * If dynamically allocated the EncapsulatedAllocation member can be used to 1069 * track it and trigger automatic cleanup on object destruction. If 1070 * EncapsulatedAllocation is zero, any object pointed to will only be 1071 * deleted. */ 1070 1072 PRTASN1CORE pEncapsulated; 1071 1073 /** Allocation tracking structure for pEncapsulated. */ -
trunk/include/iprt/crypto/digest.h
r64817 r64864 216 216 RTDECL(const char *) RTCrDigestTypeToName(RTDIGESTTYPE enmDigestType); 217 217 218 /** 219 * Translates an IPRT digest type value to a hash size. 220 * 221 * @returns Hash size (in bytes). 222 * @param enmDigestType The IPRT digest type value to convert. 223 */ 224 RTDECL(uint32_t) RTCrDigestTypeToHashSize(RTDIGESTTYPE enmDigestType); 225 218 226 /** @} */ 219 227 -
trunk/include/iprt/mangling.h
r64817 r64864 2591 2591 # define RTAsn1SetOfObjIds_Enum RT_MANGLER(RTAsn1SetOfObjIds_Enum) 2592 2592 # define RTAsn1SetOfObjIds_Init RT_MANGLER(RTAsn1SetOfObjIds_Init) 2593 # define RTAsn1SeqOfObjIdSeqs_CheckSanity RT_MANGLER(RTAsn1SeqOfObjIdSeqs_CheckSanity) 2594 # define RTAsn1SeqOfObjIdSeqs_Clone RT_MANGLER(RTAsn1SeqOfObjIdSeqs_Clone) 2595 # define RTAsn1SeqOfObjIdSeqs_Compare RT_MANGLER(RTAsn1SeqOfObjIdSeqs_Compare) 2596 # define RTAsn1SeqOfObjIdSeqs_Delete RT_MANGLER(RTAsn1SeqOfObjIdSeqs_Delete) 2597 # define RTAsn1SeqOfObjIdSeqs_Enum RT_MANGLER(RTAsn1SeqOfObjIdSeqs_Enum) 2598 # define RTAsn1SeqOfObjIdSeqs_Init RT_MANGLER(RTAsn1SeqOfObjIdSeqs_Init) 2599 # define RTAsn1SetOfObjIdSeqs_CheckSanity RT_MANGLER(RTAsn1SetOfObjIdSeqs_CheckSanity) 2600 # define RTAsn1SetOfObjIdSeqs_Clone RT_MANGLER(RTAsn1SetOfObjIdSeqs_Clone) 2601 # define RTAsn1SetOfObjIdSeqs_Compare RT_MANGLER(RTAsn1SetOfObjIdSeqs_Compare) 2602 # define RTAsn1SetOfObjIdSeqs_Delete RT_MANGLER(RTAsn1SetOfObjIdSeqs_Delete) 2603 # define RTAsn1SetOfObjIdSeqs_Enum RT_MANGLER(RTAsn1SetOfObjIdSeqs_Enum) 2604 # define RTAsn1SetOfObjIdSeqs_Init RT_MANGLER(RTAsn1SetOfObjIdSeqs_Init) 2593 2605 # define RTAsn1ObjId_DecodeAsn1 RT_MANGLER(RTAsn1ObjId_DecodeAsn1) 2594 2606 # define RTAsn1SeqOfObjIds_DecodeAsn1 RT_MANGLER(RTAsn1SeqOfObjIds_DecodeAsn1) … … 2778 2790 # define RTCrDigestTypeToAlgorithmOid RT_MANGLER(RTCrDigestTypeToAlgorithmOid) 2779 2791 # define RTCrDigestTypeToName RT_MANGLER(RTCrDigestTypeToName) 2792 # define RTCrDigestTypeToHashSize RT_MANGLER(RTCrDigestTypeToHashSize) 2780 2793 # define RTCrRsaDigestInfo_DecodeAsn1 RT_MANGLER(RTCrRsaDigestInfo_DecodeAsn1) 2781 2794 # define RTCrRsaOtherPrimeInfo_DecodeAsn1 RT_MANGLER(RTCrRsaOtherPrimeInfo_DecodeAsn1) -
trunk/src/VBox/Runtime/common/asn1/asn1-ut-objid-template.h
r62477 r64864 44 44 #undef RTASN1TMPL_INT_NAME 45 45 46 47 #define RTASN1TMPL_TYPE RTASN1SETOFOBJIDSEQS 48 #define RTASN1TMPL_EXT_NAME RTAsn1SetOfObjIdSeqs 49 #define RTASN1TMPL_INT_NAME rtAsn1SetOfObjIdSeqs 50 RTASN1TMPL_SET_OF(RTASN1SEQOFOBJIDS, RTAsn1SeqOfObjIds); 51 #undef RTASN1TMPL_TYPE 52 #undef RTASN1TMPL_EXT_NAME 53 #undef RTASN1TMPL_INT_NAME 54 -
trunk/src/VBox/Runtime/common/crypto/digest-core.cpp
r64817 r64864 419 419 } 420 420 421 422 RTDECL(uint32_t) RTCrDigestTypeToHashSize(RTDIGESTTYPE enmDigestType) 423 { 424 switch (enmDigestType) 425 { 426 case RTDIGESTTYPE_CRC32: return 32 / 8; 427 case RTDIGESTTYPE_CRC64: return 64 / 8; 428 case RTDIGESTTYPE_MD2: return 128 / 8; 429 case RTDIGESTTYPE_MD4: return 128 / 8; 430 case RTDIGESTTYPE_MD5: return 128 / 8; 431 case RTDIGESTTYPE_SHA1: return 160 / 8; 432 case RTDIGESTTYPE_SHA224: return 224 / 8; 433 case RTDIGESTTYPE_SHA256: return 256 / 8; 434 case RTDIGESTTYPE_SHA384: return 384 / 8; 435 case RTDIGESTTYPE_SHA512: return 512 / 8; 436 case RTDIGESTTYPE_SHA512T224: return 224 / 8; 437 case RTDIGESTTYPE_SHA512T256: return 256 / 8; 438 default: 439 AssertFailed(); 440 return 0; 441 } 442 } 443
Note:
See TracChangeset
for help on using the changeset viewer.