Perl / perl5

🐪 The Perl programming language
https://dev.perl.org/perl5/
Other
1.95k stars 554 forks source link

Document that empty PATH components are also insecure. #22625

Closed dakkar closed 3 weeks ago

dakkar commented 3 weeks ago

I was recently surprised by a change in behaviour between perl 5.36 and 5.38: an empty $ENV{PATH} triggered the "Insecure directory" error under taint mode.

That is correct and desired behaviour (see 5ede4453c4877110eb5214ff400c173210b101b1 (and technically 9eb153ffbbde62558146e8f9b837034f42878e13 and 92ec2fce1aace295365d7d86c61c98df8202fc9d)), but the documentation makes no mention of this.

Now it does.


demerphq commented 3 weeks ago

Note there is a test failure:

porting/bincompat.t ....... ok

#   Failed test 'Is mailmap_file '.mailmap' up to date?'
#   at Porting/updateAUTHORS.pl line [12](https://github.com/Perl/perl5/actions/runs/11052824202/job/30705762942?pr=22625#step:12:13)6.
#   File '.mailmap' changes:
#     would add: Gianni Ceccarelli <dakkar@thenautilus.net> dakkar <dakkar@thenautilus.net>
# 
# Files need updating! You probably just need to run
# 
#    Porting/updateAUTHORS.pl
# 
# and commit the results.

So you need to tweak this before we can merge it. Thanks for the patch BTW, I overlooked the need to update these docs.