[Cryptography] New Hash and RNG functions

Pierre Abbat phma at bezitopo.org
Fri Jan 3 17:11:14 EST 2025


On Friday, 3 January 2025 07:04:18 EST Jacob Christian Munch-Andersen wrote:
> On Thu, Jan 2, 2025, at 11:46 PM, Pierre Abbat wrote:
> > In reference.c, where do tjaldr_seed and tjaldr_sbox come from?
> 
> tjaldr_seed is the default seed, it is pi (3.243F6... in base 16).
> tjaldr_sbox is the AES sbox, named so to keep a consistent namespace.

Sounds good. π has been used in other ciphers as a nothing-up-my-sleeve 
number. I recently commented the number 40504 in the WringTwistree key 
schedule (or should that be called key expansion?); it's near 65537/φ.

> On Thu, Jan 2, 2025, at 11:46 PM, Pierre Abbat wrote:
> > The repo has no build system. (This is not about cryptography, but about
> > open- source software in general.) I strongly suggest setting it up with
> > a build system, such as CMake (what I use for C++ programs) or Autotools,
> > so that users can use the same commands to build it as for other
> > programs, and delete the object files, which the build system will
> > produce.
> 
> The fact that you suggest two different tools already make an issue, what
> will the users of the other tool do? I have tried to make toolless building
> as simple as possible, hopefully transplanting the command line into your
> favourite build tool shouldn't be too difficult. The object files are there
> so that installing NASM and Node.js is optional.

What you're writing is a library, so your audience is software developers, who 
know that to compile any software that uses CMake, you type "cd <builddir>; 
cmake <sourcedir>; make". CMake finds out whether the compiler is gcc, cc, or 
clang, where other libraries are located, etc., and writes a Makefile (or 
build.ninja if you use Ninja). Even if you're used to Autotools, the CMake 
commands are a lot easier than typing dozens of gcc commands.

C predates build systems, so there are several build systems for C programs, 
all of which (afaik) are also used for C++ programs. Julia, Rust, and Haskell 
have their own build systems. (Haskell has two; Cabal and Stack both use the 
Cabal library.)

> On Thu, Jan 2, 2025, at 11:46 PM, Pierre Abbat wrote:
> > Have you tested it on big-endian hardware?
> 
> No. In general this requires some testing on all the computers that I don't
> have. Whatever you build it for, please run the self test.

I've been wanting for years to get a Power box, but don't have the money. 
Hopefully this year I will.

Pierre
-- 
I believe in Yellow when I'm in Sweden and in Black when I'm in Wales.





More information about the cryptography mailing list