CI_Security::xss_hash PHP Method

xss_hash() public method

Generates the XSS hash if needed and returns it.
See also: CI_Security::$_xss_hash
public xss_hash ( ) : string
return string XSS hash
    public function xss_hash()
    {
        if ($this->_xss_hash === NULL) {
            $rand = $this->get_random_bytes(16);
            $this->_xss_hash = $rand === FALSE ? md5(uniqid(mt_rand(), TRUE)) : bin2hex($rand);
        }
        return $this->_xss_hash;
    }