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

Questions tagged [public-key]

An asymmetric cipher is an encryption scheme using a pair of keys, one to encrypt and a second to decrypt a message. This way the encrypting key need not be kept secret to ensure a private communication. Similarly in public key authentication, the verification key can be public and the signing key ...

2
votes
2answers
48 views

Why ECDSA has its form?

According to Wikipedia, if Alice wants to sign some message, she computes $s = k^{-1} (z + r d_A)$ then sends $(r, s)$ to Bob. I don't understand why they use this particular formula $s = k^{-1} (z + ...
0
votes
0answers
44 views

Diffie-Hellman exchange problem

I am having trouble to solve this Diffie-Hellman Key Exchange Problem. Imagine you are sniffing the communication between Carl and David. You are getting the domain parameters $p$ and $g = 5$ used ...
1
vote
0answers
20 views

Where does one store 3rd-party Public Keys

So, I've just started looking at the subject of Cryptography and am working through Stephen Haunt's Practical Cryptography course on PluralSight but have a question that doesn't appear to be covered. ...
1
vote
2answers
111 views

How to define a FHE scheme whose plaintext space is infinite using boolean circuits?

There are many kinds of fully homomorphic encryption scheme by using boolean circuits. And the plaintext space $\mathcal{P} = \{ 0,1 \}$. If there is a -bit FHE scheme, we can construct a FHE scheme ...
0
votes
1answer
130 views

RSA encryption/decryption process is not working correctly

I'm trying to apply the RSA cryptosystem to encrypt a byte M=72, using predefined modulus n, public key exponent ...
0
votes
1answer
166 views

Using secp256k1 keys for encryption

We are making a system where users can share files with other people but nobody should be able to figure out that all these different files belongs to same user on blockchain. these are the steps we ...
5
votes
1answer
233 views

Is a transposition cipher categorized as asymmetric algorithm?

Consider a simplest transposition cipher, such as one with block size 8 and encryption key 43725681, the decryption key will be 84215637. As the keys are different, may I say a transposition cipher is ...
2
votes
1answer
261 views

SSL - encrypt with private key and then with public key?

Say there are 2 sides that wish to communicate: side A and side B. Let's say we are looking at side ...
0
votes
1answer
30 views

The goal, the method, and the interface of the signcrypt primitive.

Some time ago, I proposed making the site more educational by teaching correct cryptographic programming. The proposal had had somewhat good reception, but was met with cold ice as there had been ...
10
votes
1answer
149 views

How does the process of creating a new secure Elliptic Curve look like?

I'm especially curious about the technique djb would have used to come up with his Curve 25519. Say I have already written down my goals, such as - Twist Secure, Speed, Side Channel resistance, etc. ...
2
votes
1answer
44 views

RSA engine with inaccessible private keys - susceptible to any attacks?

