Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

Re^3: Safely passing CGI form data to a shell command

by deibyz (Hermit)
on Apr 21, 2005 at 17:27 UTC ( #450121=note: print w/replies, xml ) Need Help??

in reply to Re^2: Safely passing CGI form data to a shell command
in thread Safely passing CGI form data to a shell command

Ok, I should have been more specefic...

I was trying to say that, instead of removing whitespace and quoting special chars, I would define what I want to match an then throw out the rest. I think that if you're searching in a dictionary for an English word, you'll only need [A-Za-z-] (not exactly \w+) if I'm not missing something. It's always safer to get less than expected than get something unexpected, and for sure you (and me) are going to miss something.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://450121]
[Cosmic37]: I'm wondering whether there is a specific/(or at least "usual") command or does one take a copy before undefining and then copy it back after slurping file into a string?
[BarApp]: I need help accessing perl files. I need permission!!!
[Cosmic37]: I wish thee a peachy life and express gratitude for considering my pathetic questions
[erix]: record separator
[Cosmic37]: Permissions are interesting earthlings. Did nature determine who gives permission and who asks permission. Who was the first to get permission? Are you not related to them as one big earthling family?
[karlgoethebier]: Cojones! We need cojones!

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (9)
As of 2017-06-29 16:35 GMT
Find Nodes?
    Voting Booth?
    How many monitors do you use while coding?

    Results (672 votes). Check out past polls.