Skip to content

Latest commit

 

History

History
37 lines (27 loc) · 1021 Bytes

README.md

File metadata and controls

37 lines (27 loc) · 1021 Bytes

SAPXSHanaCryptographic

##Cryptographic libraries for SAP XS Engine

In this example we use 2 cryptographic libraries to secure our communications.

Import the project and use folder libs: (important! these libs use a library called base64 included in project, don't forget this file)

$.import("CryptoExample.libs", "aesCrypt");
var aesCrypt = $.CryptoExample.libs.aesCrypt;

$.import("CryptoExample.libs", "SHA256");
var SHA256 = $.CryptoExample.libs.SHA256;

The code contains two libraries:

Encrypt

aesCrypt.encrypt(input,"SecretKey",256);

Decrypt

aesCrypt.decrypt(encript,"SecretKey",256);

Encrypt

SHA256.SHA256("SomeInput");