decode_asn1_data
Decodes hex or base64 encoded ASN.1 binary data into a decoded ASN.1 value string according to the provided schema definition, ASN.1 type name, and encoding rule (DER by default).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"schemaContent": "<schemaContent>",
"typeName": "<typeName>",
"data": "<data>"
},
"name": "decode_asn1_data"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | Hex or base64 encoded binary data string to be decoded. | |
| codec | No | The ASN.1 encoding rule used to encode the data. Valid options include 'DER', 'BER', 'PER', 'UPER' or 'CUPER', 'OER' or 'COER', 'JER', 'XML or 'XER' or 'EXER'. Defaults to 'DER'. | DER |
| userId | No | The user's email address to look up the asn1.io user account. If unknown, pass an empty string. | |
| fileName | No | The name of the schema file. This should end in '.asn' (e.g., 'Rocket.asn'). If not provided, defaults to 'schema.asn'. | schema.asn |
| typeName | Yes | The ASN.1 type name (PDU) to decode into (e.g., 'Rocket'). | |
| dataFormat | No | Format of the input encoded data string: 'hex' or 'base64'. Defaults to 'hex'. | hex |
| schemaContent | Yes | Plain-text ASN.1 schema definition. This must be valid ASN.1 syntax, typically starting with the 'DEFINITIONS' keyword and concluding with 'END'. |