# Tagged Questions

An asymmetric cipher is an encryption scheme using a pair of keys, one to encrypt and a second to decrypt a message. A special class of asymmetric ciphers are public-key ciphers, in which the encrypting key need not be kept secret to ensure a private communication.

98 views

### Could this “symmetric RSA” scheme provide key compromise resistant communications?

This question, and fkraiem's answer to it, made me wonder about the security and practicality of using "symmetric RSA" to provide a partially compromise-resistant secure channel. Specifically, assume ...
59 views

### Does a “commutative” asymmetric system exist?

Completely crypto noob here. I'm looking for a cryptosystem made of a func f + key1 + key2 such that they satisfy: g(f(msg, key1),key2)=msg g(f(msg, key2),key1)=msg key1 != key2 Does such a ...
4k views

### Diffie-Hellman Key Exchange with Authentication: Man-in-the-Middle query

I have been reading up on MiTM attacks, and the prevention of them using public key certificates. Recently I learnt about Diffie-Hellman Key Exchange with Authentication, and how it uses signed ...
136 views

### Private and Public Keys

I have a very basic understanding of encryption and the encapsulation process, but for the life of me I can't grasp how public keys and private keys work, how they're made, and how they're exchanged. ...
58 views

### Convert messages to elliptic curve points [duplicate]

Let $E$ be an elliptic curve; $\alpha,\beta$ two points of $E$; and $a$ a private key such that $\beta=a\cdot\alpha$. We choose random integer $k$ and plain text $x\in E$. Encryption and decryption ...
91 views

### Would it be better to use HKDF or SCrypt for deriving a child key?

Okay so I'm trying to derive a child public key from an EC public key. I've come up with a couple ideas and now I'd like to know which is more secure. Mp: The master key pair, this includes a ...
443 views

### How does RSA compute such enormous numbers?

So I have been reading and learning a lot about cryptography lately and in particular asymmetric ciphers such as RSA. One thing that I am curious about but never seems to be mentioned is how the ...
113 views

### end-to-end encrypted chat app with symmetric + public key encryption, TLS and cert pinning

A big drawback of end-to-end encrypted messaging services is that, as soon as you lose your device, you lose all your messages. Your private key is gone after all. I was wondering though, wouldn't it ...
87 views

### Does rsa-oaep provide or not plaintext integrity in addition to confidentiality?

My own understanding (possibly wrong of course) of RSA-OAEP encryption scheme is that it provides plaintext integrity (in addition to confidentiality) due to MGF function which for encryption ...
202 views

### How is El Gamal different from Diffie Hellman Key Exchange [duplicate]

I am Reading RSA and Public-Key Cryptography by Mollin and I can't make out how El Gamal is different from Diffie Hellman Key Exchange. Any thoughts?
4k views

### Advantages using Diffie-Hellman or ElGamal

For what kind of usage should we prefer using Diffie-Hellman in order to exchange keys instead of ElGamal, and most important why should we use one or the other? I do not see a clear difference ...
106 views

### How does encryption work in elliptic curve cryptography?

So I think I understand a good amount of the theory behind elliptic curve cryptography, however I am slightly unclear on how exactly a message in encrypted and then how is it decrypted. So my ...
158 views

### When/why is RSA (hybrid) encryption used rather than alternatives?

I've read that RSA is not meant for encrypting large plaintext because: (Are these also true for other public-key encryptions like ElGamal?) It is slow. Padding makes the ciphertext blocks much ...
207 views

### Modular exponentiation on calculator for textbook RSA

How do you encrypt $51$ with public key $(n,e) = (91,23)$ I understand that $c = 51^{23} \bmod 91$. How can I calculate the result on a calculator?
15k views

### How can I use asymmetric encryption, such as RSA, to encrypt an arbitrary length of plaintext?

RSA is not designed to be used on long blocks of plaintext like a block cipher, but I need to use it to send a large (encrypted) message. How can I do this?
109 views

### How long can a RSA public key be?

If I create an RSA of 4096 bits, what would be the range of the length in bytes of the public key in DER format? Also, will the private key always be exactly 4096 bits (512 bytes)? Does the public ...
225 views

