Here a first version that includes poly1305 to the chacha cipher - tests according to rfc7539 are included.
The code is far from beeing ready but it's a start

There are also some changes to the base classes... so if one could take a look at it would be great...
Still - I guess if the Mr. Humm likes the changes I need to figure on how to create a pull request on that lib....
Well, somebody is creating security risks by leaking real names of forum users

I think the other version presented in this thread only works on x86/x64 systems because of
ASM usage.
Correct? While I like the use of AVX code to speed things up any implementation which shall get added to
DEC
one daymust also have a pure pascal implementation for cross platform compatibility.
Oh and about autodetection whether a CPU supports AVX: somewhere in system.pas is some code available for
querying CPUID and from that one can find out if it supports AVX/AVX2.
Oh and since the current minimum supported Delphi version is 10.1 any version of Delphi prior to the one with
built in AVX
asm support (11.0 Alexandria) needs to use the pure Pascal implementation.
That's my take for this evening on this one.