From ec5806b8e2956941bae8da9199f62223ca1b9e3c Mon Sep 17 00:00:00 2001 From: Stig Palmquist Date: Thu, 18 Jan 2024 20:12:19 +0100 Subject: [PATCH] perlPackages.SessionToken: add patch Add patch from upstream to fix missing NULL-byte bug in tokens --- pkgs/top-level/perl-packages.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index 572ccc701e51..e1e4f350ceb8 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -22426,6 +22426,13 @@ with self; { url = "mirror://cpan/authors/id/F/FR/FRACTAL/Session-Token-1.503.tar.gz"; hash = "sha256-MsPflu9FXHGHA2Os2VDdxPvISMWU9LxVshtEz5efeaE="; }; + patches = [ + # Add final null-byte to tokens. https://github.com/hoytech/Session-Token/pull/3 + (fetchpatch { + url = "https://github.com/hoytech/Session-Token/commit/cd64e7b69986054bb715755290811308159b7959.patch"; + hash = "sha256-nMQmdvVQW8cQYO0+bLJcdVfSOLVIsongk+71fQ7fQdU="; + }) + ]; meta = { description = "Secure, efficient, simple random session token generation"; homepage = "https://github.com/hoytech/Session-Token";