Forum Moderators: coopster

Message Too Old, No Replies

Digitally Signing Emails With PHP

Asks the question how do i digitally sign an email from the server via php

         

ChrisDean

3:19 pm on Jul 5, 2007 (gmt 0)

10+ Year Member



Hi everyone,

I would like to send digitally signed emails from one of my webservers from a particular php application I am writing.

Has anyone here done this before, either in PHP or another language who can point me in the right direction to more information or guide me through the process step by step?

Some example code would be very handy if anyone has anything...

I am using php 5.2.3 and can provide more details if necessary

Thanks in advance

Chris Dean

eelixduppy

10:21 pm on Jul 5, 2007 (gmt 0)



Welcome to WebmasterWorld, Chris!

What exactly do you mean by "digitally signed"? Do you just want to send an email from a php script? To do this, you can use the mail function [php.net].

ChrisDean

8:31 am on Jul 6, 2007 (gmt 0)

10+ Year Member



Thanks and no I can do that :)

By digitally signing the email I'm talking about PGP encryption of it, generating and sending the relevant keys to the user and whatever else is needed back end for the keys to be verified.

Sorry for being a bit vague as I'm still on 50% or so up on the requirements for this to work.

I've looked around a bit and horde seems to have some similar functionality to what I am thinking of in it's Crypt scripts but I don't have the time to deconstruct that into something useful really.

Can't remember if the php examples I've seen do this too but I think the the perl ones require interfacing with gnuPG to create the keys to form a S/MIME message.

Seems to me encrypted email is something sorely overlooked when sending sensitive data out from web applications such as login details, financial information etc. and for the application I'm writing I'd like to do this if it seems feasible.

At the moment however it looks like this could be a too unreliable way to send mail to users, due to lack of support in some clients, though I guess I could have an opt out of secure email option in the app.