instruction
stringlengths
32
27.2k
This is kind of an academic question, but I wonder if it's possible to build an intentionally one-time signature scheme with elliptic curves? I assume you could do it by supplying ECDSA with deterministic input instead of randomness during signing, resulting in "sudden death" if two messages are signed by the same key....
Is there an IETF standard-track protocol have IANA-registered IDs for deterministic authenticated encryption yet? If not, what's preventing their adoption? What changes to protocols will DAEs likely require?
Classical asymmetric cryptography is commonly based on the Discrete Logarithm Problem and Integer Factorization, which are known to be solvable with a quantum computer if it has the ability to run Shor's algorithm, or an algorithm that solves these is devised to run on a classical computers. Nowadays we know this is im...
In the counter mode of encryption, the nonce cannot be used again unless a new block cipher key is chosen. What is the maximum number of messages that can be encrypted using the same key? The maximum length of messages that can be encrypted using the same key under the counter mode is $2^{39} - 256$ bits. I want to ma...
I have no clue how to determine suitable 128 bit IV (initialization vector) from a 32 bit IV. Encryption AES-128 OFB. The 32 bit IV has value 0x9a23773c (transmitted in front of the data). Any ideas?
For encryption authentication, I am using ECDSA signatures over the curve secp521r1. There is a hash function parameter, and as the curve is 521-bit, the hash output length should be > 512 bits, which is the highest offered output of the Standard SHA-2 hashes available. However, in the SHA-3 specification, the cSHAKE f...
I've scoured this website and the OpenSSL wiki pages, and done numerous internet searches, and I've come to the seemingly incredible conclusion that one cannot generate an ECDH shared secret key using a given public key and a given private key from the openssl command line. There is at least one other post on this web ...
Is there an equivalent to the birthday paradox for more than 2 messages. Solving Hash(x) = 0 takes $2^{bits}$ steps on average Solving Hash(x) XOR Hash(y) = 0 takes around $2 ^{bits/2}$ due to the birthday paradox. Is there an algorithm that can solve Hash(x) XOR Hash(y) XOR Hash(z) = 0 in $2^{bits/3}$ steps (or simila...
I'm developing a medical device that operates under extreme low-power constraints and transmits data with BLE, where every unnecessary millisecond of air time matters. I am developing a Beacon advertising protocol where sensor data is encoded directly into the advertising packet. The data I need to transmit is very sim...
Given a polynomial time deterministic algorithm $G_1:\{0,1\}^n \rightarrow \{0,1\}^{n+1}$, consider the function $G:\{0,1\}^n \rightarrow \{0,1\}^{p(n)}$ constructed as follows: Let $s \in \{0,1\}^n$ be the input seed and denote $s =s_0$. For every $i = 1,\ldots,p(n)$, compute $(s_i,\sigma_i) = G_1(s_{i-1})$. Output $...
I have used openssl rsa to generate a RSA key of 2048 bits and as expected output belongs to a file beginning with BEGIN RSA PRIVATE KEY pattern. However this file size is ways larger than 2048 bits. In order to extract the key, i have used the following openssl command: openssl rsa -in key.txt -text which returns dat...
I came across an authentication system Here that uses multiple hashing algorithms to hash data in different stages of the authentication. My question is what's the rationale behind this? If a hashing algorithm is secure (or has been secure so far, like SHA-256) why use different ones? For example: When someone/somethin...
I am trying to implement the algorithm described in this paper. It uses blocked Gibbs sampling to perform a ciphertext-only attack on text encrypted with a running key cipher. However, I am confused by what it means when it says 'Sample ___ according to ___'. I have not used Gibbs sampling before so I have watched a fe...
would it be impossible to validate the file type via magic (file command for example) of an AES encrypted ts file? asking since the magic tests are looking for the sync byte (value of 0x47) each 188 bytes.
I am not a cryptologist, just a cryptography user, so not sure if this is safe. I want to sign a public key with its private key pair. Is it dangerous to share this signature result along with public key? (For example can this be used to reverse engineer the private key) Or are there anything I should be concerned abo...
I know that calculating the cardinality of $U_{pq}$ is infeasible and therefore it is extremely hard to break a code using Lagrange's theorem. But later on my studies i realized main principle of RSA can be generalized to any abelian finite group. Is there another group structure $G$ that is suitable for RSA (i.e. it i...
Assume that hash(X) == Y Alice knows both X and Y Bob only knows Y Alice generates a random nonce N and shares it with Bob. Alice calculates H = hash(X⊕N) and shares H with Bob. Can Alice prove to Bob that H really is hash(X⊕N) without sharing the value of X? Edit: X, Y, N, H are all 32 bytes. The hash function is S...
I found a hashcat benchmark results in the internet: hashcat results: SHA-384 is 17065.4 MH/s SHA-512 is 17280.3 MH/s Why does SHA-512 take less time? SHA-512 is longer and I thought it therefore needs more time and computation resources to compute the hash?
I am struggling to understand what is meant by "standard cryptographic assumption". The Wikipedia artice on the Goldwasser–Micali system (GM) reads "GM has the distinction of being the first probabilistic public-key encryption scheme which is provably secure under standard cryptographic assumptions." But what are stand...
In this paper, it referred that there are two paradigms used in constructing group signatures: the "sign-encrypt-prove"(SEP) paradigm and "sign-randomize-proof"(SRP) paradigm. As said in this paper, SEP paradigm is Here, a signature is an encrypted membership certificate together with a signature of knowledge, where ...
I want to use AES256 CBC for protecting small data (<100kb) against misusage for my application in the local store folder. I'm not an expert at data encrypting so I'm to try to understand it step by step. I want to just make sure myself that I understand it well. I have a key for decrypting/encrypting and then IV whic...
I'm sure there is some proof that the nth prime can be found. But if we knew, would encryption that relies on primes be easy to decrypt?
Consider the following function: $f_k(mm')=\operatorname{HMAC}_{\operatorname{HMAC}_k(m)}(mm')$ Can I use $f$ as a secure MAC?
I'm trying to understand exactly how the random oracle model differs from the standard model. In many proofs & applications there are some assumptions that some randomness is sampled (i.e. a bit $b \leftarrow\{0,1\}$). My question is: given the ability to sample a single bit at random, can't we use that to construct a ...
Please explain how does this formula $(aG + bG) = (a + b) G$ work in ECDSA? According to the source: $a$ and $b$ are different private keys Suppose $a = 3$ $b = 4$ then the public key is $Q = aG$ and $W = bG$ (secp256k1) Q = F9308A019258C31049344F85F89D5229B531C845836F99B08601F113BCE036F9 W = E493DBF1C10D80F3581E49049...
The BGN paper (Evaluating 2-DNF Formulas on Ciphertexts) used a threshold variant of BGN. I also want to use this cryptosystem, however, I cannot find any open-source implementation. Is there any such an implementation? If not, how could I implement it (the secret key can be easily shared, but I do not know how to decr...
Is there any reason to use something stronger than SHA-1 with PBKDF2 if my input is fairly low entropy? I.e. if the passwords being hashed are only about 30-bits of entropy. I can't find it now, but someone stated if you want to preserve the entropy of high entropy intput, then use PBKDF2 with a higher SHA. So I'm ...
We want to migrate our userbase from bcrypt to argon2. I was planning on an approach that migrates all hashes immediately to argon2; "old" users would have an argon2'd hash of their bcrypt hash of their password. New users (and users that logged in) would get updated so their argon2 hash of their password was what was...
Go's ed25519 package exposes a function which allows creating a private key from a 32 byte seed. See: https://godoc.org/golang.org/x/crypto/ed25519#NewKeyFromSeed The reason I want to use this is because this is only 32 bytes, hence easy to copy and pass around. I assume if I use a cryptograpically secure source of ran...
From this discussion, I know that if I know $\varphi (N)$ and $N$ (where $N=pq$, $p$ and $q$ prime), then I can very easily get $p$ and $q$. Suppose I have the encrypted message $c$. I want to get the exponent $d$ such that $c^d \pmod N$ is the original message $m,$ without knowing $e.$ I know that it is theoretically ...
I am trying to decrypt a message which its ciphertext in Hex A3 BB 05 00. The original plain text is 8 bits and it is encrypted by a 32 bits RSA key. I have successfully found the public key is $(e=947,n=2671079)$ and the private key is $(d=713604)$. Then, I try to convert the Hex string to integer 00 05 BB A3 (Little ...
I would like to know what is the proper way of fitting the hash digest to the prime in which the encryption scheme operates. regardless if the bits of the hash digest is larger or smaller than the prime. I've read that the Cramer-Shoup uses a universal one-way hash function, but didn't state what it is. Wikipedia says ...
I am working on a project wherein ECC needs to be implemented on small devices, namely, CC2650 sensor-tags for authentication. The ECC implementation should be on Contiki OS. I have read some articles which suggest it is possible to implement ECC on tiny devices. I want to know is it viable practically considering the ...
Which algorithms can be used for key exchange between two wireless nodes and are not secured, meaning they can be eavesdropped?
How does it work and why is forward secrecy guaranteed? I understood that it is not susceptible to a man-in-the-middle attack by using certificates in the beginning.
Let $\Sigma$ be a sigma protocol whose commitment, challenge and response phases are $\Sigma_1, \Sigma_2, \Sigma_3$, respectively. In Fiat-Shamir Transformation, the challenges are $H(\Sigma_1)$ where $H$ is some hash function. However, in some literature, instead of having $H(\Sigma_1)$ it is $H(x \parallel \Sigma_1)$...
Why is 2PC (2-Party Computation) not used as any other primitive like Diffie-Hellman? I'm not talking about the general secure computing, but some weaker security requirement or special case schemes. A number of tricky methods for GC (Garbled Circuit) have been proposed like free-XOR, half-gate and so on. And recent pr...
It seems to me that it's theoretically possible to exfiltrate a salt against a hashing algorithm that isn't constant time using specially crafted inputs. Are there any examples of this being done in a reasonable time?
Disclaimer, this is not homework; I found the question statement here: Security of this PRF To restate the question: Given $F$ a secure PRF with input size $\lambda$. Define $F'$ as $F'(k,x\mathbin\|x') = F(k, 0\mathbin\|x)\oplus F(k, 1\mathbin\|x')$ with $x$ and $x'$ of $\lambda-1$ bits. Is $F'$ a secure PRF? ...
Let's consider a situation whereby: Alice generates a ciphertext c from a message m using Bob’s ID. An attacker Carol can get c from the open channel. She knows that c is generated by using Bob’s ID but she does not know Bob’s secret key. On the other side, Carol is able to know the random number r that Alice ha...
So, maybe this is a dumb question, or maybe it's something someone's already done and it's really common, but whatever, here goes: Why do we sign a message with our private key and then encrypt it with our contact's public key, instead of encrypting our message with our private key and then encrypting it again with our...
I have to elements of multiplicative group of finite field with generator g - $$g^x,g^y $$ Can I get? $$g^{xy} $$
The question as the title suggests is based on the key exchange with Diffie-Hellman protocol and is something like this: *"We have intercepted a communication between Alice and Bob: intercepted-communication We also have read out the code Alice was using to communicate: alice.py Unfortunately, the flag is no longer in ...
Let's say we have 3 parties and each one of them has a different secret number. Every party wants to learn the product of all the 3 numbers without learning about the other inputs. With the BGW protocol: Can we do this with 3 parties, or do we need 5 parties to do this? I am confused because BGW states that we need $2t...
I am quite new to the RSA and I have a couple of questions that confuse me. Q1: A Timing attack on RSA can be prevented _____________________________ A. By performing the “square and multiply” modular exponentiation algorithm using keys with equal number of 1’s and 0’s in binary form B. By randomizing the ciphertext o...
I am trying to decide whether to encrypt data by using attribute-based encryption or use an encryption algorithm such as AES before using attribute-based encryption. Is attribute-based encryption used to encrypt data and apply access control, or only do the latter?
I've encountered some code that I'm reviewing that is misusing RSA_public_decrypt to "authenticate" a variable-length response without using any hash. The code assumes that a successful decryption means that the given data buffer was generated by the server and processes it without any additional checks. I believe that...
In a scenario in which some of the parties have more data / compute power / trust reputation (or other meaningful properties) than other parties - are there known methods to do secure multiparty computation with load balancing that takes into account the above-mentioned (or other) parameters?
When aiming to build a MAC, classic literature discusses the use of Envelopes or key "Sandwich" to build MACs. These were proved to be as secure as HMAC in “Sandwich” Is Indeed Secure: How to Authenticate a Message with Just One Hashing by Yasuda. In these Envelopes, a key (K) is prepended to the padded message (M) and...
I am wondering whether there is a bulletproof way to know if one is successful in decrypting a file. As an example, say I encrypt a text file and protect it with a 3 letter password. I use brute force to decrypt it, but two different passwords lead to a file that contains English intelligible text. Is there a way for ...
I am working on a project in which we will XOR two messages basically adding them together, $C_1= (M+K)$ and $C_2= (M'+K')$ the result should look like $K\mathbin\|K'$ and $M \oplus M'$. My question is about the security of the resulting cipher after XORing two messages. Note: Both the keys and messages have been chose...
I want to calculate ($m^{e} \pmod{N}$) in C or C++. I want to use 2048 bits long modulus $N$ and thus the above process of exponentiation will use a huge amount of calculations and time. I want to know the possible optimizations I can use. I particularly came across this : Converting the exponent to its binary bit patt...
I'm studying the RSA protocol and I was wondering if there was any way of decrypting a message if the $e$ doesn't have an inverse $\mod (p-1)(q-1)$. Usually, you have to choose a value of $e$ that is inverse $\mod (p-1)(q-1)$, but I made a mistake in my calculations. If someone where to write to me using the formula $C...
Suppose $H = \operatorname{SHA2-256}$. Let $H_1 = H(\text{“Alpha1”})$. Let $H_2 = H(\text{“Alpha2”})$. … Let $H_N = H(\text{“AlphaN”})$. So all these digests are based off a common pre-image post-fixed with the index. Question 1: Does knowing the values $H_1, \dotsc, H_N$ and the length of common pre-image substring "A...
What does it mean by a HASH of a message with zero length or rather why is it required? What could be a possible scenario where this is used? Also note that, for a given HASHing algorithm, the hash value of a zero length message is essentially pre-defined.
I know SHA-1 hashing is regarded insecure. HMAC-SHA-1 is still regarded secure as this is an encryption process with symmetric key of the hash produced by SHA-1. So signing using RSA with a key size of 2048 with a SHA-1 hash over the content should be regarded secure just like HMAC-SHA-1, correct?
I was wondering why exactly does solving a polynomial system (directly or indirectly) "break" a multivariate cryptosystem as a digital signature. I realize that the exact reason differs from system to system, but in general, from what I can see, it then allows attackers to sign messages with a private key that is not ...
Background First, while studying MinEntropy a bit, I came across an NIST paper, "DRAFT SP 800-90B (second draft)," which suggests "twice" the entropy of the underlying block of a cryptographic hash function be used as input in order to have an output hash having fully saturated entropy capacity. This seemed unnecessary...
Does the mechanism behind Attribute Based Encryption require us to first encrypt the message by using a symmetric cipher, e.g. AES, and then encrypt the AES key by using Attribute Based Encryption? Or if I encrypt the message directly using Attribute Based Encryption, would the message still be considered encrypted an...
I got a lecturer with a slightly way of writing down the padding oracle attack equations than what's considered to be the standard definition on the internet site like Wikipedia, and I wondered if all the equations are still cryptographically correct. So it's using uppercase P and C for the plaintext and ciphertext blo...
Let $(E,D)$ be the encryption/decryption of an authenticated encryption scheme. Consider the following commitment scheme. Generate a random key $k$. Commit to $m$ by sending $c=E_k(m)$. Reveal $m$ by sending $k$. The hiding property of the above commitment scheme follows directly from standard assumptions on the conf...
I am working on a proof of concept around cryptographic accumulators. The following is my understanding so far delta : the current size of the tails file in the accumulator. witness : the current value of the accumulator when the entry of your number was made. index : the actual index that is added to the accumulator....
Consider the LWE distribution $\{(\pmb{a}_{i},\left<\pmb{a}_{i} , \pmb{s}\right> + e_{i})\}$ where secret $\pmb{s} \in \mathbb{Z}_{q}^{n}$, randomness is $\pmb{a}_{i} \xleftarrow{\$} \mathbb{Z}_{q}^{n}, e_{i} \xleftarrow{\$} \chi$, $q$ is a prime number and $\chi$ is a discrete Gaussian distribution. Grouping $m$ sampl...
My question refers to the paper "Fully homomorphic encryption modulo Fermat numbers" by Antoine Joux. On page 3, the author describes a basic concept of the system: As many FHE systems, we deal with noisy messages. In our case, the high bits of each block are used to hold significant bits, while the low bits contain...
So RSA algorithm uses pre-generated set of public and private key, and public key is usually included in private key. So public key stays always the same. Is it theoretically possible to have some algorithm that has one private key and indefinite number of public keys that can be generated on-demand? Assume we have goa...
I m looking at this Example of Merkle–Damgård I have a similar question about this topic. I have hash function maps 256b blocks into 128b blocks, how many rounds are required for hashing a 140KB file? My idea is to transform this 140kb into byte (140000 bytes) and divided this number on 256 ... So I have 546,875. S...
I’m thinking about the convergent encryption system described in the top answer to this question. However, it seems like preferred modern HMAC algorithms like HMAC-SHA256 (as used in step 2 to create the “key”) are much slower than the actual encryption. Then SHA256 is invoked again on data the size of the plaintext to...
As far as I know OTP is the only algorithm proven to provide perfect secrecy. It can work with XOR which is addition modulo 2 and obviously it can work with additions modulo N. What other operations enable perfect secrecy? Can we for example have randomized tables to define the mixing of data and key and still prove th...
I have learnt that there is a trick where you can speed up the reduction modulo of a point (x-value) in a x25519 curve. Since, it uses the prime number $2^{255} - 19$. From article: Reduction modulo exploits the fact that $2^{255} - 19$. $2^{256} \equiv 38$, so $38*r4$ is added $r0$ and $38*r5$ is added $r1$ and so o...
For one of my projects, I need a pairing group which holds the External co-Diffie-Hellman assumption. I am trying to implement it using Charm crypto python modules which provides support for MNT curves. According to Wikipedia: In practice, it is believed that the XDH assumption may hold in certain subgroups of MNT ell...
I have a cookie being encrypted with AES-256-GCM in Rust using ring. I need to decrypt the cookie in Node.js. I'm using the standard crypto library, but it's just not working. My understanding is that different implementations of AES-256-GCM algorithm should be compatible as long as they Use the same key Use the same ...
Suppose that, instead of choosing r completely at random in ElGamal public key encryption, a lazy encryptor (Alice) derives it by following r′= 2r. Suppose also that Eve knows that Alice had encrypted the same message m with the two random numbers r and r′= 2r, thus creating two ciphertexts {k, c...
Assuming our domain and codomain both have 4 elements, the uniform distribution of inputs to outputs means the function is injective. It is widely agreed that randomly selecting a domain element results in log2(4) = 2 bits of entropy in the selection, and that because of being injective, the output of said function inp...
When $n = pq$ where $p$ and $q$ are primes, we can generate random numbers until we get $a$ and $b$ such that $a^2 \equiv b^2 \pmod n$. This implies $n$ has some common factor with $a^2-b^2$, and then we can use the Euclidean algorithm to find the gcd, which will be a factor of $n$. However, I'm trying to figure out h...
As we know, in the blockchain system every node has historical data that contains all previous transactions to maintain the integrity and approve the future transaction. What if blockchain is implemented in everyday life and people makes billions of transaction in a day, then a node must run out of memory sooner or lat...
Why is the core ChaCha primitive not good for use in a collision-resistant compression function (crypto hash)? Why go through the trouble to create BLAKE? What's wrong with using the core ChaCha primitive unaltered in a Merkle–Damgård like construction to construct a collision-resistant compression function/one-way com...
I have a big problem to figure how the security model in papers about side-channel are relevant (briefly the attacker has a partial access to the hardware). Why these breaches are so seriously considered? Is there any known and famous story of a system attacked with these techniques?
A. From what I heard (and I am beginner at a security/cryptography), if you have a payload that is very large, asymmetric is a no-go. B. Also, if you do have secret symmetric (e.g. AES) keys, you might not want to share them with others, if they have high importance to you. I am trying to understand things and I cannot...
Why not use chacha derivatives (BLAKE, rumba) to make an [H]MAC for use with chacha? Why use poly1305? This question is especially interesting considering... "The security of Poly1305[...] is very close to the underlying [...] block cipher algorithm." -Wikipedia So... why not reconfigure chacha as a Merkle–Damgård...
Trusted Platform Module (TPM) is designed as a hardware-based root of trust to protect cryptographic keys even against system based adversaries. Although Intel's firmware based fTPM has FIPS 140-2 and STMicroelectronics hardware-based TPM has Common Criteria EAL 4+ certifications, recently in an attack TPM-FAIL: TPM m...
Let's try to solve a discrete logarithm: $\beta \equiv \alpha ^{x} \bmod \,\, p$ using the Pohlig-Hellman algorithm. Let's suppose that $p-1=tq$, where $q$ is a large prime number. This means that the resolution is probable infeasible, however, if $t$ is factorizable with small prime numbers the algorithm can determi...
Clearly it would provide perfect insight if all 256 bits were used. What about if 255 were used? Would the general behavior and properties of "sha-255" be expected to be close to sha-256? What about "sha-5?" I imagine at some point the insight we can gain must break down, but am not sure exactly where that is. sha-256 ...
I have doubts about this question Consider the following textbook RSA example. Let be p = 7, q = 11 and e = 3. Give a general algorithm for calculating d and run such algorithm with the above inputs. What is the max integer that can be encrypted? Is there any changes in the answers, if we swap the values of p...
How do you crack a long Vigenère cypher when the key is unknown? I have tried frequency analysis, but I'm not making any progress.
Suppose we have $N$ parties, two of whom are Alice and Bob, while some fraction of the remainder are malicious agents working together. We form a network where each party can pass an encrypted message to another indirectly by routing it through other parties. Alice and Bob know a key secretly, so they can communicate p...
As far as I understand secp256k1 is defined over the group p with p = FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFE FFFFFC2F I don't really understand how out of bounds values are handled in particular with homomorphism of the commitments. Assume I commit to the value 5 which would be $G + G + G + G +...
I'm reading through the development of PAKE protocols, starting with EKE and SPEKE, their potential pitfalls, and what motivates their protocol choices. And I've been wondering, what is wrong with the following (very simple) modification to classic DH to make that PAKE: Let Alice and Bob have a shared secret s = hash(p...
I am using this cipher-text c = 04 10 12 00 01 08 67 0A 19 65 0F 03 0A 00 with two possible keys k_1 = 45 44 46 41 42 43 47 4B 4D 45 4B 42 5D 4E and k_2 = 45 44 46 41 42 43 47 4B 4D 45 41 4C 45 4E If I decrypt the cipher-text with k_1 I am getting 'ATTACK AT DAWN' and with k_2 'ATTACK AT NOON'. Which of the plain...
If I have only the ciphertext but the alphabet and the value of a and b are all unknown ... how would I go about this? I understand decryption with the key and alphabet, that is fairly easy but if we don't have even one of them what would be my first step? also, my goal is to have the computer return the plaintext and...
If you have $a^b \bmod n = c$, and $b,n,$ and $c$ values are given, is it possible to find a value for $a$ within a given range? So is it possible to find $a$ in $a^{2051} \bmod 3149=636$ knowing a lies in between $1900$ and $2000$?
The output of VRF contains two parts, the first is the output of the VRF hashing and the second is the proof of correctness. In a unique signature scheme, the signature also contains two parts which are similar to the VRF. The previous works pointed out the VRF can be obtained via a unique signature, but in general, t...
I am a little bit confused in the terms i.e Key Scheduling and Key Generation. What is the actual difference between these two terms? According to Wikipedia, the terms are described as: Key Generation: Key generation is the process of generating keys in cryptography. A key is used to encrypt and decrypt whatever data i...
Assume that $\Pi$ is a secure PKE scheme (or other appropriate encryption schemes) with 1-bit message space. And it can be applied bit-by-bit to construct a many-bit encryption scheme $\Pi'$. Actually, let $\Pi = (\mathrm{Gen}, \mathrm{Enc}, \mathrm{Dec})$ with $\mathcal{M} = \{\, 0,1 \,\}$. And we define $\Pi' = (\ma...
Let's consider a discrete logarithm $\beta \equiv \alpha ^{x} \bmod \,\, p$ We can solve it using Pohlig-Hellman algorithm. And, if $p-1 = tq$ where $q$ is a large prime factor, we can avoid any leakages by choosing $\beta=a^{t}$. This is what my professor said at lesson, however i don't succeed in understanding why ...
The Inversive congruential generator produces random values with: $$x_{n+1} = a\cdot x_{n}^{-1} + b \mod P$$ (special case if $x_n=0$ -> $x_{n+1}=b$) starting with an initial value $x_0$ With well choosen $a,b,P$ it produces all values in $\mathbb{F}_P $ (which are $[0..P-1]$) That's the case if there is no r with $r^2...
This is from my homework: Prove that if there exists a one-way function, then there exists a one-way function f such that $f(0^n ) = 0^n$ for every $n$. Note that now for infinitely many values $y$, it is trivial to compute $f^{−1}(y)$. While I don't expect someone to spell the answer out for me, setting f as the in...
Is the probability of distinguishing HMAC from a random oracle is the same as the probability of forging HMAC? Can we say that the following statement is trivial? $\Pr[\text{Forging $\operatorname{HMAC}_k(m)$}] \geq \Pr[\text{Forging $\operatorname{HMAC}_{f(m)}(m)$}]$ where $f(\cdot)$ is a random oracle and $k$ is a ...
Alice and Bob have to talk through Eve. (server to device through untrusted third party that relays messages, no TLS available) Assume a secure key. Out of scope. Example, ECDH key exchange with HKDF. Each payload has associated data. Time, version, type, etc. Data that is used to get a message to the correct function ...
I have come across a couple of protocols in which the public keys of the parties are static across conversations, even with different users. Something about this makes my hairs stand on end but I can't pin down what the actual weakness is, if there is one. Is a scheme like this OK or is it known to be vulnerable?
From this article: https://tlu.tarilabs.com/cryptography/digital_signatures/introduction_schnorr_signatures.html#why-do-we-need-the-nonce The article states that the challenge e = H(P || m) is insecure, and that e = H(R || P || m) should be used instead. The signature is s = k * e, where k is the private key. My questi...