Re: MD5->PHP how?

From: Date: Sun, 20 Apr 2003 17:58:28 +0000
Subject: Re: MD5->PHP how?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-144565@lists.php.net to get a copy of this message
don't forget to convert to uppercase... $md5_hash = md5(strtoupper("tango" . $seller_number . $order_number . $amount)); On Sunday 20 April 2003 08:16 am, John W. Holmes wrote: > > I am trying to work with 2checkouts MD5 HASH to make a client that > > will > > > confirm that the order did actually come from 2checkout. > > > > On the 2checkout site they have given an example in perl > > http://www.2checkout.com/md5_specs.htm > > Which I will copy the main part below: > > > > ************************Start copy*********************** > > The MD5 Hash is generated using the following values in order: > > 1.. A Secret Word value known only to the seller and 2CheckOut. > > (secret > > > word now is "tango") > > 2.. Your Seller Number (my seller number: 12324) > > 3.. Total Order Number ( Including Seller Number , i.e. 123-12324 ), > > 4.. Amount of the Sale ( no currency sign or commas ). > > > > Note: The whole MD5 pasback string will be converted to UPPER CASE. > > ************************End Copy************************* > > I think all they mean is > > $md5_hash = md5("tango" . $seller_number . $order_number . $amount); > > Then you pass that hash and values to your checkout and verify > everything matches on the other end. > > Easier to just use sessions, though, IMO. > > ---John W. Holmes... > > PHP Architect - A monthly magazine for PHP Professionals. Get your copy > today. http://www.phparch.com/ -- Two hands working can do more than a thousand clasped in prayer. -Unknown

« previous php.general (#144565) next »