Shifu-Hacks Blog


Archive for the ‘General Programming’ Category

OdinMS Source v.53 (Release 0.5)

Posted by compactwater on April29 2008

Note: This same method will work for future releases and updates, so the title may be misleading to some.

And so I’ve decided to write a simple tutorial on how to start a private server from the OdinMS source files, because not many people can understand all the “complicated” stuff behind it. Follow this step-by-step, make sure you do things exactly. At the bottom of this post I will include common errors, and their fix.

Download the following and extract the files to a temporary folder. You will need these for later.

Install MySQL and the Query Browser (or administrator). This will be needed for the game’s database, remember all information you use! Be sure to create constant backups of your database in case problems arise later on. You can do this by selecting your database (default: odinms) and choosing backup, or dump database. It will output a ‘.sql’ file in most cases, keep this file safe as it contains all user information, although encrypted with SHA1, it can still be forced. To import the database from a backup (included in the source) use “File->Open Script”. It will be labeled ‘odinms.sql’. This will automatically create all the tables.
Once completed, goto your OdinMS source folder and edit “” with any text editor and change the information to what you created for your database.
user = root
password = whatever_you_used
If this is not done correctly, you will not be able to connect to the database.

Next to edit is how many channels you want to run, be warned more channels will cause more lag. Open “” and change this line:
You will also need to add a new row for

To change the meso and experience rate, open “”. This is also where you need to change
to your local IP if needed.

So on, now to the batch (.bat) files. Edit them in a text editor (clicking will execute them).
change these lines
Unless you have made any customizations. You may also want to add “pause.” to the very last line to see any errors that occur. If you wish for the server to automatically restart itself upon crashing, add this line to the end, only do this if you know the server is working, else it’ll return the same error repetitively.
It’s that simple. And here’s kill.bat, although this is only a simple work-around.
TAKSKILL /F /IM “java.exe”
start launch_world.bat
start launch_login.bat
start launch_channel.bat

In your MapleStory folder, copy all the .WZ files into your OdinMS folder, to keep it organized make a folder called ‘wz’ and put them in there. OdinMS reads from the WZ files for information.

Find your Java installation (default: c:\program files\java). There should be a few folders, copy ‘loca_policy.jar’ and ‘US_export_policy.jar’ from the Java Cryptography Extension to ‘/lib/security’ and ‘/jre/lib/security’ in all the folders. It should look something like this, depending on what you’ve installed.
Java Folder

Next, you can either make the key files, or download a pre-made key file. It is recommended you make your own. You can get one here, provided by Leena of CEF. Copy the file six times into the OdinMS source folder, and rename them to:

  • world.keystore
  • channel.keystore
  • login.keystore
  • world.truststore
  • channel.truststore
  • login.truststore

Although it isn’t really necessary to create multiple copies of the file, as you can use it for all of the different servers’ keystores and truststores. The password for the world, channel, and login will be “passwd”.

Next, copy “mina-core-1.1.7.jar”, “mysql-connector-java-3.1.14-bin.jar”, “slf4j-api-1.5.0.jar”, and “slf4j-jdk14-1.5.0.jar” to the dist folder in your OdinMS source folder. Rename them accordingly:

This is the last step, the rest is just information on adding accounts and enabling others to play on your server.

To modify an account’s password, use this in SQL:
UPDATE accounts SET password = SHA1(‘password’) WHERE name=’admin’

Or, to create an account with information, use:
INSERT INTO accounts (name, password, birthday, email, banreason, macs)
VALUES(‘username’, SHA1(‘password’), ‘2001-09-11’, ‘’, ‘notbanned’, ‘macaddr’);

This will change the default “Admin” account’s password to “password”. It is a good idea to change this, or even delete this account, as it can lead to vulnerabilities if accessed. The second code will create an account with the username “username” and password “password” as well as the other needed information. If you want to give an account GM access, simply enter this:
UPDATE accounts SET gm=1 WHERE name=’username’;

Having others connect to your server: This is limited by two things. Your router (if you have one) and your ISP. If your ISP is very restrictive, then you just cannot host a server for others to play on. If you have a router, you will need to forward ports to your computer’s local IP address. The router’s address is typically ‘’, if you are asked for a password, it should be the default for your router, usually printed on the router itself. If the default password does not work, try resetting it. Your local IP will look something like:, and may change from time to time if you do not register it to your MAC address.

