Subject: RE: [dhcwg] Open issues in DHCP FQDN, DHCID and DDNS-DHCP Related RFCs

From: "Bernie Volz \(volz\)" <[email-masked]>
Date: Sat, 25 Feb 2006 16:37:24 -0500

Here's my calculation of the 3 examples in the DHCID RR draft.

Example 1:
     client.example.com.   A       10.0.0.1
     client.example.com.   DHCID   AAABxLmlskllE0MVjd57zHcWmEH3pCQ6VytcKD//7es/deY=

Example 2:
     chi.example.com.      A       10.0.12.99
     chi.example.com.      DHCID   AAEBOSD+XR3Os/0LozeXVqcNc7FwCfQdWL3b/NaiUDlW2No=

Example 3:
     chi6.example.com.     AAAA    2000::1234:5678
     chi6.example.com.     DHCID   AAIBY2/AuCccgoJbsaxcQc9TUapptP69lOjxfNuVAA2kjEA=

When calculating the SHA-256 hash, the following data patterns were used:

unsigned char example_1_data[] = {
	0x01,								// ethernet type code
	0x01, 0x02, 0x03, 0x04, 0x05, 0x06,			// mac address
	6, 'c', 'l', 'i', 'e', 'n', 't',
	7, 'e', 'x', 'a', 'm', 'p', 'l', 'e',
	3, 'c', 'o', 'm',
	0 };

unsigned char example_2_data[] = {
	0x01, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c,		// client identifier
	3, 'c', 'h', 'i',
	7, 'e', 'x', 'a', 'm', 'p', 'l', 'e',
	3, 'c', 'o', 'm',
	0 };

unsigned char example_3_data[] = {
	0x00, 0x01, 0x00, 0x06, 0x41, 0x2d, 0xf1, 0x66,	// DUID
	      0x01, 0x02, 0x03, 0x04, 0x05, 0x06,
	4, 'c', 'h', 'i', '6',
	7, 'e', 'x', 'a', 'm', 'p', 'l', 'e',
	3, 'c', 'o', 'm',
	0 };

Before base64 encoding, the 2 octet identifier type and 1 octet digest type (=1) were added in front of  the resulting SHA-256 hash.

- Bernie

> -----Original Message-----
> From: Bernie Volz (volz) 
> Sent: Saturday, February 25, 2006 1:49 PM
> To: Ólafur Guðmundsson /DNSEXT co-chair
> Cc: [email-masked]; [email-masked]; Sam 
> Hartman; [email-masked]
> Subject: RE: [dhcwg] Open issues in DHCP FQDN,DHCID and 
> DDNS-DHCP Related RFCs
> 
> > Scanning the documents I'm concerned that the examples are TBD, thus
> > I request that at least 3 parties calculate the new digests and post
> > their results. After which the DHCID document is needs to 
> be updated.
> 
> I figured I'd wait until we settled on whether this was the 
> correct way to go before supplying the DHCID RR data for the 
> 3 examples. (I also didn't have a SHA-256 implementation 
> readily at hand to actually write a quick program but 
> implementations are readily available, such as in the OpenSSL 
> distribution. I wanted to get the updated draft out figuring 
> that the examples can be handled during the RFC editing process.)
> 
> - Bernie
> 
> _______________________________________________
> dhcwg mailing list
> [email-masked]
> https://www1.ietf.org/mailman/listinfo/dhcwg
> 

_______________________________________________
dhcwg mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/dhcwg

---

From: Mark Stapp <[email-masked]>
Date: Mon, 27 Feb 2006 10:11:29 -0500

Olafur,

I computed the sha256 hashes this morning using python 2.4 and the 
Crypto.SHA256 module, and got the same DHCID data for the three 
examples. I didn't think it would be necessary to post a transcript of 
the python command-lines or a script, but I could do that if you think 
it's helpful.

-- Mark