Examples
Example keys and passwords are public test material.
A release identifier
Input
RELEASEONEExpected checks
RC2 Decrypt recovers:
52454c454153454f4e45- Key
{"option":"Hex","string":"0001020304050607"}- IV
{"option":"Hex","string":"0000000000000000"}- Input
Raw- Output
Hex
A sensor label
Input
SENSORWESTExpected checks
RC2 Decrypt recovers:
53454e534f5257455354- Key
{"option":"Hex","string":"0001020304050607"}- IV
{"option":"Hex","string":"0000000000000000"}- Input
Raw- Output
Hex
A telescope target
Input
MOONPHASESExpected checks
RC2 Decrypt recovers:
4d4f4f4e504841534553- Key
{"option":"Hex","string":"0001020304050607"}- IV
{"option":"Hex","string":"0000000000000000"}- Input
Raw- Output
Hex
A toy puzzle clue
Input
FOLLOWBIRDExpected checks
RC2 Decrypt recovers:
464f4c4c4f5742495244- Key
{"option":"Hex","string":"0001020304050607"}- IV
{"option":"Hex","string":"0000000000000000"}- Input
Raw- Output
Hex
An archive marker
Input
ARCHIVEDOCExpected checks
RC2 Decrypt recovers:
41524348495645444f43- Key
{"option":"Hex","string":"0001020304050607"}- IV
{"option":"Hex","string":"0000000000000000"}- Input
Raw- Output
Hex
no key
Input
7a0e643132750e96d805d11e9e48e281fa39a41039286423cc1c045e5442b40bf1c3f2822bded3f9c8ef11cb25da64dda9c7ab87c246bd305385150c98f31465c2a6180fe81d31ea289b916504d5a12e1de26cb10adba84a0cb0c86f94bc14bc554f3018Expected rejection
Message containsd3644d898b51a544f690b506c3fd0caeb7a1e6097f7ea28f69b909a4d8805c9a05f4cade8b281d3f044fa069374efb90e94723622c86afc17caee394ffbee0abe627de299208460eb981c9d56f9df885091c6c89e2ee173264b2820b8e67675214e6545a05dc0d3f- Key
{"option":"Hex","string":""}- IV
{"option":"Hex","string":""}- Input
Hex- Output
Hex
RC2-CBC, Binary
Input
7a0e643132750e96d805d11e9e48e281fa39a41039286423cc1c045e5442b40bf1c3f2822bded3f9c8ef11cb25da64dda9c7ab87c246bd305385150c98f31465c2a6180fe81d31ea289b916504d5a12e1de26cb10adba84a0cb0c86f94bc14bc554f3018Expected answer
d25e5bc6c9311ef196d6f21cc4b0274b29fcca366aba5256406e02bf4ae628398f84e7d72ad92025ede76df4752d1510fe9c3492efb1dcf0be2cd41d619e10b9dd5a2304c2efbd3598d3b87f1a21f326d45e65537563436cfb6e4a41ec3733182ddc058f96f74a6cd25e5bc6c9311ef196d6f21cc4b0274b29fcca366aba5256406e02bf4ae628398f84e7d72ad92025ede76df4752d1510fe9c3492efb1dcf0be2cd41d619e10b9dd5a2304c2efbd3598d3b87f1a21f326d45e65537563436cfb6e4a41ec3733182ddc058f96f74a6c
- Key
{"option":"Hex","string":"eb970554bb213430f4bb4e5988a6a218"}- IV
{"option":"Hex","string":"ae817c784a097e0c"}- Input
Hex- Output
Hex
RC2-ECB, Binary
Input
7a0e643132750e96d805d11e9e48e281fa39a41039286423cc1c045e5442b40bf1c3f2822bded3f9c8ef11cb25da64dda9c7ab87c246bd305385150c98f31465c2a6180fe81d31ea289b916504d5a12e1de26cb10adba84a0cb0c86f94bc14bc554f3018Expected answer
a160bf23b2a85eaa43d26753e51aaa899f162ec0da7280fffd41b705c5309c7fef2bbb56bf261cab4eadd3a5c69e0a67d45e426d1097187cc9a959b4d979a9d40df26f3dc8d030453fe27701438b78d3ce044330b4b5dca7832537ecf40b914f1b1dc16d4e6d7229a160bf23b2a85eaa43d26753e51aaa899f162ec0da7280fffd41b705c5309c7fef2bbb56bf261cab4eadd3a5c69e0a67d45e426d1097187cc9a959b4d979a9d40df26f3dc8d030453fe27701438b78d3ce044330b4b5dca7832537ecf40b914f1b1dc16d4e6d7229
- Key
{"option":"Hex","string":"eb970554bb213430f4bb4e5988a6a218"}- IV
{"option":"Hex","string":""}- Input
Hex- Output
Hex
Key: RC2 uses a variable size key. You can generate a password-based key using one of the KDF operations. IV: To run the cipher in CBC mode, the Initialization Vector should be 8 bytes long. If the IV is left blank, the cipher will run in ECB mode. Padding: In both CBC and ECB mode, PKCS#7 padding will be used.
Format reference: RC2 Encrypt background and specification