Skip to content

Commit

Permalink
Removed dependency on net.i2p.crypto.eddsa.math classes (Fixes #255)
Browse files Browse the repository at this point in the history
  • Loading branch information
hierynomus committed Jul 19, 2016
1 parent 90f8c59 commit 9a5ccef
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/main/java/net/schmizz/sshj/common/KeyType.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
import com.hierynomus.sshj.secg.SecgUtils;
import com.hierynomus.sshj.signature.Ed25519PublicKey;
import net.i2p.crypto.eddsa.EdDSAPublicKey;
import net.i2p.crypto.eddsa.math.GroupElement;
import net.i2p.crypto.eddsa.spec.EdDSANamedCurveSpec;
import net.i2p.crypto.eddsa.spec.EdDSANamedCurveTable;
import net.i2p.crypto.eddsa.spec.EdDSAPublicKeySpec;
Expand Down Expand Up @@ -191,8 +190,7 @@ public PublicKey readPubKeyFromBuffer(String type, Buffer<?> buf) throws General
}

EdDSANamedCurveSpec ed25519 = EdDSANamedCurveTable.getByName("ed25519-sha-512");
GroupElement point = ed25519.getCurve().createPoint(p, true);
EdDSAPublicKeySpec publicSpec = new EdDSAPublicKeySpec(point, ed25519);
EdDSAPublicKeySpec publicSpec = new EdDSAPublicKeySpec(p, ed25519);
return new Ed25519PublicKey(publicSpec);

} catch (Buffer.BufferException be) {
Expand Down

0 comments on commit 9a5ccef

Please sign in to comment.