<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-size:small"><br></div></div><br><div class="gmail_quote"><div dir="ltr">On Fri, Jan 4, 2019 at 7:16 PM Patrick Chkoreff <<a href="mailto:pc@fexl.com">pc@fexl.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Phillip Hallam-Baker wrote on 1/3/19 1:29 PM:<br>
<br>
> UDF=KD25H-GSNE2-JVVJE-RXTMA-7VAWT<br>
> UDF=KCOO3-EKPAG-FKYFC-O2B2N-O3UUA<br>
> UDF=KBR3A-RQLV7-SMB6X-6OB7X-JMBNT  <br>
<br>
Ooh, I've tagged this email as "Later" so I can go back to that.  How<br>
will I go about verifying those when the secrets are divulged?  (Pardon<br>
me if I haven't been paying attention in class here.)<br></blockquote><div><br></div><div><div class="gmail_default" style="font-size:small">OK so I have decided to make a few changes to the structure here so the values will change.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Let us say that m = "Konrad is a Kompromised agent".</div><div class="gmail_default" style="font-size:small">first choose a random key kt = P (0xB0 || rand (512), 125)</div><div class="gmail_default" style="font-size:small">(where P is the presentation/truncation function using Base32 putting in dashes every 5 characters and truncating to 125 bits)</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">We use SHA-2-512 to construct a Keyed UDF, so HKDF(), H(), HMAC() are functions all using that as the base digest:</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">k = HKDF (kt, 512)</div><div class="gmail_default" style="font-size:small">f = HMAC (k, ct || ':' || H(m))</div><div class="gmail_default" style="font-size:small">udf = P((v || f), 125)</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Where v is simply a tag to identify the fingerprint type and ct is the IANA content type </div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">So the core here is that we have a fingerprint of the data that can only be verified if the key kt is known. Since this is a keyed digest, we are using an HMAC for the purpose.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">I have pushed out the code to GitHub but I need to clean it up a bit. The version prefixes have been chosen so that the version number shows the fingerprint type. A SHA-2 fingerprint will always start with an M (Merkle-Damguard) and SHA-3 will always start with an S (Spongeworthy). Random numbers will always start with R and I had chosen K for Keyed hash.</div></div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">It since occurs to me that I should probably use K for actual Keys so maybe I need to move the prefixes about.</div><div class="gmail_default" style="font-size:small"><br></div></div></div>