Questions tagged [asn.1]

ASN.1 stands for Abstract Syntax Notation One. It is a data specification language and a set of encoding rules for serializing the data.

ASN.1 stands for Abstract Syntax Notation One. It is part of the Presentation Layer of the OSI model.

ASN.1 specs covers two main roles:

  1. Specifies a notation to define data types and data values.
  2. Specifies different ways of encoding and decoding data values according to the syntax specifications.

Specifications

ASN.1 is an joint ISO/ITU-T standard. The documents covering the specs are:

771 questions
9
votes
4 answers

Is there a free package for reading, manipulating and writing ASN.1 in Java?

Is there a free package for reading, manipulating and writing ASN.1 in Java? It must be: Free Lightweight Self-contained (without external dependencies on, e.g. Apache commons) Java 5 (not Java 6), and Java 4 is preferred.
Lawrence Dol
  • 63,018
  • 25
  • 139
  • 189
9
votes
1 answer

Java implementation of C# SignedCms

I am working on an implementation of C# SignedCms functionality in Java. I am using bouncycastle libs. The problem is I get java signature that is different from the one generated with SignedCms. C# code X509Certificate2 certificate = new…
nixspirit
  • 509
  • 1
  • 7
  • 19
8
votes
3 answers

Retrieve Subject alternative names of X.509 certificate in java

I have tried using the solution provided in this link. I am getting following error when i tried reading subject alternative names of X.509 Certificate java.lang.NoSuchMethodError:…
LathaPatil
  • 143
  • 1
  • 3
  • 9
8
votes
2 answers

What is an ASN file and how do I use it?

I am trying to work with a communication protocol (S1AP to be specific) and I am trying to define messages to test. The LTE 36.413 specification details this protocol and also give an ASN.1 file definition at the bottom of the pdf. I have seen ASN…
Edwin
  • 797
  • 2
  • 14
  • 23
8
votes
2 answers

ASN.1 Octet Strings

I'm decoding a X.509 Certificate in ASN.1 format. I'm decoding it successfully, traversing the structure, but there is one thing that I don't understand. There are some scenarios where I get an octet string and this website that I am playing with…
Cocoanetics
  • 8,171
  • 2
  • 30
  • 57
7
votes
2 answers

How should I interpret the ASN.1 BER standard for REALs?

I have been reading X.690 "Information technology – ASN.1 encoding rules: Specification of Basic Encoding Rules (BER), Canonical Encoding Rules (CER) and Distinguished Encoding Rules (DER)" In particular, §8.5.6.4 (d), concerning a binary encoding…
Rhubbarb
  • 4,248
  • 6
  • 36
  • 40
7
votes
4 answers

Getting reasonable names for ASN.1 identifiers

Using the BouncyCastle library (although I guess the library is sort of irrelevant) I often run into algorithm IDs specified as ASN.1 identifiers. For example, the signature algorithm for a certificate might be "1.2.840.113549.1.1.11". Is there a…
Hakanai
  • 12,010
  • 10
  • 62
  • 132
7
votes
1 answer

Parsing PDOL for GET PROCESSING OPTIONS command in EMV transaction

I am trying to build a correctly formatted GET PROCESSING OPTIONS command to be sent to a contactless EMV card. This post has been very helpful but I just need to know a little more detail. When parsing the PDOL, is it safe to assume that each tag…
Scott Condron
  • 1,902
  • 16
  • 20
7
votes
1 answer

Go - decode/encode asn.1

Does anyone know where there is a good example of how to use the asn1 Marshal and Unmarshal funcs in Go? I'm familiar with the concept of how DER encoding with ASN.1 works, but do not have experience dealing with it directly in code (usually I'm…
Brad Peabody
  • 10,917
  • 9
  • 44
  • 63
7
votes
5 answers

Verify a DSA signature in C# that's using BER/DER encoded ASN.1 format

How can I verify a DSA signature in C#? Given: the message text, a signed digest (typically ASN.1 DER format), the public key (in a signed X.509 certificate, PEM or DER format) I've tried a number of approaches, but haven't had any…
andersop
  • 708
  • 1
  • 8
  • 12
7
votes
3 answers

How can I parse a raw SNMP trap in Perl?

A few weeks ago I wrote an SNMP relayer for our ops group. They have some dumb devices that can only send traps to a single IP, and we have a monitoring system that listens on multiple IPs for availability. The code's dead simple, and…
jj33
  • 7,543
  • 2
  • 38
  • 42
6
votes
2 answers

Java ASN.1 compiler

Right now I'm using BinaryNotes to parse ASN.1 files for use in a Java project. It takes an ASN.1 definition and produces Java class(s) that let me manipulate ASN.1 files. I've hit a wall with extension markers (...) because it doesn't support them.…
Andrew
  • 11,894
  • 12
  • 69
  • 85
6
votes
3 answers

Does a free general purpose ASN.1 Decode/Dump/Inspect program exist?

Does a free general purpose ASN.1 Decode/Dump/Inspect program exist? I have a suspect ASN.1 block which may have failed decryption, and I would like to inspect it to see it it appears valid, and if so what elements it contains.
Lawrence Dol
  • 63,018
  • 25
  • 139
  • 189
6
votes
2 answers

Unique Identifier for certificate Issuer (X509Name)

in my app I'm using the sha256 of the issuer Name (x509CertImpl.getIssuerDN().getName()) and the certificate serial number to uniquely identify a certificate, but now I have realized that other implementations of X509Name as the implementation of…
Jaime Hablutzel
  • 6,117
  • 5
  • 40
  • 57
6
votes
4 answers

ASN.1 Encoding-Decoding

I am currently developing a client-server program, the client in Java/C and server in C. I have to transport cryptographic data(like the client should pass data to Server to encrypt/decrypt, compute digest etc) and the server has to return the…
pimmling
  • 483
  • 5
  • 10
  • 19
1 2
3
51 52