# All Questions

502 views

### Recommended Books for Cryptography : Theory and Implementation [closed]

It is a great idea if experts in Cryptography from mathematicians to security engineers introduce books and textbooks which they think is helpful or instructive for all people interested in the ...
321 views

### Digital Certificate Chain Verification

Does a certificate contain the complete chain of all certificates up to the trusted root certificate, or does the program that verifies certificates have to fetch each parent certificate individually ...
62 views

### Design question for a service that signs messages on behalf of a user

I'm working on a messaging service that lets users author messages and have them signed with an RSA key. The key is used for identity purposes only and can be revoked, so compromising the private key ...
557 views

### Deniability of OTR messaging

I've been looking at the off-the-record messaging protocol, and there is something about its deniability property that seems strange to me. Consider the following scenario: In the course of an ...
191 views

### Do Quantum Key Distribution and Physical Unclonable Functions combine, and how?

I see there's a project to combine Quantum Key Distribution, Physical Unclonable Functions, and classical crypto, in order to secure a high speed (100Gb/s) optical link. While there does not seem to ...
2k views

### Deciphering a key from XOR encrypted cypher using boolean logic

Assume there's an unencrypted message A, and an encrypted message B. You know that message B was encrypted using a simple XOR method of A with a private key K, resulting in message B. Thus, B = A ⊕ K ...
591 views

### Expectation Value of the Index of Coincidence

Can Anybody tell me why the expectation value of the Index of Coincidence is the following? For a cipher text string of length $L$, where $n$ is the number of alphabet characters, $k_r = 1/n$, and ...
82 views

### Incorporating known ciphertext into new message

Which ciphers $c_k$ enable one to define a joining function $f_{c,k}$ such that: $$f_{c,k}(c_k(p_1), p_2) = c_k(p_1 + p_2)$$ That is, the result of joining some known ciphertext $c_k(p_1)$ with a ...
580 views

### How to represent a 32-byte SHA2 hash in the shortest possible string?

I'm calculating a SHA2 hash of a certain sensitive key value. I need to store files on disk using this hash a directory path prefix. So lets say I hash the key value 150023, I get a 32-byte value ...
123 views

### Tips on conceiving safe software messaging platform

I have a personal project in mind in which I plan to use cryptography in order to let the users be confident in the fact that, even if all data get's stolen, it would be virtually impossible to crack ...
502 views

### Brute forcing Cardan grille

Having a "rotating" square Cardan Grill with sides long n cells, how could i determinate the cost of a brute-force attack? How many configurations should be considered to perform an exhaustive ...
301 views

### Twofish key length

I'm using twofish. Say you have a 120 bit key, is there any difference in using a 128 bit bit keylength or a 256 bit one? Since the most significant digits of the key will be allo zero in both cases, ...
594 views

### Is this fixed length MAC unforgeable?

Consider the following fixed length MAC for messages of length $\ell(n)=2n-2$ using a pseudorandom function $F$: On input of a mesage $m_0||m_1$ ($|m_0| = |m_1| = n-1$) and a key $k \in \{0,1\}^n$, ...
143 views

### How is the password sent across for verification?

I am familiar with Challenge-Response Authentication scheme. However I would like to know actual message content sent between client and server for 1 way authentication, over an insecure channel. ...
721 views

### iSeries (AS/400) Database File: password encryption

I am helping with a project in which an old software system on an iSeries is having a brand new .NET UI applied to it. It's going well... except... In order to allow users to login and maintain ...
12 views

### Why Curve25519 for encryption but Ed25519 for signatures?

NaCl and libsodium libraries use Curve25519 for authenticated encryption (actually for sharing a key which is used for encryption) and Ed25519 for signatures. What is the purpose of using different ...
39 views

### Authenticating with a document

Hope you're having a nice day. I need to implement an authentication system between a "document" (it's not exactly a document, but an object without any computing capacity, only able to store ...
102 views

### Proving an encrypted message contains (but does not 100% consist of) a plain-text message?

I have keypair (u,r), and two pieces of data, X and Y. I reveal X publicly but keep Y secret. Y has high entropy. I then concatenate X and Y, into Z. I encrypt Z, into "encrypt(Z,u) = Q". r is ...
22 views

### Clarification of RFC2246 with regards to Finished Message

I'm working on a client handshake finished message for a TLS client, and I'm reading through the RFC 2246 spec. The spec states (in section 7.4.9): The hash contained in finished messages sent by ...
38 views

### How can I handle the situation if key size is less than 64 bits in DES?

If the data is not a multiple of 64 bits, then I can use padding. I know that it is not secure. But if the key is less than or more than 64 bits, should I ask the user to enter the key again, or ...
44 views

### Is there a standard for public key encrypting and signing short messages?

Some systems, that operate over flaky bearers, need to send signed, encrypted messages that are entirely self contained - i.e. send a single 300 byte UDP rather than have a 10Kb, two-way, certificate ...
36 views

### Triple-DES DUKPT CBC PIN variant vs Data variant

