4 replies [Last post]
ñull@drupal.org's picture
Offline
Joined: 01/26/2009
Juice: 114
Was this information Helpful?

Something that you don't see offered by cart systems is the possibility to electronically sign invoices. As far as I can tell on European soil this is even a legal requirement for a valid electronic invoice nowadays. What I mean is that an legally valid invoice is either printed on company paper and sent with the product or when the product is not tangible and we want to avoid snail mail, the on-line invoice should have the following characteristics (as far as I know):

1. The invoice should be electronically signed with a certified signature that is acceptable to the local authorities or tax office.
2. I think that the invoice is not allowed to change anymore after it is signed and time stamped.
3. In my country the local authorities offer a signature verification service and the signed invoice should be compatible with that. Also for the client's sake it should be easy for them to use this service.

My question is if there are developers or shop owners that are developing something in that direction? If there is any initiative I would like to know about it and may be I can contribute time, money, my input etc.

Would any of you know how to go about implementing something like that? To date I cannot find any open source PHP library. There are some references to an iText port to PHP but I did not find it anywhere, only rumors, a related getacoder project and even one that relates to Drupal. So the only open source solution would be by somehow using iText under Java and switch to a pure PHP solution when it becomes available?

Lyle's picture
Offline
AdministratoreLiTe!
Joined: 08/07/2007
Juice: 6846
Re: Electronically signed invoices

I looked on php.net a little bit, and it looks like the OpenSSL library should let you sign data with PHP. I'm not very experienced with this kind of thing, though, so I don't know how well it would work for your local authorities or how difficult it is to get all the right credentials configured.

ñull@drupal.org's picture
Offline
Joined: 01/26/2009
Juice: 114
Re: Re: Electronically signed invoices

The ideal would be when the Acrobat Reader can check the signature and that is something iText can do by signing according to PDF specification.

TR
TR's picture
Online
Bug FinderFAQ ModeratorGetting busy with the Ubercode.
Joined: 11/05/2007
Juice: 3424
Re: Re: Re: Electronically signed invoices

Yes, it's easy to sign a block of text in PHP with OpenSSL. But it seems you would rather generate an encrypted PDF. Try http://www.ubercart.org/contrib/3402 for that.

<tr>.
vincew's picture
Offline
Joined: 01/21/2009
Juice: 153
Re: Re: Re: Electronically signed invoices

Invoices on it's own is IMO a very big issue to handle. With UC going global several other aspects are coming into the play....

For instance;

  • Global-,
  • Regional- and
  • National-

laws and regulations. Not to mention inter-regional or inter-national invoicing, which is a well known phenomenon related to on-line shopping.

Electronic signed signatures is one possible solution in some countries. Other countries accept it as the only solution. In the Netherlands it's accepted to send the invoices in several forms, like:

  1. It has to obey the same rules as a paper invoice
  2. Advanced Electronic Signature
  3. Other Methods, like (don't laugh). sending by email, publication on the website, delivery as a PDF file

So it's gonna be pretty hard in this stage to write some code on this (even if some libraries are available) without knowing the specs... Is it going to be some code qualifing the demands on the shop-owner or is it going to be some code addressed to the needs (read: laws, regulations, etc) on the buyer side?

It's not only depending on laws and regulations, but also on buyer- and seller needs on trust. Can a buyer trust the invoice the seller sends, is correct? Perhaps not a big issue when ordering one or two items a week, but when recieving several hundereds of invoices a day, an account manager must depend on the correct data, simply because it's not possible for him to recalculate and check everything. In other words can a seller provide the trust the buyer is looking for. And like in the real world Smiling every buyer has his own needs.

In short... pretty big topic you've put on the agenda here com2..

Always willing to provide thoughts, legal papers, etc on this....

Best,
VinceW

PS: The Dutch Tax Administration has some information about this. It can be found here: http://www.belastingdienst.nl/zakelijk/elektronisch_factureren/elektroni...

Unfortunately there is only a Dutch version.

-=[ Your Information Matters ]=-

(You may use my personal contact form to discuss drupal/ubercart work.)