# All Questions

278 views

### Why not encrypt salt?

Assuming I had to distribute salt+ciphertext together over an insecure channel, isn't it better to store the salt encrypted? By encrypted I mean with a block cipher and with key and IV derived from ...
322 views

### Can you help me with this Random Number Generator function?

By someone's suggestion, I am posting this question from math.stackexchange.com. I want to find out a suitable function or algorithm, which can provide a random sequence like this… Input: $3$ ...
427 views

### Is this a good way to encrypt a file?

I need to encrypt a file, distribute it over an insecure channel, and decrypt it later. Using a symmetric-key algorithm. Here's what I intend to do: Get a password P from the user. Generate a 16-byte ...
342 views

### Why pairing based crypto is suitable for some particular cryptographic primitives?

Why pairing based crypto is being widely used in some special crypto primitives as ID based crypto and variations of standard signatures? I mean taking as deep as possible what makes it suitable for ...
327 views

### Secure Hash Function based on AES

How secure would a hash function be which appends an extra block of 16 zeroed out bytes to the end of the message and then AES-encrypts it with a well-known password (say the first 128 bits of pi) ...
314 views

### What are the safe ways to derive HMAC key using block cipher?

Suppose we have a state of block cipher initialized with some key unknown to us, that is, we have the state after running key schedule, but we have no access to actual key or subkeys, all we can do is ...
381 views

### Can iterated key expansion in Blowfish slow down bruteforce attacks on small key sizes?

Suppose I have to use 64-bit keys for encryption (e.g. to comply with export restrictions). For this question, assume this key is truly random, and the encryption algorithm is Blowfish. Blowfish key ...
561 views

### Storage of Private Keys

I'm building a bitcoin web application that will require all users to be assigned a wallet for adding funds to their account. I plan on exposing the public key to the user (the bitcoin address). Users ...
343 views

### How is block cipher padding verified for consistancy?

Under what circumstances is a decryption routine able to tell that the padding of a message is invalid? If a cipher text block where to be randomly modified, what is the probability that the padding ...
2k views

### Malleability attacks against encryption without authentication

Suppose there is a message that is encrypted with AES-128-CBC. The message is as follows, new lines are used to delimit the 16 byte boundary for each block: ...
22k views

### How is CipherCloud doing homomorphic encryption?

Much of the literature and latest papers suggest that homomorphic encryption is still not practical yet. How is CipherCloud able to achieve this? Does anyone have an idea? Their website does not ...
3k views

### Is there a way to make RC4 (ARCFOUR) secure, or is it completely broken?

I need a method to authenticate a process with another in order to establish interprocess communication between them, to prevent malicious processes from trying to hook onto the system. Currently I ...
610 views

### Is there another resource for Carter-Wegman-style message authentication?

I'm wondering if there are other resources that cover Carter-Wegman style message authentication, besides the sources themselves. Is there an online text or a book that covers their ideas? I'd ...
588 views

### How to submit a new method of encryption?

I came up with a truly new method of applying modulo-2-addition encryption function in stream ciphers which is inspired by a mechanism used to prove a mathematical theorem. How can I determine whether ...
217 views

### Is it OK to use a data-encryption key for key wrapping, too?

Our industry (area of cheap networked devices) has a standard that defines the usage of keys for both authentication and encryption using EAX mode of AES. This standard does not define key management, ...
882 views

### Self-expiring symmetric keys, or: cryptography in absence of secure deletion

I can encrypt some data D using a random symmetric key K, obtaining a ciphertext C, and then encrypt K with my public key Pub and obtain H. So far so good: I can only decrypt C if I have H and my ...
2k views

### Can Elgamal be made additively homomorphic and how could it be used for E-voting?

Elgamal is a cryptosystem that is homomorphic over multiplication. How can I convert it to an additive homomorphic cryptosystem? How can I use this additive homomorphic Elgamal cryptosystem for ...
655 views

### Can I make a cipher (ex: Vigenère) harder to break?

The Vigenère cipher can relatively easy be broken when the key size is small compared to the size of the message. One first finds the length of the key, and then uses frequency analysis to actually ...
273 views

### Detect tampering of data

I have the following problem: There are $n$ users and each users fills in three data points per day, this are three integers between say $-10$ and $10$. I have access to the database and hence I am ...
3k views

### How do ciphers change plaintext into numeric digits for computing?

For example, in RSA, we use this for encryption: $ciphertext = (m^e \mod n)$ and for decryption. If our message is "hello world", then what number do we have to ...
12k views

### What is the effect of the different AES key lengths?

How does a changing key length affects the ciphertext, not only in case of AES, but in general? I know that the key spaces become much larger and the number of rounds in case of AES changes, but is ...
1k views

### HRNG for One Time Pad

I have just advanced to the last grade of high school (in Denmark). In this year, we all get to do one big project, where we can build/invent/create whatever we want to "solve a problem". As I study ...
12k views

### Why is padding used for RSA encryption given that it is not a block cipher?

