# All Questions

34 views

### Nonces being used in SSL and MAC to prevent replay attacks

I'm a bit confused in the way nonces are used in these processes to prevent replay attacks. Heres How I think it works during SSL: Nonces are exchanged during stage one of the handshake protocol. ...
72 views

### Updating the secret key used for HMAC

I am designing a distributed system, composed by a set of physically distributed embedded devices (8 bit cores with less than 1 KB of RAM). The devices need to be able to authenticate the originator ...
46 views

### white-box cryptography and its applications [closed]

I am a programmer who is doing research into whitebox cryptography. What I hope to do is to use WBC for an DRM application however as some of us may know, WBC is theoretically impossible therefore I ...
67 views

### The perfect way of using IV in CTR mode

I understand that it is necessary to use the same IV for both encryption and decryption in the CTR mode. I'm thinking about the case when I concatenate the secret ...
80 views

### Comparison among algorithm based on key length

Some months ago I found in some paper that we cannot compare symmetric algorithm with asymmetric algorithm based on the key length and more important we cannot compare asymmetric algorithm using only ...
49 views

### Using hash of plaintext as nonce in NaCl secretbox- bad idea?

I need a nonce to encrypt my stuff using NaCl secretbox. I will be transmitting the nonce along with the ciphertext, which I have been told is OK to do. It occurs to me that one could simply use the ...
43 views

### Where are the ChaCha20 test vectors/examples?

I see in the Salsa20 specification there are test examples throughout the document to help an implementer make sure every function works as designed. Consequently the whole algorithm would work ...
52 views

### What is the difficulty of DLP in GF(P^Q) with a subgroup with a prime order of L

Given a finite field GF(P^Q), having a subgroup with a prime order of L (P,Q,L are all primes), how difficult is it to find the discrete log, is it related to P and Q or is it related to L, or to ...
37 views

### How to implement the Salsa20 hash function?

I am currently implementing Salsa20 from the specification as an exercise in learning and self-flagellation. I have Sections 1-7 passing the test examples provided. I am now stuck on Section 8, The ...
104 views

### How much (home PC) CPU time is required to generate a prime number of a given size?

How much CPU time is required on a typical home computer to generate a prime number of size 100 bit, 200 bit , 512 bit and 1024 bit using given random bits of the respective sizes? Please note that ...
52 views

### How secure is file header encryption for large files?

I'm having trouble location information about whether or not encrypting a file's header is good enough. The files in question are media files that range in size from 500mb to 4GB. If I had no ...
60 views

### Entropy in relation to computer security [closed]

I am going over some lecture notes and my lecturer is off sick, so not sure where to turn. There is this equation that I cannot understand as it's given with a couple of examples. I was hoping ...
74 views

### CBC with a fixed or random IV

I have two probably quite naive questions: 1) Why, exactly, is it so bad to have a fixed (or predictable) IV in CBC mode? An example would be great! 2) Given 1), why is a random IV better? And if ...
37 views

### Interested in learning cryptography [duplicate]

I'm interested in learning cryptography outside the university(studying civil engineering). I was always interested in computer sciences and programing and in mathematics. I always try to program ...
87 views

### How to calculate AES logarithm table?

I would like to know how to find multiplicative inverses in $\mathrm{GF}(2^8)$. I know how to multiply two elements of $\mathrm{GF}(2^8)$ (for example, I know that ...
60 views

### C# implementation of curve25519 to ed25519 conversions [closed]

WRT the selected answer here: Can curve25519 keys be used with ed25519 keys? Is there any c# implementation of this or equivalent? Thanks.
25 views

As always we are trying to improve password storage; before just adding new ways of storing our password we need to define what threats we will mitigate by adding in a new way to store our password. ...
48 views

### How exactly to extract information base 10 from a PGP RSA key pair?

I think I understand the mathematics of RSA ok. I'm not so computer savvy though. How, exactly, can I extract $n$, $e$, $d$, $p$ and $q$ from a PGP RSA public key pair? Is there like a converter ...
51 views

### If I know the salt, can I decrypt the commitment?

Say, I salt my key(K) with y. So, my new Key is K' = Salt(K+y). Now, Alice sends commitment = E[K',M] to Bob. Bob knows the salt(y), but not K nor K'. Can Bob decrypt the message?
89 views

### (Re-)Using deterministic IV in CTR mode / How to: deterministic AES

I am aware of the requirement of an IV to be unique in CTR mode (Why must IV/key-pairs not be reused in CTR mode?). However I wonder if I can use an IV depending on the plaintext deterministically. ...
23 views

### Is AES_CMAC specified to double ciphered zeroes during initialization?

Reading the SIV RFC https://tools.ietf.org/html/rfc5297#page-9, I found that the S2V function starts by calculating the MAC of a "zero" block, doubles it and then XORs further data to the result. Now ...
50 views

### Is it possible to decrypt this message with partially known data? [closed]

The following highlighted text must contains "547a5e0e008be33730158d63ce844e67" data. I don't know about encryption method and key. Is it possible to decrypt it? Or just give me some idea about ...
55 views

### Encryption and HMAC in a PSKC file

This is the PSKC standard https://tools.ietf.org/rfc/rfc6030.txt In Section 6.1 6.1. Encryption Based on Pre-Shared Keys They have the following ...
70 views

