开发者

Transactions approved by Authorize.Net with incorrect expiration date and CVS number

开发者 https://www.devze.com 2023-03-06 07:21 出处:网络
I have currently processed a credit card using Authorize.net with Card Present settings. The great thing is that the card is being transacted but when i use the same card with different expiry date or

I have currently processed a credit card using Authorize.net with Card Present settings. The great thing is that the card is being transacted but when i use the same card with different expiry date or a different cvs number the card is still being transacted. This shouldnt happen. Here is the code that im using in VB.NET.

Am i missing any settings?. This transaction is on test mode.

Public Sub New(ByVal authID As String, _
                   ByVal authPassword As String, _
                   ByVal authTransKey As String, _
                   ByVal serverType As AuthServerTypeEnum, _
                   ByVal cardHolderName As String, _
                   ByVal cardNumber As String, _
                   ByVal expiryMonth As String, _
                   ByVal expiryYears As String, _
                   ByVal issuenumber As Integer, _
                   ByVal cvs As Integer, _
                   ByVal issueMonth As String, _
                   ByVal issueYear As String, _
                   ByVal fullName As String, _
                   ByVal address1 As String, _
                   ByVal address2 As String, _
                   ByVal townCity As String, _
                   ByVal county As String, _
                   ByVal country As String, _
                   ByVal postCode As String, _
                   ByVal amount As String)

        Me._AuthServerType = AuthServerTypeEnum.Test
        'Me._AuthLoginID = "xxxxxx"
        'Me._AuthTransKey = "xxxxxx"
        Me._AuthLoginID = "xxxxxx"
        Me._AuthTransKey = "xxxxxx"

        Dim objInf As New NameValueCollection(30)
        Dim objRetInf As New NameValueCollection(30)

        objInf.Add("x_version", _AuthVersion)
        objInf.Add("x_delim_data", "True")
        objInf.Add("x_login", Me.AuthLoginID)
        objInf.Add("x_password", Me.AuthPassword)
        objInf.Add("x_tran_key", Me.AuthTransKey)
        objInf.Add("x_relay_response", "False")



        Select Case Me.AuthServerType
            Case AuthServerTypeEnum.Live
                objInf.Add("x_test_request", "false")
      开发者_JAVA百科      Case Else
                objInf.Add("x_test_request", "True")
        End Select

        objInf.Add("x_delim_char", ",")
        objInf.Add("x_encap_char", "|")

        objInf.Add("x_first_name", fullName)
        'objInf.Add("x_last_name", "Patel")
        objInf.Add("x_address", address1)
        objInf.Add("x_city", townCity)
        objInf.Add("x_state", county)
        objInf.Add("x_zip", postCode)
        objInf.Add("x_country", country)

        objInf.Add("x_description", "Description of Order")

        objInf.Add("x_card_num", cardNumber.Replace(" ", ""))
        objInf.Add("x_exp_date", expiryMonth.ToString & "/" & expiryYears.ToString)
        objInf.Add("x_market_type", "2")
        objInf.Add("x_device_type", "5")
        objInf.Add("x_response_format", "1")

        objInf.Add("x_card_code", cvs)

        objInf.Add("x_method", "CC")
        objInf.Add("x_type", "AUTH_CAPTURE")
        objInf.Add("x_amount", "1")

        objInf.Add("x_currency_code", "USD")

        Dim objRetBytes() As Byte
        Dim objRetVals() As String
        Dim strError As String = String.Empty

        Try

            objRetBytes = Me.WebClientRequest.UploadValues(Me.WebClientRequest.BaseAddress, objInf)
            objRetVals = System.Text.Encoding.ASCII.GetString(objRetBytes).Split(",".ToCharArray())

            If True Then

            End If

        Catch ex As Exception

        End Try

    End Sub


This is not a coding issue.

An incorrect expiration date and/or CVV number will not necessarily cause a transaction to be declined. It is not uncommon for an incorrect expiration date to be provided by a customer so many banks do not decline sales for this reason. Additionally, CVV is just a tool for determining fraud risk per transaction. A mismatch simply means the chance of risk is higher and it's up to the merchant to decide if they want to accept or reject the transaction. But the transaction will not be declined for it as it is not a factor in the approval process for most card issuing banks.

0

精彩评论

暂无评论...
验证码 换一张
取 消