In my experience with CI, I encountered some anomalies in its sessions, but for most everyday needs, the library is good and easy to use. As noted, Flashdata is a very nice feature.
If you decide to stay with CI sessions, I highly recommend storing the sessions in a database and, in addition, encrypt cookies:
$config['sess_encrypt_cookie'] = TRUE; $config['sess_use_database'] = TRUE; $config['sess_table_name'] = 'sessions';
The database structure should be as follows:
CREATE TABLE IF NOT EXISTS `sessions` ( session_id varchar(40) DEFAULT '0' NOT NULL, ip_address varchar(16) DEFAULT '0' NOT NULL, user_agent varchar(50) NOT NULL, last_activity int(10) unsigned DEFAULT 0 NOT NULL, user_data text NOT NULL, PRIMARY KEY (session_id) );
Cinnamon Jan 05 '10 at 12:45 2010-01-05 12:45
source share