[jose] Summary of JWS detached signature

Richard Barnes <rlb@ipv.sx> Mon, 15 July 2013 22:56 UTC

Return-Path: <rlb@ipv.sx>
X-Original-To: jose@ietfa.amsl.com
Delivered-To: jose@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 1B7F721E8174 for <jose@ietfa.amsl.com>; Mon, 15 Jul 2013 15:56:33 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.976
X-Spam-Level:
X-Spam-Status: No, score=-2.976 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DU6uL8gc9dHc for <jose@ietfa.amsl.com>; Mon, 15 Jul 2013 15:56:16 -0700 (PDT)
Received: from mail-oa0-f53.google.com (mail-oa0-f53.google.com [209.85.219.53]) by ietfa.amsl.com (Postfix) with ESMTP id 9CD8F21E8160 for <jose@ietf.org>; Mon, 15 Jul 2013 15:56:16 -0700 (PDT)
Received: by mail-oa0-f53.google.com with SMTP id k14so8767oag.26 for <jose@ietf.org>; Mon, 15 Jul 2013 15:56:15 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-originating-ip:date:message-id:subject:from:to :content-type:x-gm-message-state; bh=h2oD7LkmnM2W3OnGjjQG1j+9PRNtkWeM82Ir1eyU2k4=; b=DYM1ojxcDBjIeQ3BI4k3EgejJidN5173X5Q5zrcg8lbTIsxBCMcUwTVYCBsboshm6R ZPhpabaYUx2harFsbvGkqKG803NjZCrmjf/67hNL0ofA9ASzfqNUt3sXtvz3K3lUUg3L 5cskiBvHSAi7JZCCPRYZS+jzA2gde9XA700MJZrfYVKHUrHggWh4xDXqpJpTNg+27nyT 98NztEg4cQd8iGVXrnYZk7p/CzFLVgRbZMFMSxG7zjwpy9NcBRllxVGY26lV/FqSaC6e XB81RXlpzLYYrSwwETCasEmJ2/DU5iBOueAXg35fi9gH9uV3T0SomibD1LG1zgeNRJqf 3WpA==
MIME-Version: 1.0
X-Received: by 10.60.43.226 with SMTP id z2mr45658905oel.76.1373928975847; Mon, 15 Jul 2013 15:56:15 -0700 (PDT)
Received: by 10.60.26.135 with HTTP; Mon, 15 Jul 2013 15:56:15 -0700 (PDT)
X-Originating-IP: [128.89.253.152]
Date: Mon, 15 Jul 2013 18:56:15 -0400
Message-ID: <CAL02cgRuXgYeqXsW2=KBnC+hSYny9UARKjm1xPwkqP4fHba3ag@mail.gmail.com>
From: Richard Barnes <rlb@ipv.sx>
To: "jose@ietf.org" <jose@ietf.org>
Content-Type: multipart/alternative; boundary="001a11333dce8d5e6e04e194c4ba"
X-Gm-Message-State: ALoCoQmK/5DaRTE4oVL7NpuGBvVSE2HlTTvK5gcb48mrcwcTf5+P2/WAL4fRCclVDZWYN5tbKM9R
Subject: [jose] Summary of JWS detached signature
X-BeenThere: jose@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Javascript Object Signing and Encryption <jose.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/jose>, <mailto:jose-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/jose>
List-Post: <mailto:jose@ietf.org>
List-Help: <mailto:jose-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/jose>, <mailto:jose-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 15 Jul 2013 22:56:33 -0000

Suppose an application wanted to carry a signature over an HTTP entity body
in a header:

-----BEGIN-Example-----
HTTP/1.1 200 OK
Content-Type: text/plain
Content-Length: 5
Content-Signature: { "unprotected": { "alg": "RS256", "jku": "
http://example.com/key" }, "signature": "..." }

fnord
-----END-Example-----

Note that the content of the "Content-Signature" header is the same thing
that would go in an element of the "signatures" array.  So the application
would simply specify that a recipient should reconstruct a full JWS-JSON
from the following template:

{
    "payload": base64($ENTITY_BODY),
    "recipients": [$CONTENT_SIGNATURE]
}

That's what I meant when I said the revised JWS-JSON layout makes detached
signature trivial :)

--Richard