Page MenuHomePhabricator

Italian ApplePay rejections
Closed, ResolvedPublic

Description

@krobinson forwarded a report about recent ApplePay failures here. Preliminary digging shows 154 affected donations failing on fraud scores. However, the fraud scores seem to be tripping due to a default minfraud score being assigned due to the minfraud API call failing. I see the following in the logs for these donations:

Feb 11 11:11:08 payments1006 adyen_gateway_fraud: 228919160:228919160.1 "addRiskScore" An error occurred during minFraud query. Assigning MinFraudErrorScore.
Feb 11 11:11:08 payments1006 adyen_gateway_fraud: 228919160:228919160.1 region must be an ISO 3166-2 subdivision code

This suggests the country code isn't being sent or received correctly.

The default minfraud score especially hurts us with ApplePay, as we're already assigning a default CVV and AVS score due to the payment method, leading to a straight rejection.

To find examples, hop on to frlog1002 and run logdog "FINAL STATUS: 'pending-poke:reject' - visa, apple"

A large majority are Italian donors from today.

Let's figure out what's wrong with the API call. I think the pending transaction resolver will help us here, but that also needs follow-up to confirm.

Event Timeline

Apple Pay is giving us a full name for the 'state_province', which for other payment methods we always collect via a dropdown that uses the ISO code. So we need to either discard or map that when it's not an ISO code.

Change #1118832 had a related patch set uploaded (by Ejegg; author: Ejegg):

[mediawiki/extensions/DonationInterface@master] Only send ISO 3166-2 codes as 'region' to minfraud

https://gerrit.wikimedia.org/r/1118832

Change #1118832 merged by jenkins-bot:

[mediawiki/extensions/DonationInterface@master] Only send ISO 3166-2 codes as 'region' to minfraud

https://gerrit.wikimedia.org/r/1118832

OK, the fix for this went out about an hour ago, and I haven't seen any more minfraud errors since then.