JSON Credentials

A public key certificate is a credential comprising a collection of attributes bound to a public key by the signature of the credential issuer. Since they were introduced by Loren Kohnfelder in his 1978 thesis, and especially since they were standardized in the X.509 specification, public key certificates have been the mainstay of public key cryptography.

X.509 uses Abstract Syntax Notation One (ASN.1), which is difficult to use and debug. Developers much prefer using JavaScript Object Notation (JSON) because it is derived from the notation used by JavaScript for object literals. Over the last 15 years, developers have used JSON instead of ASN.1 for various cryptographic purposes, including for the design of new kinds of credentials with new issuance and presentation protocols.

JSON has many advantages over ASN.1, but instead of using new credentials encoded in JSON, we prefer to use traditional public key certificates encoded in JSON rather ASN.1. We refer to a traditional public key certificate encoded in JSON as a JSON certificate, and to a credential comprising a JSON certificate and the associated private key as a JSON credential.

We have used JSON certificates in a demonstration of a driver’s license credential usable for website registration and traffic stops at IIW XLI in October 2025, then in an online demonstration of cross-device replication of that credential in June 2026.

Some of the new credentials encoded in JSON provide selective disclosure, a feature not available in X.509 certificates. We provide selective disclosure in JSON certificates by defining a full disclosure format and a selective disclosure format.

In the full disclosure format, the attributes are properties of an object. In the selective disclosure format, on the other hand, the attributes are items of an array. Each attribute is encoded as an object, with two properties called "saltedAttribute" and "digest_hex", where the value of the "digest_hex" property is a hex-encoded digest of the value of the "saltedAttribute" property. The value of the "saltedAttribute" property is itself an object with three properties, called "name", "value" and "salt_hex", where the value of the "name" property is the name of the attribute, the value of "value" property is the value of the attribute, and the value of the "salt_hex" property is a hex-encoded random salt. An attribute is omitted from a presentation by removing the "saltedAttribute" property. The signature on the certificate is computed and verified after removing all "saltedAttribute" properties, and a disclosed attribute is verified by comparing the digest of its "saltedAttribute" property to the value of its "digest_hex" property.