poly1305

The Poly1305 message authentication code (docs.ppad.tech/poly1305).
git clone git://git.ppad.tech/poly1305.git
Log | Files | Refs | README | LICENSE

commit 541e883fc36426224a149b058fa20b70e195aa13
parent ed28a72b8862727df0f60b19e903254e214c2319
Author: Jared Tobin <jared@jtobin.io>
Date:   Sat, 31 Oct 2026 11:38:36 +0400

release: v0.4.7

Diffstat:
MCHANGELOG | 9+++++++++
Mflake.lock | 8++++----
Mppad-poly1305.cabal | 10++++++++--
3 files changed, 21 insertions(+), 6 deletions(-)

diff --git a/CHANGELOG b/CHANGELOG @@ -1,5 +1,14 @@ # Changelog +- 0.4.7 (2026-10-31) + * Bumps the ppad-fixed dependency to 0.2.1, which under the llvm + flag on x86_64 compiles ppad-fixed with LLVM's x86 cmov converter + off (-optlc=-x86-cmov-converter=false). This library is compiled + likewise, as ppad-fixed's constant-time arithmetic can be inlined + into it. + + * Crypto.MAC.Poly1305.Arm is no longer exposed. + - 0.4.6 (2026-08-01) * Merely bumps the ppad-fixed dependency. diff --git a/flake.lock b/flake.lock @@ -82,11 +82,11 @@ ] }, "locked": { - "lastModified": 1785603497, - "narHash": "sha256-rF8KdVJ+VwUT2bEfCLZMPc05rUclr0wN2uOTYvd3z7g=", + "lastModified": 1793121974, + "narHash": "sha256-kw5niq662nriUKNS71Opf+pe8E1NjfbcRX7Jpq/7fSQ=", "ref": "master", - "rev": "e303bda7578385f488c2f23baa2e1a6a2b0b2aaf", - "revCount": 305, + "rev": "cc87b097fdf31b2cab66104e9e09dcfe21e82678", + "revCount": 308, "type": "git", "url": "git://git.ppad.tech/fixed.git" }, diff --git a/ppad-poly1305.cabal b/ppad-poly1305.cabal @@ -1,6 +1,6 @@ cabal-version: 3.0 name: ppad-poly1305 -version: 0.4.6 +version: 0.4.7 synopsis: A fast Poly1305 MAC license: MIT license-file: LICENSE @@ -35,6 +35,12 @@ library -Wall if flag(llvm) ghc-options: -fllvm -O2 + -- LLVM's x86 backend rewrites a cmov whose operand is a load as a + -- branch (its cmov converter), which would make the borrow-masked + -- correction of ppad-fixed's sub_mod# (inlinable here) a branch on + -- the borrow; keep the cmov. + if flag(llvm) && arch(x86_64) + ghc-options: -optlc=-x86-cmov-converter=false exposed-modules: Crypto.MAC.Poly1305 other-modules: @@ -43,7 +49,7 @@ library build-depends: base >= 4.9 && < 5 , bytestring >= 0.9 && < 0.13 - , ppad-fixed >= 0.2 && < 0.3 + , ppad-fixed >= 0.2.1 && < 0.3 c-sources: cbits/poly1305_arm.c if arch(aarch64)