About Duffbert...

Duffbert's Random Musings is a blog where I talk about whatever happens to be running through my head at any given moment... I'm Thomas Duff, and you can find out more about me here...

Email Me!

Search This Site!

Custom Search

I'm published!

Co-author of the book IBM Lotus Sametime 8 Essentials: A User's Guide
SametimeBookCoverImage.jpg

Purchase on Amazon

Co-author of the book IBM Sametime 8.5.2 Administration Guide
SametimeAdminBookCoverImage.jpg

Purchase on Amazon

MiscLinks

Visitor Count...



View My Stats

« How to Refresh a View Programmatically Using the LotusScipt NotesTimer Class | Main| Book Review - Hardware Hacking For Geeks by Scott Fullam »

Any PHP/PGP/GPG/securemail gurus out there?

Category Software Development

I inherited a website for a non-profit that was built with PHP.  One of the features is a page that allows a user to fill in some information to join the organization.  At the end of the script, an encrypted email is sent to two individuals at the company so that they can complete the registration process and charge the credit card.

At some point in the game, the encryption piece has broken.  The original developers used GPG for the encryption, but there is no documentation on the implementation.  At the bottom of the PHP script for the membership page, we have the following:

mail("thomas.duff@marquamgroup.com", "Membership Application", $mailbody);

$an_error = securemail($SM_ID1, $SM_MAIL1, $mailbody);

if ($an_error != "1") {$an_error = securemail($SM_ID2, $SM_MAIL2, $mailbody);}

I put the first mail statement in there so that I could see when someone sent an email.  The second and third securemail functions never successfully execute, and the user gets an error message stating the transaction did not complete.  My email arrives, the other two do not, as securemail is returning an error code of "1".

$SM_ID1 and 2 are set in a config file to values like "xyz1" and "xyz2", while $SM_MAIL1 and 2 are valid email addresses.  The $mailbody is built from data entered on the form, and is fine in that I see all the data in the unencrypted email that comes to me.

Any hints on where to start looking?  I've googled a number of terms (securemail, pgp, gpg, documentation, error) and have not yet found anything of use.

I realize this is not Notes/Domino related, but I'm at wits end here...  Thanks for any help.  If you'd like, we can also carry on via email at thomas.duff@marquamgroup.com.

Comments

Gravatar Image1 - Actually, I figured out that "securemail" was a function in a functions.php file, and that function is doing a gpg encryption of the message. I'm exchanging emails with someone in Austraila who understands this stuff, so we'll see how that goes... Thanks for the clue!

Gravatar Image2 - Yo Duffbert,

I'm no PHP/GPG wiz, but I found the securemail script online (http://www.sys3175.co.uk/securemail.php ) - this is the one you're looking at, right? The only way I can see for it to suddenly start breaking would be if somebody nuked something the configuration settings - at the top of the script - rely on (deleted the tmp or gpg directories or something similar). Have you already checked those out?

Post A Comment

:-D:-o:-p:-x:-(:-):-\:angry::cool::cry::emb::grin::huh::laugh::lips::rolleyes:;-)

Want to support this blog or just say thanks?

When you shop Amazon, start your shopping experience here.

When you do that, all your purchases during that session earn me an affiliate commission via the Amazon Affiliate program. You don't have to buy the book I linked you to (although I wouldn't complain!). Simply use that as your starting point.

Thanks!

Thomas "Duffbert" Duff

Ads of Relevance...