We are going to integrate some hardware accelerator for RSA into our next system on chip. This chip can accelerate the core RSA operation, i.e. modular exponentiation $y=A^x \mod(N)$. The private key (...
0
votes
1answer
42 views

Format of hybrid crypto envelope structure?

From posts including the accepted answer to How to encrypt file with RSA and AES that anyone with RSA key can decrypt them? hybrid crypto (AKA envelope encryption) a GPG-encrypted file has an ...
0
votes
1answer
42 views

Send content to owner of gpg public key, nested content symmetric encryption

If I want to encrypt a text content file using a symmetric algorithm like AES, is there a standard format gpg will expect, where it can detect a symmetric key (encrypted with recipient gpg public key ...
2
votes
1answer
23 views

Patterns flaw to sign a counter with public key encryption protocol

In modern asymmetric encryption protocol, like secp256k1, are there any flaws if you want to sign a counter? i.e: use a private key to sign from 1-n is that any chance make n+1 easier to guess?
4
votes
1answer
156 views

Zero knowledge proof for Paillier addition under multiple keys

Suppose $m_0, m_1, m_2 \in \mathbb{N}$ such that $m_0 = m_1 + m_2$, $m_i > 0$ (none of them can be 0 or lower) Under a Paillier cryptosystem, set $e_0 = E(m_0, r_0)$ for a public key $(g_0, n_0)$ ...
1
vote
1answer
36 views

Why does DH-EKE require that public keys be indistinguishable from random?

The introduction to SPAKE pre-authentication states: Diffie-Hellman Encrypted Key Exchange (DH-EKE) is the earliest widely deployed PAKE. It works by encrypting the public keys of a Diffie-Hellman ...
3
votes
1answer
116 views

Performing a dictionary attack on RSA/ECB with no padding

I have the exponent $e=2^{16}+1$ and modulus $n$ (154 digit number) of an RSA public key along with the ciphertext (64 bytes) encrypted using the same key with RSA/ECB and no padding. I am required ...
48
votes
2answers
28k views

Impacts of not using RSA exponent of 65537

This RFC says the RSA Exponent should be 65537. Why is that number recommended and what are the theoretical and practical impacts & risks of making that number higher or lower? What are the ...
1
vote
2answers
89 views

How to calculate Trace function for a point on an elliptic curve

I encountered trouble with calculating Tr (trace function) for points on an elliptic curve in polynomial basis ( $GF(2^m), m = 431$). Maybe there are any assumptions that can simplify and allow ...
2
votes
3answers
49 views

For elliptic-curve cryptography, does a 256-bit key imply that $x$ and $y$ are each 256-bits or 128-bits?

In the wikipedia article, the claim is made that "256-bit elliptic curve public key should provide comparable security to a 3072-bit RSA public key". Since, in ECC, the public-key consists of a point $...
0
votes
2answers
88 views

A private key with multiple public keys?

I'm trying to design a wallet, where any number of public keys can be handed out. Say Alice hands out the public keys to receive messages. She doesn't want others to be able to link all of the public ...
4
votes
0answers
30 views

Difference between Secure Boot and Attestation [migrated]

What's the exact difference between secure boot and device attestation. Nowadays with secure devices both are used, even at the same time, when in the core they do similar things, which is ...
8
votes
3answers
3k views

How many KDF rounds for an SSH key?

What is the best practice on choosing how many key derivation function (KDF) rounds/iterations when generating an SSH key pair? Am I correct in saying that it is unnecessary if the passphrase is ...
2
votes
0answers
107 views

What standards of ECC point compression exist?

The method that I used before to decode EC point from public key led me in a dead end. So I just want to know what yet I could try. I've got a public key that I don't know how to decode and I am ...
2
votes
2answers
82 views

Limiting how many key pairs someone can generate without compromising their keys

Is there any way to assign someone a limited quota for how many cryptographic key pairs they can generate (ECC, RSA, any algorithm), and preferably non-interactively? By non-interactively I mean there ...
0
votes
1answer
40 views

Why does the Node crypto library do Diffie Hellman this way?

I was sifting through the Node Crytpo library and I came across their Diffie Hellman utility class. Their class implements a generateKeys function that, in their ...
44
votes
3answers
24k views

Definition of textbook RSA

What is the definition of textbook or "raw" RSA? What are some of the properties of textbook RSA? How does it differ from other schemes based on RSA?
2
votes
1answer
46 views

How to encrypt sensitive files in a business application? Is it needed?

I'm currently working on a business Java application, and we store sensitive files related to our users. What is the appropriate approach to store them securely? Is it viable to encrypt/decrypt all ...
4
votes
1answer
848 views

DGK Cryptosystem Key Generation and Decryption Issues

I detailed here the DGK (Ivan Damgård, Martin Geisler and Mikkel Krøigaard) cryptosystem, and I managed to get it to work, most of the time... The BIG problem that I am facing at the moment is that ...
2
votes
1answer
730 views

DGK Cryptosystem Encryption Speedup

Following @poncho's nice clarification of the RSA speedup here, let's see if I'm able to do the same in the case of the DGK cryptosystem: We have pk = (n, g, h, u), sk = (p, q, $v_p$, $v_q$) which ...
0
votes
0answers
45 views

Size of group for Elliptic curves vs RSA for equal security

For my research, I would like to compare the efficiency of a scheme when instantiated with Elliptic curves and RSA. So, I would like to know a "latest" comparison (as of 2018) on what group sizes of ...
3
votes
1answer
591 views

ElGamal encryption and signature using same keys

In ElGamal scheme we have message $M$; $p$, $g$ and $y=g^x \bmod p$ as public key where $x$ is unknown private key. Encrypted message $(c,d)$, where $c=g^k \bmod p$ and $d=M \cdot y^k \bmod p$. ...
0
votes
1answer
58 views

RSA How to select a value K such that $e d = 1 + k \varphi(N)$ holds

I am learning RSA cryptography. The part I am stuck on is understanding how k and the public exponent $e$ is selected. Given the formulas; Decrypting: $c^d \bmod N = (m^e)^d \bmod N$ Which is equal ...
0
votes
0answers
31 views

MTI authenticated key exchange protocol and their vulnerabilities?

Can someone please explain the different MTI key exchange protocols (A0, B0, C0, C1) and their vulnerabilities. I've been trying to read about them but couldn't get much information.
2
votes
1answer
63 views

Detect MITM with hashed session-key — Is my protocol secure?

I have the following setup: An app ("client") wants to communicate securely with a device I created ("server"). The client has the public key of the server (and a hashed password) preinstalled. I use ...
4
votes
2answers
106 views

Cryptographic scheme where a single message cannot be decrypted but if combined with other it can be

i'm wondering if this type of cryptographic scheme does exists. I know about homomorphic encryption but if one has the private key, he can decrypt every single message. I would like to know if there ...
6
votes
2answers
281 views

Do standalone Oblivious Transfer (OT) Protocols exist?

Are there any Oblivious Transfer (OT) protocols that don’t rely on asymmetrical encryption, public-key encryption or key-exchange? I’m starting to wonder, as all the OT protocols I know of (and can ...
0
votes
1answer
44 views

Is the only use for the private key of a root certificate signing certificates issued by it?

A root certificate can be used to issue intermediate certificates. The private key of the root certificate is needed in order to sign any intermediate certificates. However, after that, we only need ...
2
votes
1answer
125 views
1
vote
1answer
42 views

What are the different use cases between an HMAC and digital signature? [duplicate]

I understand that both an HMAC and digital signature are used to check the integrity and authenticity of a message. Further, I understand that a digital signature is non-repudiatible. What I do not ...
0
votes
0answers
22 views

Existence of a NIZK proof demonstrating that a ciphertext does not encrypt some specified plaintexts

Given a (El Gamal, for instance) ciphertext, can I (efficiently) prove that the ciphertext does not decrypt to plaintexts in a small set? For instance, given ciphertext $c = Enc(pk,2; r)$, can I (...
1
vote
1answer
55 views

Is a digital signature of use if you don't also encrypt the message containing it?

I'm sure this has been asked before. Its just too blindingly obvious. from wikipedia "Digital signatures, in which a message is signed with the sender's private key and can be verified by anyone who ...
1
vote
0answers
25 views

TPM 2.0 Reissued EK Cert

Unlike the TPM 1.2 module, the TPM 2.0 specification allows the platform user to create own ...
2
votes
1answer
66 views

Does the public key and private key for WhatsApp only remain within a WhatsApp account

The world of cryptography is starting to really intrigue me admittedly. I initially hated it because it looked too hard Mathematically but now it looks cool :) Got a good question for the experts and ...
1
vote
1answer
62 views

How to exchange a secret through untrusted server in two steps?

I have a web application where I control the server, however, it should not have any knowledge of secrets that are exchanged between its users. This server holds RSA public keys of each registered ...
0
votes
3answers
91 views

How is public-key cryptography secure?

Quite strange question, but here goes: I don't quite understand how asymmetric encryption works. Take SSH for an example: The server will always be listening for commands, so anyone who has the ...
1
vote
0answers
60 views

Security of BLS under additional information on the secret key

Question A Is the BLS signature scheme still secure if an adversary in addition to the public key $ pk = g_2 \, sk \in \mathbb{G}_2 $ also obtains additional information on the private key $ sk $, ...
2
votes
2answers
63 views

How to ensure confidentiality of an encrypted but public message given that computation power increases?

Say I encrypt a message with the public key of a party whom I want to contact with and then send the ciphertext over an insecure channel. Naturally, an adversary who listens to this channel can ...
32
votes
5answers
11k views

Does RSA work for any message M?

I decided to read the original RSA paper A Method for Obtaining Digital Signatures and Public-Key Cryptosystem because of a question I had about RSA (which is not the question I'm about to ask, but ...
0
votes
1answer
78 views

Newbie question: one-way functions in cryptography

I'm reading this article on the basics of cryptography and it says that the main principle is about taking such an algorithm that knowing the end result and the algorithm, an eavesdropper wouldn't be ...