I think that you are correct that fatalsToBrowser is unwise in production code. If it gives you enough information to be helpful during development, then I'm sure it gives enough to help a cracker.
There are two kinds of errors though, application errors, and user errors.
- With Application errors, I think the standard 500 error message is all that the user needs to see, though you can spruse the 500 message error page up if you want - though an email or debug dump to the server log is still wise.
- User error, and here you need to tell the user something so that they can fix their input, without giving a cracker any additional information. I think that when possible this is best caught in the browser with JavaScript and good interface design, before the CGI process starts.
While security through obscurity isn't a viable approach on it's own, there is no point in giving crackers a free ride.
I'm currently working on Perlfect Search which does use fatalsToBrowser, and I'm in the process removing it and making it run under strict.....
My humble 2 credits.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.