Security Advisories (19)
CVE-2020-12723 (2020-06-05)

regcomp.c in Perl before 5.30.3 allows a buffer overflow via a crafted regular expression because of recursive S_study_chunk calls.

CVE-2020-10878 (2020-06-05)

Perl before 5.30.3 has an integer overflow related to mishandling of a "PL_regkind[OP(n)] == NOTHING" situation. A crafted regular expression could lead to malformed bytecode with a possibility of instruction injection.

CVE-2020-10543 (2020-06-05)

Perl before 5.30.3 on 32-bit platforms allows a heap-based buffer overflow because nested regular expression quantifiers have an integer overflow.

CVE-2018-6797 (2018-04-17)

An issue was discovered in Perl 5.18 through 5.26. A crafted regular expression can cause a heap-based buffer overflow, with control over the bytes written.

CVE-2018-6913 (2018-04-17)

Heap-based buffer overflow in the pack function in Perl before 5.26.2 allows context-dependent attackers to execute arbitrary code via a large item count.

CVE-2018-18314 (2018-12-07)

Perl before 5.26.3 has a buffer overflow via a crafted regular expression that triggers invalid write operations.

CVE-2018-18313 (2018-12-07)

Perl before 5.26.3 has a buffer over-read via a crafted regular expression that triggers disclosure of sensitive information from process memory.

CVE-2018-18312 (2018-12-05)

Perl before 5.26.3 and 5.28.0 before 5.28.1 has a buffer overflow via a crafted regular expression that triggers invalid write operations.

CVE-2018-18311 (2018-12-07)

Perl before 5.26.3 and 5.28.x before 5.28.1 has a buffer overflow via a crafted regular expression that triggers invalid write operations.

CVE-2017-12883 (2017-09-19)

Buffer overflow in the S_grok_bslash_N function in regcomp.c in Perl 5 before 5.24.3-RC1 and 5.26.x before 5.26.1-RC1 allows remote attackers to disclose sensitive information or cause a denial of service (application crash) via a crafted regular expression with an invalid '\\N{U+...}' escape.

CVE-2017-12837 (2017-09-19)

Heap-based buffer overflow in the S_regatom function in regcomp.c in Perl 5 before 5.24.3-RC1 and 5.26.x before 5.26.1-RC1 allows remote attackers to cause a denial of service (out-of-bounds write) via a regular expression with a '\\N{}' escape and the case-insensitive modifier.

CVE-2015-8853 (2016-05-25)

The (1) S_reghop3, (2) S_reghop4, and (3) S_reghopmaybe3 functions in regexec.c in Perl before 5.24.0 allow context-dependent attackers to cause a denial of service (infinite loop) via crafted utf-8 data, as demonstrated by "a\x80."

CVE-2016-2381 (2016-04-08)

Perl might allow context-dependent attackers to bypass the taint protection mechanism in a child process via duplicate environment variables in envp.

CVE-2023-47100

In Perl before 5.38.2, S_parse_uniprop_string in regcomp.c can write to unallocated space because a property name associated with a \p{...} regular expression construct is mishandled. The earliest affected version is 5.30.0.

CVE-2024-56406 (2025-04-13)

A heap buffer overflow vulnerability was discovered in Perl. When there are non-ASCII bytes in the left-hand-side of the `tr` operator, `S_do_trans_invmap` can overflow the destination pointer `d`.    $ perl -e '$_ = "\x{FF}" x 1000000; tr/\xFF/\x{100}/;'    Segmentation fault (core dumped) It is believed that this vulnerability can enable Denial of Service and possibly Code Execution attacks on platforms that lack sufficient defenses.

CVE-2025-40909 (2025-05-30)

Perl threads have a working directory race condition where file operations may target unintended paths. If a directory handle is open at thread creation, the process-wide current working directory is temporarily changed in order to clone that handle for the new thread, which is visible from any third (or more) thread already running. This may lead to unintended operations such as loading code or accessing files from unexpected locations, which a local attacker may be able to exploit. The bug was introduced in commit 11a11ecf4bea72b17d250cfb43c897be1341861e and released in Perl version 5.13.6

CVE-2023-47039 (2023-10-30)

Perl for Windows relies on the system path environment variable to find the shell (cmd.exe). When running an executable which uses Windows Perl interpreter, Perl attempts to find and execute cmd.exe within the operating system. However, due to path search order issues, Perl initially looks for cmd.exe in the current working directory. An attacker with limited privileges can exploit this behavior by placing cmd.exe in locations with weak permissions, such as C:\ProgramData. By doing so, when an administrator attempts to use this executable from these compromised locations, arbitrary code can be executed.

CVE-2016-1238 (2016-08-02)

