Posted in ColdFusion | Posted on 02-08-2011 | 5,159 views
Just a quick note to let you know that a security bulletin was just released for ColdFusion. Details below.
Just a quick note to let you know that a security bulletin was just released for ColdFusion. Details below.
"Note: CFIDE.zip and WEB-INF.zip included in the hotfix contains only part of the CFIDE and WEB-INF files. Do not rename present CFIDE or WEB-INF folders to create a backup as per the instructions. "
then later on ...
"Go to {CFIDE-HOME} and make a backup of CFIDE folder."
If you have a directory such as: /somedirectory/ that has an Application.cfm file, then have another directory such as: /somedirectory/child/ that also has an Application.cfm file and both Application.cfm files enable session management (with different application names of course), when you create a session under /somedirectory/child and then open a new window or tab pointing to /somedirectory your session under /somedirectory/child is destroyed.
If you access a site on the same server under /anotherdirectory there are no problems, but session instances in a nested directory structure appear to be overriding one another regardless of application name.
I confirmed this after installing the hotfix on eight different servers. As soon as I rolled-back the hotfix, the problem went away on all eight.
It seems unbelievable that nobody at Adobe noticed a bug this big before releasing such an important Security Hotfix...
http://shilpikm.blogspot.com/2011/02/security-hot-...
The idea is to explicitely create the CFID and CFTOKEN in the directories that are using another cfapplication in order to "scope by path" the session.
I'll give this approach a try and post my findings here soon.
I've set up a test where two folders have their own Application.cfc, with the following:
<cfscript>
this.name = "#cgi.path_info#"; //this makes the app name unique
this.applicationTimeout = createTimeSpan(0,1,0,0);
this.clientmanagement= true;
this.loginstorage = "session" ;
this.sessionmanagement = true;
this.sessiontimeout = createTimeSpan(0,1,0,0);
this.setClientCookies = true;
this.setDomainCookies = false;
this.scriptProtect = "all";
</cfscript>
<cffunction name="onSessionStart" output="false">
<cfcookie name="CFID" value="#SESSION.CFID#" domain=".#cgi.http_host#" path="#listDeleteAt(cgi.path_info,listLen(cgi.path_info,'/'),'/')#">
<cfcookie name="CFTOKEN" value="#SESSION.CFTOKEN#" domain=".#cgi.http_host#" path="#listDeleteAt(cgi.path_info,listLen(cgi.path_info,'/'),'/')#">
</cffunction>
When you hit a page in folder_1 and then reload that same page, the SESSION.CFID and SESSION.CFTOKEN remain stable.
The you hit a page in folder_2 and you get a new CFID and CFTOKEN for that second application.
If you go back to folder_1 and reload your page, the original session vars are still there.
So far, so good.
Important note: this ties an application to its root folder: if you try to access the session variables of that application from another folder or from a subfolder, it won't work.
What a mess... This new behavior/bug introduced by the hotfix breaks code that had been running untouched for close to ten years, as well as code written last month.
Do you think we can assume that the problem is acknowledged and someone's working on it?
http://cfbugs.adobe.com/cfbugreport/flexbugui/cfbu...
The following is a snippt from the error message: Element ESAPIUTILS is undefined in a Java object of type class [Ljava.lang.String;.
The error occurred on line 55.
Anyone else out there with this one?
There is no c:\work on my server. I would like to know how that could be. In the meantime, I decided to remove the wizards folder altogether. What is it needed for?
I'm guessing the reason they added the option to completely turn off the fix for Session Fixation is just in case any other unexpected problems show up.
I am using Application.cfm on CF 8 and have the following code in that file:
<cfapplication
...
applicationtimeout="#CreateTimeSpan(2,0,0,0)#"
clientmanagement="false"
sessionmanagement="true"
sessiontimeout="#CreateTimeSpan(0,1,0,0)#"
setclientcookies="false"
setdomaincookies="false"
scriptprotect="URL,CGI,COOKIE">
<!--- set more secure cookie handeling --->
<cfif NOT IsDefined("COOKIE.CFID") OR NOT IsDefined("COOKIE.CFTOKEN")>
<cfheader name="Set-Cookie" value="CFID=#SESSION.CFID#;path=/;HTTPOnly">
<cfheader name="Set-Cookie" value="CFTOKEN=#SESSION.CFTOKEN#;path=/;HTTPOnly">
</cfif>
We do this to protect our session cookies as per: http://www.petefreitag.com/item/764.cfm
When i persons session times-out, I this bug still happens and they can't login without having to delete their cookies from their browser.
-J
This is because of the following -
1. You have set setClientCookies=false
2. In the code to set Cookies, you have following condition -
<cfif NOT IsDefined("COOKIE.CFID") OR NOT IsDefined("COOKIE.CFTOKEN")>
Now if users don't delete the old cookies and with the above condition, old Cookie value will always be found and if ColdFusion does not find an active session for this request, it will start a new one. However these new values are never set to Cookies.
You can probably change the check before settings the cookies to match the value from Cookie and Session. If the values don't match, then you reset the cookie as well.
Hope this helps.
Shilpi
ColdFusion Team
I've written up the problem and solution at http://cfsimplicity.com/4/coldfusion-security-hotf...
java.lang.NoClassDefFoundError: Could not initialize class coldfusion.security.ESAPIUtils
@Michael Kane - were you able to find a fix for your cf9 box?
After the update (multiserver) occurs, websites seem to work fine, but I am unable to get to the cf administrator interface.
Just a blank screen shows up.
When I view source on the blank page, I see this root cause listed: applet error.
Element ESAPIUTILS is undefined in a Java object of type class
If anyone has any assistance they can offer, please let me know. I need to get this update and subsequent hot fixes in place before 8/19 (pci check).
The 8.0.0 security hot fix broke my cfgrid from displaying correctly. Worked great before that.
current update level I'm at:
Update Level /C:/JRun4/servers/cfusion/cfusion-ear/cfusion-war/WEB-INF/cfusion/lib/updates/hf800-00002.jar
As several people posted here, the documentation is lacking a bit. Would be nice if they would just create an upgrade file that really did the upgrade.
I have a cf8 installation, but see at this post, http://www.forta.com/blog/index.cfm/2011/6/14/Cold...,
that even on cf9 installations, the hot fixes busted up the admin interface.
thanks for the response.
java.lang.ClassNotFoundException: coldfusion.security.ESAPIUtils
Really, adobe should fix this with these 2 existing versions since they have downloads for them.
The only reason I am trying to do the upgrade is for security fixes. The last one I applied for 8.0.0 broke by cfgrid cfcs.
This fix is in the 8.0.1 hotfix 1, which I cannot apply to an 8.0.0 installation.
"ESAPIUTILS is undefined in a Java object" etc., breaking the cf admin interface.
Can you please confirm at what location the hf jar is placed and also in "<cfserver-home>/lib/updates" which all files are present?
We at not seeing this error at our end.
Thanks & Regards,
Shilpi
It appears to have resulted from installing multiple hotfixes in an incorrect order. Specifically, installing the hf801-1878.jar or hf801-1875.jar _after_ the hf801-00002.jar had already been installed.
I was doing a wave of hotfixes this week for a PCI compliance process, and it wasn't immediately obvious to me that there was an order dependency. Once I had a chance to think about it a bit more, it seemed relatively obvious that there was a conflict between updates; additional evidence was provided when I re-read the release notes for hf801-00002 and noticed the list of jars to remove.
I think hf801-1875.jar should probably be added to that list of jars to remove, although I didn't absolutely confirm it; I've done enough experimenting in that environment for this week.
Thanks!
No disaster here!
--Teresa
Before this 9.0.1 updater we also had this problem. Someone had fouled up the hotfixes from 9.0 and I reapplied them in the correct order and it was fixed.
After the 9.0.1 updater, the problem resurfaced. So I applied ColdFusion 9.0.1 Cumulative Hotfix 2 (CHF2).
Note that you can skip steps 2-5 in the hotfix instructions and just drop the hotfix jar file directly into {ColdFusion-Home}/lib/updates folder. If you have the admin blank screen problem, you don't really have a choice.
I've tried deleting the jar from the updates folder as suggested, but it hasn't done anything that I can see. Any suggestions would be appreciated.
Thanks for the feedback
Mike
In my experience (providing CF support to folks as an independent consultant), most such problems are caused by one of 3 mistakes that can be easily made while applying hotfixes. I don't say this to embarrass anyone, but just to say it's not hard to make the mistakes.
I discuss them in more detail here: http://www.carehart.org/blog/client/index.cfm/2011...
But certainly if anyone has a different solution they may have found to resolve the problems, many will certainly want to hear.
Hope that's helpful.
[Add Comment] [Subscribe to Comments]