| 1 |
<?xml version="1.0" encoding="utf-8"?> |
| 2 |
<odoo> |
| 3 |
<data> |
| 4 |
<template id="export_sa_zatca_ubl_extensions"> |
| 5 |
<ext:UBLExtensions xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2" |
| 6 |
xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" |
| 7 |
xmlns:ext="urn:oasis:names:specification:ubl:schema:xsd:CommonExtensionComponents-2"> |
| 8 |
<ext:UBLExtension> |
| 9 |
<ext:ExtensionURI>urn:oasis:names:specification:ubl:dsig:enveloped:xades</ext:ExtensionURI> |
| 10 |
<ext:ExtensionContent> |
| 11 |
<sig:UBLDocumentSignatures |
| 12 |
xmlns:sac="urn:oasis:names:specification:ubl:schema:xsd:SignatureAggregateComponents-2" |
| 13 |
xmlns:sbc="urn:oasis:names:specification:ubl:schema:xsd:SignatureBasicComponents-2" |
| 14 |
xmlns:sig="urn:oasis:names:specification:ubl:schema:xsd:CommonSignatureComponents-2"> |
| 15 |
<sac:SignatureInformation> |
| 16 |
<cbc:ID>urn:oasis:names:specification:ubl:signature:1</cbc:ID> |
| 17 |
<sbc:ReferencedSignatureID>urn:oasis:names:specification:ubl:signature:Invoice |
| 18 |
</sbc:ReferencedSignatureID> |
| 19 |
<ds:Signature Id="signature" xmlns:ds="http://www.w3.org/2000/09/xmldsig#"> |
| 20 |
<ds:SignedInfo> |
| 21 |
<ds:CanonicalizationMethod |
| 22 |
Algorithm="http://www.w3.org/2006/12/xml-c14n11"/> |
| 23 |
<ds:SignatureMethod |
| 24 |
Algorithm="http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha256"/> |
| 25 |
<ds:Reference Id="invoiceSignedData" URI=""> |
| 26 |
<ds:Transforms> |
| 27 |
<ds:Transform Algorithm="http://www.w3.org/TR/1999/REC-xpath-19991116"> |
| 28 |
<ds:XPath>not(//ancestor-or-self::ext:UBLExtensions)</ds:XPath> |
| 29 |
</ds:Transform> |
| 30 |
<ds:Transform Algorithm="http://www.w3.org/TR/1999/REC-xpath-19991116"> |
| 31 |
<ds:XPath>not(//ancestor-or-self::cac:Signature)</ds:XPath> |
| 32 |
</ds:Transform> |
| 33 |
<ds:Transform Algorithm="http://www.w3.org/TR/1999/REC-xpath-19991116"> |
| 34 |
<ds:XPath> |
| 35 |
not(//ancestor-or-self::cac:AdditionalDocumentReference[cbc:ID='QR']) |
| 36 |
</ds:XPath> |
| 37 |
</ds:Transform> |
| 38 |
<ds:Transform Algorithm="http://www.w3.org/2006/12/xml-c14n11"/> |
| 39 |
</ds:Transforms> |
| 40 |
<ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/> |
| 41 |
<!-- b64encoded SHA256 digest of document --> |
| 42 |
<ds:DigestValue/> |
| 43 |
</ds:Reference> |
| 44 |
<ds:Reference Type="http://www.w3.org/2000/09/xmldsig#SignatureProperties" |
| 45 |
URI="#xadesSignedProperties"> |
| 46 |
<ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/> |
| 47 |
<ds:DigestValue/> |
| 48 |
</ds:Reference> |
| 49 |
</ds:SignedInfo> |
| 50 |
<ds:SignatureValue/> |
| 51 |
<ds:KeyInfo> |
| 52 |
<ds:X509Data> |
| 53 |
<ds:X509Certificate/> |
| 54 |
</ds:X509Data> |
| 55 |
</ds:KeyInfo> |
| 56 |
<ds:Object> |
| 57 |
<xades:QualifyingProperties xmlns:xades="http://uri.etsi.org/01903/v1.3.2#" |
| 58 |
Target="signature"> |
| 59 |
<xades:SignedProperties xmlns:xades="http://uri.etsi.org/01903/v1.3.2#" |
| 60 |
Id="xadesSignedProperties"> |
| 61 |
<xades:SignedSignatureProperties> |
| 62 |
<xades:SigningTime/> |
| 63 |
<xades:SigningCertificate> |
| 64 |
<xades:Cert> |
| 65 |
<xades:CertDigest> |
| 66 |
<ds:DigestMethod |
| 67 |
xmlns:ds="http://www.w3.org/2000/09/xmldsig#" |
| 68 |
Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/> |
| 69 |
<ds:DigestValue |
| 70 |
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"/> |
| 71 |
</xades:CertDigest> |
| 72 |
<xades:IssuerSerial> |
| 73 |
<ds:X509IssuerName |
| 74 |
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"/> |
| 75 |
<ds:X509SerialNumber |
| 76 |
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"/> |
| 77 |
</xades:IssuerSerial> |
| 78 |
</xades:Cert> |
| 79 |
</xades:SigningCertificate> |
| 80 |
</xades:SignedSignatureProperties> |
| 81 |
</xades:SignedProperties> |
| 82 |
</xades:QualifyingProperties> |
| 83 |
</ds:Object> |
| 84 |
</ds:Signature> |
| 85 |
</sac:SignatureInformation> |
| 86 |
</sig:UBLDocumentSignatures> |
| 87 |
</ext:ExtensionContent> |
| 88 |
</ext:UBLExtension> |
| 89 |
</ext:UBLExtensions> |
| 90 |
</template> |
| 91 |
|
| 92 |
<template id="export_sa_zatca_ubl_signed_properties"> |
| 93 |
<xades:SignedProperties xmlns:xades="http://uri.etsi.org/01903/v1.3.2#" Id="xadesSignedProperties"> |
| 94 |
<xades:SignedSignatureProperties> |
| 95 |
<xades:SigningTime t-out="signing_time"/> |
| 96 |
<xades:SigningCertificate> |
| 97 |
<xades:Cert> |
| 98 |
<xades:CertDigest> |
| 99 |
<ds:DigestMethod xmlns:ds="http://www.w3.org/2000/09/xmldsig#" |
| 100 |
Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/> |
| 101 |
<ds:DigestValue xmlns:ds="http://www.w3.org/2000/09/xmldsig#" |
| 102 |
t-out="public_key_hashing"/> |
| 103 |
</xades:CertDigest> |
| 104 |
<xades:IssuerSerial> |
| 105 |
<ds:X509IssuerName xmlns:ds="http://www.w3.org/2000/09/xmldsig#" t-out="issuer_name"/> |
| 106 |
<ds:X509SerialNumber xmlns:ds="http://www.w3.org/2000/09/xmldsig#" |
| 107 |
t-out="serial_number"/> |
| 108 |
</xades:IssuerSerial> |
| 109 |
</xades:Cert> |
| 110 |
</xades:SigningCertificate> |
| 111 |
</xades:SignedSignatureProperties> |
| 112 |
</xades:SignedProperties> |
| 113 |
</template> |
| 114 |
</data> |
| 115 |
</odoo> |