RE: How to enable certificate purpose programmatically?
- From: jetan@xxxxxxxxxxxxxxxxxxxx ("Jeffrey Tan[MSFT]")
- Date: Wed, 26 Apr 2006 08:21:04 GMT
Hi Gak,
Thanks for your feedback.
This blob is base64 encoded. You can use certutil ¨Cdecode to turn the
base64 text into a binary file, and use ¡°certutil ¨Cencodehex
BinaryInputFile HexadecimalOutputFile.txt 4¡± to turn the binary file into
hexadecimal text.
Below is an ASN dump (the ¨Casn verb requires Windows Vista certutil.exe),
that shows what the hex byes mean.
You can edit the hexadecimal text file and use certutil ¨Cdecodehex, then
certutil ¨Cencode to convert it back to base64 text.
The second byte (0x40) is the length of the remaining bytes. If you remove
any of the below, you will have to edit this byte.
C:> certutil -asn base64.txt
0000: 30 40 BER_SEQUENCE (40 Bytes)
0002: 06 0a BER_OBJECT_ID (a Bytes)
0004: | 2b 06 01 04 01 82 37 14 02 02
| -- 1.3.6.1.4.1.311.20.2.2 Smart Card Logon
000e: 06 0a BER_OBJECT_ID (a Bytes)
0010: | 2b 06 01 04 01 82 37 0a 03 04
| -- 1.3.6.1.4.1.311.10.3.4 Encrypting File System
001a: 06 08 BER_OBJECT_ID (8 Bytes)
001c: | 2b 06 01 05 05 07 03 04
| -- 1.3.6.1.5.5.7.3.4 Secure Email
0024: 06 08 BER_OBJECT_ID (8 Bytes)
0026: | 2b 06 01 05 05 07 03 03
| -- 1.3.6.1.5.5.7.3.3 Code Signing
002e: 06 08 BER_OBJECT_ID (8 Bytes)
0030: | 2b 06 01 05 05 07 03 02
| -- 1.3.6.1.5.5.7.3.2 Client Authentication
0038: 06 08 BER_OBJECT_ID (8 Bytes)
003a: 2b 06 01 05 05 07 03 01
-- 1.3.6.1.5.5.7.3.1 Server Authentication
CertUtil: -asn command completed successfully.
Hope this helps!
Best regards,
Jeffrey Tan
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
.
- Follow-Ups:
- RE: How to enable certificate purpose programmatically?
- From: Vlad Hrybok
- RE: How to enable certificate purpose programmatically?
- References:
- RE: How to enable certificate purpose programmatically?
- From: "Jeffrey Tan[MSFT]"
- RE: How to enable certificate purpose programmatically?
- Prev by Date: RE: Access Violation Releasing CComPtr<IAzAuthorizationStore>
- Next by Date: finding a certificate context in the certificate store meeting a search criterion.
- Previous by thread: RE: How to enable certificate purpose programmatically?
- Next by thread: RE: How to enable certificate purpose programmatically?
- Index(es):