Normalize payment operation names to Camel Case
This commit is contained in:
parent
71b0a9871e
commit
96a2945638
@ -578,25 +578,25 @@
|
||||
"AES Key Unwrap",
|
||||
"Parse TR-31 key block",
|
||||
"Parse TR-34 B9 envelope",
|
||||
"Calculate payment KCV",
|
||||
"Derive ECDH key material",
|
||||
"Derive DUKPT key",
|
||||
"Encrypt payment data",
|
||||
"Decrypt payment data",
|
||||
"Re-encrypt payment data",
|
||||
"Generate payment MAC",
|
||||
"Verify payment MAC",
|
||||
"Generate card validation data",
|
||||
"Verify card validation data",
|
||||
"Calculate Payment KCV",
|
||||
"Derive ECDH Key Material",
|
||||
"Derive DUKPT Key",
|
||||
"Encrypt Payment Data",
|
||||
"Decrypt Payment Data",
|
||||
"Re-Encrypt Payment Data",
|
||||
"Generate Payment MAC",
|
||||
"Verify Payment MAC",
|
||||
"Generate Card Validation Data",
|
||||
"Verify Card Validation Data",
|
||||
"Generate EMV ARQC",
|
||||
"Generate EMV ARPC",
|
||||
"Verify EMV ARQC",
|
||||
"Build PIN block",
|
||||
"Parse PIN block",
|
||||
"Translate PIN block",
|
||||
"Generate payment PIN data",
|
||||
"Translate payment PIN data",
|
||||
"Verify payment PIN data"
|
||||
"Build PIN Block",
|
||||
"Parse PIN Block",
|
||||
"Translate PIN Block",
|
||||
"Generate Payment PIN Data",
|
||||
"Translate Payment PIN Data",
|
||||
"Verify Payment PIN Data"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
@ -16,7 +16,7 @@ class BuildPINBlock extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Build PIN block";
|
||||
this.name = "Build PIN Block";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the clear PIN into the input field and choose the ISO 9564 clear PIN block format to build.<br><br><b>Input:</b> clear PIN digits.<br><b>Arguments:</b> choose the target format, provide the PAN when required, and optionally randomize filler digits for formats 1 and 3.<br><br>This operation currently builds clear test PIN blocks for ISO formats 0, 1, and 3.";
|
||||
this.inlineHelp = "<strong>Input:</strong> clear PIN digits.<br><strong>Args:</strong> choose the format, add the PAN for formats 0 and 3, then decide whether format 1 or 3 filler digits should be randomized.";
|
||||
|
||||
@ -19,7 +19,7 @@ class CalculatePaymentKCV extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Calculate payment KCV";
|
||||
this.name = "Calculate Payment KCV";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the key into the input field and choose how that key is encoded using <b>Key format</b>.<br><br>Use <b>Method</b> to choose the KCV style: TDES, AES-CMAC, AES-ECB, or HMAC.<br><br><b>Input:</b> raw key material such as hex, UTF-8, Latin1, or Base64.<br><b>Arguments:</b> select the key format, method, and output length in hex characters.<br><br>Returns an uppercase truncated hex KCV value.";
|
||||
this.inlineHelp = "<strong>Input:</strong> key material.<br><strong>Args:</strong> tell the op how the key is encoded, choose the KCV method, then set the output length.";
|
||||
|
||||
@ -15,7 +15,7 @@ class DecryptPaymentData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Decrypt payment data";
|
||||
this.name = "Decrypt Payment Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste ciphertext into the input field as hex and decrypt it using a payment-facing cipher wrapper.<br><br><b>Input:</b> ciphertext hex.<br><b>Arguments:</b> choose the cipher profile, provide a direct key or BDK, add IV where needed, and provide KSN plus DUKPT variant when using a DUKPT profile.";
|
||||
this.inlineHelp = "<strong>Input:</strong> ciphertext hex.<br><strong>Args:</strong> choose AES, TDES, or DUKPT-wrapped TDES, then provide key, IV, and optional KSN context.";
|
||||
|
||||
@ -195,7 +195,7 @@ class DeriveDUKPTKey extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Derive DUKPT key";
|
||||
this.name = "Derive DUKPT Key";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the Base Derivation Key (BDK) into the input field as a 16-byte hex value.<br><br>Put the 10-byte Key Serial Number in the <b>KSN</b> argument field.<br><br><b>Input:</b> BDK in hex.<br><b>Arguments:</b> choose whether to derive the IPEK or the transaction key, provide the KSN, choose the variant, and optionally return JSON.<br><br>This operation derives TDES DUKPT keys in software for test and interoperability work.";
|
||||
this.inlineHelp = "<strong>Input:</strong> BDK hex.<br><strong>Args:</strong> add the KSN, choose IPEK or transaction-key derivation, then optionally apply a variant.";
|
||||
|
||||
@ -128,7 +128,7 @@ class DeriveECDHKeyMaterial extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Derive ECDH key material";
|
||||
this.name = "Derive ECDH Key Material";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste your private key into the input field and paste the peer public key into the <b>Peer public key</b> argument field.<br><br><b>Input:</b> private key in PEM or PKCS#8 DER hex. PEM may be <code>BEGIN PRIVATE KEY</code> or <code>BEGIN EC PRIVATE KEY</code> when it can be normalized to PKCS#8.<br><b>Arguments:</b> choose the curve, peer public key format, optional KDF, optional shared info, output length, and output format.<br><br>Use <b>KDF = None</b> to get the raw shared secret.";
|
||||
this.inlineHelp = "<strong>Input:</strong> your private key.<br><strong>Args:</strong> pick the curve, paste the peer public key, then choose raw shared secret or KDF output.";
|
||||
|
||||
@ -15,7 +15,7 @@ class EncryptPaymentData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Encrypt payment data";
|
||||
this.name = "Encrypt Payment Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste plaintext into the input field as hex and encrypt it using a payment-facing cipher wrapper.<br><br><b>Input:</b> plaintext hex.<br><b>Arguments:</b> choose the cipher profile, provide a direct key or BDK, add IV where needed, and provide KSN plus DUKPT variant when using a DUKPT profile.";
|
||||
this.inlineHelp = "<strong>Input:</strong> plaintext hex.<br><strong>Args:</strong> choose AES, TDES, or DUKPT-wrapped TDES, then provide key, IV, and optional KSN context.";
|
||||
|
||||
@ -16,7 +16,7 @@ class GenerateCardValidationData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Generate card validation data";
|
||||
this.name = "Generate Card Validation Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the combined CVK pair into the input field as hex and generate a card-verification value for software testing.<br><br><b>Input:</b> combined CVK pair as 16-byte or 24-byte hex.<br><b>Arguments:</b> select whether you are generating CVV/CVC, CVV2/CVC2, or iCVV, then provide the PAN, expiry components, and service code details.<br><br>This implementation is intended for test harnesses and assumes the common CVV decimalization flow used by payment HSM integrations.";
|
||||
this.inlineHelp = "<strong>Input:</strong> combined CVK pair hex.<br><strong>Args:</strong> choose the validation-data profile, then provide PAN, expiry, and service-code inputs.";
|
||||
|
||||
@ -16,7 +16,7 @@ class GeneratePaymentMAC extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Generate payment MAC";
|
||||
this.name = "Generate Payment MAC";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the message data into the input field and generate a payment-oriented MAC using one payment-facing operation.<br><br><b>Input:</b> message data in the selected input format.<br><b>Arguments:</b> choose the MAC method, provide either a direct key or a DUKPT BDK, optionally provide a KSN for DUKPT methods, and choose the truncation length.<br><br>This wrapper reuses existing HMAC, CMAC, and DUKPT operations instead of duplicating their crypto logic.";
|
||||
this.inlineHelp = "<strong>Input:</strong> message data.<br><strong>Args:</strong> choose the payment MAC method, then provide either a direct key or a DUKPT BDK plus KSN.";
|
||||
|
||||
@ -15,7 +15,7 @@ class GeneratePaymentPINData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Generate payment PIN data";
|
||||
this.name = "Generate Payment PIN Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the clear PIN into the input field and generate clear PIN-block test data using an AWS-style payment wrapper.<br><br><b>Input:</b> clear PIN digits.<br><b>Arguments:</b> choose the PIN-block format, provide the PAN when required, and optionally return structured JSON.";
|
||||
this.inlineHelp = "<strong>Input:</strong> clear PIN digits.<br><strong>Args:</strong> choose the block format and provide the PAN for PAN-bound formats.";
|
||||
|
||||
@ -16,7 +16,7 @@ class ParsePINBlock extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Parse PIN block";
|
||||
this.name = "Parse PIN Block";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste a clear ISO 9564 PIN block into the input field as hex and decode it into its component fields.<br><br><b>Input:</b> 8-byte clear PIN block as hex.<br><b>Arguments:</b> choose the format and provide the PAN when the format binds to PAN data.<br><br>This operation currently parses clear test PIN blocks for ISO formats 0, 1, and 3.";
|
||||
this.inlineHelp = "<strong>Input:</strong> clear PIN block hex.<br><strong>Args:</strong> choose the format and provide the PAN for formats 0 and 3 so the block can be decoded.";
|
||||
|
||||
@ -15,7 +15,7 @@ class ReEncryptPaymentData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Re-encrypt payment data";
|
||||
this.name = "Re-Encrypt Payment Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste ciphertext into the input field as hex, decrypt it under the source key context, then re-encrypt it under the target key context.<br><br><b>Input:</b> source ciphertext hex.<br><b>Arguments:</b> choose source and target profiles, provide the corresponding key or BDK material, add IVs, and supply KSN plus DUKPT variant when using DUKPT profiles.";
|
||||
this.inlineHelp = "<strong>Input:</strong> source ciphertext hex.<br><strong>Args:</strong> define the source decrypt context, then the target encrypt context.";
|
||||
|
||||
@ -16,7 +16,7 @@ class TranslatePINBlock extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Translate PIN block";
|
||||
this.name = "Translate PIN Block";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste a clear ISO 9564 PIN block into the input field as hex and translate it between supported clear block formats.<br><br><b>Input:</b> 8-byte clear PIN block as hex.<br><b>Arguments:</b> choose the source and target formats, provide source and target PAN values when required, and optionally randomize target filler digits for formats 1 and 3.<br><br>This operation currently translates clear test PIN blocks for ISO formats 0, 1, and 3.";
|
||||
this.inlineHelp = "<strong>Input:</strong> source clear PIN block hex.<br><strong>Args:</strong> choose source and target formats, then provide the source and target PAN values where the formats require them.";
|
||||
|
||||
@ -15,7 +15,7 @@ class TranslatePaymentPINData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Translate payment PIN data";
|
||||
this.name = "Translate Payment PIN Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste a clear PIN block into the input field as hex and translate it between supported clear ISO 9564 formats using an AWS-style wrapper.<br><br><b>Input:</b> clear PIN block hex.<br><b>Arguments:</b> choose source and target formats, provide PAN values when required, and optionally randomize target filler digits.";
|
||||
this.inlineHelp = "<strong>Input:</strong> source clear PIN block hex.<br><strong>Args:</strong> define source and target format plus PAN context.";
|
||||
|
||||
@ -16,7 +16,7 @@ class VerifyCardValidationData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Verify card validation data";
|
||||
this.name = "Verify Card Validation Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the combined CVK pair into the input field as hex and verify a CVV/CVC-style value for software testing.<br><br><b>Input:</b> combined CVK pair as 16-byte or 24-byte hex.<br><b>Arguments:</b> select the validation-data profile, provide the PAN and expiry components, then supply the expected validation data.<br><br>This operation recomputes the validation value using the same assumptions as the generate operation and reports whether the supplied value matches.";
|
||||
this.inlineHelp = "<strong>Input:</strong> combined CVK pair hex.<br><strong>Args:</strong> provide PAN, expiry, service-code context, and the validation data to check.";
|
||||
|
||||
@ -16,7 +16,7 @@ class VerifyPaymentMAC extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Verify payment MAC";
|
||||
this.name = "Verify Payment MAC";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste the message data into the input field and verify a payment-oriented MAC using one payment-facing operation.<br><br><b>Input:</b> message data in the selected input format.<br><b>Arguments:</b> choose the MAC method, provide either a direct key or a DUKPT BDK, add the KSN for DUKPT methods, and supply the expected MAC as hex.<br><br>This wrapper recomputes the MAC using the same payment-specific assumptions as the generate operation.";
|
||||
this.inlineHelp = "<strong>Input:</strong> message data.<br><strong>Args:</strong> choose the payment MAC method, provide the key context, then paste the expected MAC.";
|
||||
|
||||
@ -15,7 +15,7 @@ class VerifyPaymentPINData extends Operation {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
this.name = "Verify payment PIN data";
|
||||
this.name = "Verify Payment PIN Data";
|
||||
this.module = "Payment";
|
||||
this.description = "Paste a clear PIN block into the input field as hex and verify it against an expected PIN using an AWS-style wrapper.<br><br><b>Input:</b> clear PIN block hex.<br><b>Arguments:</b> choose the format, provide the PAN when required, and supply the expected clear PIN.";
|
||||
this.inlineHelp = "<strong>Input:</strong> clear PIN block hex.<br><strong>Args:</strong> define the PIN-block format, PAN context, and expected PIN.";
|
||||
|
||||
@ -78,84 +78,84 @@ TestRegister.addTests([
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Calculate payment KCV: HMAC SHA-256",
|
||||
name: "Calculate Payment KCV: HMAC SHA-256",
|
||||
input: "00112233445566778899AABBCCDDEEFF",
|
||||
expectedOutput: "E8A065",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Calculate payment KCV",
|
||||
op: "Calculate Payment KCV",
|
||||
args: ["Hex", "HMAC SHA-256", 6]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Calculate payment KCV: AES-CMAC empty",
|
||||
name: "Calculate Payment KCV: AES-CMAC empty",
|
||||
input: "00112233445566778899AABBCCDDEEFF",
|
||||
expectedOutput: "917737",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Calculate payment KCV",
|
||||
op: "Calculate Payment KCV",
|
||||
args: ["Hex", "AES-CMAC (Empty)", 6]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Calculate payment KCV: AES-CMAC zeros",
|
||||
name: "Calculate Payment KCV: AES-CMAC zeros",
|
||||
input: "00112233445566778899AABBCCDDEEFF",
|
||||
expectedOutput: "53E107",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Calculate payment KCV",
|
||||
op: "Calculate Payment KCV",
|
||||
args: ["Hex", "AES-CMAC (Zeros)", 6]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Calculate payment KCV: AES-CMAC ones",
|
||||
name: "Calculate Payment KCV: AES-CMAC ones",
|
||||
input: "00112233445566778899AABBCCDDEEFF",
|
||||
expectedOutput: "7B3046",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Calculate payment KCV",
|
||||
op: "Calculate Payment KCV",
|
||||
args: ["Hex", "AES-CMAC (Ones)", 6]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Calculate payment KCV: AES-ECB zeros",
|
||||
name: "Calculate Payment KCV: AES-ECB zeros",
|
||||
input: "00112233445566778899AABBCCDDEEFF",
|
||||
expectedOutput: "FDE4FB",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Calculate payment KCV",
|
||||
op: "Calculate Payment KCV",
|
||||
args: ["Hex", "AES-ECB (Zeros)", 6]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Derive DUKPT key: known IPEK vector",
|
||||
name: "Derive DUKPT Key: known IPEK vector",
|
||||
input: "0123456789ABCDEFFEDCBA9876543210",
|
||||
expectedOutput: "6AC292FAA1315B4D858AB3A3D7D5933A",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Derive DUKPT key",
|
||||
op: "Derive DUKPT Key",
|
||||
args: ["Derive IPEK", "FFFF9876543210E00008", "None", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Build PIN block: ISO Format 0",
|
||||
name: "Build PIN Block: ISO Format 0",
|
||||
input: "1234",
|
||||
expectedOutput: "041215FEDCBA9876",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Build PIN block",
|
||||
op: "Build PIN Block",
|
||||
args: ["ISO Format 0", "5432101234567890", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Parse PIN block: ISO Format 0",
|
||||
name: "Parse PIN Block: ISO Format 0",
|
||||
input: "041215FEDCBA9876",
|
||||
expectedOutput: JSON.stringify({
|
||||
format: "ISO Format 0",
|
||||
@ -168,13 +168,13 @@ TestRegister.addTests([
|
||||
}, null, 4),
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Parse PIN block",
|
||||
op: "Parse PIN Block",
|
||||
args: ["ISO Format 0", "5432101234567890"]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Translate PIN block: ISO Format 0 to ISO Format 1",
|
||||
name: "Translate PIN Block: ISO Format 0 to ISO Format 1",
|
||||
input: "041215FEDCBA9876",
|
||||
expectedOutput: JSON.stringify({
|
||||
source: {
|
||||
@ -193,24 +193,24 @@ TestRegister.addTests([
|
||||
}, null, 4),
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Translate PIN block",
|
||||
op: "Translate PIN Block",
|
||||
args: ["ISO Format 0", "5432101234567890", "ISO Format 1", "", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Generate card validation data: known CVV2 sample",
|
||||
name: "Generate Card Validation Data: known CVV2 sample",
|
||||
input: "0123456789ABCDEFFEDCBA9876543210",
|
||||
expectedOutput: "221",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Generate card validation data",
|
||||
op: "Generate Card Validation Data",
|
||||
args: ["CVV2 / CVC2 (force 000)", "4123456789012345", "02", "25", "MMYY", "101", 3, false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Verify card validation data: known CVV2 sample",
|
||||
name: "Verify Card Validation Data: known CVV2 sample",
|
||||
input: "0123456789ABCDEFFEDCBA9876543210",
|
||||
expectedOutput: JSON.stringify({
|
||||
profile: "CVV2 / CVC2 (force 000)",
|
||||
@ -228,7 +228,7 @@ TestRegister.addTests([
|
||||
}, null, 4),
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Verify card validation data",
|
||||
op: "Verify Card Validation Data",
|
||||
args: ["CVV2 / CVC2 (force 000)", "4123456789012345", "02", "25", "MMYY", "101", "221"]
|
||||
}
|
||||
]
|
||||
@ -274,73 +274,73 @@ TestRegister.addTests([
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Encrypt payment data: AES CBC",
|
||||
name: "Encrypt Payment Data: AES CBC",
|
||||
input: "00112233445566778899AABBCCDDEEFF",
|
||||
expectedOutput: "67423557CA0509243B9EE04A5DA3448AA397F6D29B5C8BCE065D9CDC936B7F9B",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Encrypt payment data",
|
||||
op: "Encrypt Payment Data",
|
||||
args: ["AES CBC", "00112233445566778899AABBCCDDEEFF", "000102030405060708090A0B0C0D0E0F", "", "Data", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Decrypt payment data: AES CBC",
|
||||
name: "Decrypt Payment Data: AES CBC",
|
||||
input: "67423557CA0509243B9EE04A5DA3448AA397F6D29B5C8BCE065D9CDC936B7F9B",
|
||||
expectedOutput: "00112233445566778899AABBCCDDEEFF",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Decrypt payment data",
|
||||
op: "Decrypt Payment Data",
|
||||
args: ["AES CBC", "00112233445566778899AABBCCDDEEFF", "000102030405060708090A0B0C0D0E0F", "", "Data", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Re-encrypt payment data: AES CBC to TDES CBC",
|
||||
name: "Re-Encrypt Payment Data: AES CBC to TDES CBC",
|
||||
input: "67423557CA0509243B9EE04A5DA3448AA397F6D29B5C8BCE065D9CDC936B7F9B",
|
||||
expectedOutput: "C47BC6E91A9D566F649D750BCE1CE9889FB5AE1489A16692",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Re-encrypt payment data",
|
||||
op: "Re-Encrypt Payment Data",
|
||||
args: ["AES CBC", "00112233445566778899AABBCCDDEEFF", "000102030405060708090A0B0C0D0E0F", "", "Data", "TDES CBC", "0123456789ABCDEFFEDCBA9876543210", "1234567890ABCDEF", "", "Data", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Generate payment MAC: AES-CMAC",
|
||||
name: "Generate Payment MAC: AES-CMAC",
|
||||
input: "1122334455667788",
|
||||
expectedOutput: "339AF1AD1650E908",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Generate payment MAC",
|
||||
op: "Generate Payment MAC",
|
||||
args: ["Hex", "AES-CMAC", "00112233445566778899AABBCCDDEEFF", "Hex", "", 8, false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Generate payment MAC: HMAC SHA-256",
|
||||
name: "Generate Payment MAC: HMAC SHA-256",
|
||||
input: "1122334455667788",
|
||||
expectedOutput: "9300E1D36DD30415",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Generate payment MAC",
|
||||
op: "Generate Payment MAC",
|
||||
args: ["Hex", "HMAC SHA-256", "00112233445566778899AABBCCDDEEFF", "Hex", "", 8, false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Generate payment MAC: DUKPT MAC Request CMAC",
|
||||
name: "Generate Payment MAC: DUKPT MAC Request CMAC",
|
||||
input: "1122334455667788",
|
||||
expectedOutput: "3616961727FE155D",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Generate payment MAC",
|
||||
op: "Generate Payment MAC",
|
||||
args: ["Hex", "DUKPT MAC Request CMAC", "0123456789ABCDEFFEDCBA9876543210", "Hex", "FFFF9876543210E00008", 8, false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Verify payment MAC: AES-CMAC",
|
||||
name: "Verify Payment MAC: AES-CMAC",
|
||||
input: "1122334455667788",
|
||||
expectedOutput: JSON.stringify({
|
||||
method: "AES-CMAC",
|
||||
@ -355,24 +355,24 @@ TestRegister.addTests([
|
||||
}, null, 4),
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Verify payment MAC",
|
||||
op: "Verify Payment MAC",
|
||||
args: ["Hex", "AES-CMAC", "00112233445566778899AABBCCDDEEFF", "Hex", "", "339AF1AD1650E908", true]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Generate payment PIN data: ISO Format 0",
|
||||
name: "Generate Payment PIN Data: ISO Format 0",
|
||||
input: "1234",
|
||||
expectedOutput: "041215FEDCBA9876",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Generate payment PIN data",
|
||||
op: "Generate Payment PIN Data",
|
||||
args: ["ISO Format 0", "5432101234567890", false, false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Translate payment PIN data: ISO Format 0 to ISO Format 1",
|
||||
name: "Translate Payment PIN Data: ISO Format 0 to ISO Format 1",
|
||||
input: "041215FEDCBA9876",
|
||||
expectedOutput: JSON.stringify({
|
||||
source: {
|
||||
@ -391,13 +391,13 @@ TestRegister.addTests([
|
||||
}, null, 4),
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Translate payment PIN data",
|
||||
op: "Translate Payment PIN Data",
|
||||
args: ["ISO Format 0", "5432101234567890", "ISO Format 1", "", false]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Verify payment PIN data: ISO Format 0",
|
||||
name: "Verify Payment PIN Data: ISO Format 0",
|
||||
input: "041215FEDCBA9876",
|
||||
expectedOutput: JSON.stringify({
|
||||
format: "ISO Format 0",
|
||||
@ -412,29 +412,29 @@ TestRegister.addTests([
|
||||
}, null, 4),
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Verify payment PIN data",
|
||||
op: "Verify Payment PIN Data",
|
||||
args: ["ISO Format 0", "5432101234567890", "1234"]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Derive ECDH key material: raw shared secret",
|
||||
name: "Derive ECDH Key Material: raw shared secret",
|
||||
input: ecdhPrivateKey,
|
||||
expectedOutput: "4BE993A2D1BD25C7B5A625EDEBE48D022557ACA445C60EE403ECE9BA38A41CFE",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Derive ECDH key material",
|
||||
op: "Derive ECDH Key Material",
|
||||
args: ["PEM", "P-256", "PEM", ecdhPeerPublicKey, "None", 32, "", "Hex"]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: "Derive ECDH key material: SEC1 EC private key PEM",
|
||||
name: "Derive ECDH Key Material: SEC1 EC private key PEM",
|
||||
input: ecdhPrivateKeySec1,
|
||||
expectedOutput: "4BE993A2D1BD25C7B5A625EDEBE48D022557ACA445C60EE403ECE9BA38A41CFE",
|
||||
recipeConfig: [
|
||||
{
|
||||
op: "Derive ECDH key material",
|
||||
op: "Derive ECDH Key Material",
|
||||
args: ["PEM", "P-256", "PEM", ecdhPeerPublicKey, "None", 32, "", "Hex"]
|
||||
}
|
||||
]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user