activemerchant 1.113.0 → 1.119.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (201) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +114 -0
  3. data/README.md +1 -1
  4. data/lib/active_merchant.rb +1 -1
  5. data/lib/active_merchant/billing/avs_result.rb +1 -1
  6. data/lib/active_merchant/billing/compatibility.rb +3 -3
  7. data/lib/active_merchant/billing/credit_card.rb +3 -0
  8. data/lib/active_merchant/billing/credit_card_methods.rb +72 -13
  9. data/lib/active_merchant/billing/gateways/adyen.rb +24 -14
  10. data/lib/active_merchant/billing/gateways/allied_wallet.rb +7 -7
  11. data/lib/active_merchant/billing/gateways/authorize_net.rb +44 -12
  12. data/lib/active_merchant/billing/gateways/authorize_net_arb.rb +3 -4
  13. data/lib/active_merchant/billing/gateways/authorize_net_cim.rb +2 -1
  14. data/lib/active_merchant/billing/gateways/axcessms.rb +8 -9
  15. data/lib/active_merchant/billing/gateways/balanced.rb +4 -3
  16. data/lib/active_merchant/billing/gateways/bambora_apac.rb +7 -7
  17. data/lib/active_merchant/billing/gateways/bank_frick.rb +7 -7
  18. data/lib/active_merchant/billing/gateways/banwire.rb +1 -1
  19. data/lib/active_merchant/billing/gateways/barclaycard_smartpay.rb +6 -4
  20. data/lib/active_merchant/billing/gateways/beanstream.rb +3 -3
  21. data/lib/active_merchant/billing/gateways/beanstream/beanstream_core.rb +4 -5
  22. data/lib/active_merchant/billing/gateways/blue_pay.rb +2 -3
  23. data/lib/active_merchant/billing/gateways/blue_snap.rb +37 -12
  24. data/lib/active_merchant/billing/gateways/bogus.rb +19 -19
  25. data/lib/active_merchant/billing/gateways/borgun.rb +11 -11
  26. data/lib/active_merchant/billing/gateways/bpoint.rb +8 -8
  27. data/lib/active_merchant/billing/gateways/braintree.rb +1 -1
  28. data/lib/active_merchant/billing/gateways/braintree_blue.rb +13 -10
  29. data/lib/active_merchant/billing/gateways/bridge_pay.rb +7 -7
  30. data/lib/active_merchant/billing/gateways/cams.rb +8 -8
  31. data/lib/active_merchant/billing/gateways/card_connect.rb +1 -1
  32. data/lib/active_merchant/billing/gateways/card_save.rb +1 -1
  33. data/lib/active_merchant/billing/gateways/card_stream.rb +2 -2
  34. data/lib/active_merchant/billing/gateways/cardknox.rb +7 -7
  35. data/lib/active_merchant/billing/gateways/cardprocess.rb +1 -1
  36. data/lib/active_merchant/billing/gateways/cecabank.rb +5 -5
  37. data/lib/active_merchant/billing/gateways/cenpos.rb +10 -10
  38. data/lib/active_merchant/billing/gateways/checkout.rb +2 -2
  39. data/lib/active_merchant/billing/gateways/checkout_v2.rb +17 -20
  40. data/lib/active_merchant/billing/gateways/clearhaus.rb +7 -7
  41. data/lib/active_merchant/billing/gateways/commercegate.rb +1 -1
  42. data/lib/active_merchant/billing/gateways/conekta.rb +2 -2
  43. data/lib/active_merchant/billing/gateways/creditcall.rb +10 -10
  44. data/lib/active_merchant/billing/gateways/credorax.rb +26 -15
  45. data/lib/active_merchant/billing/gateways/ct_payment.rb +10 -10
  46. data/lib/active_merchant/billing/gateways/culqi.rb +9 -9
  47. data/lib/active_merchant/billing/gateways/cyber_source.rb +58 -36
  48. data/lib/active_merchant/billing/gateways/d_local.rb +11 -11
  49. data/lib/active_merchant/billing/gateways/data_cash.rb +2 -3
  50. data/lib/active_merchant/billing/gateways/decidir.rb +31 -10
  51. data/lib/active_merchant/billing/gateways/dibs.rb +8 -8
  52. data/lib/active_merchant/billing/gateways/digitzs.rb +5 -5
  53. data/lib/active_merchant/billing/gateways/ebanx.rb +9 -9
  54. data/lib/active_merchant/billing/gateways/efsnet.rb +2 -3
  55. data/lib/active_merchant/billing/gateways/elavon.rb +286 -225
  56. data/lib/active_merchant/billing/gateways/element.rb +8 -8
  57. data/lib/active_merchant/billing/gateways/evo_ca.rb +5 -6
  58. data/lib/active_merchant/billing/gateways/eway.rb +3 -4
  59. data/lib/active_merchant/billing/gateways/eway_managed.rb +6 -7
  60. data/lib/active_merchant/billing/gateways/eway_rapid.rb +19 -6
  61. data/lib/active_merchant/billing/gateways/exact.rb +8 -9
  62. data/lib/active_merchant/billing/gateways/ezic.rb +7 -7
  63. data/lib/active_merchant/billing/gateways/fat_zebra.rb +4 -4
  64. data/lib/active_merchant/billing/gateways/federated_canada.rb +2 -3
  65. data/lib/active_merchant/billing/gateways/first_giving.rb +1 -1
  66. data/lib/active_merchant/billing/gateways/first_pay.rb +6 -6
  67. data/lib/active_merchant/billing/gateways/firstdata_e4.rb +7 -7
  68. data/lib/active_merchant/billing/gateways/firstdata_e4_v27.rb +21 -10
  69. data/lib/active_merchant/billing/gateways/flo2cash.rb +8 -8
  70. data/lib/active_merchant/billing/gateways/flo2cash_simple.rb +1 -1
  71. data/lib/active_merchant/billing/gateways/forte.rb +14 -8
  72. data/lib/active_merchant/billing/gateways/global_collect.rb +35 -16
  73. data/lib/active_merchant/billing/gateways/global_transport.rb +7 -7
  74. data/lib/active_merchant/billing/gateways/hdfc.rb +9 -9
  75. data/lib/active_merchant/billing/gateways/hps.rb +17 -8
  76. data/lib/active_merchant/billing/gateways/iats_payments.rb +9 -4
  77. data/lib/active_merchant/billing/gateways/in_context_paypal_express.rb +1 -1
  78. data/lib/active_merchant/billing/gateways/inspire.rb +3 -4
  79. data/lib/active_merchant/billing/gateways/instapay.rb +1 -2
  80. data/lib/active_merchant/billing/gateways/ipp.rb +5 -5
  81. data/lib/active_merchant/billing/gateways/iridium.rb +14 -15
  82. data/lib/active_merchant/billing/gateways/iveri.rb +7 -7
  83. data/lib/active_merchant/billing/gateways/ixopay.rb +7 -7
  84. data/lib/active_merchant/billing/gateways/jetpay.rb +1 -2
  85. data/lib/active_merchant/billing/gateways/jetpay_v2.rb +4 -5
  86. data/lib/active_merchant/billing/gateways/kushki.rb +6 -6
  87. data/lib/active_merchant/billing/gateways/latitude19.rb +14 -14
  88. data/lib/active_merchant/billing/gateways/linkpoint.rb +4 -5
  89. data/lib/active_merchant/billing/gateways/litle.rb +31 -15
  90. data/lib/active_merchant/billing/gateways/mastercard.rb +10 -10
  91. data/lib/active_merchant/billing/gateways/mercado_pago.rb +7 -7
  92. data/lib/active_merchant/billing/gateways/merchant_e_solutions.rb +1 -2
  93. data/lib/active_merchant/billing/gateways/merchant_one.rb +1 -1
  94. data/lib/active_merchant/billing/gateways/merchant_partners.rb +10 -10
  95. data/lib/active_merchant/billing/gateways/merchant_ware.rb +5 -7
  96. data/lib/active_merchant/billing/gateways/merchant_ware_version_four.rb +4 -6
  97. data/lib/active_merchant/billing/gateways/mercury.rb +4 -4
  98. data/lib/active_merchant/billing/gateways/metrics_global.rb +4 -5
  99. data/lib/active_merchant/billing/gateways/micropayment.rb +8 -8
  100. data/lib/active_merchant/billing/gateways/migs.rb +3 -4
  101. data/lib/active_merchant/billing/gateways/modern_payments_cim.rb +2 -4
  102. data/lib/active_merchant/billing/gateways/monei.rb +7 -7
  103. data/lib/active_merchant/billing/gateways/moneris.rb +4 -3
  104. data/lib/active_merchant/billing/gateways/money_movers.rb +2 -3
  105. data/lib/active_merchant/billing/gateways/mundipagg.rb +37 -10
  106. data/lib/active_merchant/billing/gateways/nab_transact.rb +2 -4
  107. data/lib/active_merchant/billing/gateways/ncr_secure_pay.rb +7 -7
  108. data/lib/active_merchant/billing/gateways/net_registry.rb +1 -2
  109. data/lib/active_merchant/billing/gateways/netaxept.rb +6 -6
  110. data/lib/active_merchant/billing/gateways/netbanx.rb +19 -8
  111. data/lib/active_merchant/billing/gateways/netbilling.rb +4 -5
  112. data/lib/active_merchant/billing/gateways/network_merchants.rb +2 -3
  113. data/lib/active_merchant/billing/gateways/nmi.rb +21 -7
  114. data/lib/active_merchant/billing/gateways/ogone.rb +3 -3
  115. data/lib/active_merchant/billing/gateways/omise.rb +13 -13
  116. data/lib/active_merchant/billing/gateways/openpay.rb +3 -4
  117. data/lib/active_merchant/billing/gateways/opp.rb +9 -9
  118. data/lib/active_merchant/billing/gateways/optimal_payment.rb +2 -3
  119. data/lib/active_merchant/billing/gateways/orbital.rb +196 -85
  120. data/lib/active_merchant/billing/gateways/pac_net_raven.rb +3 -4
  121. data/lib/active_merchant/billing/gateways/pagarme.rb +8 -8
  122. data/lib/active_merchant/billing/gateways/pago_facil.rb +2 -2
  123. data/lib/active_merchant/billing/gateways/pay_conex.rb +8 -8
  124. data/lib/active_merchant/billing/gateways/pay_gate_xml.rb +6 -7
  125. data/lib/active_merchant/billing/gateways/pay_hub.rb +7 -8
  126. data/lib/active_merchant/billing/gateways/pay_junction.rb +2 -3
  127. data/lib/active_merchant/billing/gateways/pay_junction_v2.rb +9 -9
  128. data/lib/active_merchant/billing/gateways/pay_secure.rb +2 -3
  129. data/lib/active_merchant/billing/gateways/paybox_direct.rb +23 -1
  130. data/lib/active_merchant/billing/gateways/payeezy.rb +32 -14
  131. data/lib/active_merchant/billing/gateways/payex.rb +6 -7
  132. data/lib/active_merchant/billing/gateways/payflow.rb +1 -1
  133. data/lib/active_merchant/billing/gateways/payment_express.rb +8 -4
  134. data/lib/active_merchant/billing/gateways/paymentez.rb +26 -6
  135. data/lib/active_merchant/billing/gateways/paymill.rb +7 -7
  136. data/lib/active_merchant/billing/gateways/paypal.rb +10 -2
  137. data/lib/active_merchant/billing/gateways/paypal/paypal_common_api.rb +1 -0
  138. data/lib/active_merchant/billing/gateways/paypal_express.rb +1 -1
  139. data/lib/active_merchant/billing/gateways/paypal_express_common.rb +1 -1
  140. data/lib/active_merchant/billing/gateways/payscout.rb +1 -2
  141. data/lib/active_merchant/billing/gateways/paystation.rb +3 -4
  142. data/lib/active_merchant/billing/gateways/payu_in.rb +3 -3
  143. data/lib/active_merchant/billing/gateways/payu_latam.rb +17 -10
  144. data/lib/active_merchant/billing/gateways/payway.rb +8 -9
  145. data/lib/active_merchant/billing/gateways/pin.rb +11 -0
  146. data/lib/active_merchant/billing/gateways/plugnpay.rb +1 -2
  147. data/lib/active_merchant/billing/gateways/pro_pay.rb +8 -8
  148. data/lib/active_merchant/billing/gateways/psigate.rb +2 -3
  149. data/lib/active_merchant/billing/gateways/psl_card.rb +1 -2
  150. data/lib/active_merchant/billing/gateways/qbms.rb +1 -2
  151. data/lib/active_merchant/billing/gateways/quantum.rb +1 -2
  152. data/lib/active_merchant/billing/gateways/quickbooks.rb +1 -1
  153. data/lib/active_merchant/billing/gateways/quickpay/quickpay_v10.rb +3 -4
  154. data/lib/active_merchant/billing/gateways/quickpay/quickpay_v4to7.rb +1 -2
  155. data/lib/active_merchant/billing/gateways/qvalent.rb +8 -8
  156. data/lib/active_merchant/billing/gateways/realex.rb +1 -1
  157. data/lib/active_merchant/billing/gateways/redsys.rb +86 -5
  158. data/lib/active_merchant/billing/gateways/s5.rb +7 -7
  159. data/lib/active_merchant/billing/gateways/safe_charge.rb +40 -14
  160. data/lib/active_merchant/billing/gateways/sage.rb +3 -5
  161. data/lib/active_merchant/billing/gateways/sage_pay.rb +2 -3
  162. data/lib/active_merchant/billing/gateways/sallie_mae.rb +1 -2
  163. data/lib/active_merchant/billing/gateways/secure_net.rb +1 -2
  164. data/lib/active_merchant/billing/gateways/secure_pay.rb +3 -4
  165. data/lib/active_merchant/billing/gateways/secure_pay_au.rb +2 -4
  166. data/lib/active_merchant/billing/gateways/secure_pay_tech.rb +1 -2
  167. data/lib/active_merchant/billing/gateways/securion_pay.rb +5 -6
  168. data/lib/active_merchant/billing/gateways/skip_jack.rb +2 -3
  169. data/lib/active_merchant/billing/gateways/smart_ps.rb +5 -6
  170. data/lib/active_merchant/billing/gateways/so_easy_pay.rb +7 -7
  171. data/lib/active_merchant/billing/gateways/spreedly_core.rb +6 -6
  172. data/lib/active_merchant/billing/gateways/stripe.rb +10 -10
  173. data/lib/active_merchant/billing/gateways/stripe_payment_intents.rb +30 -0
  174. data/lib/active_merchant/billing/gateways/swipe_checkout.rb +3 -4
  175. data/lib/active_merchant/billing/gateways/telr.rb +8 -8
  176. data/lib/active_merchant/billing/gateways/trans_first.rb +2 -2
  177. data/lib/active_merchant/billing/gateways/trans_first_transaction_express.rb +12 -12
  178. data/lib/active_merchant/billing/gateways/transact_pro.rb +9 -9
  179. data/lib/active_merchant/billing/gateways/trust_commerce.rb +1 -2
  180. data/lib/active_merchant/billing/gateways/usa_epay.rb +1 -1
  181. data/lib/active_merchant/billing/gateways/usa_epay_advanced.rb +32 -32
  182. data/lib/active_merchant/billing/gateways/usa_epay_transaction.rb +3 -4
  183. data/lib/active_merchant/billing/gateways/vanco.rb +3 -3
  184. data/lib/active_merchant/billing/gateways/verifi.rb +1 -2
  185. data/lib/active_merchant/billing/gateways/viaklix.rb +1 -2
  186. data/lib/active_merchant/billing/gateways/visanet_peru.rb +10 -10
  187. data/lib/active_merchant/billing/gateways/webpay.rb +2 -2
  188. data/lib/active_merchant/billing/gateways/wepay.rb +3 -2
  189. data/lib/active_merchant/billing/gateways/wirecard.rb +1 -2
  190. data/lib/active_merchant/billing/gateways/worldpay.rb +19 -11
  191. data/lib/active_merchant/billing/gateways/worldpay_online_payments.rb +14 -16
  192. data/lib/active_merchant/billing/gateways/worldpay_us.rb +7 -7
  193. data/lib/active_merchant/billing/response.rb +3 -2
  194. data/lib/active_merchant/country.rb +1 -1
  195. data/lib/active_merchant/network_connection_retries.rb +2 -2
  196. data/lib/active_merchant/post_data.rb +1 -1
  197. data/lib/active_merchant/posts_data.rb +1 -1
  198. data/lib/active_merchant/version.rb +1 -1
  199. data/lib/support/ssl_verify.rb +2 -2
  200. data/lib/support/ssl_version.rb +2 -2
  201. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e55d83260a0ec7b9a824a6313782d8c2b086d55aeb33d99554a09a18836f40a5
4
- data.tar.gz: 35b24d3dd8e61c096ec4f5ef5d241a5ae3f905f32ba159e4332be36942cd3c56
3
+ metadata.gz: 93f6306f4daee82e8458586cf10ba23a4b1cfa085c912430821bf583c789aded
4
+ data.tar.gz: a943a31836368d69faf7c731dbc4c81d8b1a302b0fddd5cb4960c6714a88f11a
5
5
  SHA512:
6
- metadata.gz: 337249552ee4b5fd33ff2ca257cfcc90265e9aff657b5c42f42563aae070fd583308f5e6cfe05ed5ba1d23a791bac04edf50d0b8afce796c051d36f0b0dca256
7
- data.tar.gz: d21728f2c2448e36842ccf5c38d64bf21ace79bd61ddf37367cf08f62ec98d33e0e277d5c5d21adb32ae7db4b03b15fa8e9f6d18b3acdf2be46ac153141585da
6
+ metadata.gz: cb33c86a0b9f3be8186a69fe170656684a98f74dcd9597df7f70792e23050235a9774c4192f25a1700110315dd6a98afa4ef0c3b74e8ea495814146594c2746a
7
+ data.tar.gz: 68729586be8247575dd96b6351db94f5b726338b92229cb49ddb82d6652ed93300049dd1edc18929a01850ec161cbe7574b0ceda0f1f233941019b7dfbca74f4
data/CHANGELOG CHANGED
@@ -2,6 +2,120 @@
2
2
 
3
3
  == HEAD
4
4
 
5
+ == Version 1.119.0 (February 9th, 2021)
6
+ * Payment Express: support verify/validate [therufs] #3874
7
+ * GlobalCollect: Truncate address fields [meagabeth] #3878
8
+ * Litle: Truncate address fields [meagabeth] #3877
9
+ * Netbanx: Add-customer-information(name,email,IP)-to-a-transaction [rockyhakjoong] #3754
10
+ * Decidir: Improve error mapping [meagabeth] #3875
11
+ * Worldpay: support `skip_capture` [therufs] #3879
12
+ * Redsys: Add new response code text [britth] #3880
13
+ * Orbital: Update ECP details to use payment source [jessiagee] #3881
14
+ * Alelo: Add additional BIN ranges [meagabeth] #3882
15
+ * HPS: Update Add support for general credit [naashton] #3885
16
+ * Elavon: Fix issue with encoding data sent in the request [naashton] #3865
17
+ * Orbital: Update ECP to use EWS verification [jessiagee] #3886
18
+ * Eway: Add 3ds field when do direct payment [GavinSun9527] #3860
19
+ * Support Creditel cardtype [therufs] #3883
20
+
21
+ == Version 1.118.0 (January 22nd, 2021)
22
+ * Worldpay: Add support for challengeWindowSize [carrigan] #3823
23
+ * Adyen: Update capitalization on subMerchantId field [cdmackeyfree] #3824
24
+ * Maestro and Elo: Update BIN ranges [meagabeth] #3822
25
+ * HPS: Truncate invoice numbers that are too long [curiousepic] #3825
26
+ * Pass network_transaction_id attribute in Response [therufs] #3815
27
+ * Elavon: support standardized stored credentials [therufs] #3816
28
+ * Decidir: update fraud_detection field [cdmackeyfree] #3829
29
+ * Paymentez: Add Olimpica cardtype [meagabeth] #3831
30
+ * SafeCharge: 3DS external MPI data refinements [curiousepic] #3821
31
+ * Credorax: Add support for 3DS Adviser [meagabeth] #3834
32
+ * Adyen: Support subMerchant data [mymir][therufs] #3835
33
+ * Decidir: add device_unique_identifier to card data [cdmackeyfree] #3839
34
+ * BraintreeBlue: add support for account_type field [jimilpatel24] #3840
35
+ * Redsys: Add support for stored_credential [meagabeth] #3844
36
+ * Redsys: add_payment method solution [meagabeth] #3845
37
+ * Stripe Payment Intents: Add support for error_on_requires_action option [tatsianaclifton] #3846
38
+ * Add 3DS 2.0 values to paypal [nebdil] #3285
39
+ * Redsys: Update Mpi Fields [tatsianaclifton] #3855
40
+ * Paypal: Update AuthStatus3ds MPI field [curiousepic] #3857
41
+ * Orbital: Update 3DS support for Mastercard [meagabeth] #3850
42
+ * Payeezy: Support standardized stored credentials [therufs] #3861
43
+ * CyberSource: Update `billing_address` override [meagabeth] #3862
44
+ * Paymentez: Add 3DS MPI field support [carrigan] #3856
45
+ * BlueSnap: Add support `fraud-session-id` field [meagabeth] #3863
46
+ * BlueSnap: Update handling of `transaction-fraud-info` fields [meagabeth] #3866
47
+ * Payeezy: Allow no stored credential transaction id [therufs] #3868
48
+ * Orbital: eCheck processing added [ajawadmirza] #3870
49
+ * FirsdataE4V27: Fixes some apple pay transaction issues [pi3r] #3872
50
+
51
+ == Version 1.117.0 (November 13th)
52
+ * Checkout V2: Pass attempt_n3d along with 3ds enabled [naashton] #3805
53
+ * GlobalCollect: Add support for Third-party 3DS2 data [molbrown] #3801
54
+ * Authorize.net: Pass stored credentials [therufs] #3804
55
+ * Authorize.net: Don't pass isFirstRecurringPayment [therufs] #3805
56
+ * Litle: Add support for general credit transactions [naashton] #3807
57
+ * Redsys: Add 3DS2 Integration Support [esmitperez] #3794
58
+ * Cybersource: Use firstname/lastname from address instead of the payment method [pi3r] #3798
59
+ * Add MPI functionality for SafeCharge gateway [daniel] #3809
60
+ * SafeCharge: Standardize MPI fields [curiousepic] #3809
61
+ * Credorax: Adds AMEX to supported cards and adds 1A error code [LinTrieu] #3792
62
+ * Stripe PI: Pass external 3DS auth data [curiousepic] #3811
63
+ * Credorax: Allow 3DS1 normalized pass-through, ease version matching [britth] #3812
64
+ * Redsys: Redsys: Harden 3DS v1/v2 check for External MPI [esmitperez] #3814
65
+ * Add card types for Stripe, Worldpay, Checkout.com [LinTrieu] #3810
66
+ * ActiveMerchant::Billing::Response: Include `network_transaction_id` attribute [therufs] #3815
67
+
68
+ == Version 1.116.0 (October 28th)
69
+ * Remove Braintree specific version dependency [pi3r] #3800
70
+
71
+ == Version 1.115.0 (October 27th)
72
+ * Checkout v2: $0 Auth on gateway [jessiagee] #3762
73
+ * Adyen: Safely add execute_threeds: false [curiousepic] #3756
74
+ * RuboCop: Fix Layout/SpaceAroundEqualsInParameterDefault [leila-alderman] #3720
75
+ * iATS: Allow email to be passed outside of the billing_address context [naashton] #3750
76
+ * Orbital: Don't pass xid for transactions using network tokens [britth] #3757
77
+ * Forte: Add service_fee_amount field [meagabeth] #3751
78
+ * WorldPay: Add support for idempotency_key[cdmackeyfree] #3759
79
+ * Orbital: Handle line_tot key as a string [naashton] #3760
80
+ * RuboCop: Fix Lint/UnusedMethodArgument [leila-alderman] #3721
81
+ * RuboCop: Fix Naming/MemoizedInstanceVariableName [leila-alderman] #3722
82
+ * RuboCop: Fix Style/BlockComments [leila-alderman] #3729
83
+ * Checkout V2: Move to single-transaction Purchases [curiousepic] #3761
84
+ * RuboCop: Fix Naming/ConstantName [leila-alderman] #3723
85
+ * Orbital: Fix schema errors [britth] #3766
86
+ * Checkout V2: Start testing via amount code [curiousepic] #3767
87
+ * CyberSource: Don't include empty `mdd_` fields [arbianchi] #3758
88
+ * RuboCop: Fix Naming/VariableNumber [leila-alderman] #3725
89
+ * Update BIN ranges for Elo cardtype [cdmackeyfree] #3769
90
+ * Orbital: Resolve CardIndicators issue [meagabeth] #3771
91
+ * Adyen: Add subMerchant fields [naashton] #3772
92
+ * PayPal Express: reduce param requirements [shasum] #3773
93
+ * PayU Latam: Support partial refunds [leila-alderman] #3774
94
+ * RuboCop: Fix Style/Alias [leila-alderman] #3727
95
+ * Stripe PI: Allow `on_behalf_of` to be passed alone #3776
96
+ * RuboCop: Fix Performance/RedundantMatch [leila-alderman] #3765
97
+ * RuboCop: Fix Layout/MultilineMethodCallBraceLayout [leila-alderman] #3763
98
+ * NMI: Add standardized 3DS fields [meagabeth] #3775
99
+ * Mundipagg: Add support for SubMerchant fields [meagabeth] #3779
100
+ * Stripe Payment Intents: Add request_three_d_secure option [molbrown] #3787
101
+ * Decidir: Add support for csmdds fields [naashton] #3786
102
+ * RuboCop: Fix Performance/StringReplacement [leila-alderman] #3782
103
+ * RuboCop: Fix Naming/HeredocDelimiterCase & Naming [leila-alderman] #3781
104
+ * BlueSnap: Add address fields to contact info [naashton] #3777
105
+ * RuboCop: Fix Layout/SpaceInsideHashLiteralBraces [leila-alderman] #3780
106
+ * RuboCop: Fix Style/AndOr [leila-alderman] #3783
107
+ * Checkout V2: Support ability to pass attempt_n3d 3ds field [naashton] #3788
108
+ * Elavon: Upgrade to `processxml.do` [therufs] #3784
109
+ * Checkout V2: Support for attempt_n3d 3DS field [naashton] #3790
110
+ * Elavon: Strip ampersands [therufs] #3795
111
+ * Paybox: Add support for 3DS 1.0 values [jcpaybox] #3335
112
+ * Decidir: Add additional fraud_detection options [cdmackeyfree] #3812
113
+
114
+ == Version 1.114.0
115
+ * BlueSnap: Add address1,address2,phone,shipping_* support #3749
116
+ * BlueSnap: Protect against `nil` metadata [carrigan] #3752
117
+ * Cybersource: [CyberSource] Ensure the default address doesn't override `ActionController::Parameters` [pi3r] #3755
118
+
5
119
  == Version 1.113.0
