AHA-best-msf-interface-ever

403 views

Published on

This is more or less just for fun, but it does allow you to remotely control a metasploit instance, kind of like db_nmap lets you control nmap from msf. Since I wrote this, foundation (I think) rewrote the msfrpcd-bruteforce script, and the msgpack implementation he wrote in pure lua could probably be substituted instead, but I learned a lot doing this and am making slides for what I learned. This was briefed at AHA in "turbo-talk" style. I'll be uploading a more readable version soon

Published in: Technology
1 Comment
0 Likes
Statistics
Notes
  • to watch the movie clip:

    http://nmap.org/presentations/BHDC10/ 24th Minute
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • Be the first to like this

No Downloads
Views
Total views
403
On SlideShare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
3
Comments
1
Likes
0
Embeds 0
No embeds

No notes for slide

AHA-best-msf-interface-ever

  1. 1. Best MSF InterfaceEver! { < kernelsmith
  2. 2. msfrpcd duh
  3. 3. Via Lua
  4. 4. Ooh ooh, via NMap
  5. 5. You probably can’t hear thishttp://nmap.org/presentations/BHDC10/ 24th Minute
  6. 6. I.E. Because I Canor I at least thought I could It’s Also All the “Flame” These Days
  7. 7. For Lua Need: Lua 5.1 for nowsockets – luasocket http – luasocket*msgpack – let’s talk* http://w3.impa.br/~diego/software/luasocket/
  8. 8. Lua 5.1Default package for most Linux “Sweet spot” right now apt-get install lua5.1 liblua5.1-0-dev # <-- this is key# LuaSocket too! liblua5.1-socket2 liblua5.1-socket-dev liblua-socket-doc
  9. 9. msgpack: mplua – C/++ 1lua-msgpack – luarocks 2 lua-cmsgpack (redis) N others
  10. 10. Testingbox:~/lua/code> luaLua 5.2.0 Copyright (C) 1994…>require “msgpack”if not error then g2gelse check path & cpathend>print(package.path)
  11. 11. Easy Part: Learn Lua Learn luasocketLearn rpc api and…
  12. 12. Harder Part: NSE Integration Lots of nmap.org reading Brushing up on GCC #nmap helpfulmad thanks to bonsaiviking
  13. 13. NSE Integration:Pure Lua easy, Clib annoyingNmap 6.1 == Lua 5.1Nmap 5.2 == Lua 5.2
  14. 14. NSE Integration:I used cmsgpack, so clibCreated nse_cmsgpack.hcmsgpack.c => nse_cmsgpack.c - edited for 5.2Edited nse_main.ccEdited Makefile.in
  15. 15. Prayed a lot.Got lots of help from #nmapnear the endnse_main.cc = pastebin.com/aCYNfUA5Makefile.in = pastebin.com/AjinN6Y8nse_cmsgpack.h = pastebin.com/zz0z6TWCnse_cmsgpack.c = pastebin.com/SJbcmB9NI will finish updating these pastes and put in github.com/kernelsmith
  16. 16. Lame Demo

×