Bug #71186 [NEW]: session.hash_function - algorithm changes
From: akauffman at ne4u dot com
Operating system: Ubuntu 14.04 LTS
PHP version: 7.0.1
Package: Session related
Bug Type: Bug
Bug description:session.hash_function - algorithm changes
Description:
------------
Setting session.hash_function via php.ini does not remain consistent, it
goes back to default algorithm after session_regenerate_id(). You must
use ini_set in the script for the hashing algorithm to remain
consistent.
BTW - This bug seems to have been reintroduced.
Test script:
---------------
<?php
//ini_set('session.hash_function','sha512');
session_start();
$orig = session_id();
session_regenerate_id();
$new = session_id();
echo("$orig <br> $new");
?>
Expected result:
----------------
Hashing algorithm remains sha512.
--
Edit bug report at https://bugs.php.net/bug.php?id=71186&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=71186&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=71186&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=71186&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=71186&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=71186&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=71186&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=71186&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=71186&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=71186&r=support
Expected behavior: https://bugs.php.net/fix.php?id=71186&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=71186&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=71186&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=71186&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=71186&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=71186&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=71186&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=71186&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=71186&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=71186&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=71186&r=mysqlcfg
Thread (12 messages)
- akauffman at ne4u dot com
- yohgaki@php.netBug #71186 [Opn]: session.hash_function - algorithm changes
- yohgaki@php.netBug #71186 [Asn->Fbk]: session.hash_function - algorithm changes
- yohgaki@php.netBug #71186 [Fbk]: session.hash_function - algorithm changes
- akauffman at ne4u dot comBug #71186 [Fbk->Asn]: session.hash_function - algorithm changes
- yohgaki@php.netBug #71186 [Asn->Fbk]: session.hash_function - algorithm changes
- php-bugs at lists dot php dot netBug #71186 [Fbk->NoF]: session.hash_function - algorithm changes
- yohgaki@php.netBug #71186 [NoF->Fbk]: session.hash_function - algorithm changes
- akauffman at ne4u dot comBug #71186 [Fbk->Asn]: session.hash_function - algorithm changes
- akauffman at ne4u dot comBug #71186 [Com]: session.hash_function - algorithm changes
- yohgaki@php.netBug #71186 [Asn->Fbk]: session.hash_function - algorithm changes
- php-bugs at lists dot php dot netBug #71186 [Fbk->NoF]: session.hash_function - algorithm changes