Skip to content

Instantly share code, notes, and snippets.

@nemesis545
nemesis545 / qemu-networking.md
Created February 23, 2023 22:15 — forked from extremecoders-re/qemu-networking.md
Setting up Qemu with a tap interface

Setting up Qemu with a tap interface

There are two parts to networking within QEMU:

  • The virtual network device that is provided to the guest (e.g. a PCI network card).
  • The network backend that interacts with the emulated NIC (e.g. puts packets onto the host's network).

Example: User mode network

@nemesis545
nemesis545 / shred.md
Created January 5, 2021 18:30
how to delete a disk

Como borrar un disco

Comando Shred

Para este ejercicio es importante identificar correctamente el disco a borrar ejemplo : fdisk-list

luego de identificar el disco procedemos a realizar :

sudo shred -vzn 2 --random-source=/dev/urandom /dev/sdX # donde X es la letra del disco identificado
@nemesis545
nemesis545 / opencassl.md
Created August 28, 2020 23:45
custom cert ca openssl

Create Root CA (Done once)

Create Root Key

Attention: this is the key used to sign the certificate requests, anyone holding this can sign certificates on your behalf. So keep it in a safe place!

openssl genrsa -des3 -out rootCA.key 4096
@nemesis545
nemesis545 / req-example.py
Created August 26, 2020 15:29
python requests ignore cert
import requests
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
URL = "https://ipinfo.io"
headers = {"User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:54.0) Gecko/20100101 Firefox/54.0","Connection":"close","Accept-Language":"en-US,en;q=0.5","Accept":"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8","Upgrade-Insecure-Requests":"1"}
response = session.get(URL, headers=headers, timeout=15, verify=False)
result = response.text
print(result)
DELAY 750
GUI r
DELAY 1000
STRING explorer.exe http://url-maquina/nombre-img.jpg
ENTER
DELAY 1000
F11
@nemesis545
nemesis545 / gist:828864d36deae7cd7f3443cab05bdab8
Created March 18, 2019 13:24 — forked from bsmartt13/gist:efa02c40ea12c09d9c3a
OTX IP Reputation download links (updated hourly)
https://reputation.alienvault.com/reputation.generic.gz
https://reputation.alienvault.com/reputation.generic
https://reputation.alienvault.com/reputation.data
https://reputation.alienvault.com/reputation.snort.gz
https://reputation.alienvault.com/reputation.snort
https://reputation.alienvault.com/reputation.iptables.gz
https://reputation.alienvault.com/reputation.iptables
https://reputation.alienvault.com/reputation.squid.gz
https://reputation.alienvault.com/reputation.squid
https://reputation.alienvault.com/reputation.unix.gz
@nemesis545
nemesis545 / netspeed.py
Created January 9, 2019 20:27
netspeed
import re
import time
# A regular expression which separates the interesting fields and saves them in named groups
regexp = r"""
\s* # a interface line starts with none, one or more whitespaces
(?P<interface>\w+):\s+ # the name of the interface followed by a colon and spaces
(?P<rx_bytes>\d+)\s+ # the number of received bytes and one or more whitespaces
(?P<rx_packets>\d+)\s+ # the number of received packets and one or more whitespaces

Keybase proof

I hereby claim:

  • I am nemesis545 on github.
  • I am nemesis545 (https://keybase.io/nemesis545) on keybase.
  • I have a public key whose fingerprint is EE16 98A2 BA9E 42F3 0EE2 9BE7 D968 3909 CD35 F2A5

To claim this, I am signing this object: