php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #64895 interger overflow in SndToJewish
Submitted: 2013-05-22 06:00 UTC Modified: 2013-05-22 06:00 UTC
From: remi@php.net Assigned: remi
Status: Closed Package: Calendar related
PHP Version: 5.3.25 OS: GNU/Linux 64bits
Private report: No CVE-ID:
 [2013-05-22 06:00 UTC] remi@php.net
Description:
------------
Interger overflow occurs in SndToJewish

Last correct value is 324542846

With very large value (ex: 9223372036854746369), php hangs.

Test script:
---------------
<?php
for ($i=324542840; $i<324542850; $i++) 
echo "$i:".jdtojewish($i)."\n";'


Expected result:
----------------
324542840:12/7/887605
324542841:12/8/887605
324542842:12/9/887605
324542843:12/10/887605
324542844:12/11/887605
324542845:12/12/887605
324542846:12/13/887605
324542847:0/0/0
324542848:0/0/0
324542849:0/0/0

Actual result:
--------------
324542840:12/7/887605
324542841:12/8/887605
324542842:12/9/887605
324542843:12/10/887605
324542844:12/11/887605
324542845:12/12/887605
324542846:12/13/887605
324542847:3/434978988/887
324542848:3/434978989/887
324542849:3/434978990/887

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-05-22 06:00 UTC] remi@php.net
-Assigned To: +Assigned To: remi
 [2013-05-22 06:30 UTC] remi@php.net
-Status: Assigned +Status: Closed
 [2013-05-22 06:30 UTC] remi@php.net
Automatic comment on behalf of remi
Revision: http://git.php.net/?p=php-src.git;a=commit;h=fc2a9d6e47ae23adb28122539b56df0d6195bdce
Log: Fixed bug #64895 Integer overflow in SndToJewish
 [2013-05-22 06:30 UTC] remi@php.net
Automatic comment on behalf of remi
Revision: http://git.php.net/?p=php-src.git;a=commit;h=c50cef1dc54ffd1d0fb71d1afb8b2c3cb3c5b6ef
Log: Fixed bug #64895 Integer overflow in SndToJewish
 [2013-05-22 15:22 UTC] johannes@php.net
Automatic comment on behalf of remi
Revision: http://git.php.net/?p=php-src.git;a=commit;h=c50cef1dc54ffd1d0fb71d1afb8b2c3cb3c5b6ef
Log: Fixed bug #64895 Integer overflow in SndToJewish
 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Mon Apr 21 04:01:57 2014 UTC