-
-
Save 5342/10a3231c1e5f29c5fb10 to your computer and use it in GitHub Desktop.
Quick hack to decrypt the URL for Zone 4
http://snowmiser.counterhack.com/zone-3-EAB6B031-4EFA-49F1-B542-30EBE9EB3962/
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The key is: 5ab678a3efaac87a07dc29c8827a245f273a8f5cb4bb1485fd36b42b0fdd4f5e05709e0c8a2ebbe851ab7a | |
Plain Text: zone-4-9D469367-B60E-4E08-BDF1-FED7CC74AF33 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace xorStrings | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
string cipherText = "20d916c6c29ee53c30ea1effc63b1c72147eb86b998a25c0cf1bf66939e8621b3132d83abb1683df619238"; | |
string plainText = "zone-4-F7677DA8-3D77-11E2-BB65-E4BF6188709B"; | |
string unknownKey = ""; | |
string newCipherText = "20d916c6c29ee54343e81ff1b14c1372650cbf19998f51b5c51bf66f49ec62184034a94fc9198fa9179849"; | |
string unknownPlainText = ""; | |
for (int i = 0; i < cipherText.Length/2; i++) | |
{ | |
int ct = Convert.ToInt32(cipherText.Substring(i * 2, 2), 16); | |
int pt = char.Parse(plainText.Substring(i, 1)); | |
unknownKey += (ct ^ pt).ToString("X2"); | |
} | |
Console.WriteLine("The key is: {0}", unknownKey.ToLower()); | |
for (int i = 0; i < newCipherText.Length / 2; i++) | |
{ | |
int ct = Convert.ToInt32(newCipherText.Substring(i * 2, 2), 16); | |
int ky = Convert.ToInt32(unknownKey.Substring(i * 2, 2), 16); | |
unknownPlainText += (char)(ct ^ ky); | |
} | |
Console.WriteLine("Plain Text: {0}", unknownPlainText); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment