Skip to content

Commit 2ce5aee

Browse files
committed
feat: add npm deployment workflow and update package files
1 parent 3010122 commit 2ce5aee

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

README.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# ecutils
1+
# js-ecutils
22

33
**JavaScript Library for Elliptic Curve Cryptography**
44

5-
`ecutils` is a JavaScript library designed for implementing Elliptic Curve Cryptography (ECC) algorithms, including key exchanges (Diffie-Hellman, Massey-Omura), ECDSA signatures, and Koblitz encoding. This library is suitable for educational purposes in cryptography and for use in secure systems.
5+
`js-ecutils` is a JavaScript library designed for implementing Elliptic Curve Cryptography (ECC) algorithms, including key exchanges (Diffie-Hellman, Massey-Omura), ECDSA signatures, and Koblitz encoding. This library is suitable for educational purposes in cryptography and for use in secure systems.
66

77
## Features
88

@@ -22,18 +22,18 @@
2222

2323
## Installation
2424

25-
To install `ecutils`, you can use npm:
25+
To install `js-ecutils`, you can use npm:
2626

2727
```bash
28-
npm install ecutils
28+
npm install js-ecutils
2929
```
3030

3131
## Usage
3232

3333
After installing, you can import the library into your JavaScript project:
3434

3535
```javascript
36-
const { core: { Point, EllipticCurve } } = require('ecutils');
36+
const { core: { Point, EllipticCurve } } = require('js-ecutils');
3737

3838
// Example parameters
3939
let p = 23n; // The prime number defining the finite field's order
@@ -247,7 +247,7 @@ Here are some examples of using the key exchange protocols and other features of
247247
### Encoding and Decoding Messages with Koblitz
248248

249249
```js
250-
const { algorithms: { Koblitz } } = require('ecutils');
250+
const { algorithms: { Koblitz } } = require('js-ecutils');
251251

252252
// Initialize Koblitz with a specific curve
253253
const koblitz = new Koblitz('secp521r1');
@@ -264,7 +264,7 @@ console.log(decoded_message);
264264
### Digital Signatures with ECDSA
265265

266266
```js
267-
const { algorithms: { DigitalSignature } } = require('ecutils');
267+
const { algorithms: { DigitalSignature } } = require('js-ecutils');
268268

269269
// Create a DigitalSignature instance with your private key
270270
const privateKey = BigInt(123456);
@@ -285,7 +285,7 @@ console.log(`Is the signature valid? ${isValid}`);
285285
### Diffie-Hellman Key Exchange
286286

287287
```js
288-
const { protocols: { DiffieHellman } } = require('ecutils');
288+
const { protocols: { DiffieHellman } } = require('js-ecutils');
289289

290290
// Alice's side
291291
const alice = new DiffieHellman(12345n);
@@ -308,7 +308,7 @@ console.log(`Are the shared secrets equal? ${isSharedSecretEqual}`);
308308
### Massey-Omura Key Exchange
309309

310310
```js
311-
const { algorithms: { Koblitz }, protocols: { MasseyOmura } } = require('ecutils');
311+
const { algorithms: { Koblitz }, protocols: { MasseyOmura } } = require('js-ecutils');
312312

313313
// Initialize the Koblitz instance for the elliptic curve 'secp192k1'
314314
const koblitz = new Koblitz('secp192k1');

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "ecutils",
2+
"name": "js-ecutils",
33
"version": "0.0.1-alpha.1",
44
"description": "JavaScript library for Elliptic Curve Cryptography: key exchanges (Diffie-Hellman, Massey-Omura), ECDSA signatures, and Koblitz encoding. Suitable for crypto education and secure systems.",
55
"keywords": [

0 commit comments

Comments
 (0)