This might be daft question but I'll ask it anyway, how were they able to do this? Is the official version opensource or did they have have to reverse engineer the whole thing?
The official server isn't open source, but the Java bytecode can be decompiled into something approximating usable code. The protocol itself is also unencrypted and unobfuscated. All of this together makes it relatively simple to reverse engineer it.
http://minecraft.gamepedia.com/Programs_and_editors/Mod_Code...
The protocol is also well documented: http://wiki.vg/Protocol