Now I am getting this log message for Paypal "update_status
Module disabled due to zone restriction. Billing address is not within the Payment Zone selected in the module settings."
I have selected the same payment zone as I used successfully for several years with the built in Paypal express module, it is named EuropeandCH and the detailed setting ls in the picture below.
Customers from Switzerland (Schweiz) are now being rejected.
Suggestions welcomed
Now I had three customers rejected by PayPal "due to zone restriction". I tried ordering myself with PayPal on my live site using my Swiss details and it worked OK.
I asked Braintree and they claim it is not their problem!
Here is a typical zen cart log message [HTML]Sep-02-2017 23:20:54 (1504387254)
update_status
Anybody know where does this 150xxxx number come from? Is it a PayPal number and can I trace it somehow?Sep-02-2017 23:20:54 (1504387254)
update_status
Module disabled due to zone restriction. Billing address is not within the Payment Zone selected in the module settings.
I see someone with a USA address did some testing on my web site, thank you!
USA is not a valid zone for my site so will not work correctly!
I no longer get these Zone failure messages, I compared the Braintree Module braintree_api.php with the Paypalwpp module and changed anything that was different from the Paypalwpp, see comments with "MH".
Code:/** * Sets payment module status based on zone restrictions etc */ function update_status() { global $order, $db; // if store is not running in SSL, cannot offer credit card module, for PCI reasons if (IS_ADMIN_FLAG === false && (!defined('ENABLE_SSL') || ENABLE_SSL != 'true')) { $this->enabled = False; $this->zcLog('update_status', 'Module disabled because SSL is not enabled on this site.'); } // check other reasons for the module to be deactivated: // added "&& isset($order->billing['country']['id'])) {" from paypalwpp MH if ($this->enabled && (int) $this->zone > 0 && isset($order->billing['country']['id'])) { $check_flag = false; $sql = "SELECT zone_id FROM " . TABLE_ZONES_TO_GEO_ZONES . " WHERE geo_zone_id = :zoneId AND zone_country_id = :countryId ORDER BY zone_id"; $sql = $db->bindVars($sql, ':zoneId', $this->zone, 'integer'); $sql = $db->bindVars($sql, ':countryId', $order->billing['country']['id'], 'integer'); $check = $db->Execute($sql); while (!$check->EOF) { if ($check->fields['zone_id'] < 1) { $check_flag = true; break; } else if ($check->fields['zone_id'] == $order->billing['zone_id']) { $check_flag = true; break; } $check->MoveNext(); } if (!$check_flag) { $this->enabled = false; $this->zcLog('update_status', 'Module disabled due to zone restriction. Billing address is not within the Payment Zone selected in the module settings.'); } // added one } from next section MH } // module cannot be used for purchase > $10,000 USD $order_amount = $this->calc_order_amount($order->info['total'], 'USD'); if ($order_amount > 10000) { $this->enabled = false; $this->zcLog('update_status', 'Module disabled because purchase price (' . $order_amount . ') exceeds Braintree-imposed maximum limit of 10,000 USD.'); } if ($order->info['total'] == 0) { $this->enabled = false; /* $this->zcLog('update_status', 'Module disabled because purchase amount is set to 0.00.' . "\n" . print_r($order, true)); */ } } // removed one } from this section MH
Last edited by marton_1; 16 Sep 2017 at 09:36 PM.
My Mastercard customers are being rejected with the message the first four characters of the credit card number are incorrect.
Here in Switzerland the first four characters of the credit card number are 5487.
I assume the credit card number is pre-checked before being sent to Braintree?
Where are the numbers for this checking stored?
BTW, Visa works OK.
The actual message I receive is
So the first four numbers of the credit card are not displayed; is this some sort of security thing or does it mean the module lost the actual numbers somewhere?braintree_api
CC validation results: Die ersten 4 Ziffer der Kreditkartennummer, die Sie angegeben haben, lauten: . Ist diese Nummer richtig, können wir diese Kreditkarte nicht akzeptieren. Bitte korrigieren Sie ggf. die eingegebene Nummer oder setzen Sie sich mit Ihren Kreditinstitut in Verbindung.(-1)
When the form data is submitted to your server, the payment module takes the card number and passes it to the cc_validation class to be sure that it matches the card types that you've configured your store to accept in Admin->Configuration->Credit Cards.
But, since the error message you quoted isn't showing *any* of the rejected digits, it's possible that the value is blank when being submitted.
Or, it could be that the translation logic in your language files is missing the placeholder that displays the card number. (First test for that is to switch to english and see if the same message also doesn't show the digits.)
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Bookmarks