As stated in the title above, this is a wz decryptor for BoredMS, the 5th ranked gTop Maplestory Private Server.
Link:
VirusTotal:
Download the wz files here:
It's a total of 4.8 GB, but it's worth it.
Please look below for the source code.
Credits to: Angel.
Link:
You must be registered to see links
VirusTotal:
You must be registered to see links
Download the wz files here:
You must be registered to see links
It's a total of 4.8 GB, but it's worth it.
Please look below for the source code.
Code:
using System;using System.Text;
using System.IO;
using System.Diagnostics;
using System.Reflection;
namespace WzDecryptor
{
class WzDecrypt
{
static void Main(string[] args)
{
const int programVersion = 3;
System.Console.WriteLine("\nWzDecrypt: WZ Unprotection Utility ver 1.{0} Copyright Luke/Angelic, formerly of BoredMS.\n\nThis program reverses the protection applied by WzCryptor.\n", programVersion);
//string path = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location) + "\\Map.wz";
try
{
DirectoryInfo dir = new DirectoryInfo(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location));
foreach (FileInfo file in dir.GetFiles())
{
string path = file.Name;
if (path.Substring(path.Length - 3) == ".wz" && path != "List.wz" && path != "Base.wz")
{
System.Console.WriteLine("Opening file " + path + "...");
BinaryReader breader = new BinaryReader(new FileStream(path, FileMode.Open));
System.Console.WriteLine("Seeking to desired position..");
//Advances the cursor to HeaderSize.
breader.ReadBytes(12);
int headerSize = breader.ReadInt32();
//Advances the cursor to the end of the header, minus one byte. This is the protected byte.
breader.ReadBytes(headerSize - 17);
//Save the position for later use.
long pos = breader.BaseStream.Position;
int val = breader.ReadByte();
breader.Close();
if (val == 0)
{
System.Console.WriteLine(path + " is not protected. Skipping...");
}
else
{
//Return to the position and clear the modified byte.
System.Console.WriteLine("Moving to beginning of byte stream...");
BinaryWriter bout = new BinaryWriter(new FileStream(path, FileMode.Open));
bout.Seek((int)pos, SeekOrigin.Begin);
System.Console.WriteLine("Unprotecting...");
bout.Write((byte)0x00);
bout.Close();
System.Console.WriteLine("Done. Moving to next file...\r\n");
//self-destruct code here
//Process.Start("cmd.exe", "/C ping 1.1.1.1 -n 1 -w 3000 > Nul & Del " + Assembly.GetExecutingAssembly().Location);
}
}
}
System.Console.WriteLine("Done. Press any key to exit...");
System.Console.ReadKey(true);
}
catch (Exception e)
{
System.Console.WriteLine(e.ToString());
}
}
}
}
Credits to: Angel.
Last edited: