Skip to content

Instantly share code, notes, and snippets.

View hazcod's full-sized avatar

Niels Hofmans hazcod

View GitHub Profile
@hazcod
hazcod / setup_media_vps.sh
Last active September 23, 2015 13:33
Hardening configuration for apache2/httpd with webdav server
address="vps.tv"
sudo apt-get install -y apache2
sudo mkdir /var/log/httpd
sudo a2enmod headers
sudo a2enmod dav
sudo a2enmod dav_fs
sudo a2enmod rewrite
sudo a2enmod ssl
sudo a2enmod auth_digest
@hazcod
hazcod / drawio-vega-overclocking.xml
Last active December 27, 2017 11:21
Draw.io file for overclocking AMD VEGA cards.
<mxfile userAgent="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.108 Safari/537.36" version="7.8.7" editor="www.draw.io" type="device"><diagram name="Page-1" id="c7558073-3199-34d8-9f00-42111426c3f3">3VvbcqM4EP0aV+08TAohwPAYe3LZqs3uVKVqZudRwbJhg5FXyHGcr1/JiIsk8CWA441fbBohoT7dR6cFHsHp8vWOolX0QGY4GdnW7HUEv41sGzjQ4l/Css0t4zHIDQsaz2SjyvAYv2FplNct1vEMZ0pDRkjC4pVqDEma4pApNkQp2ajN5iRRR12hBTYMjyFKTOvPeMai3OrbXmW/x/EiKkYGXpCfeULh84KSdSrHG9lwvvvkp5eo6EtONIvQjGxqJngzglNKCMt/LV+nOBG+LdyWX3fbcra8b4pTdswFML/gBSVrOfUfN3fXniPvjm0Lj2yimOHHFQrF8YajPoITlMSLlB+GfDBMueEFUxZzL17LE8t4NhMdTOYkZY+yM8CPM0bJc+laKFrESTIlCaG74eAt/0yn5mzkBMVA+LVmkrO7w2SJGd3yJvKsDSVmMhILx28qWANpimqIetKGZCAtyo4rZ/If0p/NvnUafet6n8a3jvVRri1Arfn2erVKxL1lZM7ExMiGu41/J0hYGXpKOKGIBIacZODEAAHPOAPIw5SkwrMpuakZK9/WfBkEFv8YXudOm3C/0u3f/MC6covDX+KwHL3B+RlZ0xAruckQXeCiVcFA4m73QlQDAVgNKJRGihPE4heV+JqwkWN8J3HKavmlxYCroZtPSF5UJyKtH6B1BPSOcjcYHe0ipZz3ccEzNoLnNkFZxE2T3/96PGdkKHGxC5OjIsMxIwNeWlz4Gp7BOwMDah3p/fQXFwCay1
@MPJHorner
MPJHorner / Docker.qcow2.reduce.sh
Created August 21, 2016 10:15
Reduce / Clean Up Docker.qcow2 File
#Ensure to exit docker from taskbar first.
cd ~/Library/Containers/com.docker.docker/Data/com.docker.driver.amd64-linux /Applications/Docker.app/Contents/MacOS/qemu-img convert -O qcow2 Docker.qcow2 Docker2.qcow2 mv Docker2.qcow2 Docker.qcow2
@olivierlambert
olivierlambert / onlinenet_debian_ipv6.md
Last active May 10, 2018 00:49 — forked from eraserewind/onlinenet_debian_ipv6.md
Online.net: IPv6 in Debian virtual machines

Online.net: IPv6 in Debian virtual machines

Without this annoying dribbler thing.

Variables

  • RANGE = /64
  • EXT_IF = external interface
  • IPV6 = Any IPv6 in RANGE
  • DUID = dhcp client id. Find it in console.online.net
@mgbowman
mgbowman / enczfs
Last active July 28, 2018 12:11
FreeBSD rc script for unlocking a geli encrypted zvol
#!/bin/sh
#
# $FreeBSD$
#
# PROVIDE: enczfs
# REQUIRE: sshd
# BEFORE: iocage
# KEYWORD: shutdown
#

Trying to deploy WPA3 on my home network

Introduction

Recently, news broke about a new possible offline attack on WPA2 using PMKID. To summarize the attack, WPA2 protected APs can end up broadcasting PMKID values which can then be used to offline-brute-force the password.

These PMKID values are computed this way:

PMKID = HMAC-SHA1-128(PMK, "PMK Name" | MAC_AP | MAC_STA)
@iamprbkr
iamprbkr / scanio.sh
Created May 7, 2018 12:57 — forked from haccer/scanio.sh
PoC script to mass-locate vulnerable subdomains using results from Rapid7's Project Sonar
#!/bin/bash
# Usage : ./scanio.sh <save file>
# Example: ./scanio.sh cname_list.txt
# Premium
function ech() {
spinner=( "|" "/" "-" "\\" )
while true; do
for i in ${spinner[@]}; do
echo -ne "\r[$i] $1"

I was chasing down another issue (slow "Save As") and thought these two issues may have been related (with QuickLook being the common broken link). Unfortunately, my "Save As" dialog is still miserably slow on the initial load; but IconServicesAgent hasn't gone above 30MB and he rarely makes an appearance in the Console!

Some of these steps may not be necessary, but here are all of the steps I took that inadverdently put IconServicesAgent back in its place. Note: all commands are a single-line, if they appear to be multiple that's just the forum formatting.

  1. Check for any QuickLooks related .plist files. In a terminal: mdfind com.apple.quicklook. -name .plist

  2. I only had files at the system level (specifically within /System/Library/LaunchAgents/). If you have others, modify the directions below to take that into account (re-introducing plist files from the system level back up to the user).

  3. Make some temporary directories to store these plist files, just in case: mkdir ~/tmp-quicklook

@ledongthuc
ledongthuc / Readme.md
Last active March 23, 2020 08:19
[Github Actions][Go] Check pull requests before merging

Create template actions that's used to verify Go language pull requests before merging. It's easy to custom the flow, tools with your case.

Put pr_checker.yml or pr_checker_simple.yml to .github/workflows/ and see how it works with your pull requests. Make sure you are allows to use actions of Github.

  • pr_checker.yml is using by mine with full checking tools. It will make sure every Go langauge pull requests will be buildable, testable, passed security checking and error-able code checking.
  • pr_checker_simple.yml is more simpler with buildable, testable.

References:

@hazcod
hazcod / telenet-modem-firewall.txt
Created March 26, 2020 14:54
Telenet modem firewall ruleset.
# Generated by iptables-save v1.4.21 on Sun Jan 19 08:14:54 2020
*raw
:PREROUTING ACCEPT [17478:786616]
:OUTPUT ACCEPT [15285:6842393]
COMMIT
# Completed on Sun Jan 19 08:14:54 2020
# Generated by iptables-save v1.4.21 on Sun Jan 19 08:14:54 2020
*nat
:PREROUTING ACCEPT [412:43501]
:INPUT ACCEPT [54:3686]