Skip to content

Instantly share code, notes, and snippets.

View strugee's full-sized avatar

AJ Jordan strugee

View GitHub Profile
@daserge
daserge / logcat.ps1
Last active May 4, 2016 09:38
adb logcat filter by package id
adb logcat | Select-String (adb shell ps | findstr io.cordova.hellocordova).Split("", [System.StringSplitOptions]::RemoveEmptyEntries)[1]

Someone tried to exploit the Shellshock vulnerability in Bash on lodash.com, likely as part of a mass-exploit attempt.

In this case, the exploit attempted to download a modified version of @schierlm’s pseudo-terminal Perl script that would connect to 72.167.37.182 on port 23. The download URL contains the targeted host name (?h=lodash.com) which gives the attacker an indication of which hosts might have the /tmp/a.pl backdoor in place.

BIGVER

The BIGVER spec is a semver.io compatible versioning scheme

Rules

  1. all new versions must increment the major version always
@jashkenas
jashkenas / semantic-pedantic.md
Last active November 29, 2023 14:49
Why Semantic Versioning Isn't

Spurred by recent events (https://news.ycombinator.com/item?id=8244700), this is a quick set of jotted-down thoughts about the state of "Semantic" Versioning, and why we should be fighting the good fight against it.

For a long time in the history of software, version numbers indicated the relative progress and change in a given piece of software. A major release (1.x.x) was major, a minor release (x.1.x) was minor, and a patch release was just a small patch. You could evaluate a given piece of software by name + version, and get a feeling for how far away version 2.0.1 was from version 2.8.0.

But Semantic Versioning (henceforth, SemVer), as specified at http://semver.org/, changes this to prioritize a mechanistic understanding of a codebase over a human one. Any "breaking" change to the software must be accompanied with a new major version number. It's alright for robots, but bad for us.

SemVer tries to compress a huge amount of information — the nature of the change, the percentage of users that wil

@mtbentley
mtbentley / waste.sh
Last active August 29, 2015 14:03
Waste bandwidth over SSH
#!/bin/sh
# This script exists solely to waste download bandwidth (and thus NSA storage
# space) over ssh. It starts listening with nc on port 2020, and simultaneously
# connects to a remote server and pipes random data over the ssh connection
# USAGE: waste.sh [-P] [-p port] [-f] <remote host>
# -P pipe the output through pv, to watch it real-time (doesn't seem to work yet)
# -f use /dev/frandom on remote host
# -p port a different port
anonymous
anonymous / night-before-opsmas.txt
Created December 24, 2013 07:19
Twas the night before Opsmas..
'Twas the night before Christmas, when all through the racks
Not a server was alerting, not even Compaqs.
The backups were written to tapes with care
In hopes that later the data would be there.
The machines were nestled all snug in their sleds
Whilst visions of vengeance danced in their heads;
And oncall in his three-wolf and I in my rack.
Had just settled down for some syn and some ack.
@ryancdotorg
ryancdotorg / dnaas.c
Created October 30, 2013 23:20
Wrapper library to use /dev/null as a service on Linux via LD_PRELOAD
/* This is a wrapper library that will give your server the power of
* /dev/null as a service, as seen at http://devnull-as-a-service.com/
*
* Compile:
* gcc -ggdb -shared -fPIC dnaas.c -ldl -lcurl -o libdnaas.so
*
* Try:
* LD_PRELOAD=./libdnaas.so dd if=/dev/sda of=/dev/null bs=8192 count=16
*
* Install:
@rofl0r
rofl0r / init.c
Created August 6, 2013 21:15
minimal init daemon by rich felker, author of musl libc
#define _XOPEN_SOURCE 700
#include <signal.h>
#include <unistd.h>
int main()
{
sigset_t set;
int status;
if (getpid() != 1) return 1;
@yocontra
yocontra / gulp.coffee
Last active April 3, 2017 02:43
Ideal build system
gulp = require 'gulp'
clean = require 'gulp-clean'
jade = require 'gulp-jade'
coffee = require 'gulp-coffee'
minify = require 'gulp-minify'
###
quick syntax ideas:
gulp.files() takes a glob and is an array of file streams
@nuxodin
nuxodin / node.js "global" and browser "window"
Created December 18, 2012 00:46
node.js "global" and browser "window"
(function (global) {
/* ... Code that defines MyModule ... */
global.MyModule = (global.module || {}).exports = MyModule;
})(this);