ColdFusion Security Reminder - Read me now
I know I've blogged this before, and it's covered in my security checklist, but folks, stop what you are doing and make these changes right now on your production server:
- In the ColdFusion Admin, Debug Settings, turn off Enable Robust Exception Info.
- In the ColdFusion Admin, Settings, set a site-wide error handler. You only need to do this if you didn't bother to use onError or <cferror>. You don't need a pretty page. You can just say 'Error!' and be done. This is still 10x better than exposing an error page to your user.
The above changes will take you - approximately - 2 minutes. So please do this.... now.
Comments
# Posted By Raymond Camden
| 5/18/07 10:30 AM
Web root of the CFAdmin? Each web root in IIS?
Thanks Ray!
We have individual servers for our intranet and extranet (obviously for access reasons), but we have two sites on each box. We install CF to the default site and have the actual intranet/extranet as its own site. That way we can limit access to the CFIDE,admin, etc. and just copy over any script files we need for the actual site.
Anyway, because of this we have multiple web roots. What I did was create a mapping in the CF admin then I use that in my default error templates paths.
So, if you have multiple site roots just create a cf mapping to a folder that will hold your error page(s) and if necessary use some url path detection to pull in the desired page.
Hope all of that makes sense.
# Posted By Bash
| 5/18/07 11:06 AM
p.s. earlier versions of CF(5 and older) disabled the administrator if you disabled CFRegistry.
# Posted By Dan Sorensen
| 5/18/07 11:21 AM
# Posted By Ryan
| 5/18/07 12:05 PM
Dan: Thats what I do. Well no, that isn't. I use cferror/onError. That to me is more specific to my application. I recommend the Site Wide Error thing as its better than nothing and covers your whole box.
Does that make sense?
# Posted By Raymond Camden
| 5/18/07 1:29 PM
here's my errorHandler.cfm, what do you think?
http://cfzen.instantspot.com/blog/index.cfm/2007/5...
# Posted By Aaron Longnion
| 5/18/07 1:43 PM
# Posted By Raymond Camden
| 5/18/07 2:10 PM
(image link)
http://kamaimedia.com/funnystuff/hof_error_screens...
# Posted By david
| 5/20/07 12:34 AM
I encountered some <a href="http://blog.nazin.com/index.php/site-wide-error-ha... issues</a> with config file handling, due to the special behavior of site-wide error handlers. Got it taken care of though.
# Posted By Joshua Curtiss
| 5/22/07 12:42 PM
# Posted By Michael Dinowitz
| 5/25/07 1:58 AM
Just last night I got an email from my error handler for a page that used cfabort... I haven't looked into it yet but... will cfabort trigger the site-wide error handler???? If so, that is bad... I use cfabort from time to time, putting some logic at the top of a page and abort if certain conditions aren't met....
# Posted By Joshua Curtiss
| 5/25/07 8:30 AM
# Posted By Raymond Camden
| 5/25/07 10:07 PM

In the CF Admin it says:
Specify the relative path to a template to execute when ColdFusion encounters errors while processing a request.
Relative path to what?