Questions tagged [elliptic-curve]

In mathematics, an elliptic curve is a smooth, projective algebraic curve of genus one, on which there is a specified point O.

In mathematics, an elliptic curve is a smooth, projective algebraic curve of genus one, on which there is a specified point O (the point at infinity). An elliptic curve is in fact an abelian variety — that is, it is a (necessarily commutative) group with respect to an algebraically defined multiplication — and O serves as the identity element. Often the curve itself, without O specified, is called an elliptic curve.

685 questions
13
votes
1 answer

How do I convert libsodium private keys to OpenPGP compatible private key packets?

libsodium is an awesome encryption library, and GnuPG is an awesome key management and signing software. GnuPG recently released support for Ed25519 signing keys, and submitted a draft to the IETF. I want to use Sodium-generated keys by my web…
Fredrick Brennan
  • 7,079
  • 2
  • 30
  • 61
12
votes
3 answers

Elliptic Curve Diffie Hellman in ios/swift

Does iOS expose API for key generation, and secret key derivation using ECDH? From what I see, apple are using it (and specifically x25519) internally but I don't see it exposed as public API by common crypto or otherwise. Thanks, Z
Zohar Etzioni
  • 691
  • 5
  • 14
12
votes
5 answers

Algorithm for elliptic curve point compression

I'm using Javascript to generate elliptic curves for use in a cryptographic messaging app based on this example code http://www-cs-students.stanford.edu/~tjw/jsbn/ecdh.html The public keys will be quite large and I know it's possible to compress…
Ian Purton
  • 15,331
  • 2
  • 27
  • 26
11
votes
1 answer

Create EC private key from hex string

I am wondering if this is a correct way to create PrivateKey object in Java from HEX string from this website: https://kjur.github.io/jsrsasign/sample/sample-ecdsa.html Create a BigInteger from a HEX String: BigInteger priv = new…
serg.nechaev
  • 1,323
  • 19
  • 26
11
votes
1 answer

Does ECDiffieHellmanCng in .NET have a key derivation function that implements NIST SP 800-56A, section 5.8.1

I have a task at hand that requires deriving key material using the key derivation function described in NIST SP 800-56A, section 5.8.1. I'm not an expert in Cryptography so please excuse me if the question is naive. Here's what I've done so far: I…
Sudhanshu Mishra
  • 6,523
  • 2
  • 59
  • 76
11
votes
1 answer

Elliptic curve threshold cryptography in node

I'd like to implement something like the two-man rule using elliptic curve cryptography in javascript. Edit: I'm essentially looking for something like Bitcoin multisig. So I need to take combine two public keys to get a combined key that requires…
Luke Burns
  • 1,911
  • 3
  • 24
  • 30
11
votes
2 answers

How to use ECC in iOS

Is there any example for use ECC in iOS? I noticed that the kSecAttrKeyTypeEC in Apple Developer Documents, but I can't use it to generic Key pair. Below code is modified from the example CryptoExercise // Container dictionaries. NSMutableDictionary…
Cylon
  • 393
  • 3
  • 11
10
votes
2 answers

get x and y components from ecc public key in PEM format using openssl

I am generating a KeyPair for ECC from curve 'secp128r1' using openssl Steps I followed : first I generated a private key using the command openssl ecparam -genkey -name secp128r1 -noout -out private.pem then i viewed the corresponding public…
10
votes
4 answers

Use of Curve25519 in ECDSA

I'm currently investigating the use of curve25519 for signing. Original distribution and a C implementation (and a second C implementation). Bernstein suggests to use ECDSA for this but I could not find any code.
chmike
  • 20,922
  • 21
  • 83
  • 106
10
votes
3 answers

Turn an byte encoded Key back into it's original ECPublicKey in Bouncy Castle

In Java I have a ECDH public Key that I am sending as a byte array. Once I have received the byte array how can I turn it back into a public key? I am using Bouncy Castle but a Java solution would be just as useful. Thanks
David Read
  • 635
  • 2
  • 9
  • 13
10
votes
2 answers

How Do i compress or encode the Elliptic curve public key and put it over the network?

I am developing Distributed digital signature that signs a document and send it through network to the Application Server.I am using socket programming in java to do it. I think the public key should be encoded or compressed i.e the x and y values…
Clickmit Wg
  • 523
  • 2
  • 9
  • 25
9
votes
3 answers

How to calculate point addition using Jacobian coordinate-system over elliptic curves

I'm writing a small project of elliptic curve cryptography, and the program works well when I use affine coordinate system, which means each point is represented by 2 coordinates (x',y'). Now I'm trying to replace affine coordinate system by…
Allopopo
  • 171
  • 1
  • 9
9
votes
1 answer

Which of the Elliptic Curves are supported for the Rancher Kubernetes certificates?

Problem I have generated keys and certificates by OpenSSL with the secp256k1, run rke version v1.2.8 from the Rancher Kubernetes Engine (RKE), and got the following error: FATA[0000] Failed to read certificates from dir [/home/max/cluster_certs]:…
Maxim Masiutin
  • 3,991
  • 4
  • 55
  • 72
9
votes
2 answers

How to encrypt and decrypt data in Android using the elliptic curve key pair of type secp256r1?

I need to use NIST P-256 elliptic curves to encrypt and decrypt data. Now that I have generated the key pair, but how do I use them to encrypt and decrypt? The official website only says how to use this ec key pair to sign/verify, but I want to know…
gopher
  • 89
  • 1
  • 6
9
votes
2 answers

Parse Armored ECC public/private keys (generated from gpg cli) in java

I'm trying to convert an armored ECC gpg key to corresponding java class ECPrivateKey/ECPublicKey. To generate the key pair I'm using: gpg --expert --full-generate-key Then selecting (9) ECC and ECC (or (10) ECC (sign only)) Then selecting (3)…
1
2
3
45 46