Re: [apps-discuss] [pkix] PKIX text encodings

Martin Rex <> Fri, 27 January 2012 18:11 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 7EBFD21F866E; Fri, 27 Jan 2012 10:11:25 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -8.943
X-Spam-Status: No, score=-8.943 tagged_above=-999 required=5 tests=[AWL=-1.108, BAYES_40=-0.185, HELO_EQ_DE=0.35, RCVD_IN_DNSWL_HI=-8]
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id aTlwWshBA1mC; Fri, 27 Jan 2012 10:11:24 -0800 (PST)
Received: from ( []) by (Postfix) with ESMTP id CC6A621F8655; Fri, 27 Jan 2012 10:11:23 -0800 (PST)
Received: from by (26) with ESMTP id q0RIB65p020677 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 27 Jan 2012 19:11:06 +0100 (MET)
From: Martin Rex <>
Message-Id: <>
Date: Fri, 27 Jan 2012 19:11:05 +0100
In-Reply-To: <> from "Simon Josefsson" at Jan 27, 12 02:45:06 pm
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-SAP: out
X-Mailman-Approved-At: Fri, 27 Jan 2012 11:09:59 -0800
Subject: Re: [apps-discuss] [pkix] PKIX text encodings
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: General discussion of application-layer protocols <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Fri, 27 Jan 2012 18:11:25 -0000


Simon Josefsson wrote:
> See announcement below for a document that attempts to describe the
> de-facto deployed usage of so called "PEM encoding" of X.509 related
> data blobs, including the '-----BEGIN CERTIFICATE-----' format.  Many
> applications and security libraries rely on these formats, but to my
> knowledge they have never been standardized and there is unfortunately
> some confusion and ambiguity as a result.
the Label that is used within '-----BEGIN <some-label>----'
should be ignored on the receiver side, and all implemented formats
should be tried, that are applicable for the requested operation.

Normally, these PEM-framed base64 encodings are used for administrative
interfaces used by humans that are used with a low frequency,
rather for authentication exchanges that are used with a high
frequency. For administrative user interfaces it is usually sensible to
spend a few extra CPU cycles to improve the usability.

Strongly recommeding standardized labelling on output of these formats
is OK, and may facilitate troubleshooting.

But on input, e.g. when processing a certification response, the
administrative interface should IMO be tolerant to accept a single
certificate (provided the remaining certs required to build a
complete path are already present), accept a sequence of several
certificates, or a PKCS#7 container carry multiple certificates,
independent of what labels are used with BEGIN/END.

When the administrative interface has access to the PKI credentials
for which a certification response is to be processed, then it
can detect the end-entity cert automatically, compose the full
and correctly ordererd certificate chain automatically, and ignore
any superfluous/unrelated certs that may have been part of the input.

Btw. PKCS#7 can also be used as a carry bag for multiple CRLs,
which can be used to allow revocation checking in offline
scenarios or on isolated networks.