Skip to content

Instantly share code, notes, and snippets.

View azet's full-sized avatar
🔐
hacking audio devices, diving caves, breaking codes

Aaron Zauner azet

🔐
hacking audio devices, diving caves, breaking codes
View GitHub Profile
@azet
azet / a_qvfx10k_setup_with_qemu.md
Last active February 18, 2022 14:14
vqfx10k on kvm/qmu

install vQFX10k on KVM/QEMU for Testing or QA

This vQFX Platform is supposed to be used with vagrant and ships with a few nice fabrics that spin up on the go. But there's a few problems with that - which may not be instantly obvious if you plan on using it for testing or QA in your NetOps department:

  1. This Vagrant configuration relies and only supports virtualization via Virtualbox
    • so far no plans have been announced to switch from Virtualbox to another out of the box solution, so you'll have to hack this up a bit. libvirt, kvm/qemu makes this relatively simple, but you have to get familiar with their tools (again).
  2. vQFX comes in two "VMs": a Routing Engine (RE) and a Packet Forwarding Engine (PFE)
  • this is due to the way the hardware is actually set-up and working on a real bare metal switch or router (same story for vMX). ASICs are supplied in the form of shim kernel modules that make it possible to unit-test more advanced features or do functional testing before deploying on real (ide
@karanlyons
karanlyons / log4shell_regexes.py
Last active March 7, 2022 03:49
log4shell Regexes
import re
from urllib.parse import unquote
FLAGS = re.IGNORECASE | re.DOTALL
ESC_DOLLAR = r'(?:\$|[\\%]u0024||\\x24|\\0?44|%24)'
ESC_LCURLY = r'(?:\{|[\\%]u007B|\\x7B|\\173|%7B)'
ESC_RCURLY = r'(?:\}|[\\%]u007D|\\x7D|\\175|%7D)'
_U_PERCENT_ESCAPE_RE = re.compile(r'%(u[0-9a-f]{4})', flags=FLAGS)
_PERCENT_ESCAPE_RE = re.compile(r'%[0-9a-f]{2}', flags=FLAGS)
@leoluk
leoluk / custom_middleware.py
Created January 24, 2019 19:46
Netbox OAuth Login
"""
Custom LOGIN_REQUIRED middleware which allows OAuth URLs.
"""
import utilities.middleware
from django.conf import settings
class CustomLoginRequiredMiddleware(utilities.middleware.LoginRequiredMiddleware):
def __call__(self, request):
@0xabad1dea
0xabad1dea / rsa-not-buying-it.md
Last active May 4, 2022 21:59
Sorry, RSA, I'm just not buying it

Sorry, RSA, I'm just not buying it

I want to be extremely clear about three things. First, this is my personal opinion – insert full standard disclaimer. Second, this is not a condemnation of everyone at RSA, present and past. I assume most of them are pretty okay, and that the problem is confined to a few specific points in the company. However, “unknown problem people making major decisions at RSA” is a bit unwieldy, so I will just say RSA. Third, I'm not calling for a total boycott on RSA. I work almost literally across the street from them and I don’t want to get beat up by roving gangs of cryptographers at the local Chipotle.

RSA's denial published last night is utter codswallop that denies pretty much everything in the world except the actual allegations put forth by Reuters and hinted at for months by [other sources](http://li

@robcowart
robcowart / nprobe.conf
Created May 20, 2018 10:04
Improved nProbe Configuration File
# This configuration for nProbe exposes many more options than is available in the file provided
# when downloading nProbe.
#
# Most likely you will only need to change the -n and -i options for your environment. However, a
# number of other options are documented in case you need them.
#
# The provided template works very well with ElastiFlow - A solution to collect and analyze network
# flow data using the Elastic Stack. ElastiFlow is available from:
# https://github.com/robcowart/elastiflow
@tarcieri
tarcieri / semiprivate.md
Last active January 18, 2023 01:08
Ed25519-based semi-private keys

Semiprivate Keys

🚨 DANGER: INSECURE! 🚨

This may have seemed like a great idea in 2013, but the repeated "set/clear bits", a.k.a. clamping phases at each level of the hierarchy slowly subtract key strength.

Don't use this as described. Check out Ristretto.

Original text

Semi-private keys are an expansion of the traditional idea

@bkeating
bkeating / howto-filemerge-git-osx.md
Created March 11, 2010 21:36
HOWTO: Using FileMerge (opendiff) with Git on OSX

HOWTO: Using FileMerge (opendiff) with Git on OSX

FileMerge (opendiff) can really come in handy when you need to visually compare merging conflicts. Other times it's just a nice visual way to review your days work.

The following method works by creating a simple bash script (git-diff-cmd.sh) that sets us up with the proper command line arguments for Git to pass off files to FileMerge.

@abeluck
abeluck / gpg-offline-master.md
Last active October 22, 2023 02:59 — forked from KenMacD/cmd.md
GPG Offline Master Key w/ smartcard
@takeshixx
takeshixx / hb-test.py
Last active March 9, 2024 13:37
OpenSSL heartbeat PoC with STARTTLS support.
#!/usr/bin/env python2
"""
Author: takeshix <takeshix@adversec.com>
PoC code for CVE-2014-0160. Original PoC by Jared Stafford (jspenguin@jspenguin.org).
Supportes all versions of TLS and has STARTTLS support for SMTP,POP3,IMAP,FTP and XMPP.
"""
import sys,struct,socket
from argparse import ArgumentParser
@bradfitz
bradfitz / diskchecker.pl
Created July 24, 2012 21:05
diskchecker.pl
#!/usr/bin/perl
#
# Brad's el-ghetto do-our-storage-stacks-lie?-script
#
sub usage {
die <<'END';
Usage: diskchecker.pl -s <server[:port]> verify <file>
diskchecker.pl -s <server[:port]> create <file> <size_in_MB>
diskchecker.pl -l [port]