Estou recebendo este erro ao tentar enviar RPS em Lote.
- Código:
-
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><ns3:EnviarLoteRpsResposta xmlns:ns2="http://www.ginfes.com.br/tipos_v03.xsd" xmlns:ns3="http://www.ginfes.com.br/servico_enviar_lote_rps_resposta_v03.xsd"><ListaMensagemRetorno><ns2:MensagemRetorno><ns2:Codigo>E188</ns2:Codigo><ns2:Mensagem>Erro ao tentar efetuar a leitura do Certificado Digital contido na Assinatura do mesmo</ns2:Mensagem><ns2:Correcao>A tag X509Certificate deve estar contida na assinatura.</ns2:Correcao></ns2:MensagemRetorno></ListaMensagemRetorno></ns3:EnviarLoteRpsResposta>
Estou recebendo o erro mencionado acima, mas como podemos ver abaixo, a tag X509Certificate está contida na assinatura.
- Código:
-
<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">
<SignedInfo>
<CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/>
<SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
<Reference URI="#B1">
<Transforms>
<Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/>
<Transform Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/>
</Transforms>
<DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/>
<DigestValue>ngN...fVA=</DigestValue>
</Reference>
</SignedInfo>
<SignatureValue>GCh+Zr...APU=</SignatureValue>
<KeyInfo>
<X509Data>
<X509Certificate>MIIEIDCCA+CgAwI...BQ==</X509Certificate>
</X509Data>
</KeyInfo>
</Signature>
Alguém consegue me ajudar a identificar o meu erro.
Estou postando o meu XML completo abaixo.
Obrigado a todos que poderem ajudar.
- Código:
-
<?xml version="1.0" encoding="UTF-8"?><ns3:EnviarLoteRpsEnvio xmlns:ns3="http://www.ginfes.com.br/servico_enviar_lote_rps_envio_v03.xsd" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://www.ginfes.com.br/tipos_v03.xsd" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ns3:LoteRps Id="A2">
<ns2:NumeroLote>1</ns2:NumeroLote>
<ns2:Cnpj>07331220000147</ns2:Cnpj>
<ns2:InscricaoMunicipal>1981905</ns2:InscricaoMunicipal>
<ns2:QuantidadeRps>1</ns2:QuantidadeRps>
<ns2:ListaRps>
<ns2:Rps>
<ns2:InfRps Id="B1">
<ns2:IdentificacaoRps>
<ns2:Numero>1</ns2:Numero>
<ns2:Serie>S1</ns2:Serie>
<ns2:Tipo>1</ns2:Tipo>
</ns2:IdentificacaoRps>
<ns2:DataEmissao>2017-10-10T08:37:00</ns2:DataEmissao>
<ns2:NaturezaOperacao>1</ns2:NaturezaOperacao>
<ns2:RegimeEspecialTributacao>6</ns2:RegimeEspecialTributacao>
<ns2:OptanteSimplesNacional>1</ns2:OptanteSimplesNacional>
<ns2:IncentivadorCultural>2</ns2:IncentivadorCultural>
<ns2:Status>1</ns2:Status>
<ns2:Servico>
<ns2:Valores>
<ns2:ValorServicos>70.00</ns2:ValorServicos>
<ns2:ValorDeducoes>0.00</ns2:ValorDeducoes>
<ns2:ValorPis>0.00</ns2:ValorPis>
<ns2:ValorCofins>0.00</ns2:ValorCofins>
<ns2:ValorInss>0.00</ns2:ValorInss>
<ns2:ValorIr>0.00</ns2:ValorIr>
<ns2:ValorCsll>0.00</ns2:ValorCsll>
<ns2:IssRetido>2</ns2:IssRetido>
<ns2:ValorIss>0.00</ns2:ValorIss>
<ns2:OutrasRetencoes>0.00</ns2:OutrasRetencoes>
<ns2:BaseCalculo>70.00</ns2:BaseCalculo>
<ns2:Aliquota>0.0423</ns2:Aliquota>
<ns2:ValorLiquidoNfse>70.00</ns2:ValorLiquidoNfse>
<ns2:DescontoCondicionado>0.00</ns2:DescontoCondicionado>
</ns2:Valores>
<ns2:ItemListaServico>1.03</ns2:ItemListaServico>
<ns2:CodigoCnae>6311900</ns2:CodigoCnae>
<ns2:CodigoTributacaoMunicipio>1.03</ns2:CodigoTributacaoMunicipio>
<ns2:Discriminacao>Comissao IATA R$ 50,00</ns2:Discriminacao>
<ns2:CodigoMunicipio>3133808</ns2:CodigoMunicipio>
</ns2:Servico>
<ns2:Prestador>
<ns2:Cnpj>07331220000147</ns2:Cnpj>
<ns2:InscricaoMunicipal>1981905</ns2:InscricaoMunicipal>
</ns2:Prestador>
<ns2:Tomador>
<ns2:IdentificacaoTomador>
<ns2:CpfCnpj>
<ns2:Cnpj>17609594000801</ns2:Cnpj>
</ns2:CpfCnpj>
</ns2:IdentificacaoTomador>
<ns2:RazaoSocial>ALJA HOTELARIA E SERVIçOS LTDA - EPP</ns2:RazaoSocial>
<ns2:Endereco>
<ns2:Endereco>Avenida 1</ns2:Endereco>
<ns2:Numero>926</ns2:Numero>
<ns2:Bairro>CENTRO</ns2:Bairro>
<ns2:CodigoMunicipio>3543907</ns2:CodigoMunicipio>
<ns2:Uf>SP</ns2:Uf>
<ns2:Cep>37800000</ns2:Cep>
</ns2:Endereco>
<ns2:Contato>
<ns2:Telefone>3587205239</ns2:Telefone>
<ns2:Email>ti@classhotel.com.br</ns2:Email>
</ns2:Contato>
</ns2:Tomador>
</ns2:InfRps>
<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">
<SignedInfo>
<CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/>
<SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
<Reference URI="#B1">
<Transforms>
<Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/>
<Transform Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/>
</Transforms>
<DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/>
<DigestValue>ngN...YfVA=</DigestValue>
</Reference>
</SignedInfo>
<SignatureValue>GCh+...PU=</SignatureValue>
<KeyInfo>
<X509Data>
<X509Certificate>MIIEIDCCA+CgAwIB...3z1oBQ==</X509Certificate>
</X509Data>
</KeyInfo>
</Signature>
</ns2:Rps>
</ns2:ListaRps>
</ns3:LoteRps>
<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">
<SignedInfo>
<CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/>
<SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1"/>
<Reference URI="#A2">
<Transforms>
<Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/>
<Transform Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/>
</Transforms>
<DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/>
<DigestValue>hDwe...JG41/ZkY=</DigestValue>
</Reference>
</SignedInfo>
<SignatureValue>Dk5v...V3Q=</SignatureValue>
<KeyInfo>
<X509Data>
<X509Certificate>MIIEIDCC...JnwTt3z1oBQ==</X509Certificate>
</X509Data>
</KeyInfo>
</Signature>
</ns3:EnviarLoteRpsEnvio>