"cocotte bag"
: exact match"* is thicker than water"
:*
to replace a phrase inside exact matchjaguar -car
: minus to filter out matchessite:time.com google
: search on site, you don't need '.', e.g. 'site:gov'define:bae
: check definition, even for slang$0..$50
: numeric range (ignore$
)"inbound marketing" ~professional
: synonymsrelated:nationalgeographic.com
: similar sites
View firewall.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Simple Firewall Script. | |
#Add "pre-up iptables-restore < /etc/iptables.rules" to /etc/network/interfaces | |
#Setting up default kernel tunings here (don't worry too much about these right now, they are acceptable defaults) #DROP ICMP echo-requests sent to broadcast/multi-cast addresses. | |
echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts | |
#DROP source routed packets | |
echo 0 > /proc/sys/net/ipv4/conf/all/accept_source_route | |
#Enable TCP SYN cookies | |
echo 1 > /proc/sys/net/ipv4/tcp_syncookies |
View openbsd_vbox_resolution.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# inspired by https://www.tumfatig.net/20190131/customized-resolution-for-openbsd-in-virtualbox/ | |
if [ "$(id -u)" -ne 0 ]; then | |
echo "This script must be run as root" | |
exit 1 | |
fi | |
mkdir -p /etc/X11/xorg.conf.d |
View host_vbox_custom_resolution.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ -z "$1" ] || [ -z "$2" ]; then | |
echo "Pass VBox machine name and screen resolution" | |
echo "Example: 'OpenBSD New' '1920x1080x32'" | |
exit 1 | |
fi | |
VBoxManage setextradata "$1" CustomVideoMode1 "$2" |
View unbond.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server: | |
########################################################################### | |
# BASIC SETTINGS | |
########################################################################### | |
# Time to live maximum for RRsets and messages in the cache. If the maximum | |
# kicks in, responses to clients still get decrementing TTLs based on the | |
# original (larger) values. When the internal TTL expires, the cache item | |
# has expired. Can be set lower to force the resolver to query for data | |
# often, and not trust (very large) TTL values. | |
cache-max-ttl: 86400 |
View advanced_search.markdown
Google
View gist:b3731647a8f7940f9891b839cc5b54ac
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
! model | |
pc101 Generic 101-key PC | |
pc102 Generic 102-key (Intl) PC | |
pc104 Generic 104-key PC | |
pc105 Generic 105-key (Intl) PC | |
dell101 Dell 101-key PC | |
latitude Dell Latitude series laptop | |
dellm65 Dell Precision M65 | |
everex Everex STEPnote | |
flexpro Keytronic FlexPro |
View signing-gpg-keys.md
This is a quick guide of the commands we use to sign someone's GPG key in a virtual key signing party.
Note: The steps cover only the technical aspects of signing someone's key. Before signing someone's key, you must verify their identity. This is usually done by showing government-issued ID and confirming the key's fingerprint
The commands will work for both GPG and GPG2.
I use Julian's key for the examples. His key id is 2AD3FAE3
. You should substitute with the appropriate key id when running the commands.
Signing the key
- List the keys currently in your keyring:
gpg --list-keys
.
View gpg2qrcodes.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Heavily depends on: | |
# libqrencode (fukuchi.org/works/qrencode/) | |
# paperkey (jabberwocky.com/software/paperkey/) | |
# zbar (zbar.sourceforge.net) | |
# Producing the QR codes: | |
# Split over 4 codes to ensure the data per image is not too large. | |
gpg --export-secret-key KEYIDGOESHERE | paperkey --output-type raw | base64 > temp | |
split temp -n 4 IMG | |
for f in IMG*; do cat $f | qrencode -o $f.png; done |
View xrectsel.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<stdlib.h> | |
#include<X11/Xlib.h> | |
#include<X11/cursorfont.h> | |
#include<unistd.h> // added for sleep/usleep | |
// original from [https://bbs.archlinux.org/viewtopic.php?id=85378 Select a screen area with mouse and return the geometry of this area? / Programming & Scripting / Arch Linux Forums] | |
// build with (Ubuntu 14.04): | |
// gcc -Wall xrectsel.c -o xrectsel -lX11 |
View renew-gpgkey.md
Renew GPG key
Given that your key has expired.
$ gpg --list-keys
$ gpg --edit-key KEYID
Use the expire command to set a new expire date:
NewerOlder