In AES we use some padded bytes at end of message to fit 128/256 byte blocks. But as RSA is not a block cipher why is padding used? Can the message size be any byte length (is the encrypting agent ...
324 views

### Security considerations for partially shared password databases

Programs like KeyPass and 1Password store password database files encrypted by a single password. If someone knows the protecting password ("Vault Key"), they can read the entire database ("secrets"). ...
344 views

### Blowfish Encryptions in Bcrypt hashing algorithm

I am trying to understand the ExpandKey function used in the bcrypt hashing algorithm. As per the documentation of bcrypt hashing algorithm on USENIX here: ...
1k views

### Difference in one time key and one time pad and many time key

These terms are confusing me. One time pad is when you use one key for one message. That is what One time key is. Secondly, what is the connection of many time key, can i use one time pad many ...
388 views

### Why can't Homomorphic encryption schemes support algorithms with conditions/branching?

If it isn't already apparent from the title of my question, i should make clear that I have only a very basic understanding of homomorphic encryption. I would like to know why homomorphic encryption ...
1k views

### Is it possible to pick your Ed25519 public key?

Is it possible to generate an Ed25519 keypair that has a very similar public key as another keypair (fooling a casual visual comparison) or is this as hard as solving one of SHA-512 or the discrete ...
796 views

### RSA 1024bit decryption performance

i want to know how many RSA 1024 bit long key decryption can a regular pentium4 computer do per second ? how to calculate RSA performance and determine its remaining time ?
205 views

### Zero Knowledge auth schemes with weak secret

In Zero Knowledge auth schemes the public DH factor of each peer is encrypted with a potentially weak pre-shared secret and the resulting ciphertexts are exchanged over an insecure channel. Why is no ...
669 views

### Cryptanalysing Affine cipher

I am trying to cryptanalyse a cipher–text encrypted by Affine cipher. The encryption formula is: $c = f(x) = (ax+b)\bmod m$, where $a$ and $b$ are unknown constants; $x$ is a plain-text symbol, and ...
250 views

### data structure of random / compressed data

can anybody explain to me what data structure results after data is compressed? I just try to find out the difference between random data and compressed data, the entropy of both is very high while ...
426 views

### How do I calculate the maximum plain text length allowable for a certain cipher text length?

I am encrypting and storing sensitive values in the database. I have a set max length in the database, but in order to provide useful user feedback, I'd like to know the max input I should allow for a ...
774 views

### Can I use PBKDF2 for authentication and decryption?

I want to store a hash for authenticating a password. I also want to use the same password for decryption. Can I use PBKDF2 for both? (I plan to use different salts for the authentication and the ...
5k views

### How do I store encrypted files on a web server and decrypt them locally?

I want to store files (images) on a public webserver and let users see them if they know a password. The server shouldn't have the unecrypted files and the server can only serve files, not perform ...
531 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 ...
244 views

### Using chi square for distinguishing between compressed and random data

I am trying to find some measurement for identifying and distinguishing between compressed and random data. I tried this first by computing the entropy of such data, the entropy value is extremely ...
5k views

### Are there hash algorithms with variable length output?

I understand that for example MD5 produces a 128 bit hash value from a given text of variable size. My question is if there is a hash-like algorithm that will produce a hash value where one can ...
2k views

### Homomorphic cryptosystems in RSA

Hopefully Crypto can help me understand homomorphic cryptosystems. I'm designing a high score server for a game I made, and because of facets in the language i'm using, the player would be able to ...
958 views

### How to implement order preserving encryption or order preserving hashing [closed]

Does anybody know any free implementation of either order preserving encryption or order preserving hashing? I've found some codes like CMPH but I need to dynamically add new DATA and that's why most ...
3k views

### Common modulus attack on RSA when the 2 public exponents differ by a single bit

This is an exam question an i have no idea how to recover the message m. John wants to send an encrypted message to mary who has a pair of RSA keys, However, John does not know Mary's public key and ...
758 views

### What is the actual difference between security through obscurity and true encryption?

In an abstract sense, aren't both the same? Don't their definitions boil down to the following? security through obscurity: trying to make sure some information cannot be obtained without knowing ...
309 views

### The security of data traffic over both SSTP & SSL

Suppose you're connected to a VPN server via an SSTP VPN, and then you're trying to sign in to your webmail account that is already secured with an SSL certificate, e.g. hushmail.com. However, it ...
460 views

### Is any decent RNG acceptable as a stream cipher?

I have a function f(x,n) that takes a 128-bit key x, and generates n bytes of pseudo-random data. I've tested the output bytes this function for various keys with the NIST RNG testing suite (NIST ...
332 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 ...
306 views

### Is a continuous stream of encrypted data embedded in garbage more or less secure than only encrypting the data?

Consider a communication channel that needs to be secure (Encryption can not use full "volume" encryption, since future messages are not known). Would it be better to only transmit encrypted ...
1k views

### AES CCM vs CCMP

Are the terms AES CCM and AES CCMP are equivalent, or is there any technical differences between the two?
128 views

### MD5 pre-fixing with an unkown postfix

Is the MD5 prefixing attack still valuable to an attacker if he doesn't know the postfix of the string? For instance, what if the following sanity check was being used: ...