### How do I get the equivalent strength of an ECC key?

I know how to calculate the comparable symmetric strength of an RSA modulus: calculate the running time for a field sieve. This is how NIST gives approximate symmetric sizes for asymmetric algos in ...
120 views

### Why is Paillier Cryptosystem called probabilistic?

The definition of Paillier Cryptosystem says that it is a probabilistic asymmetric key algorithm for public key cryptography. Can some body explain why it is called "probabilistic"?
199 views

### Secure, patent-free alternative to NTRU

I'm working on a P2P communications and chat framework, and am looking for a quantum-secure asymmetric key exchange algorithm which I can use to perform a key exchange of an AES-256 bit key. This is ...
61 views

### Re-sending captured encrypted data

Let’s assume Bob is some algorithmic stock trading machine. Bob takes commands from Alice, who sends messages to Bob. For example: Alice could be sending a message to Bob to stop trading. But if ...
51 views

### Can the original message be retrieved from a public/private key signature?

When I sign a message (which has potentialy low entropy) using a private key and I send it without the original message, can the original message be retrieved from the signature(s)? I want to prove – ...
226 views

### Lightweight Asymmetric encryption algorithm

I'm an embedded systems researcher, and new in the crypto field. Actually, I need to know if there are any lightweight asymmetric encryption algorithm especially considering the time needed for key ...
109 views

### Managing data access through asymmetric cryptography

I want to manage authorization, as 3rd-party permissions, through asymmetric cryptography. I'm concerned about how it is possible to share access of encrypted data with N entities, be able to revoke ...
64 views

### Compromise between HMAC and Digital Signature, by encrypting and sending secret key?

For achieving stateless authentication tokens (like JWT), is there a compromise between the performance of HMAC, and public key distribution of Digital Signature? Scenario: Sender is a centralized ...
342 views

### Knowing pre-encryption data, can we find the private key CryptoWall used?

I'm just repurposing a question already asked about Cryptolocker for CryptoWall: "If we know exact contents of some of the files prior to them being encrypted, would it be feasible to use those ...
121 views

### What is the difference between RCCA and CCA2?

Well, I know it's easy to tell CCA1 from CCA2, but I failed to find the difference between RCCA and CCA2. What is the difference?
85 views

### What is the purpose of Pseudorandom Function Families (PRFs)?

I'm currently in a course in Cryptography, and was wondering why pseudorandom function families exist at all. If there existed one pseudorandom function f(x), based on its definition, could that not ...
308 views

