Package com.adyen.terminal.security
Class NexoCrypto
- java.lang.Object
-
- com.adyen.terminal.security.NexoCrypto
-
public class NexoCrypto extends Object
-
-
Constructor Summary
Constructors Constructor Description NexoCrypto(SecurityKey securityKey)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringdecrypt(SaleToPOISecuredMessage saleToPoiSecuredMessage)Decrypts the SaleToPOI secured message.SaleToPOISecuredMessageencrypt(String saleToPoiMessageJson, MessageHeader messageHeader)Encrypts the SaleToPOI message using the provided message header and security key.
-
-
-
Constructor Detail
-
NexoCrypto
public NexoCrypto(SecurityKey securityKey) throws NexoCryptoException
- Throws:
NexoCryptoException
-
-
Method Detail
-
encrypt
public SaleToPOISecuredMessage encrypt(String saleToPoiMessageJson, MessageHeader messageHeader) throws Exception
Encrypts the SaleToPOI message using the provided message header and security key.- Parameters:
saleToPoiMessageJson- the JSON string representing the SaleToPOI messagemessageHeader- the message header for encryption- Returns:
- encrypted SaleToPOISecuredMessage
- Throws:
Exception
-
decrypt
public String decrypt(SaleToPOISecuredMessage saleToPoiSecuredMessage) throws Exception
Decrypts the SaleToPOI secured message.- Parameters:
saleToPoiSecuredMessage- the encrypted message- Returns:
- the decrypted SaleToPOI message as a JSON string
- Throws:
Exception
-
-