Welcome Guest, Not a member yet? Register   Sign In
Anti spam honey pot
#14

It has been a while, but I have recently come a cross an issue with the honey pot.

I never created an expire time for the token.

Update the ./config/config.php file and add
PHP Code:
$config['honey_pot_expire'] = 3600

Update the ./core/MY_Security.php file and add the following lines
PHP Code:
protected $_honey_pot_expire// The time the token remains valid for. Default is 1 hour
...
...

public function 
__construct() {
   ...
   ...
   $this->_honey_pot_expire config_item('honey_pot_expire');
}

/**
 * Honey pot Set Cookie
 *
 * @return CI_Security
 */
public function honey_pot_set_cookie() {
 
 
   $expire time() + $this->_honey_pot_expire;
 
   ...
 
   ...


The code provided in the OP has also been updated
Reply


Messages In This Thread
Anti spam honey pot - by Martin7483 - 09-30-2015, 03:28 AM
RE: Anti spam honey pot - by ignitedcms - 10-01-2015, 10:52 AM
RE: Anti spam honey pot - by Martin7483 - 10-08-2015, 07:48 AM
RE: Anti spam honey pot - by ardavan - 12-19-2015, 08:20 PM
RE: Anti spam honey pot - by skunkbad - 12-19-2015, 10:06 PM
RE: Anti spam honey pot - by Martin7483 - 12-19-2015, 11:26 PM
RE: Anti spam honey pot - by Diederik - 12-20-2015, 08:00 AM
RE: Anti spam honey pot - by includebeer - 12-20-2015, 04:25 PM
RE: Anti spam honey pot - by Martin7483 - 12-22-2015, 04:57 AM
RE: Anti spam honey pot - by ardavan - 02-29-2016, 05:35 AM
RE: Anti spam honey pot - by peterm87 - 03-30-2016, 12:22 PM
RE: Anti spam honey pot - by peterm87 - 03-30-2016, 12:16 PM
RE: Anti spam honey pot - by Martin7483 - 04-07-2016, 07:12 AM
RE: Anti spam honey pot - by Martin7483 - 06-20-2017, 04:58 AM
RE: Anti spam honey pot - by jj.ranran225566 - 07-10-2022, 12:08 AM



Theme © iAndrew 2016 - Forum software by © MyBB