@aws-sdk/client-payment-cryptography-data 3.349.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (107) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +294 -0
  3. package/dist-cjs/PaymentCryptographyData.js +33 -0
  4. package/dist-cjs/PaymentCryptographyDataClient.js +41 -0
  5. package/dist-cjs/commands/DecryptDataCommand.js +47 -0
  6. package/dist-cjs/commands/EncryptDataCommand.js +47 -0
  7. package/dist-cjs/commands/GenerateCardValidationDataCommand.js +47 -0
  8. package/dist-cjs/commands/GenerateMacCommand.js +47 -0
  9. package/dist-cjs/commands/GeneratePinDataCommand.js +47 -0
  10. package/dist-cjs/commands/ReEncryptDataCommand.js +47 -0
  11. package/dist-cjs/commands/TranslatePinDataCommand.js +47 -0
  12. package/dist-cjs/commands/VerifyAuthRequestCryptogramCommand.js +47 -0
  13. package/dist-cjs/commands/VerifyCardValidationDataCommand.js +47 -0
  14. package/dist-cjs/commands/VerifyMacCommand.js +47 -0
  15. package/dist-cjs/commands/VerifyPinDataCommand.js +47 -0
  16. package/dist-cjs/commands/index.js +14 -0
  17. package/dist-cjs/endpoint/EndpointParameters.js +12 -0
  18. package/dist-cjs/endpoint/endpointResolver.js +12 -0
  19. package/dist-cjs/endpoint/ruleset.js +7 -0
  20. package/dist-cjs/index.js +10 -0
  21. package/dist-cjs/models/PaymentCryptographyDataServiceException.js +12 -0
  22. package/dist-cjs/models/index.js +4 -0
  23. package/dist-cjs/models/models_0.js +526 -0
  24. package/dist-cjs/protocols/Aws_restJson1.js +963 -0
  25. package/dist-cjs/runtimeConfig.browser.js +39 -0
  26. package/dist-cjs/runtimeConfig.js +48 -0
  27. package/dist-cjs/runtimeConfig.native.js +15 -0
  28. package/dist-cjs/runtimeConfig.shared.js +21 -0
  29. package/dist-es/PaymentCryptographyData.js +29 -0
  30. package/dist-es/PaymentCryptographyDataClient.js +37 -0
  31. package/dist-es/commands/DecryptDataCommand.js +43 -0
  32. package/dist-es/commands/EncryptDataCommand.js +43 -0
  33. package/dist-es/commands/GenerateCardValidationDataCommand.js +43 -0
  34. package/dist-es/commands/GenerateMacCommand.js +43 -0
  35. package/dist-es/commands/GeneratePinDataCommand.js +43 -0
  36. package/dist-es/commands/ReEncryptDataCommand.js +43 -0
  37. package/dist-es/commands/TranslatePinDataCommand.js +43 -0
  38. package/dist-es/commands/VerifyAuthRequestCryptogramCommand.js +43 -0
  39. package/dist-es/commands/VerifyCardValidationDataCommand.js +43 -0
  40. package/dist-es/commands/VerifyMacCommand.js +43 -0
  41. package/dist-es/commands/VerifyPinDataCommand.js +43 -0
  42. package/dist-es/commands/index.js +11 -0
  43. package/dist-es/endpoint/EndpointParameters.js +8 -0
  44. package/dist-es/endpoint/endpointResolver.js +8 -0
  45. package/dist-es/endpoint/ruleset.js +4 -0
  46. package/dist-es/index.js +5 -0
  47. package/dist-es/models/PaymentCryptographyDataServiceException.js +8 -0
  48. package/dist-es/models/index.js +1 -0
  49. package/dist-es/models/models_0.js +488 -0
  50. package/dist-es/protocols/Aws_restJson1.js +938 -0
  51. package/dist-es/runtimeConfig.browser.js +34 -0
  52. package/dist-es/runtimeConfig.js +43 -0
  53. package/dist-es/runtimeConfig.native.js +11 -0
  54. package/dist-es/runtimeConfig.shared.js +17 -0
  55. package/dist-types/PaymentCryptographyData.d.ts +88 -0
  56. package/dist-types/PaymentCryptographyDataClient.d.ts +174 -0
  57. package/dist-types/commands/DecryptDataCommand.d.ts +133 -0
  58. package/dist-types/commands/EncryptDataCommand.d.ts +138 -0
  59. package/dist-types/commands/GenerateCardValidationDataCommand.d.ts +144 -0
  60. package/dist-types/commands/GenerateMacCommand.d.ts +134 -0
  61. package/dist-types/commands/GeneratePinDataCommand.d.ts +155 -0
  62. package/dist-types/commands/ReEncryptDataCommand.d.ts +150 -0
  63. package/dist-types/commands/TranslatePinDataCommand.d.ts +147 -0
  64. package/dist-types/commands/VerifyAuthRequestCryptogramCommand.d.ts +150 -0
  65. package/dist-types/commands/VerifyCardValidationDataCommand.d.ts +156 -0
  66. package/dist-types/commands/VerifyMacCommand.d.ts +137 -0
  67. package/dist-types/commands/VerifyPinDataCommand.d.ts +134 -0
  68. package/dist-types/commands/index.d.ts +11 -0
  69. package/dist-types/endpoint/EndpointParameters.d.ts +20 -0
  70. package/dist-types/endpoint/endpointResolver.d.ts +5 -0
  71. package/dist-types/endpoint/ruleset.d.ts +2 -0
  72. package/dist-types/index.d.ts +11 -0
  73. package/dist-types/models/PaymentCryptographyDataServiceException.d.ts +13 -0
  74. package/dist-types/models/index.d.ts +1 -0
  75. package/dist-types/models/models_0.d.ts +2191 -0
  76. package/dist-types/protocols/Aws_restJson1.d.ts +101 -0
  77. package/dist-types/runtimeConfig.browser.d.ts +42 -0
  78. package/dist-types/runtimeConfig.d.ts +42 -0
  79. package/dist-types/runtimeConfig.native.d.ts +41 -0
  80. package/dist-types/runtimeConfig.shared.d.ts +18 -0
  81. package/dist-types/ts3.4/PaymentCryptographyData.d.ts +194 -0
  82. package/dist-types/ts3.4/PaymentCryptographyDataClient.d.ts +181 -0
  83. package/dist-types/ts3.4/commands/DecryptDataCommand.d.ts +35 -0
  84. package/dist-types/ts3.4/commands/EncryptDataCommand.d.ts +35 -0
  85. package/dist-types/ts3.4/commands/GenerateCardValidationDataCommand.d.ts +42 -0
  86. package/dist-types/ts3.4/commands/GenerateMacCommand.d.ts +35 -0
  87. package/dist-types/ts3.4/commands/GeneratePinDataCommand.d.ts +38 -0
  88. package/dist-types/ts3.4/commands/ReEncryptDataCommand.d.ts +35 -0
  89. package/dist-types/ts3.4/commands/TranslatePinDataCommand.d.ts +38 -0
  90. package/dist-types/ts3.4/commands/VerifyAuthRequestCryptogramCommand.d.ts +42 -0
  91. package/dist-types/ts3.4/commands/VerifyCardValidationDataCommand.d.ts +42 -0
  92. package/dist-types/ts3.4/commands/VerifyMacCommand.d.ts +35 -0
  93. package/dist-types/ts3.4/commands/VerifyPinDataCommand.d.ts +35 -0
  94. package/dist-types/ts3.4/commands/index.d.ts +11 -0
  95. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +32 -0
  96. package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
  97. package/dist-types/ts3.4/endpoint/ruleset.d.ts +2 -0
  98. package/dist-types/ts3.4/index.d.ts +5 -0
  99. package/dist-types/ts3.4/models/PaymentCryptographyDataServiceException.d.ts +8 -0
  100. package/dist-types/ts3.4/models/index.d.ts +1 -0
  101. package/dist-types/ts3.4/models/models_0.d.ts +1168 -0
  102. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +137 -0
  103. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +96 -0
  104. package/dist-types/ts3.4/runtimeConfig.d.ts +93 -0
  105. package/dist-types/ts3.4/runtimeConfig.native.d.ts +87 -0
  106. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +20 -0
  107. package/package.json +99 -0
