Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
nichoth committed Dec 14, 2024
1 parent 3bd4579 commit fbb94e5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/dh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ function checkPrime (prime, generator) {
return error
}

function DH (prime, generator, malleable) {
export function DH (prime, generator, malleable) {
this.setGenerator(generator)
this.__prime = new BN(prime)
this._prime = BN.mont(this.__prime)
Expand Down
3 changes: 1 addition & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { DH } from './dh.js'
const generatePrime = require('./lib/generatePrime')
const primes = require('./lib/primes.json')

const DH = require('./lib/dh')

export function DiffieHellmanGroup (mod) {
const prime = new Buffer(primes[mod].prime, 'hex')
const gen = new Buffer(primes[mod].gen, 'hex')
Expand Down

0 comments on commit fbb94e5

Please sign in to comment.