Questions tagged [format-preserving]

Format-preserving encryption (FPE) refers to encrypting in such a way that the output has the same length as the input, or otherwise has the same format or structure as the input.

Filter by
Sorted by
Tagged with
18 votes
3 answers
3k views

Can you create a strong blockcipher with small blocksize, given a strong blockcipher of conventional blocksize?

Suppose I want a strong 20-bit blockcipher. In other words, I want a function that takes a key (suppose the key is 128 bits), and implements a permutation from 20 bits to 20 bits. The set of ...
Fixee's user avatar
  • 4,158
11 votes
3 answers
4k views

Is there a length-preserving encryption scheme?

Is there a length-preserving encryption scheme, that preserves the lengths of input sizes such that the length of the input plain text is same as length of the output cipher text ?
Digerkam's user avatar
  • 219
10 votes
1 answer
2k views

Is there a format preserving cryptographically secure hash?

I want a way to 'scramble' strings (like words, names) in a predictable way but I don't ever want to (myself or anyone else) be able to 'unscramble' the strings. I found that perhaps what I am ...
erotavlas's user avatar
  • 507
24 votes
3 answers
2k views

Selective format-compliant JPEG encryption?

I am working towards building a format-compliant encryption system for pictures. The aim of it is to be able to obscure specific areas of a picture (i.e. faces, car license numbers...) while keeping ...
DashDotDashDot's user avatar
10 votes
3 answers
2k views

What is the most computationally efficient way of generating pseudo-random permutations?

I have an application in which I need to create up to J randomly shuffled-copies of an array of length N. Then I will have millions or even billions of iterations such that, in each iteration, I will ...
user44353's user avatar
  • 101
6 votes
4 answers
2k views

Encryption algorithm that produces dummy output on incorrect passwords

Background: I've been thinking about using encryption in the context of backing up files to untrusted locations (to the point of making the file publicly and widely distributed for practically ...
Jack Singleton's user avatar
4 votes
1 answer
1k views

Asymmetric format preserving encryption?

I would like to encrypt a string asymmetrically. I would like the ciphertext to be as short as as plaintext. (or shorter) I've read about format preserving encryption functions - are there ...
Skip's user avatar
  • 167
1 vote
1 answer
750 views

Recover plaintext from truncated ciphertext using AES for FPE

I am trying to implement an FPE for a 19-digit long number. I am trying to follow the lecture of Prof. Dan Boneh and here is how I understand it: Get the nearest power of two greater than $10^{19} \...
Frank Smith's user avatar
5 votes
3 answers
8k views

What algorithm would give the shortest ciphertext for very short plaintexts?

I have to encrypt some very short messages (approx. 5 characters) and I would like the ciphertext to be as short as possible. I am currently using AES but the initialization vector (IV) is making my ...
JoelFan's user avatar
  • 295
5 votes
2 answers
2k views

Can you help me understand Format Preserving Encryption?

I came across the definition of format-preserving encryption (FPE) as first defined in a seminal paper by Black and Rogaway. Based on their paper, FPE (or prefix cipher) is defined as follows (quoted ...
Hashed's user avatar
  • 185
4 votes
2 answers
933 views

Authenticated encryption without padding

I want to encrypt data and protect its integrity and confidentiality. However, I cannot increase the length of the data. Are there any cipher modes of operation which provide confidentiality and ...
Gev_sedrakyan's user avatar
3 votes
3 answers
4k views

Format Preserving Encryption for 32 or 64 bit plaintext values

I am looking for a Format Preserving Encryption implementation to apply to either a 32-bit or a 64-bit integer. It looks like AES/FFX mode is just what I need in terms of established security ...
Tim's user avatar
  • 31
3 votes
1 answer
928 views

Is format preserving encryption suitable for use with words or names?

Is it possible to use FPE to encrypt names and language words like 'Bob' 'the' 'tree', in order to preserve both length and format (like keeping characters within a certain range like A-Z a-z) The ...
erotavlas's user avatar
  • 507
3 votes
1 answer
495 views

Format preserving encryption FFX

In FFX mode the format of the ciphertext is same as plaintext. How does it ensure data integrity and authentication? Is there any bit flip attack in FFX mode? Is it malleable?
user3425935's user avatar
3 votes
3 answers
2k views

Is there a cryptographic method to add noise to a plaintext instead of actually encrypting it?

I'm looking for a cryptographic technique that instead of permuting a cleartext, would add noise to the cleartext to obfuscate the true text among a bunch of garbage. For example, a list of 10 ...
argybargy3's user avatar
1 vote
1 answer
289 views

Algorithm to transform plaintext to a key of desired keysize, when using input plaintext as key for FPE?

Using a format preserving encryption scheme that uses AES internally as its block cipher, for a plaintext that I encrypt I want to use that input plaintext as the key. However using AES-128, my ...
erotavlas's user avatar
  • 507
1 vote
2 answers
3k views

Want to generate numeric coupon codes?

We want to generate coupon code series and then encrypt those coupon code in numeric only, and that must also be decipherable. We will be sharing encrypted code as coupon code with customer. These ...
murtaza.webdev's user avatar
1 vote
1 answer
280 views

Is there a construction for a variable length block cipher that uses a fixed length one?

I'm looking for some way to take a fixed length block cipher (for example AES) and turn it into a variable length one with comparable security. The new length may be bigger or smaller than the ...
Daffy's user avatar
  • 2,389