This file contains hidden or 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/env bash | |
| # Copyright (c) 2021-2026 tteck | |
| # Author: tteck (tteckster) | |
| # Jon Spriggs (jontheniceguy) | |
| # License: MIT | |
| # https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE | |
| # Based on work from https://i12bretro.github.io/tutorials/0405.html | |
| source /dev/stdin <<<$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/api.func) |
This file contains hidden or 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
| package main | |
| import ( | |
| "context" | |
| "crypto/sha256" | |
| "crypto/tls" | |
| "crypto/x509" | |
| "encoding/pem" | |
| "errors" | |
| "fmt" |
This file contains hidden or 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/env python | |
| """Simple HTTP Server With Upload. | |
| This module builds on BaseHTTPServer by implementing the standard GET | |
| and HEAD requests in a fairly straightforward manner. | |
| """ |
This file contains hidden or 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
| SUBSYSTEM=="usb", ACTION=="remove", ENV{ID_VENDOR_ID}=="1050", ENV{ID_MODEL_ID}="0407", RUN+="/usr/local/bin/yubikeylocker.sh" | |
| SUBSYSTEM=="usb", ACTION=="add", ENV{ID_VENDOR_ID}=="1050", ENV{ID_MODEL_ID}=="0407", RUN+="/usr/local/bin/yubikeylocker.sh" |
This file contains hidden or 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
| router id 33.44.0.1; | |
| protocol device { | |
| scan time 10; | |
| } | |
| protocol kernel { | |
| metric 64; # Use explicit kernel route metric to avoid collisions | |
| # with non-BIRD routes in the kernel routing table | |
| import none; |
This file contains hidden or 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
| #!/bin/bash -e | |
| remote="$1@$2" | |
| echo -ne '\e]0;wait... '"$remote"'\a' | |
| eval $(/usr/bin/ssh-pageant -r -a "/tmp/.ssh-pageant-$USERNAME") | |
| localdir="$(cygpath -u "$APPDATA")/gnupg" | |
| extrasock="$localdir/S.gpg-agent.extra" # file containing "PORT\nNONCE" | |
| rdir='$HOME/.gnupg' # remote prefix | |
| rinsock="$rdir/S.gpg-agent" # listen on this socket on server |
This file contains hidden or 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 contextlib import contextmanager | |
| import signal | |
| @contextmanager | |
| def timeout(seconds=3): | |
| class TimeoutError(Exception): | |
| pass | |
| def handler(*args,**kwargs): | |
| print("[-] Timeout!") | |
| raise TimeoutError |
This file contains hidden or 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
| def ignore_error_and_retry(times=3): | |
| def real_decorator(fn): | |
| def warpper(*args, **kwargs): | |
| try: | |
| fn(*args, **kwargs) | |
| except Exception as e: | |
| print(str(e)) | |
| if not hasattr(warpper, "counter"): | |
| warpper.counter = 1 | |
| else: |
This file contains hidden or 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
| #!/bin/bash | |
| function load_var { | |
| eval $(cat ${1} <( echo -e '\nset -o posix;set\n') | env - bash --noprofile --norc --posix | sed 's/^/'$2'_/') | |
| if [ -n "$IF_IPSEC6" ]; then | |
| PEER_ENDPOINT=$PEER_ENDPOINT6 | |
| SELF_ENDPOINT=$SELF_ENDPOINT6 | |
| fi | |
| } |
This file contains hidden or 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
| #!/bin/bash | |
| function gen { | |
| dd if=/dev/urandom bs=1 count=10000 2>/dev/null | tr -dc a-f0-9 | fold -w $1 | sed 's/^/0x/' | head -n 1 | |
| } | |
| spi=`gen 8` | |
| reqid=`gen 8` | |
| auth_key=`gen 64` | |
| enc_key=`gen 64` |
NewerOlder