Skip to content

XOR

XOR is a bitwise operation used by Geometry Dash to encrypt data. It is commonly denoted as a ^ in many programming languages

  • Geometry Dash has 2 methods to encrypting data using XOR
    • Using a singular key
    • Cycling through a 5 digit key

When needed, Geometry Dash iterates through every byte of the data and applies the XOR operation using its key

Examples

Below are pseudocode examples of the algorithms used

Singular

js
result = "";
for (i = 0; i < input.length; i++) {
  byte = input[i].toByte();
  result += (byte ^ key).toChar();
}

Cycle

js
result = "";
for (i = 0; i < input.length; i++) {
  byte = input[i].toByte();
  xKey = key[i % key.length].toByte();
  result += (byte ^ xKey).toChar();
}

Keys

KeyUsageXOR Type
11Player Save DataSingular
14251Player MessagesCycled
19283Vault CodesCycled
19847Daily ChallengesCycled
26364Level PasswordCycled
29481Comment IntegrityCycled
37526Account PasswordCycled
39673Level Leaderboard IntegrityCycled
41274Level IntegrityCycled
48291Load DataCycled
52832MultiplayerCycled
57709Music/SFX Library SecretCycled
58281Rating IntegrityCycled
59182Chest RewardsCycled
85271Stat Submission IntegrityCycled