Skip to content

Instantly share code, notes, and snippets.

View Cougar's full-sized avatar
👨‍💻
I may be slow to respond.

Cougar

👨‍💻
I may be slow to respond.
View GitHub Profile
@RubenKelevra
RubenKelevra / fast_firefox.md
Last active November 11, 2024 20:23
Make Firefox fast again
@HarvsG
HarvsG / tradfriZHAhowtos.md
Last active November 17, 2024 00:29
Adding IKEA Tradfri Devices with ZHA on Home Assistant

Shortcut and On/Off switches

  1. Remove back cover with philips scredriver and instert provided battery
  2. In home assistant select a ZHA always-on zigbee device - such as a powered light or signal repeater in the same room the shortcut button will end up in
  3. Select "Add device via this device"
  4. Press the pair button 4 times on the back of the shortcut button
  5. Wait
  6. If using an On/Off switch and you want to bind it to a bulb for non-controller dependant control (i.e will work if home assistant is down)

Pairing On/Off Switches to IKEA Bulbs

@fjf2002
fjf2002 / btrfs-undelete
Last active March 29, 2021 22:12 — forked from Changaco/btrfs-undelete
btrfs-undelete
#!/bin/bash
# btrfs-undelete
# Copyright (C) 2013 Jörg Walter <[email protected]>
# Copyright (C) 2018 Franz-Josef Faerber <[email protected]>
# This program is free software; you can redistribute it and/or modify it under
# the term of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or any later version.
@cocoalabs
cocoalabs / gist:2fb7dc2199b0d4bf160364b8e557eb66
Created August 15, 2016 21:50
Color Terminal for bash/zsh etc..
man() {
env \
LESS_TERMCAP_mb=$(printf "\e[1;31m") \
LESS_TERMCAP_md=$(printf "\e[1;31m") \
LESS_TERMCAP_me=$(printf "\e[0m") \
LESS_TERMCAP_se=$(printf "\e[0m") \
LESS_TERMCAP_so=$(printf "\e[1;44;33m") \
LESS_TERMCAP_ue=$(printf "\e[0m") \
LESS_TERMCAP_us=$(printf "\e[1;32m") \
man "$@"
@Changaco
Changaco / btrfs-undelete
Last active November 2, 2024 13:07
btrfs-undelete
#!/bin/bash
# btrfs-undelete
# Copyright (C) 2013 Jörg Walter <[email protected]>
# This program is free software; you can redistribute it and/or modify it under
# the term of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or any later version.
if [ ! -b "$1" -o -z "$2" -o -z "$3" ]; then
echo "Usage: $0 <dev> <file/dir> <dest>" 1>&2
echo
@d-a-n
d-a-n / observium_agent_setup.sh
Last active March 25, 2023 06:42
Observium Agent Setup Guide
# CONFIG
SNMP_COMMUNITY=public
SYSCONTACT=dan
SYSLOCATION=Berlin
# get packages
apt-get install snmpd xinetd vim
mkdir -p /opt/observium && cd /opt
@tintinweb
tintinweb / hb-test.py
Last active August 29, 2015 13:58 — forked from takeshixx/hb-test.py
CVE-2014-0160 - OpenSSL tcp heartbeat PoC with STARTTLS, XMPP, Proxy CONNECT (SSL) support. Also includes some TLS record fixups, and features like file-dumping, TLS protocol version selection (HBMsg only)
#!/usr/bin/env python2
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
#
# tintinweb | https://github.com/tintinweb
# added proxy CONNECT support
# added HB packet variation for IPS testing
# added valid HB message padding (without HMAC)
# added options for custom HeartBeat.len, payload, fixed size TLSRecord.len, padding
@tahajahangir
tahajahangir / hb_test.py
Last active August 29, 2015 13:58 — forked from takeshixx/hb-test.py
Added threading/loop support (serveral features from different forks also added)
#!/usr/bin/env python2
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
# Modifed to send heartbeat requests for both TLS v1.1 and v1.2
import sys
import struct
import socket
@EdwardsBean
EdwardsBean / hb-test.py
Last active August 29, 2015 13:58 — forked from takeshixx/hb-test.py
#!/usr/bin/env python2
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
import sys
import struct
import socket
import time
import select
@mwgamera
mwgamera / hb-test.py
Last active August 29, 2015 13:58 — forked from takeshixx/hb-test.py
OpenSSL heartbeat PoC with SMTP and XMPP STARTTLS support.
#!/usr/bin/env python2
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
import sys
import struct
import socket
import time
import select