### Embedded devices Authentication, Integrity and Confidentiality

Embedded devices send messages to the server. The server occasionally sends messages to individual devices(Reboot, upgrade firmware etc) After some research this is my ad-hoc solution: 1) Each ...
35 views

### Specific example of a MAC in TLS?

This seems like quite a dumb question, but I really don't know if I'm finding a answer anywhere. I understand that if i access a website that is secured with TLS, we exchange ciphersuites and so on, ...
118 views

### Find private exponent in RSA

The other answers for this confuse me, I know the principle of d in terms of the equation it has to satisfy. However I'm not sure how I would go about finding the private exponent without trial and ...
46 views

### Explanation of the Fiat-Shamir heuristic

The Wikipedia page on the topic (http://en.wikipedia.org/wiki/Fiat%E2%80%93Shamir_heuristic) is completely useless as it only explains what it is and not how it works. I looked at the original paper ...
45 views

### Is a strong block cipher usable as a strong sponge function?

From the literature, it looks like the security proofs of sponge functions depend on how well they approximate a random permutation, Since a block cipher also ideally behaves like a random permutation ...
44 views

### Is there (this) a case in which salting is dispensable?

tl;dr this is not a duplicate of "what is a salt/why use salt?" question. Instead it is specificly asking when salt may not be necessary for hashing securly? (i.e. when the data being hashed is ...
50 views

### What approach is used here? [closed]

Here is an image hidding some information. I need to discover, what is the hidden text. I tried to interpret this as 27 letter alphabet(with space) in columns, tried this with Ceasar cipher. No ...
51 views

### What cipher algorithm is this routine using? [closed]

I transfered a code routine from Java to Python: ...
37 views

### Repeating something encrypted and non-encrypted?

If one wants to keep the receiver's name non encrypted, but it also appears in the encrypted message - will it leak information? (other than the receiver's name, of course.) Let's assume a "bad" case ...
97 views

### practical use of homomorphic encryption

Are RSA and Elgamal partially homomorphic techniques? which one is better if one want to use it for practical purpose? and is there some FHE technique which can be used practically?
87 views

### SHA1 - SSL/TLS Cipher Suite

SHA-1 is on the way to deprecation, in particular for digital certification (x509). But I can't find ressources about SHA-1 deprecation from SSL/TLS Cipher Suites. Is it implicit, as deprecation ...
63 views

### RSA Cryptosytsem, choosing $e$ [duplicate]

I am using the RSA crytposytem. I have $p$, $q$ and hence $n$ and $\phi$ however I don't understand how to get $e$ such that $gcd(e,\phi)=1$ Many thanks
41 views

### block cipher algorithms with variable block lengths

Rijndael supports block lengths of 128, 192 and 256. AES does not but Rijndael does. What other algorithms support variable block lengths? Or is Rijndael unique in that regard?
45 views

### Does SHA-1 hash have quasi commutative property? [closed]

Although I have tested with a program and found negative answer, I want to be sure.
59 views

### Does MD5 hash have quasi commutative property? [duplicate]

I am implementing a one-way accumulator using MD5 hash, wondering wheather it has quasi commutative property or not.
54 views

### special public keys and modulo n

I just picked up cryptography and have some questions on RSA cryptosystem: Say there are two public keys (n, e1), (n, e2), e1 is coprime to e2. They share the same n. Is it possible to find the ...
51 views

### what does rsaSha512Sign do?

I have the following function: ...
85 views

### Rabin Cryptosystem Problem (variant)

My understanding of Rabin We have p and q which are distinct primes congruent to 3 mod 4. ...
130 views

### BruteForcer XOR (bfxor.exe) to attack 64-bit keys and longer

First of all, this is not a beginner's question since I already know a good deal about encryption and brute-force attacks. This is also no question on how to code programs for brute-force attacks ...
62 views

### OpenSSL RSA same plaintext but different ciphertext

how OpenSSL RSA work ? I generate public (n,e) and private key (n,d) then I encypted a file by : ...
64 views

I am encrypting files using AES/CBC/PKCSPadding, with 256 bits long keys. So far the first 16 bytes of each encrypted file are the IV. I would like to store some more information regarding the ...
27 views

### CSPRNG's (ELI5) What's the purpose of multiple seeds/ regenerating sources of entropy (i.e. /dev/random)?

Why is there a need to generate more than one high entropy seed? It would seem like if the original source of entropy is high quality, than some 512 bits should be more than enough to seed a CSPRNG ...
41 views

### TLS - self encrypting to avoid tls setup, secure?

I am in doubt : of course one can create a tl connection between a client and a server. But what if the client sends self encrypted with, say, blowfish, data to the server? The goal is that the ...
52 views

### Signature scheme doesnt seem to hold

I can't seem to verify this signature scheme. Taking this as an example: $p = 23$, $g = 7$, Private Key : $(12$, $20$, $3$, $18)$, $y = 16$ and $q = 2$ This will give me: $y_1 = 7$12$*16$20 \$= ...
44 views

### Davies-Meyer Hash Function

So the Davies-Meyer Hash Function is: Hi = Hi−1 ⊕ exi (Hi−1) Say I pick H0 = 1110 0011 And the message x1 = "5" or "0000 0101" Is this the correct way to compute H1? H1 = 1110 0011 ⊕ (0000 0101 ⊕ ...