Skip to content

Main content

DER Boolean Value Octet Tool

Compute der boolean value octet from explicit bounded inputs.

Loading tool…

Description

Return octet 255 for true and zero for false, using DER's canonical BOOLEAN content-octet convention.

ASN.1 BER encodes values as identifiers, lengths and content; DER constrains representation to a canonical form. Content octets, first-tag octets and length prefixes are only parts of a complete encoded value.

Return octet 255 for true and zero for false, using DER's canonical BOOLEAN content-octet convention.

When to use this tool

Use DER Boolean Value Octet when inspecting one explicit ASN.1 encoding component.

How to use the tool and how it works

  1. Enter value. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read octet. Use the output convention below.

Return octet 255 for true and zero for false, using DER's canonical BOOLEAN content-octet convention.1

ASN.1 encodings distinguish identifier, length and content octets. DER adds canonical constraints; the local output still needs its surrounding encoding.2

Input fieldMeaning and unitsAccepted input
valueValueRequired. Boolean.
Output fieldInterpretationReturned shape
octetOctetRequired. Safe integer.
json
{
  "input": {
    "value": true
  },
  "output": {
    "octet": 255
  }
}

Limitations and assumptions

  • This emits the content byte only. The BOOLEAN tag and length are not included, and more permissive BER encodings are not generated.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.

Alternative or Complementary methods

Use an appropriate complete ASN.1 encoder and schema for canonical full values, nested lengths and application semantics.

References

  1. Calculation and input contract: encode/der-boolean-value-octet — tool.io

  2. ASN.1 encoding rules: ITU-T X.690 (12/1997) — International Telecommunication Union

Similar or alternative tools