Click here to Skip to main content
Click here to Skip to main content

ASN.1 Editor

By , 30 Jun 2008
 
ASN.1 Editor Main Screen

Introduction

Abstract Syntax Notation One (ASN.1) Distinguished Encoding Rule (DER) encoded data is widely used in digital security protocols (i.e. X509 digital certificate). The encoded data is not readable by regular text editors. The Asn1Processor Library is designed to parse and modify ASN.1 DER encoded data. The ASN.1 Editor is a sample project that uses the Asn1Processor library to view and to edit DER encoded data. The Asn1Processor Library source code and reference documentation (Asn1EditorLib.chm) are also included in the downloadable source code zip file.

The ASN.1 Editor doesn't do any schema checking. The user needs to make sure the edited data conforms to certain constrains (i.e. OCSP request or Key Info structure).

Main Features

1. Dump Text Format Data

You can view the selected node branch text dump by right-clicking the designated node and selecting "View Node Text". View Node Text

2. Atomically Parse “Encapsulates” Data

OCTET and BITSTRING may encapsulate ASN.1 DER encoded data, for example:

Encapsulate Parse Sample

The ASN.1 Editor can automatically parse the data structure.

3. Hex Data Viewer

Click "View->Hex Viewer" and you can view the binary data structure.

Hex Viewer

4. Extensible OID Table

OID.txt file is installed in the same directory as Asn1Editor.EXE.

Here are the sample records:

0.9.2342.19200300.100.1.25, domainComponent
1.2.36.68980861.1.1.10, Signet pilot
1.2.36.68980861.1.1.11, Signet intraNet
1.2.36.68980861.1.1.2, Signet personal
1.2.36.68980861.1.1.20, Signet securityPolicy

The OID and the description are comma separated. It can be extended in order to add in additional OIDs.

5. Change Node Content

Double click the selected node and you can see the "Node Content Editor".

Node Content Editor

6. Save Selected Node Data into Another File

You can save the designated node data into a file by right-clicking the node and selecting "Save selected node as...".

7. Copy Selected Node Data into Clipboard

Right-click the node and select "Copy".

8. Paste Node Data from Clipboard

Right-click the insertion point node and select "Paste as last child node", "Paste before current node", or "Paste after current node" to perform the insert operation.

9. Binary/Hex/Base64 Data Converter

Convert the data format between Hex, Base64, and PEM using the "Data Converter".

Data Converter

History

  • 3rd September, 2003: Initial post
  • 29th June, 2008: Updated source code and installer
    The changes are mainly for bug fixing, Visual Studio 2005, and Vista support.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

About the Author

Liping Dai
Software Developer (Senior)
United States United States
Liping Dai has worked in IT industry more than 17 years. He moved to Canada in 1996. After worked in Toronto for 4 years, he relocated to Silicon Valley. He has strong passion in the area of Multi-core/Multi thread programming, Parallel Computing, Image Reorganization, Secure Communication, and Mobile Device development.

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
Hint: For improved responsiveness ensure Javascript is enabled and choose 'Normal' from the Layout dropdown and hit 'Update'.
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
GeneralNice tool, but can't handle 'indefinite' lengthmemberQistoph17-Mar-11 11:39 
GeneralRe: Nice tool, but can't handle 'indefinite' length [modified]memberdheijl17-Nov-11 3:40 
GeneralRe: Nice tool, but can't handle 'indefinite' lengthmemberQistoph17-Nov-11 21:28 
Thanks dheijl, I'll definitely give this a try soon.
 
