To support strong end to end security and avoid request tampering and man-in-the-middle attack, it is essential that the requests and responses are encrypted. The usage of HTTPS shall ensure transport layer encryption, while encryption of request and response shall ensure integrity & authenticity of data.
• "Key" is the AES Initialization vector (128 bits) and AES Key (256 bits) separated by a pipe (|) symbol, encrypted using recipient’s RSA Public Key and then Base64 encoded.
• "Data" is the actual data encrypted using the AES IV and AES Key and then Base64 encoded.
• "Hash" is the SHA-256 hash of the unencrypted data in Hexa-decimal String Format which is further AES encrypted using the same IV and Key as mentioned above and then Base64 Encoded.
Sample Script Code for Form POST
Following is the sample code in JavaScript to invoke Form POST.