PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV 2024 → [WD] Digital sign of a file (.pdf, .doc, etc..etc)
[WD] Digital sign of a file (.pdf, .doc, etc..etc)
Débuté par Gianni Spano, 05 déc. 2017 14:18 - 1 réponse
Posté le 05 décembre 2017 - 14:18
Hello

I have a user who needs to digital sign frequently some files to send further to Italian Public Administration's offices and they need to be signed using a smartcard to produce a signed file with the extension ".p7m".

Is there some example somewhere for WD on how to add a digital sign on a file using a smartcard?? Or if someone has developed similar functions?

Suggestions and examples are welcome :)

Thanks in advance

Gianni
Posté le 05 décembre 2017 - 17:01
Hi Gianni,

OpenSSL is your friend.
You can generate the .xxx file into an encrypted and signed .p7m using OpenSSL.
You should use the public key of your counterparty and your private key (coming from the card reader I guess).
With a simple command line script you next sign and encrypt the file into a p7m and next you can ftp/upload/exchange/... it with the counterparty.
They will than use your public key and their private key to decypt and validate the file.

I've implemented an exchange like that a couple of years ago between an ERP and a cloud based treasury system.

There are other solutions but OpenSSL is free (and community driven)...

Cheers,

Peter Holemans