in reply to Re^3: Insecure dependency in mkdir while running with -T switch at ... File/Temp.pm line 542
in thread Insecure dependency in mkdir while running with -T switch at ... File/Temp.pm line 542
Same failure.my $tname = shift; $tname = untaint_var($tname); ... my $abslogdir = File::Spec->canonpath(Cwd::realpath("log")); $abslogdir = untaint_var($abslogdir); $workdir = File::Spec->abs2rel(tempdir("$tname.XXXXXX", DIR => $absl +ogdir));
I've also earlier uploaded an rc4c-TRIAL that is the same as rc4b-TRIAL except adding a module dependency on File::Temp so the report will show what version it loads, and should see results from that some hours from now.
I looked at the code in File::Temp and File::Spec, particularly File::Spec->splitpath, File::Spec->splitdir and File::Spec->catdir that hy pointed out, and I don't see anything it does that could taint the $path variable that is eventually passed to that mkdir on line 542 when, as in this case, tempdir is called with just template and DIR arguments that are not tainted.
If there are no other hints, I think I will just have to leave it as something on BINGOS' 64 bit test runners (doesn't happen on their i386 and i686 architecture runners) that I can't reproduce, and ignore it unless some user of our module reports it trying to install it.
Ken, thanks for trying it out. The optional modules are optional for a reason. I know some are not really maintained and either don't load or are finicky to load on Windows, like the three you mentioned. They still work on enough platforms that we make use of them if they are available.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Insecure dependency in mkdir while running with -T switch at ... File/Temp.pm line 542
by hv (Prior) on Dec 11, 2022 at 02:15 UTC | |
by sidney (Acolyte) on Dec 11, 2022 at 21:05 UTC |