(1) cpan/Archive-Tar/bin/ptar, (2) cpan/Archive-Tar/bin/ptardiff, (3) cpan/Archive-Tar/bin/ptargrep, (4) cpan/CPAN/scripts/cpan, (5) cpan/Digest-SHA/shasum, (6) cpan/Encode/bin/enc2xs, (7) cpan/Encode/bin/encguess, (8) cpan/Encode/bin/piconv, (9) cpan/Encode/bin/ucmlint, (10) cpan/Encode/bin/unidump, (11) cpan/ExtUtils-MakeMaker/bin/instmodsh, (12) cpan/IO-Compress/bin/zipdetails, (13) cpan/JSON-PP/bin/json_pp, (14) cpan/Test-Harness/bin/prove, (15) dist/ExtUtils-ParseXS/lib/ExtUtils/xsubpp, (16) dist/Module-CoreList/corelist, (17) ext/Pod-Html/bin/pod2html, (18) utils/c2ph.PL, (19) utils/h2ph.PL, (20) utils/h2xs.PL, (21) utils/libnetcfg.PL, (22) utils/perlbug.PL, (23) utils/perldoc.PL, (24) utils/perlivp.PL, and (25) utils/splain.PL in Perl 5.x before 5.22.3-RC2 and 5.24 before 5.24.1-RC2 do not properly remove . (period) characters from the end of the includes directory array, which might allow local users to gain privileges via a Trojan horse module under the current working directory.

CVE-2015-8608 (2017-02-07)

The VDir::MapPathA and VDir::MapPathW functions in Perl 5.22 allow remote attackers to cause a denial of service (out-of-bounds read) and possibly execute arbitrary code via a crafted (1) drive letter or (2) pInName argument.

NAME

README.pod - README for the Porting/ directory in the Perl 5 core distribution.

FILES

acknowledgements.pl

Generates the text which goes in the Acknowledgements section in a perldelta. You pass in the previous version and it guesses the next version, fetches information from the repository and outputs the text.

add-package.pl

Program to prepare dual-life distributions for insertion into the Perl 5 lib/ and t/ directories. Now thought to be largely superseded.

bisect-example.sh, bisect.pl and bisect-runner.pl

Use git bisect to pinpoint changes.

bump-perl-version

A utility to find, and optionally bump, references to the perl version number in various files within the perl source.

check83.pl

Performs pathname portability checks, including whether there are naming conflicts when names are truncated to the DOSish, case-ignoring 8.3 format.

checkansi.pl

Check source code for ANSI-C violations.

checkAUTHORS.pl

Used by t/porting/authors.t to ensure the AUTHORS list is up to date.

checkcfgvar.pl

Check that the various config.sh-clones have (at least) all the same symbols as the top-level config_h.SH so that the (potentially) needed symbols are not lagging after how Configure thinks the world is laid out. VMS is probably not handled properly here, due to their own rather elaborate DCL scripting.

check-cpan-pollution

Scans the commit logs for commits that are potentially, illegitimately touching modules that are primarily maintained outside of the perl core. Also checks for commits that span multiple distributions in cpan/ or dist/. Makes sure that updated CPAN distributions also update Porting/Maintainers.pl, but otherwise ignores changes to that file (and MANIFEST).

checkpodencoding.pl

Check if POD files contain non-ASCII without specifying encoding. Run it as: perl Porting/checkpodencoding.pl.

checkURL.pl

Checks that all the URLs in the Perl source are valid.

checkVERSION.pl

Used by t/porting/cmp_version.t to ensure changed modules have had their versions updated.

cherrymaint

Command line tool to update cherrymaint; a tool for selecting commits from blead to cherry-pick into stable perl versions.

cmpVERSION.pl

Compare the current Perl source tree and a given tag for modules that have identical version numbers but different contents.

config_H

This file is a sample config.h file. If you are unable to successfully run Configure, copy this file to config.h and edit it to suit your system.

config_h.pl

Used when importing changes from metaconfig. This script reorders config_h.SH after metaconfig.

config.sh

This file is a sample config.sh file. config.sh is normally produced by running the Configure script. It holds all the definitions figured out by Configure. If you are unable to successfully run Configure on your system, copy this sample file to config.sh at the top of the perl source tree and edit it to suit your system. Then propagate those values by running Configure -S. This sample file is normally updated each time Configure is updated.

core-cpan-diff

Compare CPAN modules with their equivalent in core. Originally based on App::DualLivedDiff by Steffen Mueller.

corecpan.pl

Reports, in a perl source tree, which dual-lived core modules have not the same version than the corresponding module on CPAN.

corelist-diff

Prints a table of differences between two Perl versions with respect to modules included in the distribution.

corelist-perldelta.pl

Generates a list of the module changes for the Perl you are currently building. Also generates a diff between the corelist sections of two perldelta* files.

corelist.pl

Generates info for Module::CoreList from this perl tree.

deparse-skips.txt

List of test files to ignore/skip for deparse tests.

epigraphs.pod

List of Perl release epigraphs.

exec-bit.txt

This file contains a list of files that makerel will ensure get an executable bit.

exercise_makedef.pl

Brute force testing for makedef.pl.

expand-macro.pl

Expand C macros using the C preprocessor.