I am working on this exercise but can't work out the answer to the question b. I have solved the question (a) by decrypting the ciphertext $C = 2$ using the formula: $$M = C^d \bmod n = 2^{17} \bmod ... 3answers 642 views ### What is the appropriate public key encryption for secure coin flipping? I quote Bobby's question here since I encountered the same one... Random Coin Flip using ElGamal and a Trusted Party Consider the following protocol for two parties to flip a fair coin. Trusted ... 0answers 24 views ### Generating keys in RSA [duplicate] I'm trying to learn how RSA works. From what I found online, I'm supposed to generate private key using Extended Euclidean algorithm. I've managed to generate the public key, but don't know how to ... 0answers 32 views ### Is it possible to re-generate ECPublic key from raw private key and curve params? As per my understanding, in Elliptical curve cryptography, the EC PrivateKey is nothing but a bigInteger value. If you know the curve specs and you have this private BigInteger value (which I am ... 0answers 83 views ### What type of encryption scheme can prevent cheating in this coin flip protocol? [duplicate] Consider the following protocol for two parties to flip a fair coin: Trusted party T publishes her public key p_k A chooses a random bit b_A, encrypts it under p_k, and announces the ... 0answers 63 views ### MITM Attack on Key Exchange Protocols I was doing research on this attack and I am wondering, why is Diffie-Hellman always associated with such an attack? ​ Aren't other public key cryptography schemes vulnerable to the same kind of ... 1answer 89 views ### Usefulness of Damgård–Jurik I am trying to understand what are the benefits of using Damgård–Jurik over Paillier. I understand that expansion factor decreases as s increases. But isn't it the ... 2answers 184 views ### Is my protocol that uses hybrid cryptography and AES-GCM secure? I'm having a lot of trouble trying to understand how to implement AES-GCM. My usecase: Person A sent me a file with a gauranteed unique name. I want to be assured it was from person A, and that no ... 2answers 128 views ### Random Coin Flip Quoting an old question: Consider the following protocol for two parties A and B to flip a fair coin (more complicated versions of this might be used for Internet gambling): A trusted ... 0answers 42 views ### How do I prove that a bit by bit PKE scheme (that is IND-CPA secure) for an n-bit message is not IND-CCA-2 secure? Gen generates Pk and Sk (l bits each), Enc encrypts m (length l) but by bit using each bit of Pk respectively, Dec decrypts ciphertext bit by bit using each bit of Sk respectively. How do I prove this ... 1answer 60 views ### RSA Optimal Asymmetric Encryption Padding Beginner I'm new to the OAEP scheme. I learn it from the Wikipedia page. Link The page does not explain a proper setup for of the system. So I'm not sure if the output of the padding scheme which contains ... 0answers 23 views ### Does OEAP padding limit the size of my modulous to the size fo the hash function? im looking at wiki at the moment as how to use oeap padding and it appears, help me out if im wrong as G(r) - expands r to the size of the padded message, I am then limited by the size of my hash ... 1answer 47 views ### Perfect Forward Secrecy in PGP/asynchronous email Looking at the RFC for PGP email/asynchronous chat with PFS here https://tools.ietf.org/html/draft-brown-pgp-pfs-03 can anyone tell me why the following scheme is no good? Alice and Bob retrieve each ... 1answer 116 views ### Cryptography of numbers Is there any algorithm capable of encrypt securely (symmetric) N numeric digits in a numeric message of M digits (N < M)? I am especially interested in a specific case in which N = 10 and M = N + ... 1answer 122 views ### Are there comprehensive alternatives to RSA? If we wished to, is there a comprehensive alternative to RSA? I say comprehensive as I wonder if there is one which does both encryption and digital signature like RSA? If not, simply what ... 2answers 689 views ### Signature schemes for underpowered devices (8bit microcontroller) I am currently researching into a small scale home automation system, aiming for cost. The system architecture is basically one master and several slaves which are connected in parallel. Recently ... 1answer 98 views ### RSA: must d be an integer? I am only taking baby steps in RSA. If p=11, q=7 and e=3,$$\phi(n) = 10*6 = 60$$Then:$$d = (2 (\phi(n)) + 1 ) / 3 = 121/3 Should $d$ be kept as a non-integer or is such a $d$ invalid? ...
160 views

Suppose I want to keep a client's password database secure (not in plaintext), while still having access to the plaintext password. Now I generates a public/private keypair. Then I send the public ...
151 views

### Confused about how chosen ciphertext attacks work?

When performing a CCA, the adversary gets the public key. At some point, he will send a message m to the challenger, and the challenger will send back either $E_{pk}(m)$ or $E_{pk}(r)$, where r is ...
39 views

### David Chaum's anonymous credential

I am a newbie in cryptography (I know the basic RSA, AES stuffs) and am interested in anonymous authentication systems. Looks like David Chaum is the godly figure in the field. I see lots of people ...
89 views

### Exactly how slow is asymmetric encryption?

I'm currently doing a project on RSA, and have just come across this website. https://www.namecheap.com/support/knowledgebase/article.aspx/798/67/what-is-an-rsa-key-used-for On here, it says that ...
81 views

### Is there a way to do single key-pair asymmetric encryption?

All of the information on asymmetric encryption I can find uses key-exchanging to get a mutual symmetric key. What I am trying to do is encrypt a message with a public key and have it only readable ...
10k views

### How can one securely generate an asymmetric key pair from a short passphrase?

Background info: I am planning on making a filehost with which one can encrypt and upload files. To protect the data against any form of hacking, I'd like not to know the encryption key ($K$) used for ...