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
from os import urandom | |
from socket import create_connection | |
from cryptography.hazmat.primitives.asymmetric import padding | |
from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes | |
from cryptography.hazmat.primitives.serialization import load_der_public_key | |
def read(sock, length): | |
result = b'' |
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
{ | |
"redirect": null, | |
"suggestions": null, | |
"type": 0, | |
"has_command": false, | |
"children": [ | |
{ | |
"redirect": null, | |
"suggestions": null, | |
"has_command": true, |
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
import sys, marshal, functools, subprocess | |
child_script = """ | |
import marshal, sys, types; | |
fn, args, kwargs = marshal.load(sys.stdin) | |
marshal.dump( | |
types.FunctionType(fn, globals())(*args, **kwargs), | |
sys.stdout) | |
""" |
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
import sys | |
import json | |
import SocketServer | |
SocketServer.TCPServer.allow_reuse_address = True | |
class MCHandler(SocketServer.BaseRequestHandler): | |
@classmethod | |
def pack_varint(cls, d): |
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
import json | |
import socket | |
### Helper functions | |
# Read n bytes from the socket | |
def read(sock, n): | |
o = "" | |
while len(o) < n: | |
o += sock.recv(n-len(o)) |
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
from __future__ import division, print_function, unicode_literals | |
import types | |
import dis | |
import os | |
import struct | |
import sys | |
def _unpack(s): |
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
from os import chdir, path | |
from tempfile import mkdtemp | |
from shutil import rmtree | |
from struct import pack | |
from subprocess import check_output | |
def jar_contents(j_path): | |
return check_output(['jar', 'tf', j_path]).split("\n") | |
def jar_extract(j_path): |
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
#!/usr/bin/python | |
import struct | |
from twisted.internet import protocol, reactor | |
PR_VERSION = "51" | |
MC_VERSION = "1.4.7" | |
class DowntimeProtocol(protocol.Protocol): | |
def __init__(self, message): |
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
import java.io.*; | |
import javax.crypto.*; | |
import java.util.*; | |
import javax.crypto.spec.*; | |
import java.net.*; | |
public class decrypt { | |
static String DESpassword = "passwordfile"; | |
static byte[] salt = { 12, -99, 74, -28, 30, -125, 21, -4 }; | |
public static void main(String[] args) { |
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
#Shortcut to /mod-broadcast | |
*:/mb $ = >>> | |
_assertperm('mod', 0) | |
assign(@mods, _get_mods()) | |
foreach(@mods, @mod, | |
tmsg(@mod, concat('[', color(red), 'Mod - ', player(), color(white), '] ', color(green), $)) | |
) | |
<<< |
NewerOlder