Skip to content

Instantly share code, notes, and snippets.

View manesec's full-sized avatar
🏠
Sleep is good

Mane manesec

🏠
Sleep is good
View GitHub Profile
@manesec
manesec / simpleWeb.html
Created September 20, 2024 22:18
一個簡單的小網站
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>My Simple Webpage</title>
<style>
body {
font-family: Arial, sans-serif;
margin: 20px;
@manesec
manesec / connect-openvpn.sh
Created September 9, 2024 17:04
一個小脚本自動把賬號密碼自動輸入到openvpn裏面,無需每次都要手動輸入賬號密碼
#!/usr/bin/expect
if { $argc != 1 } {
puts "Usage: $argv0 <config.ovpn>"
exit 1
}
set configFile [lindex $argv 0]
set timeout -1

ERROR - Script Bloken

ohh, there was an error happened when loading the web page ... QAQ ...

抱歉,加載 Javascript 時出現了問題 ...

How to solve ?

Please Disable AD Block, there are no AD in the website.

#https://rohnspowershellblog.wordpress.com/2013/03/19/viewing-service-acls/
Add-Type @"
[System.FlagsAttribute]
public enum ServiceAccessFlags : uint
{
QueryConfig = 1,
ChangeConfig = 2,
QueryStatus = 4,
EnumerateDependents = 8,
Start = 16,
@manesec
manesec / rbcd_demo.ps1
Created June 8, 2024 18:13 — forked from HarmJ0y/rbcd_demo.ps1
Resource-based constrained delegation computer DACL takeover demo
# import the necessary toolsets
Import-Module .\powermad.ps1
Import-Module .\powerview.ps1
# we are TESTLAB\attacker, who has GenericWrite rights over the primary$ computer account
whoami
# the target computer object we're taking over
$TargetComputer = "primary.testlab.local"
@manesec
manesec / updateTimeFromNTP.py
Created May 4, 2024 07:58
Update time from NTP SERVER with windows
import time
import os
import ntplib
client = ntplib.NTPClient()
response = client.request('ntp4.aliyun.com')
timestamp = int(response.tx_time)
date_string = time.strftime('%d-%m-%Y', time.localtime(timestamp))
print(date_string)
os.system('date ' + date_string)
@manesec
manesec / SimpleHTTPServerWithUpload.py
Created March 4, 2024 21:18 — forked from touilleMan/SimpleHTTPServerWithUpload.py
Simple Python Http Server with Upload - Python3 version
#!/usr/bin/env python3
"""Simple HTTP Server With Upload.
This module builds on BaseHTTPServer by implementing the standard GET
and HEAD requests in a fairly straightforward manner.
see: https://gist.github.com/UniIsland/3346170
"""
@manesec
manesec / minio-upload.sh
Created February 22, 2024 17:54 — forked from PhilipSchmid/minio-upload.sh
Upload data to Minio using CURL
#!/bin/bash
# Usage: ./minio-upload my-bucket my-file.zip
bucket=$1
file=$2
host=minio.example.com
s3_key=svc_example_user
s3_secret=svc_example_user_password
@manesec
manesec / decryptchromecookies.py
Created December 18, 2023 15:09 — forked from zackmark29/decryptchromecookies.py
Decrypt Chrome Cookies File (Python 3) - Windows
# Based on:
# https://gist.github.com/DakuTree/98c8362fb424351b803e
# https://gist.github.com/jordan-wright/5770442
# https://gist.github.com/DakuTree/428e5b737306937628f2944fbfdc4ffc
# https://stackoverflow.com/questions/60416350/chrome-80-how-to-decode-cookies
# https://stackoverflow.com/questions/43987779/python-module-crypto-cipher-aes-has-no-attribute-mode-ccm-even-though-pycry
import os
import json
import base64
@manesec
manesec / singbox.json
Created November 3, 2023 07:16
解決 HTB THM 靶場連接超時的 singbox 配置文件,使用singbox劫持openvpn
{
"log": {
"level": "info",
"timestamp": true
},
"dns": {
"servers": [
{
"tag": "dns_proxy",
"address": "tls://dns.google",