US 11,748,460 B2
Procedural code generation for challenge code
Emil Hernvall, Vällingby (SE); and Daniel Spång, Solna (SE)
Assigned to Imperva, Inc., San Mateo, CA (US)
Filed by Imperva, Inc., San Mateo, CA (US)
Filed on Oct. 30, 2020, as Appl. No. 17/84,659.
Claims priority of provisional application 62/704,207, filed on Apr. 27, 2020.
Prior Publication US 2021/0334342 A1, Oct. 28, 2021
Int. Cl. H04L 9/40 (2022.01); G06F 21/14 (2013.01); G06F 8/40 (2018.01); H04L 9/08 (2006.01); G06F 9/455 (2018.01)
CPC G06F 21/14 (2013.01) [G06F 8/40 (2013.01); G06F 9/4552 (2013.01); H04L 9/0869 (2013.01); H04L 63/1416 (2013.01); G06F 2221/0724 (2013.01); G06F 2221/2151 (2013.01); H04L 2463/144 (2013.01)] 20 Claims
OG exemplary drawing
 
1. A method by one or more computing devices for obfuscating challenge code, the method comprising:
obtain challenge code for interrogating a client;
inserting, into the challenge code, code for obfuscating outputs that are to be generated by the client, wherein the outputs include interrogation results that are to be sent to a remote bot detection server for analysis, wherein the code for obfuscating the outputs includes code for applying a first chain of reversible transformations to the outputs using client-generated random values;
interning strings appearing in the challenge code with obfuscated strings;
inserting code for deobfuscating the obfuscated strings into the challenge code;
inlining function calls in the challenge code;
removing function calls in the challenge code;
removing function definitions that are unused in the challenge code due to the inlining;
reordering the challenge code without changing the functionality of the challenge code; and
providing the challenge code for execution by the client.