Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Join us in building a kind, collaborative learning community via our updated Code of Conduct.

The Diffie–Hellman key agreement is an anonymous, non-authenticated key-agreement protocol.

0
votes
0answers
22 views

ECDH: create Public Key from x, y coordinates [on hold]

I have the x, y coordinates of a EC public key ( i have the bytes also ). I need to convert the x,y coordinates bytes into a ECPublicKey. ...
2
votes
0answers
35 views

How many qbits are required to break Diffie-Hellman over a multiplicative group

There have been comparisons between RSA and ECDH with regards to the number of qbits (qubits) required to break the algorithm with a specific key size. But how many qbits are required to break "...
0
votes
0answers
31 views

Can anyone explain the mathematics behind Elliptic curve Signature generation and verification(ECDSA)? [on hold]

I know that there are two components r and s in a signature but I am trying to understand what are these values in terms of elliptic curve co-ordinates, the curve equation and also modular arithmetic ...
0
votes
2answers
35 views

Good Diffie Hellman Encryption Method

I've just made my own implementation of Diffie Hellman in nodejs (its for a project of mine). However the shared keys are integers, I want to use those integers as a key to encrypt data. This is an ...
0
votes
0answers
29 views

Key Agreement, one end Bouncy Castle, the other end OpenSSL/TomLibCrypt [on hold]

I am struggling like mad, I have an existing system using tomlibcrypt to verify a key agreement, and when running key agreement in openSSL the two agree byte for byte on the shared key. However when ...
2
votes
2answers
113 views

AES and ECDH key

I am trying to understand public key encryption. I found the table below in a paper online. I am struggling to understand the meaning of this. From the bits and pieces read, I am tempted to think that ...
1
vote
0answers
38 views

Securing MQTT communication

I am building kinda simple IoT project, but I would like to implement good security (just for educational purposes and fun). My plan is to build simple solution where one arduino board reads some data ...
1
vote
0answers
70 views

ECC Curve25519: How to generate this kind of private key? / Strange key exchange mechanism

I'm currently reverse engineering a program that uses Curve25519 key exchange in network communication. I have only a basic understanding of ECC, so maybe this thing just seems strange to me. The ...
2
votes
1answer
66 views

The compression of the eliptic curve point coordinates

Some time ago I faced the problem of the unexpected format compression of the points on elliptic curve. I used ECDH procedure with a third party service on the base of the $\mathbb({F}_{2^m})$ curve ...
-2
votes
1answer
32 views

Diffie Hellman Key Exchange Security wrt the hardness of discrete Logarithm

Hi I am very new to this field and I was wondering how one would prove or disprove the following statements: 1) if the DH key exchange protocol is secure for a finite cyclic group G, then computing ...
1
vote
0answers
23 views

GPG encrypt performance degradence for thousands receipients