I'm just not sure if it'll work; what if, for example, an indefinite length tag contains an octet stream which contains data with two zero-bytes?
GeneralRe: Nice tool, but can't handle 'indefinite' lengthmemberdheijl17-Nov-11 21:39 
GeneralRe: Nice tool, but can't handle 'indefinite' lengthmemberQistoph17-Nov-11 21:46 
GeneralExcellent tool, + problemmemberCodyBatt14-Dec-10 11:39 
GeneralMy vote of 5memberAlastair Taylor7-Oct-10 2:50 
GeneralAssigning ASN.1 BER file for decodingmemberkkonline55522-Mar-10 5:55 
GeneralASN1 VisualizermemberKinslayerUY17-Sep-09 6:01 
General[Message Removed]memberKatekortez25-Oct-08 9:30 
GeneralConverting signed data (with PKCS7) to ASN1NodememberAsaf Levy22-Apr-08 19:12 
GeneralRe: Converting signed data (with PKCS7) to ASN1NodememberKinslayerUY17-Sep-09 5:53 
QuestionWriting ASN.1 specification for an audio file (.WAV)memberASN1keith24-Feb-08 11:45 
GeneralI want to convert Base 64 certificate to DER formatmemberyetty200028-Jun-07 21:08 
GeneralFile DERmemberSara9781-Jun-05 5:44 
GeneralRe: File DERmemberLiping Dai1-Jun-05 19:52 
GeneralFile in title bar/file name on command linememberTony Morris12-May-05 18:20 
GeneralRe: File in title bar/file name on command linememberLiping Dai16-May-05 3:24 
GeneralRe: File in title bar/file name on command linememberTony Morris16-May-05 12:26 
GeneralINTEGER value 0 encoding errormemberJoe Hartford6-Apr-05 12:27 
GeneralRe: INTEGER value 0 encoding errormemberLiping Dai25-Apr-05 20:44 
QuestionIs this project still moving?memberTony Morris3-Apr-05 14:10 
AnswerRe: Is this project still moving?memberLiping Dai3-Apr-05 16:43 
GeneralRe: Is this project still moving?suss[Tony Morris]3-Apr-05 18:41 
GeneralRe: Is this project still moving?memberLiping Dai3-Apr-05 19:21 
GeneralRe: Is this project still moving?memberTony Morris4-Apr-05 18:09 
GeneralRe: Is this project still moving?memberLiping Dai4-Apr-05 20:10 
GeneralOID Encoding Errormemberjfrazier00426-Mar-05 9:08 
GeneralRe: OID Encoding ErrormemberLiping Dai27-Mar-05 12:46 
General.ber and . dermemberBigAzam23-Feb-05 15:02 
GeneralRe: .ber and . dersussAnonymous23-Feb-05 19:15 
GeneralRe: .ber and . dermemberBigAzam7-Apr-05 6:20 
QuestionHow to detect if the node has one or multiple tags?sussgreatx16-Feb-05 16:17 
AnswerRe: How to detect if the node has one or multiple tags?memberLiping Dai16-Feb-05 19:28 
GeneralOpening X509 signed files.membersillypuppy23-Jan-05 22:41 
GeneralRe: Opening X509 signed files.memberLiping Dai24-Jan-05 19:10 
GeneralRe: Opening X509 signed files.membersillypuppy24-Jan-05 23:48 
GeneralFantastic tool.membersillypuppy22-Jan-05 5:48 
GeneralRe: Fantastic tool.memberLiping Dai22-Jan-05 7:15 
GeneralRe: Fantastic tool.membersillypuppy23-Jan-05 1:33 
GeneralRe: Fantastic tool.memberLiping Dai23-Jan-05 8:15 
GeneralRe: Fantastic tool.membersillypuppy23-Jan-05 22:16 
GeneralGreat Stuff and Thanks for your generousnessmemberyianfang24-May-04 8:55 
GeneralRe: Great Stuff and Thanks for your generousnessmemberLiping Dai27-May-04 22:16 
GeneralI got itmemberCS_Sniper28-Dec-03 18:48 
GeneralThanksmemberLiping Dai4-Sep-03 1:44 
GeneralWhy such a low ratingmemberNormski3-Sep-03 21:01 
GeneralRe: Why such a low ratingmembersfeldi4-Sep-03 4:13 
GeneralRe: Why such a low ratingmemberNormski5-Sep-03 23:08 
GeneralRe: Why such a low ratingmemberLiping Dai6-Sep-03 8:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web01 | 2.6.130617.1 | Last Updated 30 Jun 2008
Article Copyright 2003 by Liping Dai
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid