Try our conversational search powered by Generative AI!

Credit Card Payment: Authorize.net CCV validation issue

Vote:
 

I have used commerce 9 version and for credit card payment integrated with authorize.net provider. The card transaction and payment gatway integration is  fine and able to get the  successfull response. But, client asking to enable the CVV fraud filter. So we sent a card code value to validate the card, but its not validated in Authorize.net always says "Not applicable" / "Not processed" and accept the payment.

Used the below code for sending the card code value.

 var payment = selectedPayment.PreProcess(_CartHelper.OrderForm);

                if (payment != null)
                {
                    payment.PaymentMethodId = paymentMethodRow.PaymentMethodId;
                    payment.PaymentMethodName = paymentMethodRow.Name;
                    payment.BillingAddressId = _CartHelper.OrderForm.BillingAddressId;
                    payment.Amount = _CartHelper.OrderForm.Total;                     
                    Order.Payments.Add(payment);
                    Cart.AcceptChanges();

                    return true;
                }

in PreProcess

--------------------

  var payment = new CreditCardPayment()
            {
                CreditCardNumber = CreditCardNumber.Text,
                CreditCardSecurityCode = SecurityCode.Text             
           };

We feel that, the CVV value is not passed into the AUthorize.net from EPiServer CreditCardPayment class, because we tried to insert the sample transaction in the authorize.net virtual terminal and it is working fine.

Thanks in adavance.

#181224
Edited, Aug 14, 2017 13:45
Vote:
 

I'm pretty sure that AuthorizePaymentGateway sends the CCV to Authorize.net. But don't you need to add the expiration date as well? 

#181240
Aug 14, 2017 15:59
Vote:
 

Thanks for your reply. Sorry I forgot to add the code and actually I send the expiry Month and year it works perfectly. My real problem is CCV always not validated. If I give the invalid code, that is  also accepted and processed the payment in authorize.net.

Why I'm mentioned it might be the problem not passed the value, cross verified in payment gateway interface is good, but the same time if I'm not given the card code the same status is updated. 

One more thing, if I set mandatory in authorize.net payment form field the site through error " card code require"  

Thanks 

#181244
Aug 14, 2017 17:11
Vote:
 

I'm not 100% sure here, but should this relate to this setting? 

#181245
Aug 14, 2017 17:24
Vote:
 

Yes that's already defined in authorize.net, do you have any sample or reference code so that I can validate with our end? 

#181257
Aug 15, 2017 3:48
Vote:
 

Also some additional information for processing the "CartChekout" workflow used the below code:

 /// <summary>
    /// This class represents the Cart Checkout workflow
    /// </summary>
    [ActivityFlowConfiguration(Name = "CartCheckOut")]
    public class CartCheckoutActivityFlow : ActivityFlow
    {
        /// <inheritdoc />
        public override ActivityFlowRunner Configure(ActivityFlowRunner activityFlow)
        {
            return activityFlow.If(() => ShouldProcessPayment())                               
                                    .Do<ProcessPaymentActivity>()                                   
                               .EndIf()                                
                               .Do<CalculateTotalsActivity>()
                               .Do<AdjustInventoryActivity>()
                               .Do<RecordPromotionUsageActivity>();
        }
    }
#181314
Edited, Aug 16, 2017 9:04
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.