Once on your router, forward ports 8484, and 8888 to your local IP. You can goto a site (such as to find out your IP. There are two ways you can let others connect to your server with this, hex editing the client’s IP to yours, or executing it through CMD like so: “MapleStory.exe 8484”, although you could use a batch (.bat) file to do it for you. Another method is with Hamachi, or such applications. Use your Hamachi IP rather than your actual IP.

Common Errors, and fixes:

Currently, there are no common enough errors to report. Feel free to e-mail me if you have troubles, and I will try my best to find a fix and add it here.


Posted in General Programming | 17 Comments »

Running Delphi on Vista

Posted by compactwater on December29 2007

Fortunately, I have a new computer, unfortunately, it has Vista pre-installed.

First step, get rid of Anti-virus (this may not be necessary) McAfee will kill Delphi upon: Installation, Compiling, Debugging, and close it for renaming files- don’t understand why it’s so “evil”, but if you want Delphi, the Anti-virus has to go.
Download and run this:
You will be asked to restart your computer, do so. Check if it was completely removed, if not try the legendary Google to solve this part of the problem.

Second, goto your Delphi installation folder, and find Delphi32.exe in the bin folder. Right click=> Properties, and goto the compatibility tab. Check “Run this program in compatibility mode for:” and choose Windows XP SP 2. Also check “Run this program as an administrator”.

You can now use Delphi on Vista!
Tested with Borland Delphi 7 Enterprise Edition on Microsoft Windows Vista Home Premium.

Posted in General Programming | 16 Comments »

File Download Service (Proxy)

Posted by compactwater on December16 2007

This is not really a proxy, nor anywhere near as good. It can download one file at a time to your server from another server, so it can be accessed when the other server is unavailable (or blocked). This is meant for personal use, and should be passworded to prevent from misuse by someone who may want to harm your computer or server. The file comes with everything you will need and the downloader itself.

Place download.des in your cgi-bin (or it will not work), and the php files into a folder on your server. Be sure you have a folder named “down” (or what you may have changed it to) within that same folder, or the downloader will not work. You will also need to have php installed on your server. If you are running on Linux you will need to configure download.des to run with Wine.

In write.php change the password to whatever you like. Don’t use “.$’ in it. If write.php has troubles writing to down.ini, then you should replace \\down.ini with your drive letter (c:\down.ini). You can change where the files are downloaded to in download.php, though it will NOT make a new folder if the chosen directory does not currently exist.

When used, download.des will return a 500 error, but the program was still executed and the file downloaded.

Download FDS: Here

Posted in General Programming, Webmastering | 1 Comment »

Hash Gewalt 1.2

Posted by compactwater on December5 2007

Hash Gewalt is a console application used for cracking an MD5 hash. It runs using three parameters, executed through cmd in Windows, or with Wine in Linux. Example:
Gewalt.exe -hash /DictionarySize /HashLength
7f138a09169b250e9dcb378140907378 /62 /3

Which would return “MD5” in the log file. All hashes are logged to “gewalt.ini” within the same directory as the application (It will goto x:\windows or x:\ if it is in System32). The Dictionary Size is how many characters Hash Gewalt will search through before it returns to the first character. 25 (0-25, meaning full 26) would search though the first 26 lowercase English alphabet letters.

Supported characters for dictionary size:

  • a b c d e f g h i //9
  • j k l m n o p q r s t u v w x //15
  • y z A B C D E F G H I J K L M N //16
  • O P Q R S T U V W X Y Z 0 1 2 3 //16
  • 4 5 6 7 8 9 (EN SPACE) //6 (line) 62 (basic)
  • ` ! @ # $ % ^ & * ( ) _ + ~ – //15
  • = [ ] \ | ; : ” < > ? , . / //15
  • € ƒ Š Œ Ž ‘ ’ “ ” ™ š œ ž Ÿ, ¡ ¢ //16
  • £ ¤ ¥ ¦ § ¨ © ª « » ¬ ® ¯ ° ² ³ //16
  • ´ µ ¶ ¹ ¼ ½ ¾ ¿ À Á Â Ã Ä Å Æ //15 (line) 70 at ¿ (medium)
  • Ç È É Ê Ë Ì Í Î Ï Ð Ñ Ò Ó Ô Õ Ö //16
  • × Ø Ù Ú Û Ü Þ ß à á â ã ä å æ ç //16
  • è é ê ë ì í î ï ð ñ ò ó ô õ ö ø //16
  • ù ú û ü ý þ ÿ //7 (line) 194 (advanced)

The more characters you use, the slower the cracking speed will be, though there is a higher possibility the hash will be found (only if it has less common characters). The hash size can be up to 64, although a hash of that length would take very long to crack. If the hash size is unknown, use ?, and Hash Gewalt will start from 1 to 24 until the hash is cracked. The application will automatically close when it has finished, check the log for the cracked hash. The cracking speed depends on your computer’s speed, and Hash Gewalt’s priority. Setting the priority higher will crack the hash faster, but will use much more processing power. Cracking can take from a few minutes to hours, leave the application running and it will eventually crack the hash.

To test it out, you can make an MD5 Hash.

Through CMD:
Hash Gewalt 1.2

Log file example:
Hash Gewalt 1.2 INI

Download it: From this place

Posted in General Programming | 7 Comments »

Flash Player

Posted by compactwater on November24 2007

The point in this is to be able to play flash files even if the flash player isn’t installed on a computer (such as school computers). Or if the ability to play flash files has been disabled. Comes with all the basics, frame selection, open file, stop, play, and scalemode.
Original source:

Flash Player

Download it!

Posted in Flash Hacking, General Programming | 1 Comment »

Halo 3 Character Maker

Posted by compactwater on November17 2007

Make a snapshot of your Halo 3 character for… no reason at all.
Just play around with it.

Updated: Fixed bug with Chest and Left and Right Shoulders.

Halo 3 Character Maker


Posted in General Programming, Halo | 365 Comments »

File Encrypt/Decrypt

Posted by compactwater on November7 2007

This tool will encrypt and decrypt files. Note: This is a very simple method of encryption, not recommended for major files. This release is also available in German, and as always has the source (for German and English) included.
Original Sources:

Download source here.

Posted in General Programming | Leave a Comment »

Making a personal server

Posted by compactwater on October5 2007

Before I start, remember this: Personal Server. Meant only for you, and maybe a few friends. Thankyou.

What you’ll need:
Apache HTTP Server (Required)
PHP (Recommended)
An administrative account on Windows 2000 or later.

Download and install Apache HTTP Server, if you do not have a domain name or server name, enter your IP address, you can find out your IP address here, you will also be asked for an e-mail, enter whatever you want. After apache is installed, test it by connecting to or http://localhost/ or your IP address. If you see “It works!”, it works. If you don’t, your firewall or anti-virus may be blocking it. Be sure to set it to allow apache.

Next, download PHP. When it asks you for your server name and version, choose “Apache 2.2.x”. For the configuration file, navigate to your apache folder (in “program files”) and open the “conf” folder. Click next, and contenue installing. When it’s finished, you will need to restart your server. To do that, click on the Apache icon in your task bar, and click “Restart”.

NOTE: This is only if you have a router! Now goto your router (probably at 169.153.x.x), if you
don’t know, it should be listed on your router. Configure a “port forward” from port 80 to port 80 to your local IP, you can find it out by going to MS-DOS and typing “ipconfig”.

How to find your local IP

Port Forwarding on Linksys

Now you can accept connections from the Internet. Something you should be careful of, is anyone can access this server- don’t put any personal information on it. You can get a DNS from for free. Check my “Linky” page for tutorials on HTML and PHP.

Posted in General Programming, Webmastering | 1 Comment »

Logging Users (PHP)

Posted by compactwater on October1 2007

A simple small code to include in any page to log users on your server.
Use protection on log files! Do not let them become public! You can be sued for keeping unprotected logs… But unlikely unless you’re some big company.

$logname = “logs/users.” . date(“Ymd”) . “.log”;
$user = $_SERVER[‘REMOTE_ADDR’];

if (!$from == “”) {
$toput = “Time: ” . time() . ” IP: ” . $user . ” by: ” . $from . ”
} else {
$toput = “Time: ” . time() . ” IP: ” . $user . ”
“; }

$handle = fopen($logname, ‘a’);
if (fwrite($handle, $toput) === FALSE) {
echo “Error writing to ” . $logname;

Put that into some .PHP file, and upload it to your server (if necessary). Add this:
include ‘log_my_users.php’;
to all the pages you want to log users on. I recommend having a re-direct front page with this, or using cookie or IP identification, so you don’t log a user more than once on the front page.

Note: You will obviously need PHP on you server, and the folder “logs” in the same directory. You can change the folder name, and even move it to somewhere off of your server, but just remember to keep it safe from other users that may want to use it for the wrong reasons.

Posted in General Programming, Webmastering | 2 Comments »

DLL Update

Posted by compactwater on September24 2007

DLLDynamic Link Library
If your program is going to have constant updates, you should consider using a dll to update it’s functions. It will save time when updating, and won’t aggravate users by having to download a newer version every week or so. Don’t know how to make a dll? Try this. After reading, you’ll understand it better.

What should go in a dll:
Version information
Main functions
Form information (Colour, size, etc)
Images and sounds (by using .res)
Changed update location

What should not go in a dll:
Temporary information
Operating System (OS) dependent functions
Release notes
Encrypted/Packed/Obfuscated information
A dll (Yes, a dll should not go in a dll.)

And now all that’s left is finding a reliable (or free) server to host the updates.

Posted in General Programming | 3 Comments »