PHP - CURL HTTPS Request - NFSe Curitiba

0

I'm performing an integration with WebService for sending RPS, for issuing NFS-e, I'm using the PHP programming language, and the CURL library. In this integration it is mandatory when making any request to send the digital certificate, this one already has and we are sending in the parameter (CURLOPT_SSLKEY) the absolute path of the certificate.

CURL parameters are as follows:

    $_options = array (
        CURLOPT_URL => 'https://pilotoisscuritiba.curitiba.pr.gov.br/nfse_ws/NfseWs.asmx?WSDL',
        CURLOPT_CONNECTTIMEOUT => 60,
        CURLOPT_TIMEOUT => 60,
        CURLOPT_RETURNTRANSFER  => true,
        CURLOPT_SSL_VERIFYHOST => 2,
        CURLOPT_SSL_VERIFYPEER => 0,
        CURLOPT_SSLKEY  => /var/cert/cert.pem, // certificado
        CURLOPT_POSTFIELDS => $_content,
        CURLOPT_HTTPHEADER => $_header
    );

I have the following return:

<?xml version="1.0"?>
<EnviarLoteRpsResposta xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
	<NumeroLote xsi:nil="true"/>
	<DataRecebimento xsi:nil="true"/>
	<ListaMensagemRetorno>
		<MensagemRetorno>
			<Codigo>E504</Codigo>
			<Mensagem>O certificado digital do prestador de serviços é obrigatório.</Mensagem>
			<Correcao>Envie junto a requisição do serviço o certificado digital do prestador de serviços.</Correcao>
		</MensagemRetorno>
	</ListaMensagemRetorno>
</EnviarLoteRpsResposta>

Has anyone ever gone through this before and / or do you have any idea how to solve this problem?

    
asked by anonymous 15.08.2017 / 16:58

0 answers