On Thu, 17 Jul 2003 05:12:16 +0000, [EMAIL PROTECTED] (Mario Kulka)
wrote:

>I'm trying to set up credit card processing and one of the first steps is to 
>establish a "secure socket connection" - how can i do it? (My host does 
>support it)

You are not clear which part of the credit card processing you are
talking about?

To take cc info from a customer:
Just run your cgi script on a secure server, ie https not http.
https://somehost.com/my.cgi

To connect to a bank's verification service:
use  LWP which handles ssl.  The best way to do this, is
setup a simple html form which can connect to your
service's test server. Get some test transactions going thru
html, and then take the html_form_fields and plug them into
LWP like shown below.

$card_no= &z($card_no);  #decrypt card number, encrypted on hard drive
 my $ua = LWP::UserAgent->new(timeout=>45); 
 my $req = POST
'https://zentara.zentara.net/~zentara/cgi-bin/store/respgen.pl', 
  [IOC_merchant_id => '4301330018817403', 
  IOC_order_total_amount => "$grand_total", 
  IOC_merchant_shopper_id => 'susehost', 
#  IOC_merchant_order_id => "$order_id", 
  IOC_merchant_order_id => "$unique_id", 
  ecom_billto_postal_street_line1 => "$street1", 
  ecom_billto_postal_postalcode => "$zip", 
  ecom_billto_postal_countrycode => "$country", 
  ecom_billto_online_email => "$email", 
  ecom_payment_card_name => "$first $last", 
  ecom_payment_card_number => "$card_no", 
  ecom_payment_card_expdate_month => "$exp_mon", 
  ecom_payment_card_expdate_year => "$exp_yr", 
  url => 'https://192.168.0.1/~zentara/cgi-bin/shop/boacc.pl', 
 ]; 

The url is the url that you want the results returned to, typically it
will be true or false and maybe a reason or error code.





-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to