instruction stringlengths 32 27.2k |
|---|
In "Foundations of Cryptography, Volume 1" by Oded Goldreich, chapter 3.3.6 states the following theorem:
Let $G$ be a pseudorandom generator with expansion factor $l(n) = 2n$. Then the function $f\colon \{0,1\}^* \to \{0,1\}^*$ defined by letting $f(x,y) \stackrel{\text{def}}= G(x)$, for every $|x| = |y|$ is a strong... |
When we say a communication is secured by the latest version of TLS, can we say that Man-in-the-Middle attack is not possible? Do not consider the situations that we can down grade the communication protocol. With TLS, is it necessary the have certificate for the server?
|
Many encryption problems are fast to solve if a key, factor, exponent or something similar is known.
Other encryption methods don't have such keys. E.g. a hash value of another value. It's used because it is hard to determine which was the initial value. Computation time is needed for the solution. Is there a general ... |
Modern hardware and software disk encryption uses AES mode of operation. But XTS was designed to "pad" the last block when the disk sector was not divisible by block size.
However all typical disk sector sizes are divisible by AES block size (128bit). So does that mean that disk encryption uses XEX mode and not doing c... |
I have already done my research and found various sources that state that it is possible but there are also a lot of them that says it is not possible to recover $r$. This Q/A on this site for example even states the formula to get it. I don't know if it is wrong or I am missing something since I was not able to make a... |
I am studying the principles of RSA and have come across some unintuitive statements. Lets revisit the RSA algorithm:
RSA Key Generation
Output: public key: $k_{pub} = (n,e)$ and private key: $k_{pr} = (d)$
Choose two large primes $p$ and $q$.
Compute $n$ = $pq$.
Compute $\varphi(n) = (p−1)(q−1)$.
Select the public ex... |
I'm new to MPC. I was reading about it when I found an example that seemed to be trivial about how it works.
In the picture below, the way X1 sends its data to X2 is by generating a huge random number, add its number to it, and send this to X2. X2 will do the same by adding its value to what it has received, and then s... |
Alice and Bob need to share public keys to sign/verify ephemeral keys. They have a secret key $K$.
Alice generates a 32 bytes random number $A$, computes $\operatorname{HMAC-SHA256}(K, M||A)$ and sends Bob the hash and plain $M$, $A$
Bob computes $\operatorname{HMAC-SHA256}(K, M||A)$ to check the hashes
If hashes matc... |
As a newcomer to cryptography, I'm working on Exercise 2.12 in the book, Introduction to Modern Cryptography.
Using the proof of the theorem that says if $E$ is a perfectly secret encryption scheme, then $\lvert K\rvert \geq \lvert M\rvert$),
I've shown that the lower bound for the size of the keyspace is as below:
$$\... |
Fully Homomorphic Encryption (FHE) allows computations be done on ciphertexts. Can this technique be used to exchange keys?
For example, Alice and Bob need to agree on a 4-bit secret key. Alice sends Bob 4 different strings, which are ciphertexts for 0001, 0010, 0100, 1000, respectively. Now Bob chooses the secret key ... |
I try to reproduce the analysis conducted in this presentation by R. Lifchitz.
Namely, data signed by an 1024-bit key $n$ (Rabin scheme) and following ISO/IEC 9796-2.
From what I understand, for a message $m$ that went through an encoding function $\mu$, the signature $s$ is produced as $s=(\mu(m))^d \pmod{n}$, or mayb... |
To factorize N = p * q with p < q e (p-2) mod 9 = 0, there are a set of equations. These equations can be put into any popular math solver, in order to gain access to the primes p and q. For instance, the prime components of the public key N = 209 can be solved as follows:
[(h+1)^2]*[(2*h+2)^2/2-1] = X*(209-4-2*n+2*(p-... |
One of my professors mentioned in class that there is a way of using PKCS#7 padding to have the padding persistent after decryption.
For example, if I encrypt a 20-byte file using
openssl enc -aes-128-ecb -in input.txt -out encrypted.txt -K 0123456789 -v
I obviously get the padded difference of:
bytes read : 2... |
This machine has the stator, with one half of the alphabet, and three rotors with replications of the other half in different order and repeated twice. There can have two rotors in use or the full three. There is only two types of strips, SMA and SMB. These are used to differentiate what strips are used in the encrypte... |
Define a family of strongly universal hash functions as:
$$\forall x_1, x_2 \in \{0,1\}^n, \forall y_1, y_2 \in \{0,1\}^m, ~ x_1\ne x_2: ~~ \Pr_{h\in H} [h(x_1) = y_1 ~\text{and}~ h(x_2) = y_2] \le \frac{1}{2^{2m}}$$
if $h: \{0,1\}^n \rightarrow \{0,1\}^m$
and a family of $\delta$ universal hash functions:
$\forall x_1... |
I was going through this question Why is it said that if we have a duplicate ciphertext block it can leak our information? and I was just wondering
if there is a $P_i \oplus P_j= C_{i−1}\oplus C_{j−1}$ relationship, is CBC still secure?
How does this equality lead to information leak?
|
It has been shown that AES keys that are in use can be identified in memory. This identification relies on discovering expected round keys in memory that are contained within the key schedule.
My question is: can we, by extension, assume that the same technique, at least theoretically, can be used to extract Serpent a... |
The general definition of obfuscation is the process of obscuring a message (not necessarily source code). There is a "rigorous" method for obfuscation (indistinguishability obfuscation, extractability obfuscation) and a less rigorous one (spaghetti code, antipatterns, seldom used languages behaviours, ...). But is obf... |
I'm new to RSA and instead of using RSA to encrypt a symmetric encryption key to encrypt data with (although it might help to understand) I would like to use an integer ring with RSA.
My question is what are the minimum/maximum values of $P$ before being turned into $E$ cannot be recovered, and how can I encrypt with a... |
I'm trying to decipher a message encrypted by a substitution cipher (probably a monosubstitution). But the problem is, that we have symbols instead of letters (letters were substituted for random symbols). What would be the best way to decrypt such a message?
Thanks
|
Working through the Moni Naor's slides from his lecture Foundations of cryptography (Lecture 3), the slides state that the subset sum function is one-way on its iterates if it is one-way, where the subset-sum function is earlier defined as:
$f: \{0,1\}^{mn+n} \rightarrow \{0,1\}^{mn+m}$:
$$f(a_1, a_2, \dots, a_n, b_1, ... |
I wonder if there is a known hash function that for any $x$, $y$ which are numbers in a certain range with certain accuracy (I guess one can think of them as integers?), you can define two functions corresponding to addition and multiplication such that:
$h(x) \# h(y) = h(x+y)$
and
$h(x) \cdot\cdot h(y) = h(x \cdot y... |
I have been working with the following SDES Encryption templates and got the following as my ciphertext. I believe the ciphertext is correct because when I decrypted it I got my original plaintext.
If someone could inform me if the "encoded binary value is the ciphertext, and how do you convert this back to ASCII usin... |
Consider the following hash function based on RSA. The key < n, e > is known to the public. A message M is represented by blocks of predefined fixed size $M_1, M_2, M_3, ..., M_m$ such that $M_i < n$. The hash is constructed as: encrypt the first block, XOR the result with the second block and encrypt again, etc. For e... |
I understand that for AES CBC you need to split the plaintext up into blocks and perform XOR'ing using the previous blocks calculations etc.
However, if your message is exactly 128 bits long, do you only perform the XOR with the IV and the encryption with the key once? Or is there a way to split up a 128 bit message s... |
Assume we have $k = n + m$ bits string $S$ where the first $n$ bits are predictable, and the last $m$ bits are pseudorandom (the HMAC of the first $n$ bits + IV). Can we say $S$ is a pseudorandom number?
What can we call S exactly?
|
As mentioned here the verification of a Ed25519 signature takes roughly 3 times as the time for the generation of a signature. Two questions on that:
1) Can I assume that this is a rule of thumb for this algorithm? I can imagine that the ratio of the times differ for different CPUs
2) How can I exactly see (using the a... |
Let's say we have a set of numbers $n = \{ 1, 2, 3, 4, 5, \ldots \}$ and $m$ players ($m < \operatorname{sizeof}(n)$, of course).
I want to know if there's a way for all $m$'s to pick different numbers from $n$ in a way that it doesn't reveal which one did they pick or which ones were picked by the others.
|
On top of my mind comes caesar cipher, but that is not really secure
so what is the most secure encryption algorithm that doesn't affect entropy or even lowers it?
I know this might not be as secure as normal encryptions, but I'm asking about what is the most secure among these types of encryptions?
basically I have a... |
I am new to cryptography and I do not know how to prove the ECB mode is not chosen plaintext attack (CPA) secure.
|
tl;dr What does "d <= |Z|" mean in the context of bit array manipulations?
As a learning exercise I'm working on an implementation of SHA-3. I am not a cryptography specialist in any way but I have implemented similar algorithms in the past such as MD5 and SHA1, so I am roughly conversant with the kinds of operations... |
I'm thinking about ways to encrypt an endless stream of data (e.g. a video or audio feed) in a way, where a compromise of the current internal state of the encryption (e.g. a RAM dump) does not comprimse data encrypted earlier without knowing the seeding parameters (Key, IV). A stream cipher would be preferrable to a b... |
Following the Chow et al paper and Muir's tutorial, I was able to implement the AES algorithm using tables embedding keys of 128, 192 and 256-bit sizes, later extended to 1024, 2048 and 4096-bit sizes.
The original AES-128 WBC from Chow et al or Karroumi papers have a known BGE attack consisting $2^{22}$ work-steps (Yo... |
Let's say I receive a 1 MB encrypted file, but I get no information about the encryption method, and no password.
The only thing I can guess is that the person probably used a weak encryption method on a text file.
Are there ready-to-use software that will perform automatically a huge number of attacks on the ciphertex... |
I am building a computer program that deciphers Caesar, Vigenere and monoalphabetic substitution ciphers. All of those are susceptible to frequency analysis. However, it does not seem to be real-world applicable considering the complexity of the modern-day ciphers. Where else can frequency analysis be applied in the mo... |
I'm trying to sample HE ciphertexts which serve as ciphertexts encrypting some random values. I have realized a example program using Microsoft SEAL, which implements a variant of BFV scheme. Unfortunately, the ''noise budget'' of these uniformly-distributed ciphertexts is zero and thus they cannot support any further ... |
In Lattice Cryptography, problems like LWE or SIS have relatively easy to specify distributions that are thought to be average case hard.
I'm curious what specific distributions on semi-primes $(p,q)$ such that $N = pq$ is a certain bit-length are thought to be average case hard.
Essentially, there are many different s... |
I am looking for books or reference guides to learn and teach "cryptography, security and privacy preservation techniques"? I need some advice to good resources that I can use.
|
In a setup where the client signs then encrypts outgoing data packets to a VPN server / onion network, an ECDSA signature appended to the plaintext before encryption could cause the data to be too large to be contained in the packet. How is this avoided??
Side note: Encryption will be with a stream cipher, so the data ... |
This is a question I've been wondering for a while.
Technically these two strings have the same entropy I believe:
fkfnajkfkg%gsddg£5ER£%££££
011001100110101101100110011011100110000101101010011010110110011001101011011001110010010101100111011100110110010001100100011001111100001010100011001101010100010101010010110000101... |
I'm trying to generate a csr with spongyCastle in android that has to be submited to a webservice. My problem is that the webservice always complains that the CSR is not in DER or PEM format. On the other hand, if i use Openssl command line to generate it, the webservice accepts it, so i know the webservice works and t... |
I've been experimenting with MBEDTLS on an ARM-M4 (but this question is not platform-specific) and am confused/surprised regarding the computational complexity (execution time) of mbedtls_rsa_pkcs1_sign() versus mbedtls_rsa_pkcs1_verify(). Apparently the _sign is much more computationally complex than the _verify. I do... |
DISCLAIMER: I understand the question might be a bit amateurish due to my limited knowledge of cryptography but, please, bear with me for a minute.
QUESTION: Suppose a user Alice generates a pass phrase "hello", and a user Bob generates another pass phrase "world".
I need to create an encryption/hashing pipeline that w... |
What the name of the algorithm/encryption technique which outputs a set number of numerical digits e.g. 20 digits based on some input.
You can input some data e.g. text or numbers but the output is always 20 unique digits.
If you put the same input, it should give you the same output.
|
I want to ask: How to show that a result of hash function and a random is computationally indistinguishable
If we denote $H(): \mathcal{X} \rightarrow \mathcal{Y}$ is a secure hash function, $m$ is a fixed message, and $r$ is chosen randomly.
Let $c_1 = H(m \mathbin\| r)$ and $c_2 \in \mathcal{Y}$ chosen randomly.
Is t... |
There were 2 papers published in the last year, that describe 2 different white-box identity-based digital signature schemes:
White-Box Implementation of the Identity-Based Signature Scheme in the IEEE P1363 Standard for Public Key Cryptography. IACR ePrint
White-Box Implementation of Shamir's Identity-Based Signature... |
The problem of finding private key from public key is typically studied in the one-key setup: what's the expected cost of breaking one key (e.g. by factoring a public modulus, or solving a discrete logarithm in some group).
There is much less work on simultaneously attacking $k>1$ keys. One notable exception is Daniel ... |
By concatenating "words" and adding them Modulo 26, can a key be created that is indistinguishable from one generated in a truly random manner? Let's say the key is more than about ten letters.
For example, three "words" (EATED, PIG, ELEPHANTINE), whose lengths are coprime, are concatenated with themselves and added li... |
Paillier Cryptosystem depends on both the factorization where $n = p.q$ and the complex residuosity problem which is defined in the original paper as:
The problem of deciding n-th residuosity, i.e. distinguishing n-th residues
from the non n-th residues will be denoted by CR[n]. Observe that like the problems of decidi... |
I am trying to come up with an explanation of the probability of birthday collision.
$P$(no collision among t people) = $(1− \frac{1}{365}) · (1-\frac{2}{365}) ··· (1-\frac{t-1}{365})$
For one person, the probability of no collision is 1, which is trivial
since a single birthday cannot collide with anyone else’s. F... |
To get Byzantine Fault Tolerance in a synchronous model you can use an Oral Message Algorithm. For n > 3f+1 it gets an Byzantine agreement in f+1 rounds. Why f+1?
|
If crc or CRC32 is specially designed to catch errors, then what's the point of SHA or md4-5 or any other hashing function? What I did was, I had a 190 mb png file (rendered in 16k resolution with blender lol) and I took its sha256 and CRC32 hash, then I did the same, only changing 1 bit of the image. Just 1 bit. And I... |
Is the 51% attack the only technical reason no country will adopt Bitcoin as a state currency?
Let's suppose a country with a GDP size less than 300 Billion USD adopt the Bitcoin as an official currency. It will be very easy to crush or take control of state currency if a country like the US or China invests to run 51... |
Given an image size of 300 by 400, what is the maximum number of ASCII characters (7 bits) that can be embedded using the LSB steganography?
I would assume that every pixel can perform an LSB so would that mean 300x400 bits change? I should then divide this by 7?
I'm confused about how this works. Could you elaborate?... |
The Trivium encryption algorithm has two inputs, key and IV, both of which are 80 bits long. Let's call it Trivium(key, IV) → keystream. My question is whether doing Trivium(key, input) and taking the first 80 bit of keystream would result in a secure PRF.
I have found another way to create a PRF from a stream cipher, ... |
(I wondered if this question should be asked on StackOverflow instead because it's a programming related issue, but it's bound to the intricacies of SHA3, which I figured was a better fit for Crypto.SE. If this is unsuitable I'd appreciate it if a moderator could migrate this for me.)
I have faulty home-brew implement... |
The Paillier CryptoSystem has a public key that $(g,n)$ and the private key which can be exclusive to $\lambda$, where the decryption scheme is:
$m = L(c^\lambda \bmod n^2)/L(g^\lambda \bmod n^2) \bmod n$
Since $1/L(g^\lambda \bmod n^2)$ is fixed and always needed for decryption, it is usually computed once and denoted... |
I am new to Ring-LWE. I had assumed that error distribution in Ring-LWE (or, in any lattice-based cryptography) is always Gaussian.
However, while reading a few research papers (e.g. page 5, Section "Noise distribution and reconciliation" in https://www.usenix.org/system/files/conference/usenixsecurity16/sec16_paper_al... |
I have a Zip archive containing a single password-protected file file.txt.
The encryption is "ZIP 2.0 Default Encryption" (ZipCrypto).
I know what kind of text (sentences) the "file.txt" contains.
Is it possible to use known-plaintext in that case? Or,
Do I need exactly a second known encrypted file to use this type... |
Universal hash function is defined as follow:
$f_{(k_0,k_1)}(x) = (k_0\cdot x + k_1) \mod p$, where $p$ is prime
In Wikipedia, it is mentioned that the above function is pairwise independent. Pairwise independence is defined here
I wonder what are the random variables in $f$ and what pairwise independence means here. ... |
I'm using CADO-NFS to calculate discrete logarithm in a finite field GF(p). The problem is when I type
./cado-nfs.py -dlp -ell 101538509534246169632617439 target=92800609832959449330691138186 191907783019725260605646959711
as described in the README.dlp file I just can't understand which of the three values (log2, lo... |
What is the benefit of using HMAC over hash with key suffix? I realize that using key prefix is a bad idea because it allows message extension attacks. When adding key as a suffix such attack possibility is eliminated.
MAC = h(k||x) // key prefixing, bad idea
MAC = h(x||k) // key suffixing, much better idea
HMAC uses ... |
Consider the following three stage interactive zero knowledge proof
The prover sends some information $a$ to the verifier.
The verifier picks a challenge $c\in \{0 ,1\}$
Depending on the challenge, the prover responds with $r(c)$ that convinces the verifier of his knowledge.
Each round can be won with probability $\f... |
It is often said that one-time pads do not provide message authentication. But, if you and I have a one-time symmetric key, and I send you a message, and it is not complete gibberish, is that itself not message authentication? The probability of you getting a non-gibberish message is, I would have to spam you a noticea... |
As I study SHA-256, I wonder how the values inside the algorithm were determined.
Take a look, for example, at how the 16-64th Words are generated. (in Java language)
for (int j = 16; j < 64; ++j) {
int s0 = Integer.rotateRight(words[j - 15], 7) ^
Integer.rotateRight(words[j - 15], 18) ^
... |
Veracrypt 1.24 just came out. It uses a true random number generator based on hardware events; namely, on CPU timing jitter, or "Jitterentropy".
As an alternative to CPU RDRAND, I am a bit jittery about "Jitterentropy" in Veracrypt 1.24, and would like to hear some expert advice. The paper I just cited, by Stephan Mül... |
Is there any public/private homomorphic encryption scheme that directly works on floating numbers or vectors of floating numbers?
In our application, we want to find out if
$$v_1 \approx v_2, \qquad\text{or more precisely}\qquad \lVert v_1-v_2\mathbin\rVert < \epsilon,$$
with $v_1$ and $v_2$ being vectors with a fixed ... |
I was wondering if there was any way to compute the private key $d$ when knowing only $e$ and $N$, and being able to factor $N$ as 4 prime numbers $p, q, r$ and $s$. I've been searching for days and I can't find any way.
|
Intuitively, it seems that the hash of a BLS signature could be used as a VRF as well. In a nutshell, BLS-Signature is the VRF output and the verification first checks the signature is valid, and then compute the hash over it to provide the VRF output. (Or similarly, one can provide H(BLS-Signature) as the VRF output a... |
Consider the following system
1 - fixed string as a seed, example "something"
2 - concat an increment number "something-1"
3 - hash it, assume it is "9f2054ea4d2c"
4 - take the first 3 digits to get a number between 0 and 4095 for example
The next number will be taken from the hash of "something-2" and so on
|
What are the best algorithms for solving systems of $k$ polynomials equations where these are quadratic multivariate polynomials on $k$ variables?
I've encountered such systems on my research and I'm in the position to say if they are somehow solvable or not, and what would be the complexity to run an "attack". I know ... |
Gilbert, MacWilliams, and Sloane defined a solution to "perfect integrity" in Codes Which Detect Deception, unconditionally secure message authentication, not vulnerable to any cryptanalysis on its own even by an adversary with unbounded computational power, provided you have a key chosen uniformly at random the same l... |
I am reading the Handbook of Applied Cryptography and on page 99 the authors write
, after showing that $QRP \le_P FACTORING$:
It is believed that the $QRP$ is as difficult as the problem of factoring integers, although no proof of this is known.
I am not quite sure what "as difficult" means, do they say that it is as... |
The definition of an unconditionally secure cryptosystem is that it cannot be broken even with infinitely computational resources and time. The one-time pad (OTP) is an example of an unconditionally secure system, there is nothing in the ciphertext that makes one message seem more probable than the other, brute-force c... |
I have been reading about Pedersen Commitments, and have come across some contradictory examples, which is confusing.
Just focusing on simple commitment of scalars (not EC points or vectors), then I have read this:
Why is the Pedersen commitment perfectly hiding?
which states:
Public parameters - 2 primes , such that... |
I'm testing IEEE's P1619, which is XTS mode. IEEE documents from 2007 provided both test vectors and a reference implementation. Documents from 2008 only provided the reference implementation. Here is the 2007 document with both.
The reference implementation stayed the same from 2007 and 2008. The problem is, the refer... |
Sorry I didn't put enough details on my last question, I didn't expect that there is really lots of factors, so most answers were left for speculations.
In this question, I will give the scenario I am looking at:
This is the code
//seed is 64xF Hex
//example 0123456789abcdef0123456789abcdef0123456789abcdef0123456789a... |
For a public one-way function $f()$, we can use zero proof to prove I know some secret $x$, such that the output of $x$ is a specific number $y$.
However, in zcash, I need to prove that I have some secret $x$, then $cm$ which is the commitment result of $x$ is a leaf in Merkle tree. Here, $cm$ is not a specific number... |
I manage a proxy server. Is it technically possible to observe and determine which cipher suite is selected between end points (client and server) without changing their SSL certificate, without mimicking server certificate through a proxy in general?
My main goal is to obtain weak algorithms that parties agree upon.
F... |
Can someone please share a link of any research paper or web-page analyzing the security of Ring-LWE? Essentially, how should I choose my parameters to get security equivalent to 128-bit or 256-bit?
|
I'm looking for the homomorphic version of the following (I'm using Python here):
$ a = [1,2,3]
$ s = sum(a)
$ print(s)
6
Is there an open source fully homomorphic library which is able to do $sum(vector)$? So far I just found libraries allowing operations with input-output either only vectorial or only integer. Her... |
Are there any commutative one-way functions for floating points?
I tried to explain why I need these functions.
First, I describe the problem on a high level and then I further formalize it;
There are three parties. Alice, Bob, and Charlie.
Charlie wants to check if Alice and Bob have the same value without knowing the... |
I want a cryptosystem with the following four functions:
declare function encrypt(text: string, key: CryptoKey): ArrayBuffer;
declare function decrypt(ciphertext: ArrayBuffer, key: CryptoKey): string;
declare function concat(ciphertext1: ArrayBuffer, ciphertext2: ArrayBuffer): ArrayBuffer;
declare function slice(cipher... |
I was reading the paper by Boneh et al. Link. The scheme describes what is called a Verifier Local Revocation Technique. The Scheme assumes that a Revocation List [RL] allows each verifier to check the validity of the signature. The revocation check works as follows:
$e(T_2/A,\hat{u}) =^{?}e(T_1,\hat{v})$, Given $T_1 ... |
Suppose I always reuse p, g and a in DH and there is someone monitoring my communication. Is there a way this person can use this to perform some kind of attack to me?
I believe that reusing p and g isn't a big issue, however I'm not quite sure about a.
|
Let $f$ be a collision resistant function i.e. it is computationally impossible to find $x_0, x_1$ such that $f(x_0) = f(x_1)$. If a computationally bounded adversary demonstrates that he knows some $x_0$ and $f(x_0)$, in what sense is he unable to determine $x_1$?
My instinct is that he can do no better than choosing... |
Consider a block cipher (such as AES256) as $E$, a randomly selected key $k$, a counter $i$, and an array of n-bits $M$ as the message. Also consider the following block cipher modes of operations:
$E_{k \oplus i}(M_i)$, e.g. three block encryption:
$$E_k(M_0), E_{k \oplus 00\ldots 1}(M_1), E_{k \oplus 00\ldots 10}(M_... |
I have been studying additive ElGamal and I think I have the hang of it except the part where the message $M$ must be retrieved by computing the discrete log of $g^M$.
From what I've read, the result of such computations is a function of $k$ e.g. for $g=3, M=4, \pmod{17}$ we have $3^4=13 \pmod{17}$ but computing the d... |
This paper explains an attack on TLS 1.3. This was published way back in 2015 when TLS RFC was in draft stage.
My question is now TLS 1.3 RFC is finalized, is this attack got addressed?
|
How can I find the known plain text P2 based on the given information? Assuming that the encryption is made using a common initialization vector and the mode used for encryption is OFB.
Plaintext (P1): This is a known message!
Ciphertext (C1): a469b1c502c1cab966965e50425438e1bb1b5f9037a4c159
Plaintext (P2): (unknown)... |
The attacker doesn't need the key in order to decrypt ciphertexts or encrypt plaintexts since he/she already has the full implementation.
So what's the point of hiding the key?
What advantage would the attacker even have by knowing the key?
Update:
ddddavidee's answer below, in the second paragraph, raises an interes... |
My government issues certificates for many purposed, including e-mail signing.
The government doesn't provide e-mail addresses, but it does declare my e-mail in the certificate.
Can I use this certificate to sign e-mail in S/MIME?
Can I use this certificate to sign e-mails using Microsoft Outlook?
Can I use this certi... |
if you know the result of a hash, for this example the resulting hash is: ec664d1d65fd8a58c59b337b11c37a4d
And you also know the hash has been made like this:
const salt = "asdjbsdhal"
const password = unknown; // only thing we don't know
const hash = md5(salt + password);
So we know that md5(salt + password) == "ec66... |
How can I find two strings that have the same hash value for first $n$ bits in SHA-256? I'm implementing it by Python and I have the following ideas and problems:
Keep generating two random string
What is the length of the string that I need to generate?
How to avoid generating the existing string again?
How many ... |
I have recently gotten interested in cryptography, so I looked some things up.
I thought, why even use AES or DES or any other complex way for encrypting data when there are far simpler ways, like just generating a random (pseudorandom) bitstream, and XOR'ing it with the data or secret message? The point is, if you hav... |
Just for anyone reading this: DO NOT ROLL YOUR OWN ALGORITHM.
Besides that, is implementing a well-trusted protocol with well-trusted algorithms and libraries a good idea? Is this likely to colossally fail like rolling your own crypto? Could this be used in production after enough peer review? (I know that rolling your... |
In discrete log cryptosystems like ElGamal it is noted that the "private key" $k$ should be chosen as any element of the group $G$ i.e. $k < p-1$. Does the integrity of the cryptosystem rely on $k$ being an element of the group or can it be larger as well (always assuming that $g^k \bmod{p}$ will be published in the pu... |
I have read here that Elgamal is resistant to brute-force attack, because the group to where the key is selected is very large. But since the key generation is random, (i assume)there is a chance that the key generated is lower than the recommended.
example, the recommended keylength is 1024 bits, but the key generated... |
I have been reading a bit about how the Enigma machine was cracked in WW2.
There was also this wonderful post which highlighted a lot of useful information.
Let's assume I know everything about how the M3 Army Enigma machine works according to Kerckhoff's principle. Now I am wondering, in theory, if say, the Germans de... |
I'm having a hard time understanding the purpose of having two primes $p,q$ for RSA to work. To illustrate my point, imagine only one prime ($p$) is used.
Alice, the encryptor, can take the public encryption exponent $e$, which Bob, the decryptor, created (along with the private exponent $d$) to satisfy
$$ed\equiv 1\p... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.