FirmaSAT Manual

Sign XML

Signs an XML file. Creates the signature and sets the 'Sello' node in an XML file.
Señales de un archivo XML. Crea la firma y se establece el «Sello» de nodo en un archivo XML.

<cfdi:Comprobante xmlns:cfdi="http://www.sat.gob.mx/cfd/4"
Version="4.0" ...
NoCertificado="30001000000300023708"
Certificado=""
Sello=""
...>
<cfdi:Comprobante xmlns:cfdi="http://www.sat.gob.mx/cfd/3"
Version="4.0" ...
NoCertificado="30001000000300023708" 
Certificado="MIIE/TCCA+WgAwIBAgIUMzAwMDEwMDAwMD..." 
Sello="Gnm1yXaIig5hr1dJ+88gjLY5usQxXP2s..."
...>
<cfdi:Comprobante xmlns:cfdi="http://www.sat.gob.mx/cfd/3"
Version="3.3" ...
NoCertificado="30001000000100000800"
Certificado=""
Sello=""
...>
<cfdi:Comprobante xmlns:cfdi="http://www.sat.gob.mx/cfd/3"
Version="3.3" ...
NoCertificado="30001000000100000800" 
Certificado="MIIE/TCCA+WgAwIBAgIUMzAwMDEwMDAwMD..." 
Sello="AyiGH1muK3mMdxL705tSpShxswu0OyGkg9L4AP03..."
...>
<retenciones:Retenciones
xmlns:retenciones="http://www.sat.gob.mx/esquemas/retencionpago/2"
Version="2.0" ...
NoCertificado="20001000000100005867"
Certificado=""
Sello=""
...>
<retenciones:Retenciones 
xmlns:retenciones="http://www.sat.gob.mx/esquemas/retencionpago/2"
version="2.0" ...
NoCertificado="20001000000100005867"
Certificado="MIIEdDCCA1ygAwIBAgIUMj..."
Sello="O0w5ZAoywGZMQWxowwSsJ..."
...>
<controlesvolumetricos:ControlesVolumetricos
xmlns:controlesvolumetricos="http://www.sat.gob.mx/esquemas/controlesvolumetricos"
version="1.1" ...
noCertificado="20001000000300003600"
certificado="MIIFhjCCA26gAwIBA...
sello=""
...>
<controlesvolumetricos:ControlesVolumetricos 
xmlns:controlesvolumetricos="http://www.sat.gob.mx/esquemas/controlesvolumetricos"
version="1.1" ...
noCertificado="20001000000300003600"
certificado="MIIFhjCCA26gAwIBA..."
sello="ggYOp3kBN+TXtO+vsheCM6i23wOp/NX..."
...>

Note that the NoCertificado attribute in a CFDi document and Retenciones document must be set to the correct certificate serial number before signing or computing the digest. For a ControlesVolumetricos document both the noCertificado and the certificado attributes must be set to match the certificate used to sign document.

Function index by language

Cmd : SIGNXML Command  
.NET : Sat.SignXml Method   Sat.SignXmlToBytes Method (String, ...)   Sat.SignXmlToBytes Method (Byte[], ...)  
VBA/VB6 : satSignXml Function   satSignXmlToBytes   satSignXmlToString  
C (ANSI) : SAT_SignXml Function   SAT_SignXmlToString Function 
C++ (STL) : firmasat::Sat::SignXml  
[PREV: Key file format...]   [Contents]   [Index]   
   [NEXT: Stricter checks before signing...]

Copyright © 2007-24 D.I. Management Services Pty Ltd. All rights reserved. Generated 2024-04-31T10:54:00Z.