Direct Payment Integrator V6 - Online Help
Direct Payment Integrator V6
Questions / Feedback?

MACValue Property

Hash of transaction data used to verify message was not tampered with.

Syntax

[VB.NET]
Public Property MACValue As String

[C#]
public string MACValue {get; set;}

Remarks

Each transaction you send (excluding RequestCurrentKeys and MACReversals) requires an accompanying MACValue. This value is a hash of the contents of GetRequestDataToMAC, and is hashed by the PIN Pad device using the MACKey returned in response to the last transaction.

The GetRequestDataToMAC method returns a string containing the values of several transaction properties. This string must be MAC'ed by the PIN pad, so it is essential that the following properties be set before calling GetRequestDataToMAC:

First, retrieve the CardTrack2Data, EncryptedPIN, and AccountType from the PIN pad, and set all other properties listed above. Now send the string returned from GetRequestDataToMAC to the PIN pad. Set the MACValue property with the data returned in the PIN pad response.

Note that VeriFone pinpads support a PURCHASE transaction where the CardTrack2Data, EncryptedPIN, AccountType, and MACValue are returned in a single step. When using a VeriFone pad make sure AccountType is set to acctNotSet, otherwise the MACValue will not be calculated correctly. (AccountType must be set before calling GetRequestDataToMAC for Ingenico pads)


  component.MerchantNumber = "yourMerchantNumber"  
  component.TerminalNumber = "100"
  component.ClientNumber = "0002"
  component.UserId = "yourUserId"
  component.Password = "yourPassword"
  component.SequenceNumber = 2
  component.TransactionAmount = "1.00" 
  component.PinPadSerialNumber = "30700015P3600000" ' from label on back of PIN pad
  component.InteracTransactionType = ittSale 
  component.AccountType = acctChecking       
  component.CardTrack2Data = "9999999800002773=05121015432112345678" ' from card reader
  component.EncryptedPIN = "FFFFFFFFFFFFFFFF" ' from the PIN pad 

  ' Now use the PIN pad to MAC the value returned from GetRequestDataToMAC 
  ' and then set MACValue with the results
  component.MACValue = "FFFFFFFF"             

  component.Authorize()

Default Value

""

 
 
Copyright (c) 2017 /n software inc. - All rights reserved.
Build 6.0.6240.0