Class: AuthJWEUtility
- Inherits:
-
Object
- Object
- AuthJWEUtility
- Defined in:
- lib/AuthenticationSDK/util/AuthJWEUtility.rb
Class Method Summary collapse
-
.decrypt_jwe_using_pem(merchant_config, encoded_response) ⇒ Object
DEPRECATED: This method has been marked as Deprecated and will be removed in coming releases.
- .decrypt_jwe_using_private_key(private_key, encoded_response) ⇒ Object
Class Method Details
.decrypt_jwe_using_pem(merchant_config, encoded_response) ⇒ Object
DEPRECATED: This method has been marked as Deprecated and will be removed in coming releases. Use decrypt_jwe_using_private_key() instead.
14 15 16 17 18 19 |
# File 'lib/AuthenticationSDK/util/AuthJWEUtility.rb', line 14 def self.decrypt_jwe_using_pem(merchant_config, encoded_response) warn('[DEPRECATED] `decrypt_jwe_using_pem()` method is deprecated and will be removed in coming releases. Use `decrypt_jwe_using_private_key()` instead.') validate_jwe_algorithms(encoded_response) key = Cache.new.fetchPEMFileForNetworkTokenization(merchant_config.pemFileDirectory) JOSE::JWE.block_decrypt(key, encoded_response).first end |
.decrypt_jwe_using_private_key(private_key, encoded_response) ⇒ Object
21 22 23 24 |
# File 'lib/AuthenticationSDK/util/AuthJWEUtility.rb', line 21 def self.decrypt_jwe_using_private_key(private_key, encoded_response) validate_jwe_algorithms(encoded_response) JOSE::JWE.block_decrypt(private_key, encoded_response).first end |