Skip to content

Instantly share code, notes, and snippets.

View adepasquale's full-sized avatar

Andrea De Pasquale adepasquale

View GitHub Profile
@res0nat0r
res0nat0r / screen_ssh.sh
Created October 29, 2009 19:50
Set screen window title to remote host.
#!/bin/bash
# screen_ssh.sh by Chris Jones <cmsj@tenshu.net>
# Released under the GPL v2 licence.
# Set the title of the current screen to the hostname being ssh'd to
#
# usage: screen_ssh.sh $PPID hostname
#
# This is intended to be called by ssh(1) as a LocalCommand.
# For example, put this in ~/.ssh/config:
#
@jed
jed / LICENSE.txt
Created May 20, 2011 13:27 — forked from 140bytes/LICENSE.txt
generate random UUIDs
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Jed Schmidt <http://jed.is>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@ksose
ksose / emeaiutati
Created January 16, 2012 22:19
memaiutati
#!/usr/bin/python
import sys
import subprocess
import winappdbg
from winappdbg import win32
winappdbg.System.request_debug_privileges()
system = winappdbg.System()
system.request_debug_privileges()
@benizi
benizi / simpler
Created November 30, 2012 05:26 — forked from justinabrahms/colortest.py
Show how different terminals show bold colors
#!/bin/sh
# Print four lines showing blocks of colors: 0-7 | 0-7bold | 8-15 | 8-15bold
perl -CADS -lwe '
my $block = shift || (chr(0x2588) x 3);
for (["", 0], ["1;", 0], ["", 8], ["1;", 8]) {
my ($bold, $offset) = @$_;
my @range = map $offset + $_, 0..7;
printf "%s %-6s ", $bold ? "bold" : "norm", "$range[0]-$range[-1]";
print map("\e[${bold}38;5;${_}m$block", @range), "\e[0m"
}
@doitian
doitian / build.xml
Created May 29, 2013 22:59
Install android app, start it and forward jdwp port to local for jdb
<target name="run" depends="debug,install">
<xpath input="${manifest.abs.file}"
expression="/manifest/application/activity/@android:name" output="project.app.activity" />
<exec executable="${sdk.dir}/platform-tools/adb">
<arg value="shell" />
<arg value="am" />
<arg value="force-stop" />
<arg value="${project.app.package}" />
</exec>
anonymous
anonymous / kippo_cmd_analyzer.py
Last active December 22, 2015 18:59
analyzes Kippo logs to build a Graphviz directed graph of commands and what is likely to come next. Could use some clean up. For more information see http://monkey.org/~jose/honeynet/kippo/ ...
#!/usr/bin/env python
# builds a stochastic model of ssh honeypot activity from
# kippo logs.
# yields a dot graph to be processed by graphviz.
import sys
def main():
res = {}
@eshizhan
eshizhan / conv2vmx-ovf.py
Last active April 25, 2021 22:05
a script that can help import VMs into VMware ESXi from VirtualBox. tested vbox 4.2.18 and ESXi 5.1.
#!/usr/bin/env python
#
# usage:
# conv2vmx-ovf.py some-vm.ovf
#
# ref: http://www.cnblogs.com/eshizhan/p/3332020.html
#
import sys
fn = sys.argv[1]
@pedroagabreu
pedroagabreu / dns2.py
Created October 22, 2013 16:16
Query nameservers nonrecursively. Script by Jeremy McGuinn, Cisco.
#!/usr/bin/python
# This script will query a name server nonrecursively
# RFC 1912 recommends that the $TTL value on the name server
# be set to 1 day or longer
# -*- coding: utf-8 -*-
import sys
import dns
from dns.exception import DNSException
from dns.rdataclass import *
@JamieMason
JamieMason / unfollow.js.md
Last active July 23, 2024 07:26
Unfollow everyone on twitter.com

Unfollow everyone on twitter.com

  1. Go to https://twitter.com/YOUR_USER_NAME/following
  2. Open the Developer Console. (COMMAND+ALT+I on Mac)
  3. Paste this into the Developer Console and run it
// Unfollow everyone on twitter.com, by Jamie Mason (https://twitter.com/fold_left)
// https://gist.github.com/JamieMason/7580315
//
@nsonnad
nsonnad / tsv2csv.py
Created November 22, 2013 11:38
Python script for converting tsv to csv
import sys
import csv
tabin = csv.reader(sys.stdin, dialect=csv.excel_tab)
commaout = csv.writer(sys.stdout, dialect=csv.excel)
for row in tabin:
commaout.writerow(row)