Amadis

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 34 Next »

AgnosMW provides a set of primitives to manage the data model an. It also defines the main stack’s C structures used to iniatite transaction fflows (see AgnosEP API ). The payment application shall call pmwInitialiseFromFile before any transaction triggering.

C Structures

tPaymentContext (paymentMW.h)

typedef struct {
////////////////////////////////////////////////////////////////////
// Information provided by Level3
tAmount *mAmount;// EMV Tag 9F02 = "Amount, Authorized"  + "Amount, Other"
tAmount *mCashBack;// EMV Tag 9F03 = "Amount, Other"
tTransactionType mTransactionType;// EMV Tag 9C
tNumericDate mTransactionDate[3];// EMV Tag 9A
tNumericDate mTransactionTime[3];// EMV Tag 9F21
tByte mMerchantCustomData[20];// EMV Tag 9F7C
tByte mTransactionCurrencyCode[2];// EMV Tag 5F2A
tByte mTransactionCurrencyExponent;// EMV Tag 5F36
tByte mTransactionCategoryCode;// EMV Tag 9F53
tByte mMerchantCategoryCode[2];// EMV Tag 9F15
tByte mMerchantID[15];// EMV Tag 9F16
tBoolean mForcedOnline;// As per merchant decision
char mWorkingPath[2*MAX_NAME_LENGTH];

////////////////////////////////////////////////////////////////////
// Information set by Payment System
tBoolean mEMVContact;// by configuration (terminal)
tBoolean mEMVContactless;// by configuration	(terminal)
tBoolean mMagstripe;// by configuration	(terminal)

tAmount mAmountReferenceCurrency;// EMV Tag 9F3A - not used yet
tByte mTransactionReferenceCurrencyCode[2];// EMV Tag 9F3C - not used yet
tByte mTransactionReferenceCurrencyExponent;// EMV Tag 9F3D - not used yet
tByte mTerminalRiskManagementData[8];// EMV Tag 9F1D - not used yet
tAccountType mAccountType;// EMV Tag 5F57 - payment application specific
tByte mPOSEntryMode;// EMV Tag 9F39 - payment application specific

tCounter mTransactionSequenceCounter;
tARC mARC;//Authorization Response Code, eg mapping from Issuer's Response Code (ISO8583:DE39)
tBoolean mUnableToGoOnline;

////////////////////////////////////////////////////////////////////
// Information set by Payment Application (from Agnos primitives)
tByte mRID[RID_LENGTH];
tADF mADF;
tByte mADFOrderNumber;// For a given configuration, AID's order number

 tBoolean mAdvice;
 tBoolean mBatchData;
 tBoolean mReversal;

////////////////////////////////////////////////////////////////////
// Information set by EMV Library
tSessionId mSession;
tByte mCID;// Information used by Level3 to detect transaction's outcome requested by ICC
	
////////////////////////////////////////////////////////////////////
// Information calculated by Level3 once transaction is completed (from paymentMW primitives)
tByte mFinal9F02[6];
tByte mCVMResult[3];
tByte mTVR[5];
tByte mTSI[2];
tByte mAC[8];
tByte mUN[4];
tByte mAID[MAX_AID_LENGTH];
tByte mAIDLen;
tByte mPANSHA[20];
tByte mCardholderNameLen;
tByte mCardholderName[26];
tByte mAgnosTVR[AGNOS_TVR_SIZE];
#ifdef _AGNOSISR_
tBoolean mIsScriptExecuted;
tByte mIssuerScriptResultLen;
tByte mIssuerScriptResult[2*MAX_SCRIPT*sizeof(tScriptResult)];
#endif

////////////////////////////////////////////////////////////////////
// Level3 <-> Level2 communication
tDataExchange mDataExchange;

} tPaymentContext;

tOutComeParameter (paymentMW.h)

typedef struct {
tOutCome mOutCome;

tStartingPoint mStartingPoint;
tOnlineResponseData mOnlineResponseData;
tCVM mCVM;
tBoolean mUIReqOnOutcomePresent; // If bTRUE, found in DataExchange
tBoolean mUIReqOnRestartPresent; // If bTRUE, found in DataExchange
tBoolean mReceipt;
tBoolean mDRPresent;	// Data record. If present, found in DataExchange
tBoolean mDDPresent;	// Discretionary Data. If present, found in DataExchange
tAlternateInterfacePreference mAlternateInterfacePreference;
tWord mFieldOffReq;
tWord mRemovalTimeout;

} tOutComeParameter;

Primitives

Names

Comments

Initialization

pmwGetPaymentMiddlewareVersionNumber

Get AgnosMW version

pmwGetKernelVersion

Get EMV core engine version

pmwInitializePaymentContext

Shall be called before any new transaction

pmwIntializeOutComeParameter

Shall be called before any new transaction

dtmInitializeFromFile

Agnos uses three files to persit the data model:

  • TERMINAL

  • PROCESSING

  • ENTRY_POINT

Use this primitive ahead any transaction flow in order to initialize the transient data model.

dtmSetTransactionalContext

dtmSetData

  • TERMINAL_CTX

  • CONTACT_PROCESSING_CTX

  • CONTACTLESS_PROCESSING_CTX

  • ENTRY_POINT

dtmGetData

  • TERMINAL_CTX

  • CONTACT_PROCESSING_CTX

  • CONTACTLESS_PROCESSING_CTX

  • ENTRY_POINT

pmwProceedToUniversalFinalSelection

Proceed to standard final selection following EMVCo specs. This function call can be overloaded in CT and hooked in contactless in order to implement specific selection logic (US, Canada, France)

dtmSelectCTKernel

pmwSetEMVResult

Set EMV parameters after a transaction (see tPaymentContext)

pmwCloseSession

  • No labels