public function testSetKeys() { $this->pki->makeKeys(); $publicKey = $this->pki->getPublicKey(); $this->pki->setPublicKey($publicKey); $this->assertEquals($publicKey, $this->pki->getPublicKey()); }
protected function setupPki() { $config = $this->_controller->getConfig(); if (!is_readable($config->getPublicKeyCertificatePath())) { throw new \Jazzee\Exception('Unable to read public key for EncryptedInput: ' . $config->getPublicKeyCertificatePath()); } $this->_pki = new \Foundation\PKI(); $this->_pki->setPublicKey(file_get_contents($config->getPublicKeyCertificatePath())); }