Skip to content

Add std::crypto to pattern language - #260

Open
a-sakharov wants to merge 1 commit into
WerWolv:masterfrom
a-sakharov:crypto
Open

a-sakharov wants to merge 1 commit into
WerWolv:masterfrom
a-sakharov:crypto

Conversation

@a-sakharov

Copy link
Copy Markdown

Hello.

Sometimes files are completely or partially (usually headers only) encrypted, and patterns couldn't be applied without at least partial decryption. Of course, it could be done with the pattern language, but it's really slow when processing arrays byte by byte.

I've implemented only an XOR function now, which could be used to apply a variable-length XOR key (from a single byte) to a variable-length encoded buffer. In my tests, it's saving about 28 seconds when applied to a 520 KB buffer.

I would like to implement other algorithms if this request will be accepted when I encounter files that require this for applying patterns.

To reinforce my position, some files use XOR to hide their contents:

Arx Fatalis data paks
Plants vs Zombies data paks
MS COFF (only the part with the "Rich header")
Wolf RPG games data

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant