4.0.7 • Published 1 year ago
@neoskop/ethereal-secrets-client v4.0.7
Ethereal Secrets Client
Usage
To add the library to your project:
$ npm i --save @neoskop/ethereal-secrets-clientLocal Mode
to store a value bar under the key foo encrypted in the session storage:
const client = new EtherealSecretsClient({
  endpoint: 'http://localhost:8080/secrets',
});
await client.saveLocal('foo', 'bar');
await client.getLocal('foo'); // => bar
await client.removeLocal('foo');Remote Mode
To store a value bar encrypted on the server:
const client = new EtherealSecretsClient({
  endpoint: 'http://localhost:8080/secrets',
});
const result = await client.saveRemote('foo', 'bar');
await client.getRemote(result.fragmentIdentifier); // => bar
await client.removeRemote(result.fragmentIdentifier);To use a second factor:
const client = new EtherealSecretsClient({
  endpoint: 'http://localhost:8080/secrets',
});
const result = await client.saveRemote('foo', 'bar', { secondFactor: 'baz' });
await client.getRemote(result.fragmentIdentifier, { secondFactor: 'baz' }); // => bar
await client.removeRemote(result.fragmentIdentifier, { secondFactor: 'baz' });Test suite
To run integration tests in this repository:
$ docker-compose -f docker-compose.test.yml up --abort-on-container-exit --build4.0.7
1 year ago
4.0.6
1 year ago
4.0.5
1 year ago
4.0.4
1 year ago
4.0.1
2 years ago
4.0.3
2 years ago
4.0.2
2 years ago
4.0.0
2 years ago
3.0.3
3 years ago
3.1.1
3 years ago
3.0.2
3 years ago
3.1.0
3 years ago
3.0.0
3 years ago
2.0.2
3 years ago
2.0.1
3 years ago
1.4.1
3 years ago
2.0.0
3 years ago
1.4.0
4 years ago
1.3.1
6 years ago
1.3.0
6 years ago
1.2.3
6 years ago
1.2.0
6 years ago
1.1.1
6 years ago
1.1.0
8 years ago
1.0.1
8 years ago
1.0.0
8 years ago
0.1.1
8 years ago
0.1.0
8 years ago
0.0.6
8 years ago
0.0.5
8 years ago
0.0.4
8 years ago
0.0.3
8 years ago
0.0.2
8 years ago
0.0.1
8 years ago