Does any know the difference between triple des dukpt decryption algorithm with PIN variant and Data variant? I have done Triple DES DUKPT PIN variant, which generate session key from KSN and BDK. ...
49 views

### public key cryptography and authentication for cross-platform network application

I'm developing network based application for control and telemetry on Linux based embedded system. I'm using ZMQ network library and Google Protocol Buffers serialization library for communication ...
46 views

### Difference between RSA-617 and RSA-2048

according to wikipedia: RSA-617 has 617 decimal digits (2,048 bits). RSA-2048 has 617 decimal digits (2,048 bits). What is the main difference between them?
85 views

### Secret Sharing Encryption

Suppose Alice shares a secret block cipher key, $K_{AB}$ with Bob, and a different secret block cipher key, $K_{AC}$ with Charlie. Describe a method for Alice to encrypt an m block message such that ...
73 views

### Modular Multiplicative Inverse and RSA?

In trying to understand this specific part of the RSA algorithm, I found this online... I understand by Euler's theorem, that $d^{\phi(n)}$ = 1 mod $n$ What I don't understand is the substitution ...
49 views

### Factors of the group order to secure against Pohlig-Hellman

I am looking into the security of Diffie-Hellman and the discrete log in general. To make sure an attacker can not use Pohlig-Hellman to solve the discrete log quickly we need to make sure that the ...
71 views

### Proving security of TLS handshake with ProVerif

Background For my dissertation I am working on an application protocol for which I require a TLS session. I am looking to achieve Perfect Forward Secrecy, which means I have selected ephemeral ...
72 views

### SSL pinning - how to safely hide the certificate?

We are doing an iPhone app and read multiple forums which says SSL pinning makes it possible to avoid man in the middle as we trust our web services server through the certificate which will be pre ...
91 views

### Simulation Based Proof: How the Corrupted Party's Input is Given To Simulator

Imagine we have a 3-party protocol, including client $A$,client $B$ and a server. In this protocol client $B$ encrypts its input under its public key and sends it to the server. The server performs ...
38 views

### ssh-keygen DH Primality Testing

I'm pretty familiar with using ssh-keygen to create groups that go in the /etc/ssh/moduli file for the Diffie-Hellman Group Exchange in openssh. Reading over the man page, it says "By default, each ...
45 views

### Encryption algorithms larger than 256 Bit for “big data” encryption?

I'm somewhat new to encryption. When looking at encryption programs for big data, I frequently see a maximum of 256 bits. Why do we generally restrict our (symmetric) keys to 256 bits? Can more ...
46 views

### How AES treat string input to encrypt data and what will happen if the cipher key is less than that expected?

The official docs of AES have several example of how hexadecimal or byte input can be encrypted. I have some problem about the input text and cipher key. My question is: How can encrypt string input ...
31 views

64 views

### Converting a pre-image resistant hash to second pre-image resistant

I am looking for some standard conversion from any hash function $f$, which has pre-image resistance, to another hash function with second preimage resistance. Is there such a standard conversion?
81 views

### Simulation based proofs: Simple examples

I am aware that,(in theory) in order to proof that a scheme is secure using simulation based proof we replace an adversary in real world with a simulator in ideal world. Then we try to show that their ...
47 views

### ElGamal and Paillier key sizes for short messages

I am using ElGamal and Paillier schemes to encrypt a large number of short messages: typical 4-byte integers. I do this for the homomorphic properties of these schemes. However, the way the ...
38 views

### Unconditional authentication

I have a few questions regarding universal-hash functions: Is there a way universal hash functions can be used to provide unconditional authentication in the way the OTP provides unconditional ...
63 views

### Is it a good practice to use plain text for derivation of Keys?

I have a question regarding the derivation of keys in crypto. Is it a good practice to use the plain text (in form of hashes) for derivation of keys ? these keys will be used for encryption of the ...
40 views

### “Order” in cryptographic terms for generators

Frequently I have seen people use the term order in cryptography (the group theoretic one). I have a mathematical background and order (say for prime modulus $p$) is defined as the smallest integer ...
50 views

### AES-CBC pre-determined IV vs. null IV

Is there any security advantage to using a pre-determined IV in CBC mode over a null IV? I'm implementing a license key system similar to this article on CodeProject, but I'm confused by the authors ...
115 views

### TRNG vs PRNG - Entropy?

How much more entropy gives a Hardware Random Number Generator or True Random Number Generator compared to a Pseudo Random Number Generator? I know it depends on which TRNG is used, but I'm thinking ...
63 views

Suppose I have a message $M$ for which I generate an RSA-2048 digital signature as follows: $H = H(M)$, $H(M)$ being the SHA-256 of the message $M$ $S = H^d \bmod N$ Assume $N = pq$ is properly ...
31 views

### J-PAKE : About Schnorr NIZK proof for ephemeral private keys

Reading J-PAKE Authenticated Key Exchange Without PKI document : J-PAKE Round 1 : Alice sends out g^x1 and knowledge proof for x1, e.g : To prove the knowledge of the exponent for X = g^x1 ...