From owner-spki@c2.net Mon May 3 12:00:53 1999 Received: from blacklodge.c2.net (blacklodge.c2.net [140.174.185.245]) by lox.sandelman.ottawa.on.ca (8.8.7/8.8.8) with ESMTP id MAA29556; Mon, 3 May 1999 12:00:51 -0400 (EDT) Received: (from majordom@localhost) by blacklodge.c2.net (8.8.8/8.7.3) id HAA06064 for spki-outgoing; Mon, 3 May 1999 07:53:10 -0700 (PDT) Message-Id: <3.0.3.32.19990503075227.034a9958@spiritone.com> X-Sender: cellison@spiritone.com X-Mailer: QUALCOMM Windows Eudora Pro Version 3.0.3 (32) Date: Mon, 03 May 1999 07:52:27 -0700 To: JoanMa Mas =?iso-8859-1?Q?Rib=E9s?= From: Carl Ellison Subject: Re: Question Cc: SPKI List In-Reply-To: <37289CB9.8D5CDDAE@tele.ucl.ac.be> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Sender: owner-spki@c2.net Precedence: bulk Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by lox.sandelman.ottawa.on.ca id MAA29556 -----BEGIN PGP SIGNED MESSAGE----- At 07:54 PM 4/29/99 +0200, JoanMa Mas Ribés wrote: > >List, > >I've started implementing a SPKI toolbox in Java, and right now I've a question >(which won't be the last) about comparing principals. > >If I've understood it correctly, the field in a public key is used to >point where you can get certificates on that key, right? I guess that the > field in the hash has the same purpose, when this hash is of a public >key. > >The question is, how do I compute the hash of a public key? I mean, should one >take the s-expression representing the whole key (uris included)? If so, should >I copy the field from the key into the hash? > >And when comparing principals for "samePrincipalAs", do I take into account >also the field? If the answer is yes, then a principal is not only a >public key or hash, but also the , which has the problem that we'd have 2 >different principals represented by the same key but with different >field. >And if not, then computing the hashing of a public key is a special case in >SPKI (it'd only be some more lines of code), which would first remove the > field in the public key, compute the hash and add in the hash. > >I hope I made myself clear. Thanks a lot in advance. > >JoanMa Yes, the hash of a public key is the hash of a canonical S-expression holding the public key. So, just alling it the key hash is slightly misleading. It is a placekeeper. You could have put the whole public key S-expression there, but if the other party already has that S-expression, then you can save space by using just the hash of it. Comparing principals, on the other hand, should be comparison of the key parameters. The question there (e.g., for tuple reduction) is whether K1 is the same key that made a given digital signature. -----BEGIN PGP SIGNATURE----- Version: PGP 6.5 iQCVAwUBNy24KhN3Wx8QwqUtAQFhNwQAje3YB+kDS/T7INxISrmNa1lDKNQkRt+o Kxa0HRvCCjiK9YZQ0n1rB1bwt2mFGZWxAWdwFd5OV8b+DWMu03aI6x3MNmayEsVU y9KOcQVGY7o3gDAuNajGAMBxwEIF5nGhZvmwU1IYdrtIgDrKBFU21Cc8WXByvevF y1T3oon1Vvk= =du6T -----END PGP SIGNATURE----- +------------------------------------------------------------------+ |Carl M. Ellison cme@acm.org http://www.pobox.com/~cme | | PGP: 08FF BA05 599B 49D2 23C6 6FFD 36BA D342 | +--Officer, officer, arrest that man. He's whistling a dirty song.-+