This API allows you to perform basic cryptographic functions.
Endpoints are exposed at the URL: https://cryptographic-api.herokuapp.com/
Alternatively, the program can be run locally. To start the application, clone the repo and type the following commands:
npm install
npm start
This API exposes four endpoints.
Takes a JSON payload and encrypts every value in the object at a depth of 1. The encrypted message is sent back in JSON response.
Takes a JSON payload, detects encrypted strings and decrypts them. The encrypted message is sent back in JSON response.
Takes a JSON payload and computes a cryptographic signature for the plaintext payload. The signature is then sent in JSON response.
Takes a JSON payload of the form :
{
"signature": <COMPUTED_SIGNATURE>,
"data": {...}
}
The data can be any JSON object and can contain encrypted fields. Any encrypted fields in the data will be decrypted before computing it's signature. If this signature matches the given signature the response will be 204, else 400.