SallaApp / ZATCA

An unofficial package maintained by Salla to help developers to implement ZATCA (Fatoora) QR code easily which required for e-invoicing
MIT License
137 stars 54 forks source link

Issues with XML Validation in ZATCA Portal #42

Open mub009 opened 1 month ago

mub009 commented 1 month ago

Hi,

I am encountering several issues with the web validator for XML in the ZATCA portal. Below are the specific error messages I have received:

Wrong X509IssuerName HashedXml does not match with QR code hashedXml or the hashedXml is missing Wrong X509IssuerName Wrong X509SerialNumber Wrong Signature Value TimeStamp does not match with QR code TimeStamp or TimeStamp missing in invoice These errors seem to depend on the CSR token.

Could you please assist in resolving these issues?

Thank you!

image

bestiony commented 1 month ago

I have the same problem , any luck finding a solution ?

bestiony commented 1 month ago

@thaifanisalla are we doing sth wrong? or did Zatca devs make some changes making the package unusable? it'd be great to know so we can decide where to investigate

bestiony commented 1 month ago

@mub009 have you found the cause of the problem or an alternative package?

bestiony commented 1 month ago

@mub009 I fixed the problem. I was using Laravel Blade to make XML files.

  1. hash problem was caused by the the whitespace in my XML templates . I removed all whitespace and comments image

  2. the time in QR code does not time in the invoice was caused by the absence of 'Z' after the timestamps.

    • explanation: The Zatca docs state that adding 'Z' is optional but this Sella package always adds it
      image
  3. do not use the web XML validator because for some reason it does not work with simulation invoices or maybe it does not work with invoices that were made for the compliance testing phase. I'll keep you updated if that changes

mub009 commented 1 month ago

Bro i fixed this issue and completed passed sanbox .. now iam working on simulation portal