Generating cryptographic function parameters from compact source code
Methods, systems, and computer programs for generating cryptographic function parameters are described. In some examples, source code that defines seed information and a pseudorandom function is accessed. A parameter for a cryptographic function by operation of one or more data processors is generated. The parameter is generated from the seed information and the pseudorandom function. The parameter has a larger size in memory than the source code that defines the seed information and the pseudorandom function.
1. A cryptography method comprising:
accessing a source code that defines seed information and a pseudorandom function, wherein the source code comprises a programming language that assembles or compiles into a machine language executable by one or more data processors, the source code has a complexity lower than a predefined threshold, the complexity measured based on a code length of the source code;
generating a parameter for a cryptographic function, wherein the parameter comprises a constant for the cryptographic function, the parameter is generated from the seed information and the pseudorandom function, and the parameter is a number that has a larger size in memory than the source code that defines the seed information and the pseudorandom function;
encrypting data using the generated parameter and the cryptographic function; and
transmitting the encrypted data.
2. The method of claim 1 , wherein generating the parameter comprises deriving the parameter from one or more outputs produced by operating the pseudorandom function seeded by the seed information.
3. The method of claim 1 , wherein the source code comprises a minimal-size source code for generating the parameter for the cryptographic function.
4. The method of claim 1 , further comprising using the parameter to perform cryptographic operations according to a cryptographic communication protocol.
5. The method of claim 1 , comprising generating a full set of parameters for the cryptographic function, the full set of parameters having a larger size in memory than the source code that defines the seed information and the pseudorandom function.
6. The method of claim 5 , wherein the source code comprises an incompressible code for generating a full set of parameters for the cryptographic function.
7. A computing system comprising:
memory storing a source code that defines seed information and a pseudorandom function, wherein the source code comprises a programming language that assembles or compiles into a machine language executable by one or more data processors, the source code has a complexity lower than a predefined threshold, the complexity measured based on a code length of the source code; and
the one or more data processors configured to:
generate, from the seed information and the pseudorandom function, a parameter for a cryptographic function, wherein the parameter comprises a constant for the cryptographic function, the parameter is a number that has a larger size in memory than the source code that defines the seed information and the pseudorandom function;
encrypt data using the generated parameter and the cryptographic function; and transmit the encrypted data.
8. The system of claim 7 , wherein generating the parameter comprises deriving the parameter from one or more outputs produced by operating the pseudorandom function seeded by the seed information.
9. The system of claim 7 , wherein the source code comprises a minimal-size source code for generating the parameter for the cryptographic function.
10. The system of claim 7 , further comprising a terminal configured to use the parameter in a cryptographic communication protocol.
11. The system of claim 7 , the one or more data processors configured to generate a full set of parameter for the cryptographic function, the full set of parameter having a larger size in memory than the source code that defines the seed information and the pseudorandom function.
12. A non-transitory computer-readable medium storing instructions that, when executed by a data processing apparatus, cause the data processing apparatus to perform operations comprising:
accessing a source code that defines seed information and a pseudorandom function, wherein the source code comprises a programming language that assembles or compiles into a machine language executable by one or more data processors, the source code has a complexity lower than a predefined threshold, the complexity measured based on a code length of the source code;
generating a parameter for a cryptographic function, wherein the parameter comprises a constant for the cryptographic function, the parameter is generated from the seed information and the pseudorandom function, and the parameter is a number that has a larger size in memory than the source code that defines the seed information and the pseudorandom function;
encrypting data using the generated parameter and the cryptographic function; and
transmitting the encrypted data.
13. The computer-readable medium of claim 12 , wherein generating the parameter comprises deriving the parameter from one or more outputs produced by operating the pseudorandom function seeded by the seed information.
14. The computer-readable medium of claim 12 , wherein the source code comprises a minimal-size source code for generating the parameter for the cryptographic function.
15. The computer-readable medium of claim 12 , the operations further comprising using the parameter in a cryptographic communication protocol.
16. The computer-readable medium of claim 12 , the operations comprising generating a full set of parameters for the cryptographic function, the full set of parameters having a larger size in memory than the source code that defines the seed information and the pseudorandom function.