Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re^2: Using SSH and SCP in a perl script with taint flag

by stefl (Acolyte)
on May 28, 2015 at 16:03 UTC ( [id://1128155]=note: print w/replies, xml ) Need Help??


in reply to Re: Using SSH and SCP in a perl script with taint flag
in thread Using SSH and SCP in a perl script with taint flag

Thanks for replying! In my full application code, I have $ENV{PATH} = "/bin"; but I'm not sure if this is sufficient (I'm still new to perl). Would that meet the requirement, or is there something else I need to consider?
Edit: I should say as well, I added that line to my test code and got the following error: "Cannot exec(ssh -e none <username>@<IP>): No such file or directory"

  • Comment on Re^2: Using SSH and SCP in a perl script with taint flag

Replies are listed 'Best First'.
Re^3: Using SSH and SCP in a perl script with taint flag
by herveus (Prior) on May 29, 2015 at 13:37 UTC
    Howdy!

    That would suggest that your PATH is lacking. Try "which ssh" from a command line to sort out where it actually is. Setting PATH explicitly as you do is something you have to do in taint mode; you just need to make sure you put everything in or invoke it with a full path.

    yours,
    Michael

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1128155]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (9)
As of 2024-04-16 08:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found