6
120
  * Orbital: Add cardIndicators field [meagabeth] #3734
7
121
  * Openpay: Add Colombia to supported countries [molbrown] #3740
data/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
  # Active Merchant
2
- [![Build Status](https://travis-ci.org/activemerchant/active_merchant.svg?branch=master)](https://travis-ci.org/activemerchant/active_merchant)
2
+ [![Build Status](https://github.com/activemerchant/active_merchant/workflows/CI/badge.svg?branch=master)](https://github.com/activemerchant/active_merchant/actions?query=workflow%3ACI)
3
3
  [![Code Climate](https://codeclimate.com/github/activemerchant/active_merchant.svg)](https://codeclimate.com/github/activemerchant/active_merchant)
4
4
 
5
5
  Active Merchant is an extraction from the ecommerce system [Shopify](http://www.shopify.com).
@@ -50,7 +50,7 @@ require 'active_merchant/version'
50
50
  require 'active_merchant/country'
51
51
 
52
52
  module ActiveMerchant
53
- def self.deprecated(message, caller=Kernel.caller[1])
53
+ def self.deprecated(message, caller = Kernel.caller[1])
54
54
  warning = caller + ': ' + message
55
55
  if respond_to?(:logger) && logger.present?
56
56
  logger.warn(warning)
@@ -88,7 +88,7 @@ module ActiveMerchant
88
88
  { 'code' => code,
89
89
  'message' => message,
90
90
  'street_match' => street_match,
91
- 'postal_match' => postal_match}
91
+ 'postal_match' => postal_match }
92
92
  end
93
93
  end
94
94
  end
@@ -28,7 +28,7 @@ module ActiveMerchant
28
28
  def self.humanize(lower_case_and_underscored_word)
29
29
  result = lower_case_and_underscored_word.to_s.dup
30
30
  result.gsub!(/_id$/, '')
31
- result.gsub!(/_/, ' ')
31
+ result.tr!('_', ' ')
32
32
  result.gsub(/([a-z\d]*)/i, &:downcase).gsub(/^\w/) { $&.upcase }
33
33
  end
34
34
  end
@@ -56,7 +56,7 @@ module ActiveMerchant
56
56
  private
57
57
 
58
58
  def internal_errors
59
- @errors ||= Errors.new
59
+ @internal_errors ||= Errors.new
60
60
  end
61
61
 
62
62
  class Errors < Hash
@@ -75,7 +75,7 @@ module ActiveMerchant
75
75
  end
76
76
 
77
77
  def empty?
78
- all? { |k, v| v&.empty? }
78
+ all? { |_k, v| v&.empty? }
79
79
  end
80
80
 
81
81
  def on(field)
@@ -24,6 +24,7 @@ module ActiveMerchant #:nodoc:
24
24
  # * Naranja
25
25
  # * UnionPay
26
26
  # * Alia
27
+ # * Olimpica
27
28
  #
28
29
  # For testing purposes, use the 'bogus' credit card brand. This skips the vast majority of
29
30
  # validations, allowing you to focus on your core concerns until you're ready to be more concerned
@@ -100,6 +101,8 @@ module ActiveMerchant #:nodoc:
100
101
  # * +'naranja'+
101
102
  # * +'union_pay'+
102
103
  # * +'alia'+
104
+ # * +'olimpica'+
105
+ # * +'creditel'+
103
106
  #
104
107
  # Or, if you wish to test your implementation, +'bogus'+.
105
108
  #
@@ -30,7 +30,9 @@ module ActiveMerchant #:nodoc:
30
30
  in_bin_range?(num.slice(0, 6), CARNET_RANGES) ||
31
31
  CARNET_BINS.any? { |bin| num.slice(0, bin.size) == bin }
32
32
  )
33
- }
33
+ },
34
+ 'olimpica' => ->(num) { num =~ /^636853\d{10}$/ },
35
+ 'creditel' => ->(num) { num =~ /^601933\d{10}$/ }
34
36
  }
35
37
 
36
38
  # http://www.barclaycard.co.uk/business/files/bin_rules.pdf
@@ -72,11 +74,57 @@ module ActiveMerchant #:nodoc:
72
74
  ]
73
75
 
74
76
  MAESTRO_BINS = Set.new(
75
- %w[500033 581149]
77
+ %w[ 500057
78
+ 501018 501043 501045 501047 501049 501051 501072 501075 501087 501089 501095
79
+ 501500
80
+ 501879 502113 502301 503175
81
+ 503645 503670
82
+ 504310 504338 504363 504533 504587 504620 504639 504656 504738 504781 504910
83
+ 507001 507002 507004 507082 507090
84
+ 560014 560565 561033
85
+ 572402 572610 572626
86
+ 576904
87
+ 578614
88
+ 581149
89
+ 585274 585697
90
+ 586509
91
+ 588729 588792
92
+ 589244 589407 589471 589605 589633 589647 589671
93
+ 590043 590206 590263 590265 590278 590361 590362 590379 590393 590590
94
+ 591235 591420 591481 591620 591770 591948 591994
95
+ 592024 592161 592184 592186 592201 592384 592393 592528 592566 592704 592735 592879 592884
96
+ 593074 593264 593272 593355 593496 593556 593589 593666 593709 593825 593963 593994
97
+ 594184 594409 594468 594475 594581 594665 594691 594710 594874 594968
98
+ 595355 595364 595532 595547 595561 595568 595743 595929
99
+ 596245 596289 596399 596405 596590 596608 596645 596646 596791 596808 596815 596846
100
+ 597077 597094 597143 597370 597410 597765 597855 597862
101
+ 598053 598054 598395 598585 598793 598794 598815 598835 598838 598880 598889
102
+ 599000 599069 599089 599148 599191 599310 599741 599742 599867
103
+ 601070
104
+ 604983
105
+ 606126
106
+ 636380 636422 636502 636639
107
+ 637046 637756
108
+ 639130
109
+ 690032]
76
110
  )
77
111
 
78
112
  # https://www.mastercard.us/content/dam/mccom/global/documents/mastercard-rules.pdf, page 73
79
113
  MAESTRO_RANGES = [
114
+ (500032..500033),
115
+ (501015..501016),
116
+ (501020..501021),
117
+ (501023..501029),
118
+ (501038..501041),
119
+ (501053..501058),
120
+ (501060..501063),
121
+ (501066..501067),
122
+ (501080..501083),
123
+ (501091..501092),
124
+ (501104..501105),
125
+ (501107..501108),
126
+ (501104..501105),
127
+ (501107..501108),
80
128
  (561200..561269),
81
129
  (561271..561299),
82
130
  (561320..561356),
@@ -101,14 +149,14 @@ module ActiveMerchant #:nodoc:
101
149
 
102
150
  # https://dev.elo.com.br/apis/tabela-de-bins, download csv from left sidebar
103
151
  ELO_RANGES = [
104
- 506707..506708, 506715..506715, 506718..506722, 506724..506724, 506726..506736, 506739..506739, 506741..506743,
105
- 506745..506747, 506753..506753, 506774..506776, 506778..506778, 509000..509001, 509003..509003, 509007..509007,
106
- 509020..509022, 509035..509035, 509039..509042, 509045..509045, 509048..509048, 509051..509071, 509073..509074,
107
- 509077..509080, 509084..509084, 509091..509094, 509098..509098, 509100..509100, 509104..509104, 509106..509109,
108
- 627780..627780, 636368..636368, 650031..650033, 650035..650045, 650047..650047, 650406..650410, 650434..650436,
109
- 650439..650439, 650485..650504, 650506..650530, 650577..650580, 650582..650591, 650721..650727, 650901..650922,
110
- 650928..650928, 650938..650939, 650946..650948, 650954..650955, 650962..650963, 650967..650967, 650971..650971,
111
- 651652..651667, 651675..651678, 655000..655010, 655012..655015, 655051..655052, 655056..655057
152
+ 506707..506708, 506715..506715, 506717..506722, 506724..506736, 506739..506743,
153
+ 506745..506747, 506753..506753, 506774..506778, 509000..509007, 509009..509014,
154
+ 509020..509030, 509035..509042, 509044..509089, 509091..509101, 509104..509807,
155
+ 509831..509877, 509897..509900, 509918..509964, 509971..509986, 509995..509999,
156
+ 627780..627780, 636368..636368, 650031..650033, 650035..650051, 650057..650081,
157
+ 650406..650439, 650485..650504, 650506..650538, 650552..650598, 650720..650727,
158
+ 650901..650922, 650928..650928, 650938..650939, 650946..650978, 651652..651704,
159
+ 655000..655019, 655021..655057
112
160
  ]
113
161
 
114
162
  # Alelo provides BIN ranges by e-mailing them out periodically.
@@ -120,8 +168,9 @@ module ActiveMerchant #:nodoc:
120
168
  402588..402588, 404347..404347, 405876..405876, 405882..405882, 405884..405884,
121
169
  405886..405886, 430471..430471, 438061..438061, 438064..438064, 470063..470066,
122
170
  496067..496067, 506699..506704, 506706..506706, 506713..506714, 506716..506716,
123
- 506749..506750, 506752..506752, 506754..506756, 506758..506762, 506764..506767,
124
- 506770..506771, 509015..509019, 509880..509882, 509884..509885, 509987..509992
171
+ 506749..506750, 506752..506752, 506754..506756, 506758..506767, 506770..506771,
172
+ 506773..506773, 509015..509019, 509880..509882, 509884..509885, 509887..509887,
173
+ 509987..509992
125
174
  ]
126
175
 
127
176
  CABAL_RANGES = [
@@ -298,6 +347,8 @@ module ActiveMerchant #:nodoc:
298
347
  case brand
299
348
  when 'naranja'
300
349
  valid_naranja_algo?(numbers)
350
+ when 'creditel'
351
+ valid_creditel_algo?(numbers)
301
352
  when 'alia'
302
353
  true
303
354
  else
@@ -352,7 +403,7 @@ module ActiveMerchant #:nodoc:
352
403
  sum % 10 == 0
353
404
  end
354
405
 
355
- # Checks the validity of a card number by use of Naranja's specific algorithm.
406
+ # Checks the validity of a card number by use of specific algorithms
356
407
  def valid_naranja_algo?(numbers) #:nodoc:
357
408
  num_array = numbers.to_s.chars.map(&:to_i)
358
409
  multipliers = [4, 3, 2, 7, 6, 5, 4, 3, 2, 7, 6, 5, 4, 3, 2]
@@ -361,6 +412,14 @@ module ActiveMerchant #:nodoc:
361
412
  final_num = intermediate > 9 ? 0 : intermediate
362
413
  final_num == num_array[15]
363
414
  end
415
+
416
+ def valid_creditel_algo?(numbers) #:nodoc:
417
+ num_array = numbers.to_s.chars.map(&:to_i)
418
+ multipliers = [5, 4, 3, 2, 1, 9, 8, 7, 6, 5, 4, 3, 2, 1, 9]
419
+ num_sum = num_array[0..14].zip(multipliers).map { |a, b| a * b }.reduce(:+)
420
+ final_num = num_sum % 10
421
+ final_num == num_array[15]
422
+ end
364
423
  end
365
424
  end
366
425
  end
@@ -29,13 +29,13 @@ module ActiveMerchant #:nodoc:
29
29
  '135' => STANDARD_ERROR_CODE[:incorrect_address]
30
30
  }
31
31
 
32
- def initialize(options={})
32
+ def initialize(options = {})
33
33
  requires!(options, :username, :password, :merchant_account)
34
34
  @username, @password, @merchant_account = options.values_at(:username, :password, :merchant_account)
35
35
  super
36
36
  end
37
37
 
38
- def purchase(money, payment, options={})
38
+ def purchase(money, payment, options = {})
39
39
  if options[:execute_threed] || options[:threed_dynamic]
40
40
  authorize(money, payment, options)
41
41
  else
@@ -46,7 +46,7 @@ module ActiveMerchant #:nodoc:
46
46
  end
47
47
  end
48
48
 
49
- def authorize(money, payment, options={})
49
+ def authorize(money, payment, options = {})
50
50
  requires!(options, :order_id)
51
51
  post = init_post(options)
52
52
  add_invoice(post, money, options)
@@ -62,7 +62,7 @@ module ActiveMerchant #:nodoc:
62
62
  commit('authorise', post, options)
63
63
  end
64
64
 
65
- def capture(money, authorization, options={})
65
+ def capture(money, authorization, options = {})
66
66
  post = init_post(options)
67
67
  add_invoice_for_modification(post, money, options)
68
68
  add_reference(post, authorization, options)
@@ -70,7 +70,7 @@ module ActiveMerchant #:nodoc:
70
70
  commit('capture', post, options)
71
71
  end
72
72
 
73
- def refund(money, authorization, options={})
73
+ def refund(money, authorization, options = {})
74
74
  post = init_post(options)
75
75
  add_invoice_for_modification(post, money, options)
76
76
  add_original_reference(post, authorization, options)
@@ -78,13 +78,13 @@ module ActiveMerchant #:nodoc:
78
78
  commit('refund', post, options)
79
79
  end
80
80
 
81
- def void(authorization, options={})
81
+ def void(authorization, options = {})
82
82
  post = init_post(options)
83
83
  add_reference(post, authorization, options)
84
84
  commit('cancel', post, options)
85
85
  end
86
86
 
87
- def adjust(money, authorization, options={})
87
+ def adjust(money, authorization, options = {})
88
88
  post = init_post(options)
89
89
  add_invoice_for_modification(post, money, options)
90
90
  add_reference(post, authorization, options)
@@ -92,7 +92,7 @@ module ActiveMerchant #:nodoc:
92
92
  commit('adjustAuthorisation', post, options)
93
93
  end
94
94
 
95
- def store(credit_card, options={})
95
+ def store(credit_card, options = {})
96
96
  requires!(options, :order_id)
97
97
  post = init_post(options)
98
98
  add_invoice(post, 0, options)
@@ -115,7 +115,7 @@ module ActiveMerchant #:nodoc:
115
115
  end
116
116
  end
117
117
 
118
- def unstore(options={})
118
+ def unstore(options = {})
119
119
  requires!(options, :shopper_reference, :recurring_detail_reference)
120
120
  post = {}
121
121
 
@@ -126,7 +126,7 @@ module ActiveMerchant #:nodoc:
126
126
  commit('disable', post, options)
127
127
  end
128
128
 
129
- def verify(credit_card, options={})
129
+ def verify(credit_card, options = {})
130
130
  MultiResponse.run(:use_first_response) do |r|
131
131
  r.process { authorize(0, credit_card, options) }
132
132
  options[:idempotency_key] = nil
@@ -227,7 +227,16 @@ module ActiveMerchant #:nodoc:
227
227
  end
228
228
 
229
229
  def add_merchant_data(post, options)
230
- post[:additionalData][:subMerchantId] = options[:sub_merchant_id] if options[:sub_merchant_id]
230
+ post[:additionalData][:subMerchantID] = options[:sub_merchant_id] if options[:sub_merchant_id]
231
+ post[:additionalData][:subMerchantName] = options[:sub_merchant_name] if options[:sub_merchant_name]
232
+ post[:additionalData][:subMerchantStreet] = options[:sub_merchant_street] if options[:sub_merchant_street]
233
+ post[:additionalData][:subMerchantCity] = options[:sub_merchant_city] if options[:sub_merchant_city]
234
+ post[:additionalData][:subMerchantState] = options[:sub_merchant_state] if options[:sub_merchant_state]
235
+ post[:additionalData][:subMerchantPostalCode] = options[:sub_merchant_postal_code] if options[:sub_merchant_postal_code]
236
+ post[:additionalData][:subMerchantCountry] = options[:sub_merchant_country] if options[:sub_merchant_country]
237
+ post[:additionalData][:subMerchantTaxId] = options[:sub_merchant_tax_id] if options[:sub_merchant_tax_id]
238
+ post[:additionalData][:subMerchantMCC] = options[:sub_merchant_mcc] if options[:sub_merchant_mcc]
239
+ post[:additionalData] = post[:additionalData].merge(options[:sub_merchant_data]) if options[:sub_merchant_data]
231
240
  end
232
241
 
233
242
  def add_risk_data(post, options)
@@ -271,7 +280,7 @@ module ActiveMerchant #:nodoc:
271
280
  post[:shopperReference] = options[:shopper_reference] if options[:shopper_reference]
272
281
  end
273
282
 
274
- def add_shopper_interaction(post, payment, options={})
283
+ def add_shopper_interaction(post, payment, options = {})
275
284
  if (options.dig(:stored_credential, :initial_transaction) && options.dig(:stored_credential, :initiator) == 'cardholder') ||
276
285
  (payment.respond_to?(:verification_value) && payment.verification_value && options.dig(:stored_credential, :initial_transaction).nil?) ||
277
286
  payment.is_a?(NetworkTokenizationCreditCard)
@@ -364,7 +373,7 @@ module ActiveMerchant #:nodoc:
364
373
  cvc: credit_card.verification_value
365
374
  }
366
375
 
367
- card.delete_if { |k, v| v.blank? }
376
+ card.delete_if { |_k, v| v.blank? }
368
377
  card[:holderName] ||= 'Not Provided' if credit_card.is_a?(NetworkTokenizationCreditCard)
369
378
  requires!(card, :expiryMonth, :expiryYear, :holderName, :number)
370
379
  post[:card] = card
@@ -432,7 +441,8 @@ module ActiveMerchant #:nodoc:
432
441
  return unless !options[:execute_threed].nil? || !options[:threed_dynamic].nil?
433
442
 
434
443
  post[:browserInfo] = { userAgent: options[:user_agent], acceptHeader: options[:accept_header] } if options[:execute_threed] || options[:threed_dynamic]
435
- post[:additionalData] = { executeThreeD: options[:execute_threed] } if !options[:execute_threed].nil?
444
+ post[:additionalData] ||= {}
445
+ post[:additionalData][:executeThreeD] = options[:execute_threed] if !options[:execute_threed].nil?
436
446
  end
437
447
  end
438
448