Security Advisories (4)
CVE-2026-57432 (2026-07-13)

Perl versions through 5.43.10 have an integer overflow in S_measure_struct leading to an out-of-bounds heap read in pack and unpack. S_measure_struct adds each item's size times its repeat count to a running total with no overflow check, so a large repeat count in a pack or unpack template wraps the signed SSize_t total negative. The @, X, and x position codes then guard their moves with a signed length comparison that passes when the length is negative, advancing the buffer pointer out of bounds. A template derived from untrusted input can read heap memory past the buffer and return it to the caller.

CVE-2026-13221 (2026-07-13)

Perl versions through 5.43.9 produce silently incorrect regular expression matches when an alternation of more than 65535 fixed string branches is compiled into a trie in Perl_study_chunk. When such branches are combined into a trie, the delta between the first branch and the shared tail is stored in a 16-bit field. A branch count above 65535 overflows the field, and the trie's match decision table is truncated with no warning or error. A pattern of this shape produces false positive matches (matching strings it should not) and false negative matches (failing to match strings it should). When such a pattern gates an access or filtering decision, the result is wrong.

CVE-2026-15534 (2026-08-09)

Perl versions through 5.45.1 have out-of-bounds heap reads and writes during regular expression matching via an undersized superlinear cache in S_regmatch. The regex engine's superlinear cache holds one bit per subject position for each participating WHILEM node, so the bit count is the subject length plus one times the number of nodes. Nothing checks that product for positive overflow of the signed 32-bit count: a 286331153 byte subject matched against a pattern with 15 participating nodes stores the count as 14, leaving a two byte cache. The cache is then indexed from the real match position and node number, so reads go past the end of the allocation, and on failure CACHEsayNO sets a bit past it. A caller that matches an attacker controlled subject of this size against a pattern of this shape can crash the process or corrupt heap memory.

CVE-2026-8376 (2026-05-25)

Perl versions through 5.43.10 have a heap buffer overflow when compiling regular expressions with a repeated fixed string on 32-bit builds. Perl_study_chunk in regcomp_study.c checked the size of the joined substring buffer in characters rather than bytes. For a quantified fixed substring with a large minimum count, the byte length mincount * l could overflow SSize_t, producing an undersized SvGROW allocation; the subsequent copy writes past the end of the buffer. A caller that compiles an attacker-controlled regular expression on a 32-bit perl build triggers a heap buffer overflow at compile time.

NAME

test-dist-modules.pl - test modules in dist/ against the perl invoked with

SYNOPSIS

# from a checked out clean perl source tree
# test all dist/ modules, abort on first failure
path/to/perl test-dist-modules.pl

# test all dist/ modules, continue on failure
path/to/perl test-dist-modules.pl -c

# test all dist/ modules, and install into path/to/perl's site_perl
path/to/perl test-dist-modules.pl -i

DESCRIPTION

Porting/test-dist-modules.pl is used by the Github workflow to test modules from dist/ against the perl it is invoked with, within a git clone of a development perl. This clone must be a clean clone, ie. as with git clean -dxf .

That perl should have any prerequisites needed by those modules installed, at this point this includes sufficiently recent versions of:

ExtUtils::MakeMaker
Perl::OSType
Scalar::Util
Socket
version

test-dist-modules.pl will always test Devel::PPPort first and then use that when testing the other modules, even if invoked with a distribution list.

INVOKING test-dist-modules.pl

By default test-dist-modules.pl will test each directory in dist/, but you can test specific distributions by supplying them on the command-line:

path/to/perl test-dist-modules.pl threads

which will test Devel-PPPort and threads.

Options:

  • -i

  • -install

    Install the modules to the invoking perl's site_perl. This may require privileges such as running as root.

  • -c

  • -continue

    Continue testing modules even if one fails.

  • -s

  • -separate

    Install to a temp tree instead of to the invoking perl's site_perl. This is now the default.

  • -h

  • -help

    Produce a help message.