/** * The application does not want to verify the authenticity of the app list, * so it's valid - even if signed by someone else. */ public function testUnsignedValid() { list($caKeyPair, $caCert) = $this->createCA(); $distPointKeyPair = KeyPair::create(); $distPointCert = CA::signCSR($caKeyPair, $caCert, CA::createDirSvcCSR($distPointKeyPair, 'O=Someone, CN=else')); $msg = new AppMetasMessage($distPointCert, $distPointKeyPair, array('app-2' => array('appId' => 'app-2'))); $appMetas = AppMetasMessage::decode(NULL, $msg->encode())->getData(); $this->assertEquals('app-2', $appMetas['app-2']['appId']); }