Skip to content

Instantly share code, notes, and snippets.

View lsr00ter's full-sized avatar

letsroot lsr00ter

View GitHub Profile
@lsr00ter
lsr00ter / zerotier_install_config.sh
Last active May 17, 2024 13:43
install and forward zerotier-one traffic from zt0 to eth0 in ubuntu
#!/bin/env bash
set -u
# install
curl -s https://install.zerotier.com | sudo bash
read -p "Please input zerotier-one id to join: " ZID
sudo zerotier-cli join $ZID
# display all network interface
RED='\033[0;31m'
NC='\033[0m'
@lsr00ter
lsr00ter / test_dll.c
Created April 12, 2024 11:17 — forked from Homer28/test_dll.c
DLL code for testing CVE-2024-21378 in MS Outlook
/**
* This DLL is designed for use in conjunction with the Ruler tool for
* security testing related to the CVE-2024-21378 vulnerability,
* specifically targeting MS Outlook.
*
* It can be used with the following command line syntax:
* ruler [auth-params] form add-com [attack-params] --dll ./test.dll
* Ruler repository: https://github.com/NetSPI/ruler/tree/com-forms (com-forms branch).
*
* After being loaded into MS Outlook, it sends the PC's hostname and
@lsr00ter
lsr00ter / settings.json
Created April 10, 2024 15:57 — forked from diego3g/settings.json
VSCode Settings (Updated)
{
"workbench.startupEditor": "newUntitledFile",
"editor.fontSize": 14,
"editor.lineHeight": 1.8,
"javascript.suggest.autoImports": true,
"javascript.updateImportsOnFileMove.enabled": "always",
"editor.rulers": [80, 120],
"extensions.ignoreRecommendations": true,
"typescript.tsserver.log": "off",
"files.associations": {
@lsr00ter
lsr00ter / EdgeRouter-IPv6-CONFIG.sh
Created April 6, 2024 06:35
config ipv6 enable on eth0, switch0 for EdgeRouter er-x/er-x sfp
configure
# Configure the PPPoE for IPv6(eth0):
set interfaces ethernet eth0 pppoe 0 ipv6 enable
set interfaces ethernet eth0 pppoe 0 ipv6 address autoconf
set interfaces ethernet eth0 pppoe 0 ipv6 dup-addr-detect-transmits 1
set interfaces ethernet eth0 pppoe 0 dhcpv6-pd pd 0 prefix-length /60
set interfaces ethernet eth0 pppoe 0 dhcpv6-pd rapid-commit enable
set interfaces ethernet eth0 pppoe 0 dhcpv6-pd prefix-only
# Enable IPv6 SLAAC on the LAN(switch0):
set interfaces ethernet eth0 pppoe 0 dhcpv6-pd pd 0 interface switch0 host-address ::1
# split panes using | and -
bind | split-window -h
bind - split-window -v
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# reload config file (change file location to your the tmux.conf you want to use)
bind r source-file ~/.tmux.conf
@lsr00ter
lsr00ter / install.sh
Last active December 12, 2023 09:13 — forked from mislav/bashrc
Basic vimrc and tmux config for servers
curl -fsSL \
"https://gist.github.com/mislav/5706063/raw/vimrc" -o ~/.vimrc \
"https://gist.github.com/mislav/5706063/raw/ssh_rc.sh" -o ~/.ssh/rc \
"https://gist.github.com/mislav/5706063/raw/tmux.conf" -o ~/.tmux.conf
curl -fsSL "https://gist.github.com/wr00t/ede9ac998395415fd02898a5e63e2509/raw/zshrc" >> ~/.zshrc
chmod +x ~/.ssh/rc
@lsr00ter
lsr00ter / packr_cobaltstrike_mac.sh
Created December 5, 2023 13:19
Pack Cobalt Strike client as a macOS app use packr.jar and adopt jre 11
java -jar packr-all-4.0.0.jar --jdk https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.21%2B9/OpenJDK11U-jre_x64_mac_hotspot_11.0.21_9.tar.gz --bundle com.cobaltstrike --classpath cobaltstrike-client.jar --executable "Cobalt Strike" --icon macIcon.icns --platform mac --resources uHook.jar cobaltstrike.auth --vmargs XX:ParallelGCThreads=4 XX:+AggressiveHeap XX:+UseParallelGC javaagent:uHook.jar --output 'Cobalt Strike.app' --mainclass aggressor.Aggressor
@lsr00ter
lsr00ter / uninstall_aliyun_service.sh
Last active October 16, 2023 09:31
uninstall_aliyun
# 阿里云 ECS 服务器,请在服务器上以 root 权限执行以下命令:
wget -O /tmp/ecs_uninstall.sh "http://update2.aegis.aliyun.com/download/uninstall.sh" && chmod +x /tmp/ecs_uninstall.sh && bash /tmp/ecs_uninstall.sh
# 非阿里云服务器,请在服务器上以 root 权限执行以下命令:
wget -O /tmp/ecs_uninstall2.sh "http://update.aegis.aliyun.com/download/uninstall.sh" && chmod +x /tmp/ecs_uninstall2.sh && bash /tmp/ecs_uninstall2.sh
# 继续执行
wget -O /tmp/quartz_uninstall.sh http://update.aegis.aliyun.com/download/quartz_uninstall.sh && chmod +x /tmp/quartz_uninstall.sh && bash /tmp/quartz_uninstall.sh
# 停止阿里云盾服务
killall -9 aliyun-service
killall -9 CmsGoAgent.linux-amd64
# tested on ubuntu 20
sudo apt-get -y remove docker docker-engine docker.io containerd runc
sudo apt-get -y update
sudo apt-get -y install ca-certificates curl gnupg
sudo install -m 0755 -d /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
sudo chmod a+r /etc/apt/keyrings/docker.gpg
echo \
"deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
"$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | \
@lsr00ter
lsr00ter / install.sh
Last active May 25, 2023 05:06 — forked from gythialy/install.sh
install and config zsh tmux
#!/bin/bash
set -e
cd $HOME
# install zsh and tmux
sudo yum -y install git zsh tmux
echo "setting antigen and zsh"
curl -L git.io/antigen | sudo tee /opt/antigen.zsh