Fast format-preserving encryption for variable length data
AssigneeVisa International Service Association
InventorEugene Pivovarov
Life of this patent
Estimating the term…
Abstract
Systems, apparatuses, and methods are provided for fast format-preserving encryption. An input string can be divided into blocks (potentially of varying length). An arrangement of cryptographic pipelines can perform operations on different blocks, each pipeline providing an output block. The cryptographic pipelines can interact such that the output blocks are dependent on each other, thereby providing strong encryption. The pipelines can operate efficiently on the block and operations can occur partly in parallel.
Claims20
A method for performing a format-preserving cryptographic operation, the method comprising performing, at a computer system:
- receiving an input string of M characters, M being an integer greater than 4;
- dividing the input string into a plurality of sub strings;
- storing one or more substitution tables, each of the one or more substitution tables corresponding to at least one substring of the plurality of substrings and providing an output block of a respective number of characters based on an input block of the same respective number of characters;
- loading a plurality of cryptographic pipelines, each corresponding to one substring of the plurality of sub strings, wherein the plurality of cryptographic pipelines have an ordered arrangement such that a starting cryptographic pipeline has one forward neighboring pipeline, a final cryptographic pipeline has one reverse neighboring pipeline, and any other cryptographic pipelines have a two neighboring pipelines;
- for each of the plurality of cryptographic pipelines:
- performing a first substitution operation using a corresponding substitution table of a same size as the corresponding substring to obtain a first output block based on a first input block that corresponds to the input string;
- after the first substitution operation, sending the first output block to a forward neighbor pipeline when the forward neighbor pipeline exists for the forward neighbor pipeline to use the first output block and a neighbor block corresponding to a neighbor sub string in a first combination operation to obtain a neighbor input block to be used for a neighbor substitution operation;
- applying a mask function to an intermediate input block corresponding to the first output block to obtain an intermediate output block, the mask function dependent on output blocks of at least two of the plurality of cryptographic pipelines;
- when the cryptographic pipeline has a reverse neighbor pipeline, sending a first intermediate block to the reverse neighbor pipeline to use the first intermediate block with a neighbor intermediate block in a second combination operation, the first intermediate block being the intermediate output block or derived from the intermediate output block;
- and
- performing a final substitution operation using the corresponding substitution table as part of obtaining a final output block based on the intermediate output block, the final output block being obtained further based on the second combination operation when the forward neighbor pipeline exists, wherein the final output block has a same size as the corresponding substring;
- assembling the final output blocks of the plurality of cryptographic pipelines to obtain an output string of M characters;
- and
- sending a message comprising at least the output string to another device.
A computer system for performing a format-preserving cryptographic operation, the computer system comprising:
- one or more processors;
- and
- a computer readable medium storing instructions for controlling the one or more processors to perform:
- receiving an input string of M characters, M being an integer greater than 6;
- dividing the input string into a plurality of sub strings;
- storing one or more substitution tables, each of the one or more substitution tables corresponding to at least one substring and providing an output block of a respective number of characters based on an input block of the same respective number of characters;
- loading a plurality of cryptographic pipelines, each corresponding to one of the plurality of sub strings, wherein the plurality of cryptographic pipelines have an ordered arrangement such that a starting cryptographic pipeline has one forward neighboring pipeline, a final cryptographic pipeline has one reverse neighboring pipeline, and any other cryptographic pipelines have a two neighboring pipelines;
- for each of the plurality of cryptographic pipelines:
- performing a first substitution operation using a corresponding substitution table of a same size as the corresponding substring to obtain a first output block based on a first input block that corresponds to the input string;
- after the first substitution operation, sending the first output block to a forward neighbor pipeline when the forward neighbor pipeline exists for the forward neighbor pipeline to use the first output block and a neighbor block corresponding to a neighbor sub string in a first combination operation to obtain a neighbor input block to be used for a neighbor substitution operation;
- applying a mask function to an intermediate input block corresponding to the first output block to obtain an intermediate output block, the mask function dependent on output blocks of at least two of the plurality of cryptographic pipelines;
- when the cryptographic pipeline has a reverse neighbor pipeline, sending a first intermediate block to the reverse neighbor pipeline to use the first intermediate block with a neighbor intermediate block in a second combination operation, the first intermediate block being the intermediate output block or derived from the intermediate output block;
- and
- performing a final substitution operation using the corresponding substitution table as part of obtaining a final output block based on the intermediate output block, the final output block being obtained further based on the second combination operation when the forward neighbor pipeline exists, wherein the final output block has a same size as the corresponding substring;
- and
- assembling the final output blocks of the plurality of cryptographic pipelines to obtain an output string of M characters;
- and
- sending a message comprising at least the output string to another device.
Dependencies are inferred from the claim text.