Skip to content

Instantly share code, notes, and snippets.

View cmbaughman's full-sized avatar
🧐
I may be slow to respond.

Chris Baughman cmbaughman

🧐
I may be slow to respond.
View GitHub Profile
@cmbaughman
cmbaughman / remove_pattern_lock.sh
Created February 4, 2014 02:03
How to break into an Android phone that uses pattern lock...
#!/bin/bash
adb shell
cp /data/data/com.android.providers.settings/databases
sqlite3 settings.db
update system set value=0 where name='lock_pattern_autolock'
update system set value=0 where name='lockscreen.lockedoutpermanently'
#It's good to include this part too.
adb shell rm -f /data/system/gesture.key
@cmbaughman
cmbaughman / setup-gnomedev-tools.sh
Created February 4, 2014 15:49
Automatically set up GNOME development environment (C, C++, Python, and JavaScript), all optional libs, and documentation.
#!/bin/bash
BH=$(which bash)
echo "Currently using " + $BH
echo " "
echo "update apt repos..."
echo " "
sudo apt-get update
@cmbaughman
cmbaughman / setup-android-dev.sh
Created February 4, 2014 15:53
Script to set up a complete AOSP development environment on Ubuntu variants by IOKP Team.
#!/bin/bash
#
# Author: mrimp
#
# Description:
# Setup script for AOKP Build Enviroment Ubuntu 13.04
#
# Legal Stuff:
#
# This script is free software; you can redistribute it and/or modify it under
@cmbaughman
cmbaughman / get-wifi-hotspot.md
Created February 5, 2014 18:47
Turn your Linux Machine into a WiFi Hotspot!

Turn Ubuntu based distros into a better WiFi hotspot


Use the following instructions to set up, configure, and run a WiFi hotspot from your computer. Note: The strength will increase with more connections.

  1. Add the following ppa: sudo add-apt-repository ppa:nilarimogard/webupd8
  2. Run: sudo apt-get update && sudo apt-get install ap-hotspot

After install, ap-hotspot must be configured, however first if using any sort of firewall, unblock the following apps:

@cmbaughman
cmbaughman / py-captcha.py
Created February 16, 2014 17:49
Script to beat CAPTCHA with Python 3
# A script to bypass the Bugcrowd sign-up page captcha
# Created by @pwndizzle - http://pwndizzle.blogspot.com
from PIL import Image
from urllib.error import *
from urllib.request import *
from urllib.parse import *
import re
import subprocess
@cmbaughman
cmbaughman / GetRSSFeed.js
Created March 5, 2014 16:02
Parse RSS feed as JSON from client using Google API
var rssUrl = "http://www.exploit-db.com/rss.xml";
function parseRSS(url, callback) {
$.ajax({
url: document.location.protocol + '//ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=10&callback=?&q=' + encodeURIComponent(url),
dataType: 'json',
success: function(data) {
callback(data.responseData.feed.entries);
}
});
}
var crypto = require('crypto');
function encrypt(text){
var cipher = crypto.createCipher('aes-256-cbc','d6F3Efeq');
var crypted = cipher.update(text,'utf8','hex');
crypted += cipher.final('hex');
return crypted;
}
function decrypt(text){
var decipher = crypto.createDecipher('aes-256-cbc','d6F3Efeq');
var dec = decipher.update(text,'hex','utf8');
[QUOTE=llrraa2010;47347928]1. mkdir hello
USER-NAME@MACHINE-NAME:~/Android$ cd kernel/common/drivers
USER-NAME@MACHINE-NAME:~/Android/kernel/common/drivers$ mkdir hello
2. hello.h
#ifndef _HELLO_ANDROID_H_
#define _HELLO_ANDROID_H_
#include

Key commands available when a group is selected

[ - Expand the currently selected group, and all its subgroups

] - Collapse the currently selected group, and all its subgroups

Enter - Expand or collapse the currently selected group.

Key commands available when a package is selected
@cmbaughman
cmbaughman / rails_resources.md
Created April 4, 2014 17:02 — forked from jookyboi/rails_resources.md
Rails-related Gems and guides to accelerate your web project.

Gems

  • Bundler - Bundler maintains a consistent environment for ruby applications. It tracks an application's code and the rubygems it needs to run, so that an application will always have the exact gems (and versions) that it needs to run.
  • rabl - General ruby templating with json, bson, xml, plist and msgpack support
  • Thin - Very fast and lightweight Ruby web server
  • Unicorn - Unicorn is an HTTP server for Rack applications designed to only serve fast clients on low-latency, high-bandwidth connections and take advantage of features in Unix/Unix-like kernels.
  • SimpleCov - SimpleCov is a code coverage analysis tool for Ruby 1.9.
  • Zeus - Zeus preloads your Rails app so that your normal development tasks such as console, server, generate, and specs/tests take less than one second.
  • [factory_girl](h