Jose\Algorithm\Signature\ECDSA::verifyOpenSSLSignature PHP Method

verifyOpenSSLSignature() private method

private verifyOpenSSLSignature ( Jose\Object\JWKInterface $key, string $data, string $R, string $S ) : boolean
$key Jose\Object\JWKInterface
$data string
$R string
$S string
return boolean
    private function verifyOpenSSLSignature(JWKInterface $key, $data, $R, $S)
    {
        $pem = ECKey::toPublic(new ECKey($key))->toPEM();
        $oid_sequence = new Sequence();
        $oid_sequence->addChildren([new Integer(gmp_strval($this->convertHexToGmp($R), 10)), new Integer(gmp_strval($this->convertHexToGmp($S), 10))]);
        return 1 === openssl_verify($data, $oid_sequence->getBinary(), $pem, $this->getHashAlgorithm());
    }