D
D
Danil2020-10-29 12:32:25
CodeIgniter
Danil, 2020-10-29 12:32:25

Why does ci_sessions create two identical sessions?

Codeigniter 3
Session Config

$config['sess_driver'] 				= 'database';
$config['sess_cookie_name'] 		= 'ci_session';
$config['sess_expiration'] 			= 0;
$config['sess_save_path'] 			= 'ci_sessions';
$config['sess_match_ip'] 			= FALSE;
$config['sess_time_to_update'] 		= 360;
$config['sess_regenerate_destroy'] 	= TRUE;
$config['sess_expire_on_close']	    = FALSE;
$config['sess_encrypt_cookie']	    = TRUE;
$config['sess_use_database']	    = TRUE;
$config['sess_table_name']		    = 'ci_sessions';

Yes, the config may look strange

For authorization, I use Ion_Auth
Sessions in the database are completely the same, only the id changes
One of them is used by the site and the second simply exists

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Danil, 2020-11-06
@Deletron247

the solution was the simplest
Comment out in ion_auth_model
$this->session->sess_regenerate(FALSE);
I still do not understand why it is needed, if you know, hurry up

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question