vishank848 / owasp-esapi-java

Automatically exported from code.google.com/p/owasp-esapi-java
Other
4 stars 2 forks source link

Incorrect Equality test on floating point values #313

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I have V2.1 sources.

2 places in RuleUtil.java have an invalid floating point comparison logic.

The corrected block(for both cases) is:

                                                                                if ( Double.compare(Double.parseDouble(s), ((Double)o).doubleValue()) ==  0 ) {

                                                                                                return true;

                                                                                }

Original issue reported on code.google.com by eamonn.w...@gmail.com on 26 Nov 2013 at 7:23

GoogleCodeExporter commented 9 years ago
Eamonn,
Would you like this work (that is your collective works on all these issues) to 
be considered for the ESAPI hackathon contest? If so, please email me ASAP. 
Thanks.
-kevin wall <kevin.w.wall@gmail.com>

Original comment by kevin.w.wall@gmail.com on 23 Jan 2014 at 6:58