Skip to content

Instantly share code, notes, and snippets.

Bea Hughes barn

Block or report user

Report or block barn

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
barn / pinentry-hax
Created Mar 18, 2015
An alternative pinentry script for scripting PIN responses for GPG.
View pinentry-hax
# This.
# Is.
# Awful.
# write that file as:
# round=<0|1|2>
# oldpass=1234
# newpass=4321
barn / gist:51aeb936371e74c7424c
Created Feb 20, 2015
Example of building pyinstaller across platforms
View gist:51aeb936371e74c7424c
% export| egrep -i 'OSX|SDK'
% VERSIONER_PYTHON_PREFER_32_BIT=no arch -x86_64 /System/Library/Frameworks/Python.framework/Versions/2.7/bin/python /usr/local/bin/pyinstaller --console --clean --onefile --distpath /tmp/dist/ --workpath /tmp/work/
15 INFO: wrote /Users/bhughes/demo_pyinstaller.spec
33 WARNING: You are running 64-bit Python: created binaries will only work on Mac OS X 10.6+.
If you need 10.4-10.5 compatibility, run Python as a 32-bit binary with this command:
barn /
Created Feb 19, 2015
Simple pyinstaller failure demo script
#!/usr/bin/env python
import re
import sys
import time
import signal
import subprocess
import multiprocessing
# from xml.dom import minidom
View gist:5146daa120a98639796c
### Keybase proof
I hereby claim:
* I am barn on github.
* I am barn ( on keybase.
* I have a public key whose fingerprint is 8D57 9E3C 877D E203 8919 616D 2576 D730 2CAF DACA
To claim this, I am signing this object:
View gist:b68a3aff7cc025750f4c
barn / gist:f012fd085d963b3b7c3c
Last active Aug 29, 2015
Update bash on OSX 10.9.5
View gist:f012fd085d963b3b7c3c
[ "$(sw_vers -productVersion)" == "10.9.5" ] \
&& wget \
&& hdiutil attach BashUpdateMavericks.dmg \
&& sudo installer -target / -pkg '/Volumes/OS X bash update/BashUpdateMavericks.pkg' -verbose \
&& hdiutil eject '/Volumes/OS X bash update' \
&& rm BashUpdateMavericks.dmg \
&& echo "Done."
barn / bash.rb
Created Oct 1, 2014
Ohai 6 version of bash.rb for shellshock testing in Chef. From Find hosts via knife search node -i 'languages_bash_shellshock_vulnerable:true'
View bash.rb
# Taken from
# and
# for the CVE-2014-6271 et al Bash vulns.
# Regrettably, that's an ohai 7 version, so that doesn't work. Ohai 6 for lyfe.
provides 'languages/bash'
require_plugin 'languages'
barn / gist:11022a826e1e7cca291a
Created Aug 11, 2014
gogo and how bad this flight is.
View gist:11022a826e1e7cca291a
--- ping statistics ---
1601 packets transmitted, 809 packets received, 49.5% packet loss
round-trip min/avg/max/stddev = -17960.609/5519.345/56449.221/7589.958 ms
barn / nmap-rspec-fail.rb
Last active Aug 29, 2015 — forked from garethr/nmap-rspec.rb
Building on @garethr's work on nmap-rspec, this adds being able to do multiple hosts, rather than just a single IP/host. Just specify more of those blocks...
View nmap-rspec-fail.rb
[ben@laptop:nmap-rspec2]% rspec -f d -c nmap-rspec.rb
the scan of the IP ranges
Starting Nmap 6.46 ( ) at 2014-07-06 23:21 EDT
Nmap scan report for
Host is up (0.26s latency).
20/tcp filtered ftp-data
21/tcp filtered ftp
22/tcp filtered ssh
View gist:6706060
SPEAKER: Peter Norton / Knewton, Inc.
TITLE: Cloudy with a 3-Headed Dog
Most startups begin their cloud adventures by using shared ssh keys, shared accounts, and
avoid thinking about infrastructure until pretty late in the game. At Knewton, we've gone
the other way and implemented Kerberos and LDAP as our authentication and naming services...
in the public AWS cloud. This case study will discuss the factors we considered as we
You can’t perform that action at this time.