Login

    Register

Managed Hosting

PROJECT CATEGORIES

 

CFFormProtect
Project Home Blog Forums Known Issues Screenshots Contact Project

CFFormProtect Issue: Timed Form Submission Bug in Railo 3.1.2.001 Windows

Name: Timed Form Submission Bug in Railo 3.1.2.001 Windows
ID: 14
Project: CFFormProtect
Type: Bug
Area: Code
Severity: Normal
Status: Fixed
Related URL:
Creator: Ted Serpa
Created: 12/10/10 2:51 PM
Updated: 10/05/12 10:02 AM
Description: Not sure if this is a Railo bug or a CFFormProtect bug, although since it's not an issue with CFMX 6.1 I'm inclined to think it's related to how Railo handles date/time functions.

At certain times of the day, Timed Form Submission throws and error. A sampling of my Railo exception log:

-----
"ERROR","web-0","12/10/2010","03:15:42","","hour number [31] can not be gigger than 24"

"ERROR","web-0","12/10/2010","03:23:08","","hour number [31] can not be gigger than 24"

"ERROR","web-0","12/10/2010","03:23:13","","hour number [32] can not be gigger than 24"

"ERROR","web-0","12/10/2010","03:56:45","","hour number [35] can not be gigger than 24"

"ERROR","web-0","12/10/2010","07:43:39","","hour number [74] can not be gigger than 24"

"ERROR","web-0","12/10/2010","08:47:14","","hour number [84] can not be gigger than 24"

"ERROR","web-0","12/10/2010","09:49:34","","hour number [94] can not be gigger than 24"
----

When the hour number is not bigger than 24, it works as expected.

The error occurs on line 253 of cffpVerify.cfc:

FormDateTime = CreateDateTime(Left(FormDate,4),Mid(FormDate,5,2)...

History: Created by tedserpa (Ted Serpa) : 12/10/10 2:51 PM

Comment by tedserpa (Ted Serpa) : 04/08/11 2:45 PM
The fix is to modify line 250 of cffpVerify.cfc from

FormTime = NumberFormat(FormTime,000000);

to

FormTime = NumberFormat(FormTime,'000000');

Although the CF docs indicate that the mask must be either a string or a variable that contains one, CFMX 6.1 (didn't test later versions of CF) doesn't enforce that requirement; however, Railo does.

Comment by yacoubean (Jake Munson) : 10/05/12 10:01 AM
This has been fixed and will be part of the next release.

Updated by yacoubean (Jake Munson) : 10/05/12 10:02 AM

To add a comment to this bug, please login using the link above.