FirmaSAT Manual

Command-line utility

The executable file FirmaSAT.exe must be in the PATH. For more examples and the latest advice, go to our command-line utility page.

Syntax:

FirmaSAT.exe Version 5.1.0 (32-bit) last updated Mar 23 2012 11:36:47.
Usage: FirmaSAT ACTION [OPTIONS] [-o outfile] [-i] infile
ACTION (one of):
 ATTRIBUTE      = extract a given attribute from XML file.
 CERTSTRING     = get the certificate data as a base64 string.
 DATENOTAFTER   = get the expiry date of the certificate.
 EXTRACTDIGEST  = extract the digest from the signature.
 FORMDIGEST     = form the digest of the pipestring.
 GETKEYSTRING   = get the private key as a base64 string.
 HELP           = display this help.
 KEYCHECK       = check that key matches certificate.
 LIBINFO        = display DLL library details.
 MAKESIG        = make signature from XML file.
 NUMBERCERT     = get the certificate serial number.
 PIPESTRING     = make pipestring (cadena) from XML file.
 QUERYCERT      = query a certificate for a given value (use -q option).
 RECEIPTVERSION = get the version number of XML receipt (2,3,22,32).
 SIGNXML        = create the signature and set `sello` field in XML file.
 UTF8FIX        = add UTF-8 byte-order mark to a file.
 VERIFYSIG      = verify the signature in XML file.
 WRITEPFX       = create PFX file from private key and certificate.
 XMLOK          = validate XML file.
OPTIONS:
 -k <keyfile>        required for SIGNXML/KEYCHECK/MAKESIG
 -p <password>       required for SIGNXML/KEYCHECK/MAKESIG/GETKEYSTRING
 -n <newpassword>    optional new password for WRITEPFX
 -g [sha1]|md5       set digest algorithm for SIGNXML/MAKESIG/FORMDIGEST
 -c <certfile>       optional X.509 certificate file for VERIFYSIG/SIGNXML
 -a <attribute-name> required for ATTRIBUTE action
 -e <element-name>   ditto
 -s <statusfile>     default=none; for stdout use ``-s @''
 -t <tracking-info>  optional info for the status file
 -f act on tfd:TimbreFiscalDigital node instead of Comprobante (CFDi only)
 -l use Loose XML restrictions with XMLOK (default=strict)
 -q query for QUERYCERT {rfc|organizationName|notAfter|notBefore|serialNumber}
 -w display help/errors in Windows console font (default=Latin-1)
 -b return start date (notBefore) with DATENOTAFTER action (default=notAfter)
 -d show debug info; -dd show more
For help type ``FirmaSAT HELP'' (en espanol ``FirmaSAT AYUDA'')
Uso: FirmaSAT ACCION [OPCIONES] [-i] infile [[-o] outfile]]
ACCION (uno de):
 ATTRIBUTE = extracto de un determinado atributo de archivo XML.
 CERTSTRING = obtener los datos del certificado de cadena de un Base64.
 DATENOTAFTER = obtener la fecha de expiracion del certificado de.
 EXTRACTDIGEST = extraer el digestion de la firma.
 FORMDIGEST = formulario el digestion de la cadena.
 HELP/AYUDA = muestra esta ayuda (mi aerodeslizador esta lleno de anguilas!).
 GETKEYSTRING = Obtener la clave privada en forma de cadena base64.
 KEYCHECK = comprobar que el certificado partidos clave.
 LIBINFO = mostrar detalles de la DLL.
 MAKESIG = hacer firma de archivo XML.
 NUMBERCERT = obtener el numero de serie de certificados.
 PIPESTRING = hacer cadena de archivo XML.
 QUERYCERT  = consultar un certificado para un valor dado (uso -q opcion).
 RECEIPTVERSION = obtener el numero de version de la comprobante XML.
 SIGNXML = crear la firma y establecer el `sello` de campo en el archivo XML.
 UTF8FIX = anadir un UTF-8 marca de orden de bytes en un archivo.
 VERIFYSIG = verificar la firma en el archivo XML.
 WRITEPFX = crear el archivo PFX de clave privada y certificado.
 XMLOK = validar el archivo XML.
Para obtener ayuda, escriba ``FirmaSAT AYUDA'' (en Ingles ``FirmaSAT HELP'')

WARNING: The behaviour of the FirmaSAT command-line has changed in version 5.1. As of [v5.1] the output file must be specified using the "-o" option. This first example will no longer work.

FirmaSAT SIGNXML -k llave.key -p password -c certificado.cer muestra.xml muestra-signed.xml

But these next three examples are OK:

FirmaSAT SIGNXML -k llave.key -p password -c certificado.cer -o muestra-signed.xml muestra.xml 
FirmaSAT SIGNXML -k llave.key -p password -c certificado.cer -o muestra-signed.xml -i muestra.xml 
FirmaSAT SIGNXML -k llave.key -p password -c certificado.cer -i muestra.xml -o muestra-signed.xml 

[Contents] [Index]

[HOME]   [NEXT: Example batch file...]

Copyright © 2007-12 D.I. Management Services Pty Ltd. All rights reserved.