Introduction
Commands
Addresses
Values
Encryption
Joker Commands
Examples
Codes
Thanks
Links
Bonus
PS2DIS

Action Replay Encryption

Once you have picked a Command and filled in the Address and Value, you need to encrypt the code so it can be used with the AR2. All 16 digits of the code are encrypted. There are currently three different encryption schemes in use. Use the links below to select which encryption you need to use. I have identified them by the value that 00000000 encrypts to with each respective scheme.

1456E7A5 BCA99B83 F8FCFEFE

1456E7A5 Encryption

This encryption is used for games that have a one-line (M) Must Be On code. Use the two tables below to perform the encryption, or you can use kpdavatar's Hex-to-AR2 Converter.

Number In:
Number Out:
           
           
           
             

Here are the equations that are used for the encryption. The input to the encryption is denoted as a0a1a2a3 d0d1d2d3, and the output is denoted as A0A1A2A3 D0D1D2D3 . Each a0, a1, etc is a two digit hex number. In the equations below, the '$' means that the following number is a hexidecimal number. XOR is a binary operation that can be performed on hex numbers using Windows Calculator in Scientific Mode.

A0 = (a0 XOR $A6) - $6A
A1 = (a1 XOR $96) - $FF
A2 = (a2 XOR $01) - $7E
A3 = (a3 XOR $82) - $5A
D0 = (d0 XOR $D9) - $C5
D1 = (d1 XOR $3B) - $E5
D2 = (d2 XOR $1B) - $34
D3 = (d3 XOR $CC) - $27

Use the following table to encrypt or decrypt the first 8 digits of the code:


Digit of encrypted value
1st2nd 3rd4th 5th6th 7th8th
U
n
e
n
c
r
y
p
t
e
d

V
a
l
u
e
0 3C 97 83 28
1 4D 88 92 39
2 1A B5 A5 46
3 2B A6 B4 57
4 78 D3 C7 6C
5 89 C4 D6 7D
6 56 F1 E9 8A
7 67 E2 F8 9B
8 B4* 1F 0B A0*
9 C5* 00* 1A B1*
A 92* 3D 2D CE
B A3* 2E 3C DF
C F0* 5B 4F E4*
D 01* 4C 5E F5*
E DE 79 61* 02*
F EF 6A 70* 13*

* - Subtract 1 from the left digit of the current pair before decrypting
* - Add 1 to the left digit of the current pair after encrypting

Use the following table to encrypt or decrypt the last 8 digits of the code:


Digit of encrypted value
1st2nd 3rd4th 5th6th 7th8th
U
n
e
n
c
r
y
p
t
e
d

V
a
l
u
e
0 14 56 E7 A5
1 03 45 D6 B6
2 36 34 05 C7
3 25 23 F4 D8
4 D8 9A 2B 61
5 C7 89 1A 72
6 FA 78 49 83
7 E9 67 38 94
8 9C# DE# 6F# 2D#
9 8B# CD# 5E# 3E#
A BE# BC# 8D# 4F#
B AD# AB# 7C# 50
C 50 12 A3 E9#
D 4F# 01 92 FA#
E 72 F0 C1 0B#
F 61 EF# B0 1C#

# - Add 1 to the left digit of the current pair before decrypting
# - Subtract 1 from the left digit of the current pair after encrypting


Please send any additional information for this section to me at hellion00@comcast.net.