I want to regenerate my cookie's name after every successfull login ( I regenerate already my Session Id).
When I try to regenerate my cookie's name, joomla lost my session! ( in JSession class)
Do you know the best joomla's practise for regenerate the cookie's name?
It's my code, for get different cookie's name on every Session :
// It's on Joomla\Session\Session.php
if (isset($options['name']))
{
$date = new DateTime();
$timestamp = $date->getTimestamp();
session_name(md5($options['name'] . $timestamp));
}
The instance of the JSession is a singleton, Is it for that I just add a dynamic timestamp when the instance is create, that generate a different name for every first instance of the JSession (No?) .
Thanks you!