22
Core Implementation: WinForms
if
(cardData.msr_hashTrack2 != null)
text +=
"Track 2 Hash: "
+ Common.getHexStringFromBytes(cardData.msr_hashTrack2) +
"
\
r
\
n"
;
if
(cardData.msr_track3Length > 0)
text +=
"Track 3: "
+ cardData.msr_
"
\
r
\
n"
;
if
(cardData.msr_encTrack3 != null)
text +=
"Track 3 Encrypted: "
+ Common.getHexStringFromBytes(cardData.msr_encTrack3) +
"
\
r
\
n"
;
if
(cardData.msr_hashTrack3 != null)
text +=
"Track 3 Hash: "
+ Common.getHexStringFromBytes(cardData.msr_hashTrack3) +
"
\
r
\
n"
;
if
(cardData.msr_KSN != null)
text +=
"KSN: "
+ Common.getHexStringFromBytes(cardData.msr_KSN) +
"
\
r
\
n"
;
if
(cardData.emv_clearingRecord != null)
{
if
(cardData.emv_clearingRecord.Length > 0)
{
text +=
"
\
r
\
nCTLS Clearing Record:
\
r
\
n"
;
text += Common.getHexStringFromBytes(cardData.emv_clearingRecord) +
"
\
r
\
n"
;
Dictionary<string, string> dict = Common.processTLVUnencrypted(cardData.emv_clearingRecord);
foreach
(KeyValuePair<string, string> kvp
in
dict) text += kvp.Key +
": "
+ kvp.Value +
"
\
r
\
n"
;
text +=
"
\
r
\
n
\
r
\
n"
;
}
}
if
(cardData.emv_unencryptedTags != null)
{
if
(cardData.emv_unencryptedTags.Length > 0)
{
text +=
"
\
r
\
n========================
\
r
\
n"
;
text +=
"
\
r
\
nUnencrypted Tags:
\
r
\
n"
;
text += Common.getHexStringFromBytes(cardData.emv_unencryptedTags) +
"
\
r
\
n
\
r
\
n"
;
text += tlvToValues(cardData.emv_unencryptedTags);
text +=
"
\
r
\
n========================
\
r
\
n"
;
}
}
if
(cardData.emv_encryptedTags != null)
{
if
(cardData.emv_encryptedTags.Length > 0)
{
text +=
"
\
r
\
n========================
\
r
\
n"
;
text +=
"
\
r
\
nEncrypted Tags:
\
r
\
n"
;
text += Common.getHexStringFromBytes(cardData.emv_encryptedTags) +
"
\
r
\
n
\
r
\
n"
;
text += tlvToValues(cardData.emv_encryptedTags);
text +=
"
\
r
\
n========================
\
r
\
n"
;
}
}
if
(cardData.emv_maskedTags != null)
{
if
(cardData.emv_maskedTags.Length > 0)
{
text +=
"
\
r
\
n========================
\
r
\
n"
;
text +=
"
\
r
\
nMasked Tags:
\
r
\
n"
;
text += Common.getHexStringFromBytes(cardData.emv_maskedTags) +
"
\
r
\
n
\
r
\
n"
;
text += tlvToValues(cardData.emv_maskedTags);
text +=
"
\
r
\
n========================
\
r
\
n"
;
}
}
text +=
"ICC Present: "
;
text += (cardData.iccPresent ?
"TRUE"
:
"FALSE"
) +
"
\
r
\
n"
;
text +=
"is CTLS: "
;
text += (cardData.isCTLS ?
"TRUE"
:
"FALSE"
) +
"
\
r
\
n"
;
if
(cardData.Event == EVENT_TRANSACTION_DATA_Types.EVENT_TRANSACTION_DATA_EMV_DATA)
{
if
(!cardData.isCTLS) text +=
"Capture Encrypt Type: "
+ ((cardData.emv_encryptionMode ==
EMV_ENCRYPTION_MODE.EMV_ENCRYPTION_MODE_TDES) ?
"TDES"
:
"AES"
) +
"
\
r
\
n"
;
switch
(cardData.emv_resultCode)
#80136501-001 IDTech Windows SDK Guide for Kiosk III/IV