Skip to content

Instantly share code, notes, and snippets.

View wargio's full-sized avatar
:shipit:
ready to share knowledge

Giovanni wargio

:shipit:
ready to share knowledge
View GitHub Profile
@wargio
wargio / wigeguard_setup.md
Created February 6, 2021 19:03 — forked from atomlab/wigeguard_setup.md
Wireguard setup on Ubuntu 18.04

Wireguard setup on Ubuntu 16.04/18.04

Install

# sudo add-apt-repository ppa:wireguard/wireguard
# sudo apt-get update
# sudo apt-get install wireguard

Generate keys

@wargio
wargio / spyonbash
Last active March 8, 2019 10:16
simple script to spy a shell via strace + python (one line)
## just find the pid of the shell
[root]> ps -aux | grep bash
user 28202 0.0 0.1 4464 3696 pts/0 Ss+ 10:26 0:00 -bash
root 28227 0.0 0.1 4360 3760 pts/1 Ss 10:26 0:00 -bash
root 28855 0.0 0.0 3044 884 pts/1 S+ 11:13 0:00 grep bash
## then call the oneline command
## strace -p<pid> -s9999 -e write 2>&1 | python -c "import sys,re;[print(re.sub(r'write\(\d,\s\"(.+)\",\s\d+\)\s+=\s+\d+$|^---.+$', r'\1', line).replace('\n', '').encode('utf-8').decode('unicode_escape'), end='', flush=True) for line in sys.stdin]"
strace -p28202 -s9999 -e write 2>&1 | python -c "import sys,re;[print(re.sub(r'write\(\d,\s\"(.+)\",\s\d+\)\s+=\s+\d+$|^---.+$', r'\1', line).replace('\n', '').encode('utf-8').decode('unicode_escape'), end='', flush=True) for line in sys.stdin]"
strace: Process 28202 attached
@wargio
wargio / arch-linux-install.md
Created March 4, 2019 09:37 — forked from kylemanna/arch-linux-install.md
Minimal instructions for installing arch linux on an UEFI NVMe system with full system encryption using dm-crypt and luks

Keybase proof

I hereby claim:

  • I am wargio on github.
  • I am der0ad (https://keybase.io/der0ad) on keybase.
  • I have a public key whose fingerprint is 16D2 1F3F FFC6 D07A 233D 7F7D BAB3 FDCF 8315 7E41

To claim this, I am signing this object:

@wargio
wargio / Browser.java
Created November 3, 2015 21:52
Browser.java
import java.io.IOException;
import java.util.Set;
import javafx.application.Application;
import javafx.scene.*;
import javafx.scene.layout.StackPane;
import javafx.scene.web.WebEngine;
import javafx.scene.web.WebView;
import javafx.stage.Stage;
import javafx.collections.ListChangeListener;
@wargio
wargio / hb-ps4.sh
Last active August 29, 2015 13:58 — forked from takeshixx/hb-test.py
added wait
#!/bin/bash
PORT_FOUND="0"
PORT=0
if [ $# -eq 1 ]; then
echo "I'm testing the port"
for port in `seq 1 65535`; do
echo "port=" $port
./hb-test.py $1 -p $port -P >> /dev/null
if [ $? -eq 0 ]; then