9

I have the following code error when trying to test communication Web Service:

Fatal error: Uncaught SoapFault exception: [Client] SoapClient::SoapClient(): 'uri' option is required in nonWSDL mode in /home/site/public_html/WebPayService/WebpayService.php:96 Stack trace: #0 /home/site/public_html/WebPayService/WebpayService.php(96): SoapClient->SoapClient(NULL, Array) #1 /home/site/public_html/WebPayService/InitTransaction.php(37): WebpayService->__construct(NULL) #2 {main} thrown in /home/site/public_html/WebPayService/WebpayService.php on line 96

Any idea what it could be?

This is my page soap.php:

class MySoap extends SoapClient{
    function __doRequest($request, $location, $saction, $version){
        $doc = new DOMDocument('1.0');
        $doc->LoadXML($request);
        $objWSSE = new WSEESoap($doc);
        $objkey = new XMLSecurityKey(XMLSecurityKey::RSA_SHA1,array('type'=>'private'));
        $objkey->LoadKey(PRIVATE_KEY, TRUE); //Ruta LLave Privada $objkey->LoadKey(PRIVATE_KEY, TRUE); 
        $options = array("insertBefore" => TRUE);
        $objWSSE->signSoapDoc($objKey, $options);
        $objWSSE->addIssuerSerial(CERT_FILE);      //Ruta Certificado de Comercio $objWSSE->addIssuerSerial(CERT_FILE);
        $objKey = new XMLSecurityKey(XMLSecurityKey::AES256_CBC);
        $objKey->generateSessionKey();
        $retVal = parent::__doRequest($objWSSE->saveXML(), $location, $saction, $version);        
        $doc = new DOMDocument();
        $doc->loadXML($retVal);

        return $doc->saveXML();
    }
}
technophobia
  • 2,644
  • 1
  • 20
  • 29
Barbatos
  • 101
  • 1
  • 8
  • `WSEESoap` is not the standard soap library, and I can't find it on Packagist or Google. I suspect it's something you or your company developed, which is why the help here has been lacking. – donatJ Dec 13 '21 at 08:54

0 Answers0