From e23ac9e5679f0ab2bb6425fcd017ca3bba7df4c0 Mon Sep 17 00:00:00 2001
From: ringe <runar@rin.no>
Date: Fri, 9 Mar 2012 21:40:28 +0100
Subject: [PATCH] Add some more about the public key

---
 docs/PRIMARY_PROTOCOL.md | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/docs/PRIMARY_PROTOCOL.md b/docs/PRIMARY_PROTOCOL.md
index c0d31fbdf..ff13f3225 100644
--- a/docs/PRIMARY_PROTOCOL.md
+++ b/docs/PRIMARY_PROTOCOL.md
@@ -285,8 +285,18 @@ authentication page should include a javascript shim, hosted at:
 
 ### 6.1 Public Key Format
 
-BrowserID public keys make use of Cryptographic Algorithms for JWS as [listed here](http://self-issued.info/docs/draft-ietf-jose-json-web-algorithms-00.html#SigningAlgs).
-The private/public key pair can be generated using OpenSSL.
+The public key is a JSON Web Algorihtms (JWA) public key as [listed here](http://self-issued.info/docs/draft-ietf-jose-json-web-algorithms-00.html#SigningAlgs).
+This is a private/public key pair than can be generated using OpenSSL. The
+EyeDeeMe service has a [.well-known/browserid document](https://eyedee.me/.well-known/browserid)
+that shows exactly what the [Mozilla Wiki](https://wiki.mozilla.org/Identity/BrowserID#Public_Key)
+means in the example.
+
+Generate a public key JSON document in Ruby:
+
+    private_key = OpenSSL::PKey::RSA.new(1024)
+    public_key = private_key.public_key
+    {"algorithm"=> "RS", "n" => public_key.n.to_s, "e" => public_key.e.to_s }.to_json
+    
 
 ### 6.2 Certificate Format
 
-- 
GitLab