Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: C any bugs?

by buckaduck (Chaplain)
on Jun 19, 2001 at 00:29 UTC ( #89434=note: print w/replies, xml ) Need Help??


in reply to C any bugs?

On general principle, I believe all CGI programs should run with the -T flag to enable taint mode (see perlsec). That's not a serious issue here, because your code doesn't use tainted data in an unsafe manner -- at least, not yet. But it could grow, so it doesn't hurt to be careful early on.

I would also be more comfortable if your regex did something like this:

$name =~ /\Q$search_name\E/i
To make sure that special characters in your CGI parameter don't accidentally do something you didn't intend. See quotemeta and perlre.

buckaduck

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (4)
As of 2021-09-19 11:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?