[Cryptography] Blockchain without proof of work

Mark Steward marksteward at gmail.com
Sat Jan 5 14:55:39 EST 2019


On Sat, Jan 5, 2019 at 7:46 AM Phillip Hallam-Baker
<phill at hallambaker.com> wrote:
...
>> > UDF=KD25H-GSNE2-JVVJE-RXTMA-7VAWT
>> > UDF=KCOO3-EKPAG-FKYFC-O2B2N-O3UUA
>> > UDF=KBR3A-RQLV7-SMB6X-6OB7X-JMBNT
...
>
> OK so I have decided to make a few changes to the structure here so the values will change.
>
> Let us say that m = "Konrad is a Kompromised agent".
> first choose a random key kt = P (0xB0 || rand (512), 125)
> (where P is the presentation/truncation function using Base32 putting in dashes every 5 characters and truncating to 125 bits)
>
> We use SHA-2-512 to construct a Keyed UDF, so HKDF(), H(), HMAC() are functions all using that as the base digest:
>
> k = HKDF (kt, 512)
> f = HMAC (k, ct || ':' || H(m))
> udf = P((v || f), 125)
>
> Where v is simply a tag to identify the fingerprint type and ct is the IANA content type
>

So that's effectively just HMAC(rand(117), m), truncated to 120 bits
(i.e. a birthday complexity of 60 bits). What purpose does the
obfuscation serve?

> 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.
>
> I have pushed out the code to GitHub but I need to clean it up a bit.

Is that this code?

  https://github.com/hallambaker/Mathematical-Mesh/blob/8f309a1/Libraries/Goedel.Cryptography/UDF.cs#L212-L222

That link is to some bizarre functionality to "compress" the output by
adding the number of leading zero bytes to the versionID, which
further reduces the hash to 117 bits, and allows fingerprints from two
different versions to collide.

Your convenient Validate function isn't constant time:

  https://github.com/hallambaker/Mathematical-Mesh/blob/8f309a1/Libraries/Goedel.Cryptography/UDF.cs#L407-L408

And throughout this library you've wrapped all the crypto functions in
a way that obscure their nature and leads to typos:

  https://github.com/hallambaker/Mathematical-Mesh/blob/8f309a1/Libraries/Goedel.Cryptography/UDF.cs#L39
  https://github.com/hallambaker/Mathematical-Mesh/blob/8f309a1/Libraries/Goedel.Cryptography/Standard/Digest.cs#L440
https://github.com/hallambaker/Mathematical-Mesh/blob/8f309a1/Libraries/Goedel.Cryptography/Standard/Digest.cs#L515
  https://github.com/hallambaker/Mathematical-Mesh/blob/8f309a1/Libraries/Goedel.Cryptography/Algorithms/SHA3Managed.cs#L94


Mark


More information about the cryptography mailing list