Thursday, 11 March 2010 02:36

I want to send my apologies to all the users that had their orders delayed due to some weirdness involving PayPal's IPN notifications. Apparently, PayPal was sending IPN notifications from an IP address that VirtueMart couldn't resolve as belonging to PayPal, and was rejecting the IPN notice as fraud. The notice I received from VirtueMart was:

Error code 506. Possible fraud. Error with REMOTE IP ADDRESS =

In order to resolve this, I dove into the notification script at administrator/components/com_virtuemart/notify.php to see how it was determining what constituted a "fraudulent" IP address. Here's what I found:

$paypal_iplist = gethostbynamel('');
$paypal_iplist2 = gethostbynamel('');
$paypal_iplist = array_merge( $paypal_iplist, $paypal_iplist2 );

Further down in the code, the array $paypal_iplist is looped and if $_SERVER['REMOTE_ADDR'] doesn't match, it's considered a fraudulent transaction. What I ended up doing was adding an extra line and explicitly added this new IP:

$paypal_iplist = gethostbynamel('');
$paypal_iplist2 = gethostbynamel('');
$paypal_iplist = array_merge( $paypal_iplist, $paypal_iplist2 );
$paypal_iplist[] = '';

Hopefully, this resolves this issue and nobody else will have to wait for their downloads. I suppose only time will tell...


Add your comment

Your name:
  The word for verification. Lowercase letters only with no spaces.
Word verification:

The Joomla!® name is used under a limited license from Open Source Matters in the United States and other countries. Jeff Channell is not affiliated with or endorsed by Open Source Matters or the Joomla!® Project.

Joomla Extensions