@@ -0,0 +1,526 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SessionKeyMastercardFilterSensitiveLog = exports.SessionKeyEmvCommonFilterSensitiveLog = exports.SessionKeyEmv2000FilterSensitiveLog = exports.SessionKeyAmexFilterSensitiveLog = exports.TranslatePinDataInputFilterSensitiveLog = exports.TranslationIsoFormatsFilterSensitiveLog = exports.TranslationPinDataIsoFormat034FilterSensitiveLog = exports.ReEncryptDataOutputFilterSensitiveLog = exports.ReEncryptDataInputFilterSensitiveLog = exports.ReEncryptionAttributesFilterSensitiveLog = exports.GeneratePinDataInputFilterSensitiveLog = exports.GenerateMacInputFilterSensitiveLog = exports.MacAttributesFilterSensitiveLog = exports.MacAlgorithmEmvFilterSensitiveLog = exports.GenerateCardValidationDataInputFilterSensitiveLog = exports.EncryptDataOutputFilterSensitiveLog = exports.EncryptDataInputFilterSensitiveLog = exports.DecryptDataOutputFilterSensitiveLog = exports.DecryptDataInputFilterSensitiveLog = exports.EncryptionDecryptionAttributesFilterSensitiveLog = exports.SymmetricEncryptionAttributesFilterSensitiveLog = exports.DukptEncryptionAttributesFilterSensitiveLog = exports.PinVerificationAttributes = exports.SessionKeyDerivation = exports.VerificationFailedException = exports.VerificationFailedReason = exports.TranslationIsoFormats = exports.ReEncryptionAttributes = exports.PinData = exports.PinBlockFormatForPinData = exports.PinGenerationAttributes = exports.MacAttributes = exports.SessionKeyDerivationValue = exports.SessionKeyDerivationMode = exports.MajorKeyDerivationMode = exports.MacAlgorithm = exports.ValidationException = exports.ThrottlingException = exports.ResourceNotFoundException = exports.InternalServerException = exports.EncryptionDecryptionAttributes = exports.EncryptionMode = exports.DukptEncryptionMode = exports.DukptKeyVariant = exports.DukptDerivationType = exports.CryptogramAuthResponse = exports.CardVerificationAttributes = exports.CardGenerationAttributes = exports.PaddingType = exports.AccessDeniedException = void 0;
4
+ exports.VerifyPinDataInputFilterSensitiveLog = exports.VerifyMacInputFilterSensitiveLog = exports.VerifyCardValidationDataInputFilterSensitiveLog = exports.VerifyAuthRequestCryptogramInputFilterSensitiveLog = exports.SessionKeyDerivationFilterSensitiveLog = exports.SessionKeyVisaFilterSensitiveLog = void 0;
5
+ const smithy_client_1 = require("@aws-sdk/smithy-client");
6
+ const PaymentCryptographyDataServiceException_1 = require("./PaymentCryptographyDataServiceException");
7
+ class AccessDeniedException extends PaymentCryptographyDataServiceException_1.PaymentCryptographyDataServiceException {
8
+ constructor(opts) {
9
+ super({
10
+ name: "AccessDeniedException",
11
+ $fault: "client",
12
+ ...opts,
13
+ });
14
+ this.name = "AccessDeniedException";
15
+ this.$fault = "client";
16
+ Object.setPrototypeOf(this, AccessDeniedException.prototype);
17
+ this.Message = opts.Message;
18
+ }
19
+ }
20
+ exports.AccessDeniedException = AccessDeniedException;
21
+ exports.PaddingType = {
22
+ OAEP_SHA1: "OAEP_SHA1",
23
+ OAEP_SHA256: "OAEP_SHA256",
24
+ OAEP_SHA512: "OAEP_SHA512",
25
+ PKCS1: "PKCS1",
26
+ };
27
+ var CardGenerationAttributes;
28
+ (function (CardGenerationAttributes) {
29
+ CardGenerationAttributes.visit = (value, visitor) => {
30
+ if (value.AmexCardSecurityCodeVersion1 !== undefined)
31
+ return visitor.AmexCardSecurityCodeVersion1(value.AmexCardSecurityCodeVersion1);
32
+ if (value.AmexCardSecurityCodeVersion2 !== undefined)
33
+ return visitor.AmexCardSecurityCodeVersion2(value.AmexCardSecurityCodeVersion2);
34
+ if (value.CardVerificationValue1 !== undefined)
35
+ return visitor.CardVerificationValue1(value.CardVerificationValue1);
36
+ if (value.CardVerificationValue2 !== undefined)
37
+ return visitor.CardVerificationValue2(value.CardVerificationValue2);
38
+ if (value.CardHolderVerificationValue !== undefined)
39
+ return visitor.CardHolderVerificationValue(value.CardHolderVerificationValue);
40
+ if (value.DynamicCardVerificationCode !== undefined)
41
+ return visitor.DynamicCardVerificationCode(value.DynamicCardVerificationCode);
42
+ if (value.DynamicCardVerificationValue !== undefined)
43
+ return visitor.DynamicCardVerificationValue(value.DynamicCardVerificationValue);
44
+ return visitor._(value.$unknown[0], value.$unknown[1]);
45
+ };
46
+ })(CardGenerationAttributes = exports.CardGenerationAttributes || (exports.CardGenerationAttributes = {}));
47
+ var CardVerificationAttributes;
48
+ (function (CardVerificationAttributes) {
49
+ CardVerificationAttributes.visit = (value, visitor) => {
50
+ if (value.AmexCardSecurityCodeVersion1 !== undefined)
51
+ return visitor.AmexCardSecurityCodeVersion1(value.AmexCardSecurityCodeVersion1);
52
+ if (value.AmexCardSecurityCodeVersion2 !== undefined)
53
+ return visitor.AmexCardSecurityCodeVersion2(value.AmexCardSecurityCodeVersion2);
54
+ if (value.CardVerificationValue1 !== undefined)
55
+ return visitor.CardVerificationValue1(value.CardVerificationValue1);
56
+ if (value.CardVerificationValue2 !== undefined)
57
+ return visitor.CardVerificationValue2(value.CardVerificationValue2);
58
+ if (value.CardHolderVerificationValue !== undefined)
59
+ return visitor.CardHolderVerificationValue(value.CardHolderVerificationValue);
60
+ if (value.DynamicCardVerificationCode !== undefined)
61
+ return visitor.DynamicCardVerificationCode(value.DynamicCardVerificationCode);
62
+ if (value.DynamicCardVerificationValue !== undefined)
63
+ return visitor.DynamicCardVerificationValue(value.DynamicCardVerificationValue);
64
+ if (value.DiscoverDynamicCardVerificationCode !== undefined)
65
+ return visitor.DiscoverDynamicCardVerificationCode(value.DiscoverDynamicCardVerificationCode);
66
+ return visitor._(value.$unknown[0], value.$unknown[1]);
67
+ };
68
+ })(CardVerificationAttributes = exports.CardVerificationAttributes || (exports.CardVerificationAttributes = {}));
69
+ var CryptogramAuthResponse;
70
+ (function (CryptogramAuthResponse) {
71
+ CryptogramAuthResponse.visit = (value, visitor) => {
72
+ if (value.ArpcMethod1 !== undefined)
73
+ return visitor.ArpcMethod1(value.ArpcMethod1);
74
+ if (value.ArpcMethod2 !== undefined)
75
+ return visitor.ArpcMethod2(value.ArpcMethod2);
76
+ return visitor._(value.$unknown[0], value.$unknown[1]);
77
+ };
78
+ })(CryptogramAuthResponse = exports.CryptogramAuthResponse || (exports.CryptogramAuthResponse = {}));
79
+ exports.DukptDerivationType = {
80
+ AES_128: "AES_128",
81
+ AES_192: "AES_192",
82
+ AES_256: "AES_256",
83
+ TDES_2KEY: "TDES_2KEY",
84
+ TDES_3KEY: "TDES_3KEY",
85
+ };
86
+ exports.DukptKeyVariant = {
87
+ BIDIRECTIONAL: "BIDIRECTIONAL",
88
+ REQUEST: "REQUEST",
89
+ RESPONSE: "RESPONSE",
90
+ };
91
+ exports.DukptEncryptionMode = {
92
+ CBC: "CBC",
93
+ ECB: "ECB",
94
+ };
95
+ exports.EncryptionMode = {
96
+ CBC: "CBC",
97
+ CFB: "CFB",
98
+ CFB1: "CFB1",
99
+ CFB128: "CFB128",
100
+ CFB64: "CFB64",
101
+ CFB8: "CFB8",
102
+ ECB: "ECB",
103
+ OFB: "OFB",
104
+ };
105
+ var EncryptionDecryptionAttributes;
106
+ (function (EncryptionDecryptionAttributes) {
107
+ EncryptionDecryptionAttributes.visit = (value, visitor) => {
108
+ if (value.Symmetric !== undefined)
109
+ return visitor.Symmetric(value.Symmetric);
110
+ if (value.Asymmetric !== undefined)
111
+ return visitor.Asymmetric(value.Asymmetric);
112
+ if (value.Dukpt !== undefined)
113
+ return visitor.Dukpt(value.Dukpt);
114
+ return visitor._(value.$unknown[0], value.$unknown[1]);
115
+ };
116
+ })(EncryptionDecryptionAttributes = exports.EncryptionDecryptionAttributes || (exports.EncryptionDecryptionAttributes = {}));
117
+ class InternalServerException extends PaymentCryptographyDataServiceException_1.PaymentCryptographyDataServiceException {
118
+ constructor(opts) {
119
+ super({
120
+ name: "InternalServerException",
121
+ $fault: "server",
122
+ ...opts,
123
+ });
124
+ this.name = "InternalServerException";
125
+ this.$fault = "server";
126
+ Object.setPrototypeOf(this, InternalServerException.prototype);
127
+ this.Message = opts.Message;
128
+ }
129
+ }
130
+ exports.InternalServerException = InternalServerException;
131
+ class ResourceNotFoundException extends PaymentCryptographyDataServiceException_1.PaymentCryptographyDataServiceException {
132
+ constructor(opts) {
133
+ super({
134
+ name: "ResourceNotFoundException",
135
+ $fault: "client",
136
+ ...opts,
137
+ });
138
+ this.name = "ResourceNotFoundException";
139
+ this.$fault = "client";
140
+ Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
141
+ this.ResourceId = opts.ResourceId;
142
+ }
143
+ }
144
+ exports.ResourceNotFoundException = ResourceNotFoundException;
145
+ class ThrottlingException extends PaymentCryptographyDataServiceException_1.PaymentCryptographyDataServiceException {
146
+ constructor(opts) {
147
+ super({
148
+ name: "ThrottlingException",
149
+ $fault: "client",
150
+ ...opts,
151
+ });
152
+ this.name = "ThrottlingException";
153
+ this.$fault = "client";
154
+ Object.setPrototypeOf(this, ThrottlingException.prototype);
155
+ this.Message = opts.Message;
156
+ }
157
+ }
158
+ exports.ThrottlingException = ThrottlingException;
159
+ class ValidationException extends PaymentCryptographyDataServiceException_1.PaymentCryptographyDataServiceException {
160
+ constructor(opts) {
161
+ super({
162
+ name: "ValidationException",
163
+ $fault: "client",
164
+ ...opts,
165
+ });
166
+ this.name = "ValidationException";
167
+ this.$fault = "client";
168
+ Object.setPrototypeOf(this, ValidationException.prototype);
169
+ this.fieldList = opts.fieldList;
170
+ }
171
+ }
172
+ exports.ValidationException = ValidationException;
173
+ exports.MacAlgorithm = {
174
+ CMAC: "CMAC",
175
+ HMAC_SHA224: "HMAC_SHA224",
176
+ HMAC_SHA256: "HMAC_SHA256",
177
+ HMAC_SHA384: "HMAC_SHA384",
178
+ HMAC_SHA512: "HMAC_SHA512",
179
+ ISO9797_ALGORITHM1: "ISO9797_ALGORITHM1",
180
+ ISO9797_ALGORITHM3: "ISO9797_ALGORITHM3",
181
+ };
182
+ exports.MajorKeyDerivationMode = {
183
+ EMV_OPTION_A: "EMV_OPTION_A",
184
+ EMV_OPTION_B: "EMV_OPTION_B",
185
+ };
186
+ exports.SessionKeyDerivationMode = {
187
+ AMEX: "AMEX",
188
+ EMV2000: "EMV2000",
189
+ EMV_COMMON_SESSION_KEY: "EMV_COMMON_SESSION_KEY",
190
+ MASTERCARD_SESSION_KEY: "MASTERCARD_SESSION_KEY",
191
+ VISA: "VISA",
192
+ };
193
+ var SessionKeyDerivationValue;
194
+ (function (SessionKeyDerivationValue) {
195
+ SessionKeyDerivationValue.visit = (value, visitor) => {
196
+ if (value.ApplicationCryptogram !== undefined)
197
+ return visitor.ApplicationCryptogram(value.ApplicationCryptogram);
198
+ if (value.ApplicationTransactionCounter !== undefined)
199
+ return visitor.ApplicationTransactionCounter(value.ApplicationTransactionCounter);
200
+ return visitor._(value.$unknown[0], value.$unknown[1]);
201
+ };
202
+ })(SessionKeyDerivationValue = exports.SessionKeyDerivationValue || (exports.SessionKeyDerivationValue = {}));
203
+ var MacAttributes;
204
+ (function (MacAttributes) {
205
+ MacAttributes.visit = (value, visitor) => {
206
+ if (value.Algorithm !== undefined)
207
+ return visitor.Algorithm(value.Algorithm);
208
+ if (value.EmvMac !== undefined)
209
+ return visitor.EmvMac(value.EmvMac);
210
+ if (value.DukptIso9797Algorithm1 !== undefined)
211
+ return visitor.DukptIso9797Algorithm1(value.DukptIso9797Algorithm1);
212
+ if (value.DukptIso9797Algorithm3 !== undefined)
213
+ return visitor.DukptIso9797Algorithm3(value.DukptIso9797Algorithm3);
214
+ if (value.DukptCmac !== undefined)
215
+ return visitor.DukptCmac(value.DukptCmac);
216
+ return visitor._(value.$unknown[0], value.$unknown[1]);
217
+ };
218
+ })(MacAttributes = exports.MacAttributes || (exports.MacAttributes = {}));
219
+ var PinGenerationAttributes;
220
+ (function (PinGenerationAttributes) {
221
+ PinGenerationAttributes.visit = (value, visitor) => {
222
+ if (value.VisaPin !== undefined)
223
+ return visitor.VisaPin(value.VisaPin);
224
+ if (value.VisaPinVerificationValue !== undefined)
225
+ return visitor.VisaPinVerificationValue(value.VisaPinVerificationValue);
226
+ if (value.Ibm3624PinOffset !== undefined)
227
+ return visitor.Ibm3624PinOffset(value.Ibm3624PinOffset);
228
+ if (value.Ibm3624NaturalPin !== undefined)
229
+ return visitor.Ibm3624NaturalPin(value.Ibm3624NaturalPin);
230
+ if (value.Ibm3624RandomPin !== undefined)
231
+ return visitor.Ibm3624RandomPin(value.Ibm3624RandomPin);
232
+ if (value.Ibm3624PinFromOffset !== undefined)
233
+ return visitor.Ibm3624PinFromOffset(value.Ibm3624PinFromOffset);
234
+ return visitor._(value.$unknown[0], value.$unknown[1]);
235
+ };
236
+ })(PinGenerationAttributes = exports.PinGenerationAttributes || (exports.PinGenerationAttributes = {}));
237
+ exports.PinBlockFormatForPinData = {
238
+ ISO_FORMAT_0: "ISO_FORMAT_0",
239
+ ISO_FORMAT_3: "ISO_FORMAT_3",
240
+ };
241
+ var PinData;
242
+ (function (PinData) {
243
+ PinData.visit = (value, visitor) => {
244
+ if (value.PinOffset !== undefined)
245
+ return visitor.PinOffset(value.PinOffset);
246
+ if (value.VerificationValue !== undefined)
247
+ return visitor.VerificationValue(value.VerificationValue);
248
+ return visitor._(value.$unknown[0], value.$unknown[1]);
249
+ };
250
+ })(PinData = exports.PinData || (exports.PinData = {}));
251
+ var ReEncryptionAttributes;
252
+ (function (ReEncryptionAttributes) {
253
+ ReEncryptionAttributes.visit = (value, visitor) => {
254
+ if (value.Symmetric !== undefined)
255
+ return visitor.Symmetric(value.Symmetric);
256
+ if (value.Dukpt !== undefined)
257
+ return visitor.Dukpt(value.Dukpt);
258
+ return visitor._(value.$unknown[0], value.$unknown[1]);
259
+ };
260
+ })(ReEncryptionAttributes = exports.ReEncryptionAttributes || (exports.ReEncryptionAttributes = {}));
261
+ var TranslationIsoFormats;
262
+ (function (TranslationIsoFormats) {
263
+ TranslationIsoFormats.visit = (value, visitor) => {
264
+ if (value.IsoFormat0 !== undefined)
265
+ return visitor.IsoFormat0(value.IsoFormat0);
266
+ if (value.IsoFormat1 !== undefined)
267
+ return visitor.IsoFormat1(value.IsoFormat1);
268
+ if (value.IsoFormat3 !== undefined)
269
+ return visitor.IsoFormat3(value.IsoFormat3);
270
+ if (value.IsoFormat4 !== undefined)
271
+ return visitor.IsoFormat4(value.IsoFormat4);
272
+ return visitor._(value.$unknown[0], value.$unknown[1]);
273
+ };
274
+ })(TranslationIsoFormats = exports.TranslationIsoFormats || (exports.TranslationIsoFormats = {}));
275
+ exports.VerificationFailedReason = {
276
+ INVALID_AUTH_REQUEST_CRYPTOGRAM: "INVALID_AUTH_REQUEST_CRYPTOGRAM",
277
+ INVALID_MAC: "INVALID_MAC",
278
+ INVALID_PIN: "INVALID_PIN",
279
+ INVALID_VALIDATION_DATA: "INVALID_VALIDATION_DATA",
280
+ };
281
+ class VerificationFailedException extends PaymentCryptographyDataServiceException_1.PaymentCryptographyDataServiceException {
282
+ constructor(opts) {
283
+ super({
284
+ name: "VerificationFailedException",
285
+ $fault: "client",
286
+ ...opts,
287
+ });
288
+ this.name = "VerificationFailedException";
289
+ this.$fault = "client";
290
+ Object.setPrototypeOf(this, VerificationFailedException.prototype);
291
+ this.Reason = opts.Reason;
292
+ this.Message = opts.Message;
293
+ }
294
+ }
295
+ exports.VerificationFailedException = VerificationFailedException;
296
+ var SessionKeyDerivation;
297
+ (function (SessionKeyDerivation) {
298
+ SessionKeyDerivation.visit = (value, visitor) => {
299
+ if (value.EmvCommon !== undefined)
300
+ return visitor.EmvCommon(value.EmvCommon);
301
+ if (value.Mastercard !== undefined)
302
+ return visitor.Mastercard(value.Mastercard);
303
+ if (value.Emv2000 !== undefined)
304
+ return visitor.Emv2000(value.Emv2000);
305
+ if (value.Amex !== undefined)
306
+ return visitor.Amex(value.Amex);
307
+ if (value.Visa !== undefined)
308
+ return visitor.Visa(value.Visa);
309
+ return visitor._(value.$unknown[0], value.$unknown[1]);
310
+ };
311
+ })(SessionKeyDerivation = exports.SessionKeyDerivation || (exports.SessionKeyDerivation = {}));
312
+ var PinVerificationAttributes;
313
+ (function (PinVerificationAttributes) {
314
+ PinVerificationAttributes.visit = (value, visitor) => {
315
+ if (value.VisaPin !== undefined)
316
+ return visitor.VisaPin(value.VisaPin);
317
+ if (value.Ibm3624Pin !== undefined)
318
+ return visitor.Ibm3624Pin(value.Ibm3624Pin);
319
+ return visitor._(value.$unknown[0], value.$unknown[1]);
320
+ };
321
+ })(PinVerificationAttributes = exports.PinVerificationAttributes || (exports.PinVerificationAttributes = {}));
322
+ const DukptEncryptionAttributesFilterSensitiveLog = (obj) => ({
323
+ ...obj,
324
+ ...(obj.InitializationVector && { InitializationVector: smithy_client_1.SENSITIVE_STRING }),
325
+ });
326
+ exports.DukptEncryptionAttributesFilterSensitiveLog = DukptEncryptionAttributesFilterSensitiveLog;
327
+ const SymmetricEncryptionAttributesFilterSensitiveLog = (obj) => ({
328
+ ...obj,
329
+ ...(obj.InitializationVector && { InitializationVector: smithy_client_1.SENSITIVE_STRING }),
330
+ });
331
+ exports.SymmetricEncryptionAttributesFilterSensitiveLog = SymmetricEncryptionAttributesFilterSensitiveLog;
332
+ const EncryptionDecryptionAttributesFilterSensitiveLog = (obj) => {
333
+ if (obj.Symmetric !== undefined)
334
+ return { Symmetric: (0, exports.SymmetricEncryptionAttributesFilterSensitiveLog)(obj.Symmetric) };
335
+ if (obj.Asymmetric !== undefined)
336
+ return { Asymmetric: obj.Asymmetric };
337
+ if (obj.Dukpt !== undefined)
338
+ return { Dukpt: (0, exports.DukptEncryptionAttributesFilterSensitiveLog)(obj.Dukpt) };
339
+ if (obj.$unknown !== undefined)
340
+ return { [obj.$unknown[0]]: "UNKNOWN" };
341
+ };
342
+ exports.EncryptionDecryptionAttributesFilterSensitiveLog = EncryptionDecryptionAttributesFilterSensitiveLog;
343
+ const DecryptDataInputFilterSensitiveLog = (obj) => ({
344
+ ...obj,
345
+ ...(obj.CipherText && { CipherText: smithy_client_1.SENSITIVE_STRING }),
346
+ ...(obj.DecryptionAttributes && {
347
+ DecryptionAttributes: (0, exports.EncryptionDecryptionAttributesFilterSensitiveLog)(obj.DecryptionAttributes),
348
+ }),
349
+ });
350
+ exports.DecryptDataInputFilterSensitiveLog = DecryptDataInputFilterSensitiveLog;
351
+ const DecryptDataOutputFilterSensitiveLog = (obj) => ({
352
+ ...obj,
353
+ ...(obj.PlainText && { PlainText: smithy_client_1.SENSITIVE_STRING }),
354
+ });
355
+ exports.DecryptDataOutputFilterSensitiveLog = DecryptDataOutputFilterSensitiveLog;
356
+ const EncryptDataInputFilterSensitiveLog = (obj) => ({
357
+ ...obj,
358
+ ...(obj.PlainText && { PlainText: smithy_client_1.SENSITIVE_STRING }),
359
+ ...(obj.EncryptionAttributes && {
360
+ EncryptionAttributes: (0, exports.EncryptionDecryptionAttributesFilterSensitiveLog)(obj.EncryptionAttributes),
361
+ }),
362
+ });
363
+ exports.EncryptDataInputFilterSensitiveLog = EncryptDataInputFilterSensitiveLog;
364
+ const EncryptDataOutputFilterSensitiveLog = (obj) => ({
365
+ ...obj,
366
+ ...(obj.CipherText && { CipherText: smithy_client_1.SENSITIVE_STRING }),
367
+ });
368
+ exports.EncryptDataOutputFilterSensitiveLog = EncryptDataOutputFilterSensitiveLog;
369
+ const GenerateCardValidationDataInputFilterSensitiveLog = (obj) => ({
370
+ ...obj,
371
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
372
+ ...(obj.GenerationAttributes && { GenerationAttributes: obj.GenerationAttributes }),
373
+ });
374
+ exports.GenerateCardValidationDataInputFilterSensitiveLog = GenerateCardValidationDataInputFilterSensitiveLog;
375
+ const MacAlgorithmEmvFilterSensitiveLog = (obj) => ({
376
+ ...obj,
377
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
378
+ ...(obj.SessionKeyDerivationValue && { SessionKeyDerivationValue: obj.SessionKeyDerivationValue }),
379
+ });
380
+ exports.MacAlgorithmEmvFilterSensitiveLog = MacAlgorithmEmvFilterSensitiveLog;
381
+ const MacAttributesFilterSensitiveLog = (obj) => {
382
+ if (obj.Algorithm !== undefined)
383
+ return { Algorithm: obj.Algorithm };
384
+ if (obj.EmvMac !== undefined)
385
+ return { EmvMac: (0, exports.MacAlgorithmEmvFilterSensitiveLog)(obj.EmvMac) };
386
+ if (obj.DukptIso9797Algorithm1 !== undefined)
387
+ return { DukptIso9797Algorithm1: obj.DukptIso9797Algorithm1 };
388
+ if (obj.DukptIso9797Algorithm3 !== undefined)
389
+ return { DukptIso9797Algorithm3: obj.DukptIso9797Algorithm3 };
390
+ if (obj.DukptCmac !== undefined)
391
+ return { DukptCmac: obj.DukptCmac };
392
+ if (obj.$unknown !== undefined)
393
+ return { [obj.$unknown[0]]: "UNKNOWN" };
394
+ };
395
+ exports.MacAttributesFilterSensitiveLog = MacAttributesFilterSensitiveLog;
396
+ const GenerateMacInputFilterSensitiveLog = (obj) => ({
397
+ ...obj,
398
+ ...(obj.GenerationAttributes && { GenerationAttributes: (0, exports.MacAttributesFilterSensitiveLog)(obj.GenerationAttributes) }),
399
+ });
400
+ exports.GenerateMacInputFilterSensitiveLog = GenerateMacInputFilterSensitiveLog;
401
+ const GeneratePinDataInputFilterSensitiveLog = (obj) => ({
402
+ ...obj,
403
+ ...(obj.GenerationAttributes && { GenerationAttributes: obj.GenerationAttributes }),
404
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
405
+ });
406
+ exports.GeneratePinDataInputFilterSensitiveLog = GeneratePinDataInputFilterSensitiveLog;
407
+ const ReEncryptionAttributesFilterSensitiveLog = (obj) => {
408
+ if (obj.Symmetric !== undefined)
409
+ return { Symmetric: (0, exports.SymmetricEncryptionAttributesFilterSensitiveLog)(obj.Symmetric) };
410
+ if (obj.Dukpt !== undefined)
411
+ return { Dukpt: (0, exports.DukptEncryptionAttributesFilterSensitiveLog)(obj.Dukpt) };
412
+ if (obj.$unknown !== undefined)
413
+ return { [obj.$unknown[0]]: "UNKNOWN" };
414
+ };
415
+ exports.ReEncryptionAttributesFilterSensitiveLog = ReEncryptionAttributesFilterSensitiveLog;
416
+ const ReEncryptDataInputFilterSensitiveLog = (obj) => ({
417
+ ...obj,
418
+ ...(obj.CipherText && { CipherText: smithy_client_1.SENSITIVE_STRING }),
419
+ ...(obj.IncomingEncryptionAttributes && {
420
+ IncomingEncryptionAttributes: (0, exports.ReEncryptionAttributesFilterSensitiveLog)(obj.IncomingEncryptionAttributes),
421
+ }),
422
+ ...(obj.OutgoingEncryptionAttributes && {
423
+ OutgoingEncryptionAttributes: (0, exports.ReEncryptionAttributesFilterSensitiveLog)(obj.OutgoingEncryptionAttributes),
424
+ }),
425
+ });
426
+ exports.ReEncryptDataInputFilterSensitiveLog = ReEncryptDataInputFilterSensitiveLog;
427
+ const ReEncryptDataOutputFilterSensitiveLog = (obj) => ({
428
+ ...obj,
429
+ ...(obj.CipherText && { CipherText: smithy_client_1.SENSITIVE_STRING }),
430
+ });
431
+ exports.ReEncryptDataOutputFilterSensitiveLog = ReEncryptDataOutputFilterSensitiveLog;
432
+ const TranslationPinDataIsoFormat034FilterSensitiveLog = (obj) => ({
433
+ ...obj,
434
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
435
+ });
436
+ exports.TranslationPinDataIsoFormat034FilterSensitiveLog = TranslationPinDataIsoFormat034FilterSensitiveLog;
437
+ const TranslationIsoFormatsFilterSensitiveLog = (obj) => {
438
+ if (obj.IsoFormat0 !== undefined)
439
+ return { IsoFormat0: (0, exports.TranslationPinDataIsoFormat034FilterSensitiveLog)(obj.IsoFormat0) };
440
+ if (obj.IsoFormat1 !== undefined)
441
+ return { IsoFormat1: obj.IsoFormat1 };
442
+ if (obj.IsoFormat3 !== undefined)
443
+ return { IsoFormat3: (0, exports.TranslationPinDataIsoFormat034FilterSensitiveLog)(obj.IsoFormat3) };
444
+ if (obj.IsoFormat4 !== undefined)
445
+ return { IsoFormat4: (0, exports.TranslationPinDataIsoFormat034FilterSensitiveLog)(obj.IsoFormat4) };
446
+ if (obj.$unknown !== undefined)
447
+ return { [obj.$unknown[0]]: "UNKNOWN" };
448
+ };
449
+ exports.TranslationIsoFormatsFilterSensitiveLog = TranslationIsoFormatsFilterSensitiveLog;
450
+ const TranslatePinDataInputFilterSensitiveLog = (obj) => ({
451
+ ...obj,
452
+ ...(obj.IncomingTranslationAttributes && {
453
+ IncomingTranslationAttributes: (0, exports.TranslationIsoFormatsFilterSensitiveLog)(obj.IncomingTranslationAttributes),
454
+ }),
455
+ ...(obj.OutgoingTranslationAttributes && {
456
+ OutgoingTranslationAttributes: (0, exports.TranslationIsoFormatsFilterSensitiveLog)(obj.OutgoingTranslationAttributes),
457
+ }),
458
+ });
459
+ exports.TranslatePinDataInputFilterSensitiveLog = TranslatePinDataInputFilterSensitiveLog;
460
+ const SessionKeyAmexFilterSensitiveLog = (obj) => ({
461
+ ...obj,
462
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
463
+ });
464
+ exports.SessionKeyAmexFilterSensitiveLog = SessionKeyAmexFilterSensitiveLog;
465
+ const SessionKeyEmv2000FilterSensitiveLog = (obj) => ({
466
+ ...obj,
467
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
468
+ });
469
+ exports.SessionKeyEmv2000FilterSensitiveLog = SessionKeyEmv2000FilterSensitiveLog;
470
+ const SessionKeyEmvCommonFilterSensitiveLog = (obj) => ({
471
+ ...obj,
472
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
473
+ });
474
+ exports.SessionKeyEmvCommonFilterSensitiveLog = SessionKeyEmvCommonFilterSensitiveLog;
475
+ const SessionKeyMastercardFilterSensitiveLog = (obj) => ({
476
+ ...obj,
477
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
478
+ });
479
+ exports.SessionKeyMastercardFilterSensitiveLog = SessionKeyMastercardFilterSensitiveLog;
480
+ const SessionKeyVisaFilterSensitiveLog = (obj) => ({
481
+ ...obj,
482
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
483
+ });
484
+ exports.SessionKeyVisaFilterSensitiveLog = SessionKeyVisaFilterSensitiveLog;
485
+ const SessionKeyDerivationFilterSensitiveLog = (obj) => {
486
+ if (obj.EmvCommon !== undefined)
487
+ return { EmvCommon: (0, exports.SessionKeyEmvCommonFilterSensitiveLog)(obj.EmvCommon) };
488
+ if (obj.Mastercard !== undefined)
489
+ return { Mastercard: (0, exports.SessionKeyMastercardFilterSensitiveLog)(obj.Mastercard) };
490
+ if (obj.Emv2000 !== undefined)
491
+ return { Emv2000: (0, exports.SessionKeyEmv2000FilterSensitiveLog)(obj.Emv2000) };
492
+ if (obj.Amex !== undefined)
493
+ return { Amex: (0, exports.SessionKeyAmexFilterSensitiveLog)(obj.Amex) };
494
+ if (obj.Visa !== undefined)
495
+ return { Visa: (0, exports.SessionKeyVisaFilterSensitiveLog)(obj.Visa) };
496
+ if (obj.$unknown !== undefined)
497
+ return { [obj.$unknown[0]]: "UNKNOWN" };
498
+ };
499
+ exports.SessionKeyDerivationFilterSensitiveLog = SessionKeyDerivationFilterSensitiveLog;
500
+ const VerifyAuthRequestCryptogramInputFilterSensitiveLog = (obj) => ({
501
+ ...obj,
502
+ ...(obj.SessionKeyDerivationAttributes && {
503
+ SessionKeyDerivationAttributes: (0, exports.SessionKeyDerivationFilterSensitiveLog)(obj.SessionKeyDerivationAttributes),
504
+ }),
505
+ ...(obj.AuthResponseAttributes && { AuthResponseAttributes: obj.AuthResponseAttributes }),
506
+ });
507
+ exports.VerifyAuthRequestCryptogramInputFilterSensitiveLog = VerifyAuthRequestCryptogramInputFilterSensitiveLog;
508
+ const VerifyCardValidationDataInputFilterSensitiveLog = (obj) => ({
509
+ ...obj,
510
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
511
+ ...(obj.VerificationAttributes && { VerificationAttributes: obj.VerificationAttributes }),
512
+ });
513
+ exports.VerifyCardValidationDataInputFilterSensitiveLog = VerifyCardValidationDataInputFilterSensitiveLog;
514
+ const VerifyMacInputFilterSensitiveLog = (obj) => ({
515
+ ...obj,
516
+ ...(obj.VerificationAttributes && {
517
+ VerificationAttributes: (0, exports.MacAttributesFilterSensitiveLog)(obj.VerificationAttributes),
518
+ }),
519
+ });
520
+ exports.VerifyMacInputFilterSensitiveLog = VerifyMacInputFilterSensitiveLog;
521
+ const VerifyPinDataInputFilterSensitiveLog = (obj) => ({
522
+ ...obj,
523
+ ...(obj.VerificationAttributes && { VerificationAttributes: obj.VerificationAttributes }),
524
+ ...(obj.PrimaryAccountNumber && { PrimaryAccountNumber: smithy_client_1.SENSITIVE_STRING }),
525
+ });
526
+ exports.VerifyPinDataInputFilterSensitiveLog = VerifyPinDataInputFilterSensitiveLog;