Skip to content

Instantly share code, notes, and snippets.

View todb-r7's full-sized avatar

Tod Beardsley todb-r7

View GitHub Profile
@todb-r7
todb-r7 / gist:3789444
Created September 26, 2012 17:43
typical work flow
# Short story:
$ cd metasploit-framework/
$ git checkout master
$ git log -1
$ git fetch upstream
$ git merge upstream/master
$ git checkout -b something-wonderful
$ echo "Here's something rad" > modules/auxiliary/something_rad.rb
$ git status
$ git add modules/auxiliary/something_rad.rb
def validate_suspender
suspender = datastore['SUSPENDER_DLL']
suspender.valid?
end
# Then call this somewhere.
https://github.com/ALICE/metasploit-framework/pull/new/BOB:BRANCHNAME..BRANCHNAME
Module options (exploit/windows/smb/psexec):
Name Current Setting Required Description
---- --------------- -------- -----------
RHOST 192.168.155.6 yes The target address
RPORT 445 yes Set the SMB service port
SHARE ADMIN$ yes The share to connect to, can be an admin share (ADMIN$,C$,...) or a normal read/write folder share
SMBDomain WORKGROUP no The Windows domain to use for authentication
SMBPass mypasswd! no The password for the specified username
SMBUser administrator no The username to authenticate as
@todb-r7
todb-r7 / msf-backtrack5r3.md
Last active December 19, 2021 06:39
Fixing and updating Metasploit on BackTrack5, R3

Metasploit on BackTrack5, Revision 3 (BT5R3)

Significantly easier than the Windows install, since you're pretty much already there. You just need to remove the broken SVN checkout and get onto the new Git hotness. If you just want the one-liner fix, scroll to the bottom of this page.

1) Load the Metasploit environment options

After opening a terminal session:

source /opt/metasploit/scripts/setenv.sh

@todb-r7
todb-r7 / pre-commit
Last active December 10, 2015 10:39 — forked from anonymous/pre-commit
#!/usr/bin/env ruby
# Check that modules actually pass msftidy checks first.
# To install this script, copy it to ".git/hooks/pre-commit" and
# make it executable
valid = true # Presume validity
files_to_check = []
results = %x[git diff --cached --name-only]
@todb-r7
todb-r7 / .vimrc
Last active December 11, 2015 20:58
My .vimrc.after (for use with Metasploit)
" If using Janus, then this should be .vimrc.after
" Technically this is really a gvimrc but who's counting.
set nocompatible
colorscheme slate
filetype plugin indent on
set hls
" Pretty standard Ruby default tab indentation
set tabstop=2 softtabstop=2 shiftwidth=2 expandtab shiftround smarttab
@todb-r7
todb-r7 / modules by commits
Created February 5, 2013 16:45
A snapshot of modules ranked by number of commits that touched that module. The theory is that the more "popular" a module is, the more tweaks it'll get over the course of its life.
========================================================================
Sorted modules by commit counts
modules/exploits/windows/smb/psexec.rb 61
modules/exploits/windows/smb/ms08_067_netapi.rb 56
modules/exploits/multi/http/tomcat_mgr_deploy.rb 48
modules/exploits/multi/browser/java_signed_applet.rb 39
modules/exploits/windows/browser/ms03_020_ie_objecttype.rb 37
modules/exploits/multi/http/jboss_maindeployer.rb 36
modules/exploits/windows/iis/ms03_007_ntdll_webdav.rb 36
modules/exploits/unix/webapp/php_include.rb 34
@todb-r7
todb-r7 / module-stats.md
Last active December 14, 2015 16:59
Blog post about module stats

America's Next Top Module

If you follow this blog at all, you're familiar with Christian Kirsch's round up of the most searched modules in our Exploit database. These stats are gathered from the Metasploit exploit database backend, and tends to have a pretty strong recency bias -- modules that recently got a lot of press or Twitter buzz tend to shoot up to the top of the list.

Of course, that's the point of "Exploit Trends" exercise -- we and our readers want to know what's recently interesting. But we sometimes ask

@todb-r7
todb-r7 / client.md
Last active December 15, 2015 04:09
TODO: Build a vulnerable workstation