PMA\libraries\plugins\auth\AuthenticationCookie::setIV PHP Méthode

setIV() public méthode

This is for testing only!
public setIV ( string $vector ) : void
$vector string The IV
Résultat void
    public function setIV($vector)
    {
        $this->_cookie_iv = $vector;
    }

Usage Example

 /**
  * Test for PMA\libraries\plugins\auth\AuthenticationConfig::cookieEncrypt
  *
  * @return void
  */
 public function testCookieEncrypt()
 {
     $this->object->setIV('testiv09testiv09');
     // works with the openssl extension active or inactive
     $this->assertEquals('{"iv":"dGVzdGl2MDl0ZXN0aXYwOQ==","mac":"347aa45ae1ade00c980f31129ec2defef18b2bfd","payload":"YDEaxOfP9nD9q\\/2pC6hjfQ=="}', $this->object->cookieEncrypt('data123', 'sec321'));
 }
All Usage Examples Of PMA\libraries\plugins\auth\AuthenticationCookie::setIV