Skip to content

Instantly share code, notes, and snippets.

View cr0sh's full-sized avatar
🦀

Junghyun Nam cr0sh

🦀
View GitHub Profile
#!/bin/bash
#Needed to use aliases
shopt -s expand_aliases
type wget > /dev/null 2>&1
if [ $? -eq 0 ]; then
if [ "$IGNORE_CERT" == "yes" ]; then
alias download_file="wget --no-check-certificate -q -O -"
else
alias download_file="wget -q -O -"
from os import system
from sys import exit
from platform import platform
from random import choice
from time import time
from math import floor
from sys import version_info
if version_info[0] != 3:
print('Python 3 required')

Before reading, please consider I have poor English writing skills. Sorry. :(

What is 'Magenta'?

'Magenta' is Python script, which are made to crash PocketMine-MP servers, exactly PocketMine-Raklib.

How is it possible?

To understand this, you should know how Raklib's session system is working. Raklib creates every session per IP/Port to manage each clients, and these sessions are PHP objects.

They have many properties, such as $messageIndex, $address, $port, etc. What we need to play with is $preJoinQueue[] array. This contains MCPE DataPackets before a server-client handshake, and all stored packets will be processed after the connection process is completed. (See This)

@cr0sh
cr0sh / compile.sh
Last active September 17, 2015 11:49
#!/bin/bash
[ -z "$PHP_VERSION" ] && PHP_VERSION="7.0.0RC3"
PHP_IS_BETA="yes"
ZEND_VM="GOTO"
ZLIB_VERSION="1.2.8"
POLARSSL_VERSION="1.3.8"
LIBMCRYPT_VERSION="2.5.8"