Class: Aws::PaymentCryptographyData::Client
- Inherits:
-
Seahorse::Client::Base
- Object
- Seahorse::Client::Base
- Aws::PaymentCryptographyData::Client
- Includes:
- ClientStubs
- Defined in:
- lib/aws-sdk-paymentcryptographydata/client.rb,
sig/client.rbs
Overview
An API client for PaymentCryptographyData. To construct a client, you need to configure a :region and :credentials.
client = Aws::PaymentCryptographyData::Client.new(
region: region_name,
credentials: credentials,
# ...
)
For details on configuring region and credentials see the developer guide.
See #initialize for a full list of supported configuration options.
Defined Under Namespace
Modules: _DecryptDataResponseSuccess, _EncryptDataResponseSuccess, _GenerateAs2805KekValidationResponseSuccess, _GenerateAuthRequestCryptogramResponseSuccess, _GenerateCardValidationDataResponseSuccess, _GenerateMacEmvPinChangeResponseSuccess, _GenerateMacResponseSuccess, _GeneratePinDataResponseSuccess, _ReEncryptDataResponseSuccess, _TranslateKeyMaterialResponseSuccess, _TranslatePinDataResponseSuccess, _VerifyAuthRequestCryptogramResponseSuccess, _VerifyCardValidationDataResponseSuccess, _VerifyMacResponseSuccess, _VerifyPinDataResponseSuccess
Class Attribute Summary collapse
- .identifier ⇒ Object readonly private
API Operations collapse
-
#decrypt_data(params = {}) ⇒ Types::DecryptDataOutput
Decrypts ciphertext data to plaintext using a symmetric (TDES, AES), asymmetric (RSA), or derived (DUKPT or EMV) encryption key scheme.
-
#encrypt_data(params = {}) ⇒ Types::EncryptDataOutput
Encrypts plaintext data to ciphertext using a symmetric (TDES, AES), asymmetric (RSA), or derived (DUKPT or EMV) encryption key scheme.
-
#generate_as_2805_kek_validation(params = {}) ⇒ Types::GenerateAs2805KekValidationOutput
Generates a
KekValidationRequestor aKekValidationResponsefor node-to-node initialization between payment processing nodes using [Australian Standard 2805 (AS2805)][1]. -
#generate_auth_request_cryptogram(params = {}) ⇒ Types::GenerateAuthRequestCryptogramOutput
Generates an Authorization Request Cryptogram (ARQC) for an EMV chip payment card authorization.
-
#generate_card_validation_data(params = {}) ⇒ Types::GenerateCardValidationDataOutput
Generates card-related validation data using algorithms such as Card Verification Values (CVV/CVV2), Dynamic Card Verification Values (dCVV/dCVV2), or Card Security Codes (CSC).
-
#generate_mac(params = {}) ⇒ Types::GenerateMacOutput
Generates a Message Authentication Code (MAC) cryptogram within Amazon Web Services Payment Cryptography.
-
#generate_mac_emv_pin_change(params = {}) ⇒ Types::GenerateMacEmvPinChangeOutput
Generates an issuer script mac for EMV payment cards that use offline PINs as the cardholder verification method (CVM).
-
#generate_pin_data(params = {}) ⇒ Types::GeneratePinDataOutput
Generates pin-related data such as PIN, PIN Verification Value (PVV), PIN Block, and PIN Offset during new card issuance or reissuance.
-
#re_encrypt_data(params = {}) ⇒ Types::ReEncryptDataOutput
Re-encrypts ciphertext using DUKPT, symmetric, or asymmetric data encryption keys.
-
#translate_key_material(params = {}) ⇒ Types::TranslateKeyMaterialOutput
Translates an cryptographic key between different wrapping keys without importing the key into Amazon Web Services Payment Cryptography.
-
#translate_pin_data(params = {}) ⇒ Types::TranslatePinDataOutput
Translates encrypted PIN block from and to ISO 9564 formats 0,1,3,4.
-
#verify_auth_request_cryptogram(params = {}) ⇒ Types::VerifyAuthRequestCryptogramOutput
Verifies Authorization Request Cryptogram (ARQC) for a EMV chip payment card authorization.
-
#verify_card_validation_data(params = {}) ⇒ Types::VerifyCardValidationDataOutput
Verifies card-related validation data using algorithms such as Card Verification Values (CVV/CVV2), Dynamic Card Verification Values (dCVV/dCVV2) and Card Security Codes (CSC).
-
#verify_mac(params = {}) ⇒ Types::VerifyMacOutput
Verifies a Message Authentication Code (MAC).
-
#verify_pin_data(params = {}) ⇒ Types::VerifyPinDataOutput
Verifies pin-related data such as PIN and PIN Offset using algorithms including VISA PVV and IBM3624.
Class Method Summary collapse
- .errors_module ⇒ Object private
- .new ⇒ Object
Instance Method Summary collapse
- #build_request(operation_name, params = {}) ⇒ Object private
-
#initialize(options) ⇒ Client
constructor
A new instance of Client.
- #waiter_names ⇒ Object deprecated private Deprecated.
Constructor Details
#initialize(options) ⇒ Client
Returns a new instance of Client.
479 480 481 |
# File 'lib/aws-sdk-paymentcryptographydata/client.rb', line 479 def initialize(*args) super end |
Class Attribute Details
.identifier ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
2635 2636 2637 |
# File 'lib/aws-sdk-paymentcryptographydata/client.rb', line 2635 def identifier @identifier end |
Class Method Details
.errors_module ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
2638 2639 2640 |
# File 'lib/aws-sdk-paymentcryptographydata/client.rb', line 2638 def errors_module Errors end |
.new(credentials:, region:, access_key_id:, account_id:, active_endpoint_cache:, adaptive_retry_wait_to_fill:, auth_scheme_preference:, client_side_monitoring:, client_side_monitoring_client_id:, client_side_monitoring_host:, client_side_monitoring_port:, client_side_monitoring_publisher:, convert_params:, correct_clock_skew:, defaults_mode:, disable_clock_skew_correction:, disable_host_prefix_injection:, disable_request_compression:, endpoint:, endpoint_cache_max_entries:, endpoint_cache_max_threads:, endpoint_cache_poll_interval:, endpoint_discovery:, ignore_configured_endpoint_urls:, log_formatter:, log_level:, logger:, max_attempts:, profile:, request_checksum_calculation:, request_min_compression_size_bytes:, response_checksum_validation:, retry_backoff:, retry_base_delay:, retry_jitter:, retry_limit:, retry_max_delay:, retry_mode:, sdk_ua_app_id:, secret_access_key:, session_token:, sigv4a_signing_region_set:, stub_responses:, telemetry_provider:, token_provider:, use_dualstack_endpoint:, use_fips_endpoint:, validate_params:, endpoint_provider:, http_proxy:, http_open_timeout:, http_read_timeout:, http_idle_timeout:, http_continue_timeout:, ssl_timeout:, http_wire_trace:, ssl_verify_peer:, ssl_ca_bundle:, ssl_ca_directory:, ssl_ca_store:, on_chunk_received:, on_chunk_sent:, raise_response_errors:) ⇒ instance .new(arg0) ⇒ instance
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 |
# File 'sig/client.rbs', line 14
def self.new: (
?credentials: untyped,
?region: String,
?access_key_id: String,
?account_id: String,
?active_endpoint_cache: bool,
?adaptive_retry_wait_to_fill: bool,
?auth_scheme_preference: Array[String],
?client_side_monitoring: bool,
?client_side_monitoring_client_id: String,
?client_side_monitoring_host: String,
?client_side_monitoring_port: Integer,
?client_side_monitoring_publisher: untyped,
?convert_params: bool,
?correct_clock_skew: bool,
?defaults_mode: String,
?disable_clock_skew_correction: bool,
?disable_host_prefix_injection: bool,
?disable_request_compression: bool,
?endpoint: String,
?endpoint_cache_max_entries: Integer,
?endpoint_cache_max_threads: Integer,
?endpoint_cache_poll_interval: Integer,
?endpoint_discovery: bool,
?ignore_configured_endpoint_urls: bool,
?log_formatter: untyped,
?log_level: Symbol,
?logger: untyped,
?max_attempts: Integer,
?profile: String,
?request_checksum_calculation: String,
?request_min_compression_size_bytes: Integer,
?response_checksum_validation: String,
?retry_backoff: Proc,
?retry_base_delay: Float,
?retry_jitter: (:none | :equal | :full | ^(Integer) -> Integer),
?retry_limit: Integer,
?retry_max_delay: Integer,
?retry_mode: ("legacy" | "standard" | "adaptive"),
?sdk_ua_app_id: String,
?secret_access_key: String,
?session_token: String,
?sigv4a_signing_region_set: Array[String],
?stub_responses: untyped,
?telemetry_provider: Aws::Telemetry::TelemetryProviderBase,
?token_provider: untyped,
?use_dualstack_endpoint: bool,
?use_fips_endpoint: bool,
?validate_params: bool,
?endpoint_provider: untyped,
?http_proxy: String,
?http_open_timeout: (Float | Integer),
?http_read_timeout: (Float | Integer),
?http_idle_timeout: (Float | Integer),
?http_continue_timeout: (Float | Integer),
?ssl_timeout: (Float | Integer | nil),
?http_wire_trace: bool,
?ssl_verify_peer: bool,
?ssl_ca_bundle: String,
?ssl_ca_directory: String,
?ssl_ca_store: String,
?on_chunk_received: Proc,
?on_chunk_sent: Proc,
?raise_response_errors: bool
) -> instance
| (?Hash[Symbol, untyped]) -> instance
|
Instance Method Details
#build_request(operation_name, params = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 |
# File 'lib/aws-sdk-paymentcryptographydata/client.rb', line 2608 def build_request(operation_name, params = {}) handlers = @handlers.for(operation_name) tracer = config.telemetry_provider.tracer_provider.tracer( Aws::Telemetry.module_to_tracer_name('Aws::PaymentCryptographyData') ) context = Seahorse::Client::RequestContext.new( operation_name: operation_name, operation: config.api.operation(operation_name), client: self, params: params, config: config, tracer: tracer ) context[:gem_name] = 'aws-sdk-paymentcryptographydata' context[:gem_version] = '1.71.0' Seahorse::Client::Request.new(handlers, context) end |
#decrypt_data(params = {}) ⇒ Types::DecryptDataOutput
Decrypts ciphertext data to plaintext using a symmetric (TDES, AES), asymmetric (RSA), or derived (DUKPT or EMV) encryption key scheme. For more information, see Decrypt data in the Amazon Web Services Payment Cryptography User Guide.
You can use an decryption key generated within Amazon Web Services
Payment Cryptography, or you can import your own decryption key by
calling ImportKey. For this operation, the key must have
KeyModesOfUse set to Decrypt. In asymmetric decryption, Amazon Web
Services Payment Cryptography decrypts the ciphertext using the
private component of the asymmetric encryption key pair. For data
encryption outside of Amazon Web Services Payment Cryptography, you
can export the public component of the asymmetric key pair by calling
GetPublicCertificate.
This operation also supports dynamic keys, allowing you to pass a
dynamic decryption key as a TR-31 WrappedKeyBlock. This can be used
when key material is frequently rotated, such as during every card
transaction, and there is need to avoid importing short-lived keys
into Amazon Web Services Payment Cryptography. To decrypt using
dynamic keys, the keyARN is the Key Encryption Key (KEK) of the
TR-31 wrapped decryption key material. The incoming wrapped key shall
have a key purpose of D0 with a mode of use of B or D. For more
information, see Using Dynamic Keys in the Amazon Web Services
Payment Cryptography User Guide.
For symmetric and DUKPT decryption, Amazon Web Services Payment
Cryptography supports TDES and AES algorithms. For EMV decryption,
Amazon Web Services Payment Cryptography supports TDES algorithms.
For asymmetric decryption, Amazon Web Services Payment Cryptography
supports RSA.
When you use TDES or TDES DUKPT, the ciphertext data length must be a multiple of 8 bytes. For AES or AES DUKPT, the ciphertext data length must be a multiple of 16 bytes. For RSA, it sould be equal to the key size unless padding is enabled.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
EncryptData
89 90 91 92 93 94 95 |
# File 'sig/client.rbs', line 89
def decrypt_data: (
key_identifier: ::String,
cipher_text: ::String,
decryption_attributes: Params::encryption_decryption_attributes,
?wrapped_key: Params::wrapped_key
) -> _DecryptDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _DecryptDataResponseSuccess
|
#encrypt_data(params = {}) ⇒ Types::EncryptDataOutput
Encrypts plaintext data to ciphertext using a symmetric (TDES, AES), asymmetric (RSA), or derived (DUKPT or EMV) encryption key scheme. For more information, see Encrypt data in the Amazon Web Services Payment Cryptography User Guide.
You can generate an encryption key within Amazon Web Services Payment Cryptography by calling CreateKey. You can import your own encryption key by calling ImportKey.
For this operation, the key must have KeyModesOfUse set to
Encrypt. In asymmetric encryption, plaintext is encrypted using
public component. You can import the public component of an asymmetric
key pair created outside Amazon Web Services Payment Cryptography by
calling ImportKey.
This operation also supports dynamic keys, allowing you to pass a
dynamic encryption key as a TR-31 WrappedKeyBlock. This can be used
when key material is frequently rotated, such as during every card
transaction, and there is need to avoid importing short-lived keys
into Amazon Web Services Payment Cryptography. To encrypt using
dynamic keys, the keyARN is the Key Encryption Key (KEK) of the
TR-31 wrapped encryption key material. The incoming wrapped key shall
have a key purpose of D0 with a mode of use of B or D. For more
information, see Using Dynamic Keys in the Amazon Web Services
Payment Cryptography User Guide.
For symmetric and DUKPT encryption, Amazon Web Services Payment
Cryptography supports TDES and AES algorithms. For EMV encryption,
Amazon Web Services Payment Cryptography supports TDES
algorithms.For asymmetric encryption, Amazon Web Services Payment
Cryptography supports RSA.
When you use TDES or TDES DUKPT, the plaintext data length must be a multiple of 8 bytes. For AES or AES DUKPT, the plaintext data length must be a multiple of 16 bytes. For RSA, it sould be equal to the key size unless padding is enabled.
To encrypt using DUKPT, you must already have a BDK (Base Derivation
Key) key in your account with KeyModesOfUse set to DeriveKey, or
you can generate a new DUKPT key by calling CreateKey. To encrypt
using EMV, you must already have an IMK (Issuer Master Key) key in
your account with KeyModesOfUse set to DeriveKey.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
DecryptData
-
ReEncryptData
104 105 106 107 108 109 110 |
# File 'sig/client.rbs', line 104
def encrypt_data: (
key_identifier: ::String,
plain_text: ::String,
encryption_attributes: Params::encryption_decryption_attributes,
?wrapped_key: Params::wrapped_key
) -> _EncryptDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _EncryptDataResponseSuccess
|
#generate_as_2805_kek_validation(params = {}) ⇒ Types::GenerateAs2805KekValidationOutput
Generates a KekValidationRequest or a KekValidationResponse for
node-to-node initialization between payment processing nodes using
Australian Standard 2805 (AS2805).
During node-to-node initialization, both communicating nodes must validate that they possess the correct Key Encrypting Keys (KEKs) before proceeding with session key exchange. In AS2805, the sending KEK (KEKs) of one node corresponds to the receiving KEK (KEKr) of its partner node. Each node uses its KEK to encrypt and decrypt session keys exchanged between the nodes. A KEK can be created or imported into Amazon Web Services Payment Cryptography using either the CreateKey or ImportKey operations.
To use GenerateAs2805KekValidation to generate a KEK validation
request, set KekValidationType to KekValidationRequest. This
operation returns both RandomKeySend (KRs) and RandomKeyReceive
(KRr) as response values. The partnering node receives the KRs, uses
its KEKr to decrypt it, and generates a KRr which is an inverted value
of KRs. The node receiving the KRr validates it against its own KRr
generated during KEK validation request outside of Amazon Web Services
Payment Cryptography.
You can also use this operation to generate a KEK validation response,
by setting KekValidationType to KekValidationResponse and
providing the incoming KRs. This operation then calculates a KRr. To
learn more about more about node-to-node initialization, see
Validation of KEK in the Amazon Web Services Payment
Cryptography User Guide.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
120 121 122 123 124 125 126 127 128 129 130 131 132 133 |
# File 'sig/client.rbs', line 120
def generate_as_2805_kek_validation: (
key_identifier: ::String,
kek_validation_type: {
kek_validation_request: {
derive_key_algorithm: ("TDES_2KEY" | "TDES_3KEY" | "AES_128" | "AES_192" | "AES_256" | "HMAC_SHA256" | "HMAC_SHA384" | "HMAC_SHA512" | "HMAC_SHA224"),
random_key_max_length: ("BYTES_8" | "BYTES_16" | "BYTES_24")?
}?,
kek_validation_response: {
random_key_send: ::String
}?
},
random_key_send_variant_mask: ("VARIANT_MASK_82C0" | "VARIANT_MASK_82")
) -> _GenerateAs2805KekValidationResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GenerateAs2805KekValidationResponseSuccess
|
#generate_auth_request_cryptogram(params = {}) ⇒ Types::GenerateAuthRequestCryptogramOutput
Generates an Authorization Request Cryptogram (ARQC) for an EMV chip payment card authorization. For more information, see Generate auth request cryptogram in the Amazon Web Services Payment Cryptography User Guide.
ARQC generation uses an Issuer Master Key (IMK) for application
cryptograms (TR31_E0_EMV_MKEY_APP_CRYPTOGRAMS) to derive a
session key, which is then used to generate the cryptogram from the
provided transaction data (when applicable). To use this operation,
you must first create or import an IMK-AC key by calling
CreateKey or ImportKey. The KeyModesOfUse should be set to
DeriveKey for the IMK-AC encryption key.
This operation is intended for development and testing scenarios only. It is not recommended to use this operation as a substitute for card-based cryptogram generation in production payment flows.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
- VerifyAuthRequestCryptogram
^
142 143 144 145 146 147 148 |
# File 'sig/client.rbs', line 142
def generate_auth_request_cryptogram: (
key_identifier: ::String,
transaction_data: ::String,
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
session_key_derivation_attributes: Params::session_key_derivation
) -> _GenerateAuthRequestCryptogramResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GenerateAuthRequestCryptogramResponseSuccess
|
#generate_card_validation_data(params = {}) ⇒ Types::GenerateCardValidationDataOutput
Generates card-related validation data using algorithms such as Card Verification Values (CVV/CVV2), Dynamic Card Verification Values (dCVV/dCVV2), or Card Security Codes (CSC). For more information, see Generate card data in the Amazon Web Services Payment Cryptography User Guide.
This operation generates a CVV or CSC value that is printed on a
payment credit or debit card during card production. The CVV or CSC,
PAN (Primary Account Number) and expiration date of the card are
required to check its validity during transaction processing. To begin
this operation, a CVK (Card Verification Key) encryption key is
required. You can use CreateKey or ImportKey to establish a
CVK within Amazon Web Services Payment Cryptography. The
KeyModesOfUse should be set to Generate and Verify for a CVK
encryption key.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
VerifyCardValidationData
157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 |
# File 'sig/client.rbs', line 157
def generate_card_validation_data: (
key_identifier: ::String,
primary_account_number: ::String,
generation_attributes: {
amex_card_security_code_version_1: {
card_expiry_date: ::String
}?,
amex_card_security_code_version_2: {
card_expiry_date: ::String,
service_code: ::String
}?,
card_verification_value_1: {
card_expiry_date: ::String,
service_code: ::String
}?,
card_verification_value_2: {
card_expiry_date: ::String
}?,
card_holder_verification_value: {
unpredictable_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String
}?,
dynamic_card_verification_code: {
unpredictable_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String,
track_data: ::String
}?,
dynamic_card_verification_value: {
pan_sequence_number: ::String,
card_expiry_date: ::String,
service_code: ::String,
application_transaction_counter: ::String
}?
},
?validation_data_length: ::Integer
) -> _GenerateCardValidationDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GenerateCardValidationDataResponseSuccess
|
#generate_mac(params = {}) ⇒ Types::GenerateMacOutput
Generates a Message Authentication Code (MAC) cryptogram within Amazon Web Services Payment Cryptography.
You can use this operation to authenticate card-related data by using known data values to generate MAC for data validation between the sending and receiving parties. This operation uses message data, a secret encryption key and MAC algorithm to generate a unique MAC value for transmission. The receiving party of the MAC must use the same message data, secret encryption key and MAC algorithm to reproduce another MAC value for comparision.
You can use this operation to generate a DUPKT, CMAC, HMAC or EMV MAC
by setting generation attributes and algorithm to the associated
values. The MAC generation encryption key must have valid values for
KeyUsage such as TR31_M7_HMAC_KEY for HMAC generation, and the key
must have KeyModesOfUse set to Generate.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
- VerifyMac
^
204 205 206 207 208 209 210 |
# File 'sig/client.rbs', line 204
def generate_mac: (
key_identifier: ::String,
message_data: ::String,
generation_attributes: Params::mac_attributes,
?mac_length: ::Integer
) -> _GenerateMacResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GenerateMacResponseSuccess
|
#generate_mac_emv_pin_change(params = {}) ⇒ Types::GenerateMacEmvPinChangeOutput
Generates an issuer script mac for EMV payment cards that use offline PINs as the cardholder verification method (CVM).
This operation generates an authenticated issuer script response by appending the incoming message data (APDU command) with the target encrypted PIN block in ISO2 format. The command structure and method to send the issuer script update to the card is not defined by this operation and is typically determined by the applicable payment card scheme.
The primary inputs to this operation include the incoming new encrypted pinblock, PIN encryption key (PEK), issuer master key (IMK), primary account number (PAN), and the payment card derivation method.
The operation uses two issuer master keys - secure messaging for confidentiality (IMK-SMC) and secure messaging for integrity (IMK-SMI). The SMC key is used to internally derive a key to secure the pin, while SMI key is used to internally derive a key to authenticate the script reponse as per the EMV 4.4 - Book 2 - Security and Key Management specification.
This operation supports Amex, EMV2000, EMVCommon, Mastercard and Visa derivation methods, each requiring specific input parameters. Users must follow the specific derivation method and input parameters defined by the respective payment card scheme.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
EncryptData
-
GenerateMac
225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 |
# File 'sig/client.rbs', line 225
def generate_mac_emv_pin_change: (
new_pin_pek_identifier: ::String,
new_encrypted_pin_block: ::String,
pin_block_format: ("ISO_FORMAT_0" | "ISO_FORMAT_1" | "ISO_FORMAT_3"),
secure_messaging_integrity_key_identifier: ::String,
secure_messaging_confidentiality_key_identifier: ::String,
message_data: ::String,
derivation_method_attributes: {
emv_common: {
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
primary_account_number: ::String,
pan_sequence_number: ::String,
application_cryptogram: ::String,
mode: ("ECB" | "CBC"),
pin_block_padding_type: ("NO_PADDING" | "ISO_IEC_7816_4"),
pin_block_length_position: ("NONE" | "FRONT_OF_PIN_BLOCK")
}?,
amex: {
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
primary_account_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String,
authorization_request_key_identifier: ::String,
current_pin_attributes: {
current_pin_pek_identifier: ::String,
current_encrypted_pin_block: ::String
}?
}?,
visa: {
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
primary_account_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String,
authorization_request_key_identifier: ::String,
current_pin_attributes: {
current_pin_pek_identifier: ::String,
current_encrypted_pin_block: ::String
}?
}?,
emv_2000: {
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
primary_account_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String
}?,
mastercard: {
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
primary_account_number: ::String,
pan_sequence_number: ::String,
application_cryptogram: ::String
}?
}
) -> _GenerateMacEmvPinChangeResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GenerateMacEmvPinChangeResponseSuccess
|
#generate_pin_data(params = {}) ⇒ Types::GeneratePinDataOutput
Generates pin-related data such as PIN, PIN Verification Value (PVV), PIN Block, and PIN Offset during new card issuance or reissuance. For more information, see Generate PIN data in the Amazon Web Services Payment Cryptography User Guide.
PIN data is never transmitted in clear to or from Amazon Web Services
Payment Cryptography. This operation generates PIN, PVV, or PIN Offset
and then encrypts it using Pin Encryption Key (PEK) to create an
EncryptedPinBlock for transmission from Amazon Web Services Payment
Cryptography. This operation uses a separate Pin Verification Key
(PVK) for VISA PVV generation.
Using ECDH key exchange, you can receive cardholder selectable PINs into Amazon Web Services Payment Cryptography. The ECDH derived key protects the incoming PIN block. You can also use it for reveal PIN, wherein the generated PIN block is protected by the ECDH derived key before transmission from Amazon Web Services Payment Cryptography. For more information on establishing ECDH derived keys, see the Generating keys in the Amazon Web Services Payment Cryptography User Guide.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
GenerateCardValidationData
-
TranslatePinData
-
VerifyPinData
290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 |
# File 'sig/client.rbs', line 290
def generate_pin_data: (
generation_key_identifier: ::String,
encryption_key_identifier: ::String,
generation_attributes: {
visa_pin: {
pin_verification_key_index: ::Integer
}?,
visa_pin_verification_value: {
encrypted_pin_block: ::String,
pin_verification_key_index: ::Integer
}?,
ibm_3624_pin_offset: {
encrypted_pin_block: ::String,
decimalization_table: ::String,
pin_validation_data_pad_character: ::String,
pin_validation_data: ::String
}?,
ibm_3624_natural_pin: {
decimalization_table: ::String,
pin_validation_data_pad_character: ::String,
pin_validation_data: ::String
}?,
ibm_3624_random_pin: {
decimalization_table: ::String,
pin_validation_data_pad_character: ::String,
pin_validation_data: ::String
}?,
ibm_3624_pin_from_offset: {
decimalization_table: ::String,
pin_validation_data_pad_character: ::String,
pin_validation_data: ::String,
pin_offset: ::String
}?
},
?pin_data_length: ::Integer,
?primary_account_number: ::String,
pin_block_format: ("ISO_FORMAT_0" | "ISO_FORMAT_1" | "ISO_FORMAT_3" | "ISO_FORMAT_4"),
?encryption_wrapped_key: Params::wrapped_key
) -> _GeneratePinDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _GeneratePinDataResponseSuccess
|
#re_encrypt_data(params = {}) ⇒ Types::ReEncryptDataOutput
Re-encrypts ciphertext using DUKPT, symmetric, or asymmetric data encryption keys.
You can either generate an encryption key within Amazon Web Services
Payment Cryptography by calling CreateKey or import your own
encryption key by calling ImportKey. The KeyArn for use with
this operation must be in a compatible key state with KeyModesOfUse
set to Encrypt.
This operation also supports dynamic keys, allowing you to pass a
dynamic encryption key as a TR-31 WrappedKeyBlock. This can be used
when key material is frequently rotated, such as during every card
transaction, and there is need to avoid importing short-lived keys
into Amazon Web Services Payment Cryptography. To re-encrypt using
dynamic keys, the keyARN is the Key Encryption Key (KEK) of the
TR-31 wrapped encryption key material. The incoming wrapped key shall
have a key purpose of D0 with a mode of use of B or D. For more
information, see Using Dynamic Keys in the Amazon Web Services
Payment Cryptography User Guide.
Amazon Web Services Payment Cryptography supports the following encryption key schemes:
-
DUKPT:
TDESandAESalgorithms. To encrypt using DUKPT, a DUKPT key must already exist within your account withKeyModesOfUseset toDeriveKeyor a new DUKPT can be generated by calling CreateKey. -
Symmetric:
TDESandAESalgorithms. -
Asymmetric:
RSA. You can use anRSAkey on either the incoming or the outgoing side, paired with a symmetric key on the other side.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
DecryptData
-
EncryptData
338 339 340 341 342 343 344 345 346 347 |
# File 'sig/client.rbs', line 338
def re_encrypt_data: (
incoming_key_identifier: ::String,
outgoing_key_identifier: ::String,
cipher_text: ::String,
incoming_encryption_attributes: Params::re_encryption_attributes,
outgoing_encryption_attributes: Params::re_encryption_attributes,
?incoming_wrapped_key: Params::wrapped_key,
?outgoing_wrapped_key: Params::wrapped_key
) -> _ReEncryptDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _ReEncryptDataResponseSuccess
|
#translate_key_material(params = {}) ⇒ Types::TranslateKeyMaterialOutput
Translates an cryptographic key between different wrapping keys without importing the key into Amazon Web Services Payment Cryptography.
This operation can be used when key material is frequently rotated, such as during every card transaction, and there is a need to avoid importing short-lived keys into Amazon Web Services Payment Cryptography. It translates short-lived transaction keys such as PEK generated for each transaction and wrapped with an ECDH derived wrapping key to another KEK wrapping key.
Before using this operation, you must first request the public key
certificate of the ECC key pair generated within Amazon Web Services
Payment Cryptography to establish an ECDH key agreement. In
TranslateKeyData, the service uses its own ECC key pair, public
certificate of receiving ECC key pair, and the key derivation
parameters to generate a derived key. The service uses this derived
key to unwrap the incoming transaction key received as a
TR31WrappedKeyBlock and re-wrap using a user provided KEK to generate
an outgoing Tr31WrappedKeyBlock.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 |
# File 'sig/client.rbs', line 354
def translate_key_material: (
incoming_key_material: {
diffie_hellman_tr_31_key_block: {
private_key_identifier: ::String,
certificate_authority_public_key_identifier: ::String,
public_key_certificate: ::String,
derive_key_algorithm: ("TDES_2KEY" | "TDES_3KEY" | "AES_128" | "AES_192" | "AES_256" | "HMAC_SHA256" | "HMAC_SHA384" | "HMAC_SHA512" | "HMAC_SHA224"),
key_derivation_function: ("NIST_SP800" | "ANSI_X963"),
key_derivation_hash_algorithm: ("SHA_256" | "SHA_384" | "SHA_512"),
derivation_data: {
shared_information: ::String?
},
wrapped_key_block: ::String
}?
},
outgoing_key_material: {
tr_31_key_block: {
wrapping_key_identifier: ::String
}?
},
?key_check_value_algorithm: ("CMAC" | "ANSI_X9_24" | "HMAC" | "SHA_1")
) -> _TranslateKeyMaterialResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _TranslateKeyMaterialResponseSuccess
|
#translate_pin_data(params = {}) ⇒ Types::TranslatePinDataOutput
Translates encrypted PIN block from and to ISO 9564 formats 0,1,3,4. For more information, see Translate PIN data in the Amazon Web Services Payment Cryptography User Guide.
PIN block translation involves changing a PIN block from one encryption key to another and optionally change its format. PIN block translation occurs entirely within the HSM boundary and PIN data never enters or leaves Amazon Web Services Payment Cryptography in clear text. The encryption key transformation can be from PEK (Pin Encryption Key) to BDK (Base Derivation Key) for DUKPT or from BDK for DUKPT to PEK.
Amazon Web Services Payment Cryptography also supports use of dynamic keys and ECDH (Elliptic Curve Diffie-Hellman) based key exchange for this operation.
Dynamic keys allow you to pass a PEK as a TR-31 WrappedKeyBlock. They
can be used when key material is frequently rotated, such as during
every card transaction, and there is need to avoid importing
short-lived keys into Amazon Web Services Payment Cryptography. To
translate PIN block using dynamic keys, the keyARN is the Key
Encryption Key (KEK) of the TR-31 wrapped PEK. The incoming wrapped
key shall have a key purpose of P0 with a mode of use of B or D. For
more information, see Using Dynamic Keys in the Amazon Web
Services Payment Cryptography User Guide.
Using ECDH key exchange, you can receive cardholder selectable PINs into Amazon Web Services Payment Cryptography. The ECDH derived key protects the incoming PIN block, which is translated to a PEK encrypted PIN block for use within the service. You can also use ECDH for reveal PIN, wherein the service translates the PIN block from PEK to a ECDH derived encryption key. For more information on establishing ECDH derived keys, see the Creating keys in the Amazon Web Services Payment Cryptography User Guide.
The allowed combinations of PIN block format translations are guided by PCI. It is important to note that not all encrypted PIN block formats (example, format 1) require PAN (Primary Account Number) as input. And as such, PIN block format that requires PAN (example, formats 0,3,4) cannot be translated to a format (format 1) that does not require a PAN for generation.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
GeneratePinData
-
VerifyPinData
385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 |
# File 'sig/client.rbs', line 385
def translate_pin_data: (
incoming_key_identifier: ::String,
outgoing_key_identifier: ::String,
incoming_translation_attributes: Params::translation_iso_formats,
outgoing_translation_attributes: Params::translation_iso_formats,
encrypted_pin_block: ::String,
?incoming_dukpt_attributes: {
key_serial_number: ::String,
dukpt_key_derivation_type: ("TDES_2KEY" | "TDES_3KEY" | "AES_128" | "AES_192" | "AES_256")?,
dukpt_key_variant: ("BIDIRECTIONAL" | "REQUEST" | "RESPONSE")?
},
?outgoing_dukpt_attributes: {
key_serial_number: ::String,
dukpt_key_derivation_type: ("TDES_2KEY" | "TDES_3KEY" | "AES_128" | "AES_192" | "AES_256")?,
dukpt_key_variant: ("BIDIRECTIONAL" | "REQUEST" | "RESPONSE")?
},
?incoming_wrapped_key: Params::wrapped_key,
?outgoing_wrapped_key: Params::wrapped_key,
?incoming_as_2805_attributes: {
system_trace_audit_number: ::String,
transaction_amount: ::String
}
) -> _TranslatePinDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _TranslatePinDataResponseSuccess
|
#verify_auth_request_cryptogram(params = {}) ⇒ Types::VerifyAuthRequestCryptogramOutput
Verifies Authorization Request Cryptogram (ARQC) for a EMV chip payment card authorization. For more information, see Verify auth request cryptogram in the Amazon Web Services Payment Cryptography User Guide.
ARQC generation is done outside of Amazon Web Services Payment
Cryptography and is typically generated on a point of sale terminal
for an EMV chip card to obtain payment authorization during
transaction time. For ARQC verification, you must first import the
ARQC generated outside of Amazon Web Services Payment Cryptography by
calling ImportKey. This operation uses the imported ARQC and an
major encryption key (DUKPT) created by calling CreateKey to
either provide a boolean ARQC verification result or provide an APRC
(Authorization Response Cryptogram) response using Method 1 or Method
2. The ARPC_METHOD_1 uses AuthResponseCode to generate ARPC and
ARPC_METHOD_2 uses CardStatusUpdate to generate ARPC.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
VerifyCardValidationData
-
VerifyPinData
417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 |
# File 'sig/client.rbs', line 417
def verify_auth_request_cryptogram: (
key_identifier: ::String,
transaction_data: ::String,
auth_request_cryptogram: ::String,
major_key_derivation_mode: ("EMV_OPTION_A" | "EMV_OPTION_B"),
session_key_derivation_attributes: Params::session_key_derivation,
?auth_response_attributes: {
arpc_method_1: {
auth_response_code: ::String
}?,
arpc_method_2: {
card_status_update: ::String,
proprietary_authentication_data: ::String?
}?
}
) -> _VerifyAuthRequestCryptogramResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _VerifyAuthRequestCryptogramResponseSuccess
|
#verify_card_validation_data(params = {}) ⇒ Types::VerifyCardValidationDataOutput
Verifies card-related validation data using algorithms such as Card Verification Values (CVV/CVV2), Dynamic Card Verification Values (dCVV/dCVV2) and Card Security Codes (CSC). For more information, see Verify card data in the Amazon Web Services Payment Cryptography User Guide.
This operation validates the CVV or CSC codes that is printed on a payment credit or debit card during card payment transaction. The input values are typically provided as part of an inbound transaction to an issuer or supporting platform partner. Amazon Web Services Payment Cryptography uses CVV or CSC, PAN (Primary Account Number) and expiration date of the card to check its validity during transaction processing. In this operation, the CVK (Card Verification Key) encryption key for use with card data verification is same as the one in used for GenerateCardValidationData.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
GenerateCardValidationData
-
VerifyAuthRequestCryptogram
-
VerifyPinData
441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 |
# File 'sig/client.rbs', line 441
def verify_card_validation_data: (
key_identifier: ::String,
primary_account_number: ::String,
verification_attributes: {
amex_card_security_code_version_1: {
card_expiry_date: ::String
}?,
amex_card_security_code_version_2: {
card_expiry_date: ::String,
service_code: ::String
}?,
card_verification_value_1: {
card_expiry_date: ::String,
service_code: ::String
}?,
card_verification_value_2: {
card_expiry_date: ::String
}?,
card_holder_verification_value: {
unpredictable_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String
}?,
dynamic_card_verification_code: {
unpredictable_number: ::String,
pan_sequence_number: ::String,
application_transaction_counter: ::String,
track_data: ::String
}?,
dynamic_card_verification_value: {
pan_sequence_number: ::String,
card_expiry_date: ::String,
service_code: ::String,
application_transaction_counter: ::String
}?,
discover_dynamic_card_verification_code: {
card_expiry_date: ::String,
unpredictable_number: ::String,
application_transaction_counter: ::String
}?
},
validation_data: ::String
) -> _VerifyCardValidationDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _VerifyCardValidationDataResponseSuccess
|
#verify_mac(params = {}) ⇒ Types::VerifyMacOutput
Verifies a Message Authentication Code (MAC).
You can use this operation to verify MAC for message data authentication such as . In this operation, you must use the same message data, secret encryption key and MAC algorithm that was used to generate MAC. You can use this operation to verify a DUPKT, CMAC, HMAC or EMV MAC by setting generation attributes and algorithm to the associated values.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
- GenerateMac
^
492 493 494 495 496 497 498 499 |
# File 'sig/client.rbs', line 492
def verify_mac: (
key_identifier: ::String,
message_data: ::String,
mac: ::String,
verification_attributes: Params::mac_attributes,
?mac_length: ::Integer
) -> _VerifyMacResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _VerifyMacResponseSuccess
|
#verify_pin_data(params = {}) ⇒ Types::VerifyPinDataOutput
Verifies pin-related data such as PIN and PIN Offset using algorithms including VISA PVV and IBM3624. For more information, see Verify PIN data in the Amazon Web Services Payment Cryptography User Guide.
This operation verifies PIN data for user payment card. A card holder
PIN data is never transmitted in clear to or from Amazon Web Services
Payment Cryptography. This operation uses PIN Verification Key (PVK)
for PIN or PIN Offset generation and then encrypts it using PIN
Encryption Key (PEK) to create an EncryptedPinBlock for transmission
from Amazon Web Services Payment Cryptography.
For information about valid keys for this operation, see Understanding key attributes and Key types for specific data operations in the Amazon Web Services Payment Cryptography User Guide.
Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.
Related operations:
-
GeneratePinData
-
TranslatePinData
509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 |
# File 'sig/client.rbs', line 509
def verify_pin_data: (
verification_key_identifier: ::String,
encryption_key_identifier: ::String,
verification_attributes: {
visa_pin: {
pin_verification_key_index: ::Integer,
verification_value: ::String
}?,
ibm_3624_pin: {
decimalization_table: ::String,
pin_validation_data_pad_character: ::String,
pin_validation_data: ::String,
pin_offset: ::String
}?
},
encrypted_pin_block: ::String,
?primary_account_number: ::String,
pin_block_format: ("ISO_FORMAT_0" | "ISO_FORMAT_1" | "ISO_FORMAT_3" | "ISO_FORMAT_4"),
?pin_data_length: ::Integer,
?dukpt_attributes: {
key_serial_number: ::String,
dukpt_derivation_type: ("TDES_2KEY" | "TDES_3KEY" | "AES_128" | "AES_192" | "AES_256")
},
?encryption_wrapped_key: Params::wrapped_key
) -> _VerifyPinDataResponseSuccess
| (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _VerifyPinDataResponseSuccess
|
#waiter_names ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
2628 2629 2630 |
# File 'lib/aws-sdk-paymentcryptographydata/client.rb', line 2628 def waiter_names [] end |