findrfuncs

This script finds reentrant variants of functions used in an executable and shared objects.

git-deltatool

This script, a rough draft, aids in generating a perldelta file from a series of git commits.

git-find-p4-change

This script, given a Perforce change number, outputs the equivalent git commit id.

git-make-p4-refs

This script creates a tag for every p4raw-id.

GitUtils.pm

This script contains the subroutine to generate a .patch file for a committish (the SHA1 checksum of a commit, a number made of 40 hexadecimal digits which acts the internal unique identifier for this commit (lilypond.org). Related file: make_dot_patch.pl

Glossary

This file is built by metaconfig. This file contains a description of all the shell variables whose value is determined by the Configure script. It later gets incorporated into the pod for Config.pm.

how_to_write_a_perldelta.pod

This file contains a specification as to how to write a perldelta pod. Related file: perldelta_template.pod

leakfinder.pl

This script executes every line in every file in the build directory and its subdirectories to determine if the number of SVs goes up and reports it as a leak to STDOUT. WARNING! some harm could be done if a line contains something similar to `rm *`.

Maintainers

This script shows information about the maintainers of core files/modules.

Related files: Maintainers.pl, Maintainers.pm

Maintainers.pl

A package associating core files/modules with maintainers. Related files: Maintainers, Maintainers.pm

Maintainers.pm

A package to search and show information about which core files/modules are associated with maintainers. Related files: Maintainers, Maintainers.pl

make_dot_patch.pl

Generate a .patch file to STDOUT for a commit ID specified on the command-line.

makemeta

This script creates META.yml and META.json files.

make_modlib_cpan.pl

This script generates the list of registered CPAN sites in perlmodlib.PL.

makerel

This script builds a Perl release tarball.

make-rmg-checklist

This script creates a release checklist as a simple HTML document.

make_snapshot.pl

This script is a quick and dirty snapshot generator for the perl5.git.perl.org web page to use to generate the snapshot files.

manicheck

This script outputs a list of files in MANIFEST which don't exist and a list of files that exist and aren't in MANIFEST.

manisort

This script sorts the files in MANIFEST.

new-perldelta.pl

This script automates the process for creating perldelta.pl.

newtests-perldelta.pl

This script outputs the added tests between the two versions of Perl.

perldelta_template.pod

Template for perldelta.

perlhist_calculate.pl

Generates info for perlhist from this perl tree.

pod_lib.pl

When required into other programs in the Perl 5 core distribution, provides functions useful during testing.

pod_rules.pl

Generate the sections of files listed in %Targets from pod/perl.pod. Mostly these are rules in Makefiles.

--verbose gives slightly more output
--build-all tries to build everything
--build-foo updates foo as follows
--showfiles shows the files to be changed
--test exit if perl.pod, MANIFEST are consistent, and regenerated
  files are up to date, die otherwise.

podtidy

Applies podtidy to a file.

pumpkin.pod

Pumpkin - Notes on handling the Perl Patch Pumpkin And Porting Perl. Many of these are out of date or superseded by other documents in this directory.

README.pod

This file. An exhaustive list of the contents of the Porting/ directory along with a description of each file. The test t/porting/readme.t ensures that this lists every file and that every file is listed.

README.y2038

The y2038 implementation for perl. This is an implementation of POSIX time.h which solves the year 2038 bug on systems where time_t is only 32 bits. It is implemented in bog-standard ANSI C. The latest version can be found at http://y2038.googlecode.com/.

release_announcement_template.txt

Release announcement for minor releasements of the 5.19 development series.

release_managers_guide.pod

Releasing a new version of perl 5.x. Note that things change at each release, so there may be new things not covered here, or tools may need updating.

release_schedule.pod

This schedule lists the projected or historical development and release schedules for the next, current and previous stable versions of Perl. Dates with all question marks will only be releases if deemed necessary by the Pumpking.

rt_list_patches

Shell script to list patches in RT.

sort_perldiag.pl

This is a script for sorting the warning and error messages in perldiag.pod. POD formatting, printf-style escapes, non-letter characters, and case are ignored, as explained in perldiag.

sync-with-cpan

Script to help out with syncing cpan distros.

timecheck2.c

A little program to test the limits of your system's time functions. See Porting/README.y2038 for details.

timecheck.c

A helper tool for perl's 2038 support See Porting/README.y2038 for details.

todo.pod

This is a list of wishes for Perl. The most up-to-date version of this file is at http://perl5.git.perl.org/perl.git/blob_plain/HEAD:/Porting/todo.pod. The tasks we think are smaller or easier are listed first. Anyone is welcome to work on any of these, but it's a good idea to first contact perl5-porters@perl.org to avoid duplication of effort, and to learn from any previous attempts.

valgrindpp.pl

A post-processor for make test.valgrind. valgrindpp.pl is a post-processor for .valgrind files created during make test.valgrind. It collects all these files, extracts most of the information and produces a significantly shorter summary of all detected memory access errors and memory leaks.