Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

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.


Comment on Re^3: Safely passing CGI form data to a shell command
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (16)
As of 2015-07-29 20:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (267 votes), past polls