简体   繁体   English

CodeIgniter:sess_match_ip 的替代方法为动态 IP 地址设置为真

[英]CodeIgniter: Alternate method for sess_match_ip is set true for dynamic IP address

I have a CodeIgniter 3 application with MySQL as the database.我有一个 CodeIgniter 3 应用程序,其中 MySQL 作为数据库。 I had set the sess_match_ip to TRUE to check for the IP address of the users.我已将 sess_match_ip 设置为 TRUE 以检查用户的 IP 地址。 Some of my clients has dynamic IPs which changes automatically.我的一些客户有自动更改的动态 IP。 At the time of changing the IP address the application logged out them automatically.在更改 IP 地址时,应用程序会自动将其注销。 Please suggest me a alternate solution to prevent the users forms log out with changing the sess_match_ip to false.请建议我一个替代解决方案,以防止用户 forms 通过将 sess_match_ip 更改为 false 注销。

$config['sess_match_ip'] = TRUE;

Just disable sess_match_ip .只需禁用sess_match_ip I know it looks like an attractive option, but it is simply not suitable for a typical public webapp on the inte.net.我知道它看起来是一个有吸引力的选择,但它根本不适合 inte.net 上的典型公共 Web 应用程序。

It can be used as an extra security layer for restricted admin areas where only a handful of users are permitted anyway, but that's quite rare.它可以用作受限管理区域的额外安全层,无论如何只允许少数用户使用,但这种情况很少见。 Its primary use is for intr.net systems where you control the whole.network and there are no regularly changing IP addresses.它的主要用途是用于控制整个网络的 intr.net 系统,并且没有定期更改的 IP 地址。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 CodeIgniter ip_address()始终返回0.0.0.0 - CodeIgniter ip_address() always returns 0.0.0.0 $ config ['sess_use_database'] = TRUE然后set_flashdata()在codeigniter中无法正常工作 - $config['sess_use_database'] = TRUE Then set_flashdata() is not working properly in codeigniter codeigniter会话不返回用户代理或IP地址或会话ID - codeigniter session does not returning the user agent or ip address or session id Codeigniter会话-同一IP地址上的多台相同计算机 - Codeigniter sessions - multiple identical computers on same IP address 为什么CodeIgniter将IP地址,用户代理和上次活动存储在cookie中? - Why is CodeIgniter storing IP address, user agent and last activity in cookie? 根据IP地址设置ASP.net会话超时 - Set ASP.net Session Timeout Based on IP Address Codeigniter 2.1.3:当'sess_use_database'== TRUE时,sess_destroy()会导致未定义索引:session_id等通知 - Codeigniter 2.1.3: sess_destroy() causes Undefined index: session_id etc notice when 'sess_use_database' == TRUE 在codeigniter tank auth中将sess_use_database设置为TRUE有什么用? - What is the use of setting sess_use_database to TRUE in codeigniter tank auth? CodeIgniter会话用户数据不显示ip地址/ session_id等 - CodeIgniter session userdata does not show ip address/session_id etc codeigniter sess_driver和路径 - codeigniter sess_driver and path
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM