Skip to content

Instantly share code, notes, and snippets.

View leveryd's full-sized avatar
💭
working

leveryd leveryd

💭
working
View GitHub Profile
@leveryd
leveryd / keyword_encoder.py
Created April 12, 2024 15:06
关键字编码,包括overlong、hex、unicode
import os
class Encoder(object):
@staticmethod
def chr_to_hex(i):
"""
49 -> '\x31'
:param i:
:return:
// 需要先创建文件 touch file1.txt、file2.txt、file3.txt
package main
import (
"fmt"
"syscall"
"os/exec"
"os"
)
import re
import base64
class GenerateBase64(object):
@staticmethod
def split_string_by_length(text, length):
# 使用正则表达式匹配长度为指定值的子串
pattern = f'.{{{length}}}'
return [match.group(0) for match in re.finditer(pattern, text)]
@leveryd
leveryd / CVE-2019-11580.py
Created December 21, 2023 06:34
python3版本
# this is python3 version poc for https://github.com/jas502n/CVE-2019-11580/blob/master/CVE-2019-11580.py
import requests
import sys
banner = '''\n _______ ________ ___ ___ __ ___ __ __ _____ ___ ___
/ ____\ \ / / ____| |__ \ / _ \/_ |/ _ \ /_ /_ | ____|/ _ \ / _ \
| | \ \ / /| |__ ______ ) | | | || | (_) |______| || | |__ | (_) | | | |
| | \ \/ / | __|______/ /| | | || |\__, |______| || |___ \ > _ <| | | |
| |____ \ / | |____ / /_| |_| || | / / | || |___) | (_) | |_| |
# coding:utf-8
import argparse
import base64
import json
import os
from enum import Enum
args = None
@leveryd
leveryd / asm开发记录-集成katana.md
Last active February 14, 2023 03:10
asm开发记录-集成katana

背景

中间有一段时间没有数据

如果重启proxify pod,es就会又有数据。就像图中那样

为什么会这样?

<?php
error_reporting(E_ALL);
//设置无限请求超时时间
set_time_limit(0);
echo "<h2>TCP/IP Connection</h2>\n";
$ip = '127.0.0.1';
$port = 8099;
#include <stdio.h>
#include <sys/socket.h>
#include <netdb.h>
#include <string.h>
#include <unistd.h>
int main(int argc, char **argv) {
int listenfd, connfd;
socklen_t clilen;
struct sockaddr_in cliaddr, servaddr;
@leveryd
leveryd / nfqueue_backdoor.md
Last active March 20, 2024 06:00
nfqueue_backdoor.c
// https://github.com/irontec/netfilter-nfqueue-samples/blob/master/sample-helloworld.c
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <netinet/in.h>
#include <linux/types.h>
#include <linux/netfilter.h>
#include <libnetfilter_queue/libnetfilter_queue.h>