Files
boc/vims-backend/node_modules/http_ece/README.md
T
Bernt 6de2455917 v1.2.0: Add Global Markets footer, translated to 9 languages
- Added GLOBAL_MARKETS_TITLE to all translation files
- Updated footer with 12 markets (4 active + 8 upcoming)
- Translated market section to: zh-cn, zh-tw, ja, ko, th, vi, id, ms, hi
- Built and deployed to production
- CloudFront invalidation: I3RTMXVFDJXWLG3SYX208OP1CC
2026-07-08 19:56:03 +00:00

28 lines
635 B
Markdown

# encrypted-content-encoding
A simple implementation of the [HTTP encrypted
content-encoding](https://tools.ietf.org/html/rfc8188)
# Use
```js
var ece = require('http_ece');
var crypto = require('crypto')
var parameters = {
key: crypto.randomBytes(16).toString('base64url'),
salt: crypto.randomBytes(16).toString('base64url')
};
var encrypted = ece.encrypt(data, parameters);
var decrypted = ece.decrypt(encrypted, parameters);
require('assert').equal(decrypted.compare(data), 0);
```
This also supports the static-ephemeral ECDH mode. The source explains how.
# TODO
Use the node streams API instead of the legacy APIs.