I plan to use GPG to encrypt a small file (32KB) for very many recipient public keys (few thousands). I tested GPG with RSA and then ECDH public key encryptions. If RSA is very slow, with ECDH (nist ...
1
vote
2answers
80 views

Are there benefits for using Static Diffie-Hellman over Ephemeral Diffie-Hellman?

TL;DR - Are there any benefits to using static DH over ephemeral DH? I'm reading about the differences between static DH & ephemeral DH and I am trying to think of one logical reason to use ...
0
votes
0answers
31 views

What protocols are secure under computational and decisional diffie hellman assumption respectively?

I am new to crypto, and I have read the definitions of Computational Diffie-Hellman(CDH) and Decisional Diffie-Hellman(DDH) assumption, though I tried to figure out the differences between the two ...
2
votes
1answer
121 views

Finding missing bits mathematicaly in a DLP situation (full problem)

In a preparatory question we had to recover decimal digits $@$ of $r$ and $s$ given $g=51234$, $h=90403$, $N=111649$, $r=3@497$, $s=276@3$, with $r$ and $s$ the smallest positive solutions to $g^r\...
2
votes
1answer
91 views

Finding missing bits mathematicaly in a DLP situation

Here is a DLP exercice $g = 51234,\; h = 90403 ,\; N = 311 \cdot 359 = 111649$. Define $r$ as the smallest positive integer with $g^r \equiv h \pmod N$. Define $s$ as the smallest positive integer ...
0
votes
1answer
52 views

Differences between ECIES and DHIES

I'm studying the Integrated Encryption Scheme and I did't understand which are the main differences between ECIES and DHIES. Can someone help me ? Thank you in advance.
3
votes
1answer
62 views

Breaking a small-scale Example Diffie-Hellman?

I started to read about Diffie-Hellman exchange and I encountered a problem which I don't know how to solve. Given $g=3$, $p=131$, $g^x\bmod p=112$, $g^y\bmod p=74$, compute $g^{xy}\bmod p$ $113$ $...
-1
votes
1answer
80 views

ECDH over secp256k1 implementation

I'm using ECDH over secp256k1 in multiple languages, and I saw something a little weird in the rust library I use. After the point multiplication it changes y to <...
0
votes
1answer
53 views

Anything known about this variation of Diffie-Hellman key exchange protocol?

I'm considering a variation of the Diffie-Hellman key exchange protocol based on integer modular multiplication in place of exponentiation. If done naively, that would obviously be insecure, but I'm ...
2
votes
1answer
52 views

Understanding the q-SDH Problem (on elliptic curves)

I have some troubles in understanding the q-SDH problem. The discrete logarithm problem states the following. Given a point P of order on an elliptic curve and a point Q on the same curve. It is hard ...
4
votes
0answers
43 views

Where do the PKs come from in Bluetooth device?

I am studying the Elliptic Curve Diffie-Hellman (ECDH) on Bluetooth 4.2. There are some questions about the PK.. Where do these public and private keys come from? Who defines them? and Will it ...
1
vote
1answer
59 views

prove PRG is secure assuming DDH holds

Let $\Bbb{G}$ be a cyclic group of prime order $q$ generated by $g \in G$. Let $G$ be a PRG defined over $(\Bbb{Z}_q^2, \Bbb{G}^3)$ such that: $G(a, b) = (g^{a}, g^{b}, g^{ab})$ How can I show ...
3
votes
2answers
95 views

Questions about the double ratchet mechanism in Signal

I am trying to understand the threats the double ratchet system is trying to prevent against. The threats mentioned in the paper do not quite make sense to me. May be someone can explain where I am ...
2
votes
2answers
103 views

Does Diffie Hellman guarantee secrecy?

I am studying my Cryptology exam and one question I got stuck below; Recall the Diffie-Hellman key establishment protocol. Alice runs this protocol over the Internet to communicate with Bob. ...
9
votes
1answer
832 views

After ECDH with Curve25519, is it pointless to use anything stronger than AES128?

Is the following reasoning correct: After ECDH with Curve25519, the resulting shared secret will be an EC public key with a bit strength of 128 bits. This public key would then be hashed (let's say ...
2
votes
1answer
80 views

About DDH over cyclic group Z*p^2

To construct a secure multiparty computation function, we need to use the cyclic group G = Z*p^2 with p is a large prime. However, we are uncertain that DDH holds over this group. Can you show that ...
1
vote
2answers
62 views

Let $ALG_2$ be an algorithm that solves the RSA problem, can it solve the generalized Diffie-Hellman problem?

Let $ALG_2$ be an algorithm that solves the RSA problem for all $e\in \mathbb{Z}_n^*$ i.e given $e,m^e,n$ then $ALG_2(e,m^e,n)=m$. Is it possible to use this algorithm to solve the generalized Diffie-...
4
votes
0answers
74 views

Encrypt using ECDH with two different EC public keys, minimizing payload size

Let's say Alice has the private EC keys $a$ and $b$, with a base point of prime order $G$. Alice computes the corresponding public keys $A = aG$ and $B = bG$, and sends them to Bob. Bob now wants to ...
0
votes
2answers
103 views

Why is RSA preferred over Diffie-Hellman if they're both used to establish shared key?

I've read that the RSA algorithm is preferred over Diffie-Hellman key exchange as it makes key management easier. In the context of online banking, before the RSA algorithm they would have to maintain ...
4
votes
1answer
45 views

Lightweight primality certificates for untrusted DH parameters

Are there any light-weight techniques to generate primality certificates for custom Diffie-Hellman parameters that could be sent to the client to allow it to verify primality without needing to run ...
10
votes
2answers
1k views

How do malware rely safely on ECDH algorithm to maintain secrecy of keys?

In traditional malware (especially ransomware) using RSA approach, the public key may be hard-coded in the malware binary and is used to encrypt a symmetric key generated on the system. The symmetric ...
2
votes
0answers
150 views

What ECDSA key is used to sign the ECDHE key exchange?

I have a server using TLS1.2 with an ECDSA certificate using secp256r1. The algorithms being used to connect to my browser are TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 as I expect from my server ...
2
votes
0answers
50 views

Is it secure to encrypt with EC “for myself”? [duplicate]

I want to encrypt some small amount of data using ECDH for use by myself later, but I don't want to generate an ephemeral keypair like in ECIES, due to time and space constraints. Would it be safe to ...
1
vote
1answer
49 views

Example of calculating a primitive root for large prime?

I am trying to figure out how to calculate primitive root $w$ for a prime. Following what I read, I generated my prime to be 'safe prime', $p=qr+1$. I know $q$ (also prime) and $r$. Let's assume, ...
2
votes
1answer
28 views

What should be broken to break a cipher with perfect forward secrecy?

What should be broken to break a cipher with perfect forward secrecy as a passive observer? RSA/EC analog, (EC)DHE or both?
2
votes
0answers
49 views

Are there any one-way operations that could be used for Diffie-Hellman post-quantum? (See criteria)

With quantum-computers looming, there is a need for Public Key Cryptosystems that can withstand attacks by quantum-computers. Are there any known one-way operations that fit the following criteria? ...
1
vote
2answers
311 views

Why is a Diffie-Hellman key exchange required when RSA is already being used for key exchange in TLS?

Specifically with TLS, What is RSA used for during key exchange? What is Diffie-Hellman used for? Since RSA already provides authenticity and confidentiality, why is Diffie-Hellman used during the ...
0
votes
1answer
84 views

Finding the Shared Key In DHKE

I am trying to work out the shared key between Alice and Bob in DHKE equation. The generator is 7 and the Prime P = 71. Bobs private choice of number is 28 and he also receives g ^ A = 70 from Alice. ...
0
votes
1answer
62 views

EL gamal cryptosystem

I have this question which gives me q=71(my prime number) , a=7(generator), Yb=3(public key), m=30(message), c1=59(first cipher text) and he wants me to find c2 (second cipher text) I know that c2 = ...
0
votes
1answer
34 views

Breaking a modified version of Diffie Hellmann Protocol

I'm modifying the Diffie Hellman protocol as follows: We are given a large prime number $p$ and exponent $x$ such that $0 \lt x \lt p-1$ and $\mathrm{gcd}(x, p-1) = 1$. Also we pick $g$ such as $1 \lt ...
3
votes
1answer
117 views

How hard is the following q-Strong Diffie-Hellman problem?

From On the $q$-Strong Diffie-Hellman Problem, the following problem is well-known to be hard. For an randomly chosen element $x \in \mathbb{Z}_p$ and a random generator $g \in \mathbb{G}$, the ...
0
votes
1answer
35 views

A method to receive payments at obscured addresses [closed]

The background: We assume that coin ownership and payments are recorded on a public ledger. Suppose Alice wants to publish some information to let her receive coins from anyone. But she does not want ...
0
votes
2answers
73 views

Does AES-GCM without security tag turn into regular CTR Mode?

We are looking to implement a simple password based key agreement scheme. Part of this is deriving a symmetric key from a common passphrase known to both parties involved. This symmetric key is then ...
0
votes
2answers
245 views

AES encryption using a Diffie-Hellman question

this is something that has always nagged at me and I've wanted to know the answer to. Does AES create it's own shared secret symmetrical key after the DH process has completed? I'm not as familiar ...
0
votes
1answer
85 views

Diffie Hellman vs Three Pass Exchange

Given an insecure channel, what are the pros and cons of using Diffie Hellman to generate a symmetric shared key and then send encrypted data with this key, or simply use Shamir's three-pass protocol ...
0
votes
0answers
27 views

Questions regarding the concept of encrypting a device's USB communication

I'm trying to understand the following two images. They describe the Initialization and authentication process of an embedded device that supports encrypted USB communication. In the first image the ...
4
votes
1answer
84 views

How secure is ECDH if the public keys are never changed?

I have a scenario where I'd like to use Diffie Hellman keys where the public keys are exchanged once and then never changed. So server generates a key pair (secp256k1 or secp256r1) and sends its ...
3
votes
1answer
187 views

Varying ECDH key output on different ECC implementations on the secp256k1 curve

Like the title says, I have used several implementations of ECDH, and I have found a discrepancy with libraries that wrap ...
3
votes
1answer
107 views

difference between the math of RSA problem and DH problem

I'm trying to understand why the RSA problem is not related to the Discrete Log problem, and how breaking the Discrete Log problem does not directly compromise RSA. I will explain my reasoning of why ...
2
votes
1answer
65 views

Supersingular isogeny Diffie–Hellman key exchange (SIDH) Library Support AES-256?

In the version 3.0 of the SIDH library, it implements SIDH/SIKEp503 (AES-128) and SIDH/SIKEp751 (AES-192) only. Are there plans to incorporate AES-256? Nathan Aw