Archiwum

Archive for Maj 2012

Metasploit – How To install Pcaprub For Windows

Maj 31, 2012 1 komentarz

While using Metasploit 3 console and trying to use the auxiliary ipidseq scanner module I get the following error message:

The Pcaprub module is not available: no such file to load — pcaprub
[-] Auxiliary failed: RuntimeError Pcaprub not available
[-] Call stack:

Ho to install Pcapruby for Windows  ( Windows 7 ) :

  •     Install latest msf3 either through installer or (tortoise) svn, the ruby shipped with msf3 installer will not be used for this test
  •     Update msf3 to at least version  – ( svn update )
  •     Unzip it to c:\ to have C:\WpdPack\Include, C:\WpdPack\Lib , ….
  •     copy this file in c:\devkit and extract here
  •     launch your command prompt and cd c:\devkit
  •     launch devkitvars.bat
  •     ruby dk.rb init
  •     ruby dk.rb install
  •     cd …../msf3/external/pcaprub
  •     ruby extconf.rb
  •     make
  •     make install
  •     ruby test_pcaprub.rb
  • copy c:\Ruby193\lib\ruby\site_ruby\1.9.1\i386-msvcrt\pcaprub.so to c:\Program Files (x86)\Rapid7\framework\ruby\lib\ruby\site_ruby\1.9.1\i386-msvcrt\

Microsoft Windows [Wersja 6.1.7601]
 Copyright (c) 2009 Microsoft Corporation. Wszelkie prawa zastrzeżone.

c:\devkit>dir
 Wolumin w stacji C nie ma etykiety.
 Numer seryjny woluminu: FE45-9B53

Katalog: c:\devkit
 c:\devkit>dir *.bat
 Wolumin w stacji C nie ma etykiety.
 Numer seryjny woluminu: FE45-9B53

Katalog: c:\devkit

2010-12-14  21:00               297 devkitvars.bat
 2010-09-29  01:48             7 167 msys.bat
 2 plik(ów)              7 464 bajtów
 0 katalog(ów)  93 853 249 536 bajtów wolnych

c:\devkit>devkitvars.bat
 Adding the DevKit to PATH...

c:\devkit>ruby dk.rb init
 [INFO] found RubyInstaller v1.9.3 at C:/Ruby193

Initialization complete! Please review and modify the auto-generated
 'config.yml' file to ensure it contains the root directories to all
 of the installed Rubies you want enhanced by the DevKit.

c:\devkit>ruby dk.rb install
 [INFO] Updating convenience notice gem override for 'C:/Ruby193'
 [INFO] Installing 'C:/Ruby193/lib/ruby/site_ruby/devkit.rb'

c:\devkit>cd c:\programs files (x86)
 System nie może odnaleźć określonej ścieżki.

c:\devkit>cd ..

c:\>cd Programs Files (x86)
 System nie może odnaleźć określonej ścieżki.

c:\>cd Program Files (x86)

c:\Program Files (x86)>cd Rapid7

c:\Program Files (x86)\Rapid7>cd framework

c:\Program Files (x86)\Rapid7\framework>cd msf3

c:\Program Files (x86)\Rapid7\framework\msf3>cd external

c:\Program Files (x86)\Rapid7\framework\msf3\external>cd pcaprub

c:\Program Files (x86)\Rapid7\framework\msf3\external\pcaprub>ruby extconf.rb
 platform is i386-mingw32

[*] Running checks for netifaces code added by metasploit project
 -----------------------------------------------------------------
 checking for main() in -lws2_32... yes
 checking for main() in -liphlpapi... yes
 checking for windows.h... yes
 checking for winsock2.h... yes
 checking for iphlpapi.h... yes

[*] Running checks for pcap code...
 -----------------------------------
 checking for pcap_open_live() in -lwpcap... yes
 checking for pcap_setnonblock() in -lwpcap... yes
 creating Makefile

c:\Program Files (x86)\Rapid7\framework\msf3\external\pcaprub>make
 generating pcaprub-i386-mingw32.def
 compiling netifaces.c
 netifaces.c: In function 'add_to_family':
 netifaces.c:194:2: warning: ISO C90 forbids mixed declarations and code
 netifaces.c: In function 'rbnetifaces_s_addresses':
 netifaces.c:213:2: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:218:2: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:261:3: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:266:3: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:279:4: warning: ISO C90 forbids mixed declarations and code
 netifaces.c: In function 'rbnetifaces_s_interfaces':
 netifaces.c:545:2: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:588:3: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:590:3: warning: ISO C90 forbids mixed declarations and code
 netifaces.c: In function 'rbnetifaces_s_interface_info':
 netifaces.c:753:3: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:763:3: warning: ISO C90 forbids mixed declarations and code
 netifaces.c:775:3: warning: ISO C90 forbids mixed declarations and code
 compiling pcaprub.c
 In file included from C:/WpdPack/include/pcap/pcap.h:41:0,
 from C:/WpdPack/include/pcap.h:45,
 from pcaprub.c:9:
 C:/WpdPack/include/pcap-stdinc.h:64:0: warning: "snprintf" redefined
 c:/Ruby193/include/ruby-1.9.1/ruby/subst.h:6:0: note: this is the location of th
 e previous definition
 C:/WpdPack/include/pcap-stdinc.h:65:0: warning: "vsnprintf" redefined
 c:/Ruby193/include/ruby-1.9.1/ruby/subst.h:7:0: note: this is the location of th
 e previous definition
 linking shared-object pcaprub.so

c:\Program Files (x86)\Rapid7\framework\msf3\external\pcaprub>make install
 /usr/bin/install -c -m 0755 pcaprub.so C:/Ruby193/lib/ruby/site_ruby/1.9.1/i386-
 msvcrt
 installing default pcaprub libraries

c:\Program Files (x86)\Rapid7\framework\msf3\external\pcaprub>ruby test_pcaprub.
 rb
 Run options:

# Running tests:

Pcaprub default device: \Device\NPF_{FC3FE7B3-21B1-410F-AAFD-57F5E62EFDB3}
 .Pcaprub net (\Device\NPF_{FC3FE7B3-21B1-410F-AAFD-57F5E62EFDB3}): 192.168.0.0 f
 fffff00
 .AF_LINK Value is -1000
 AF_INET Value is 2
 AF_INET6 Value is 23
 .\Device\NPF_{14ED440E-E5BE-4290-852A-073A7BD7E251} :
 -1000 :
 addr : 22:24:2c:0b:07:33

2 :
 addr : 0.0.0.0
 netmask : 0.0.0.0
 broadcast : 255.255.255.255

\Device\NPF_{271276FF-FBEE-4113-98FA-BF770EB76C38} :
 -1000 :
 addr : 00:23:8b:9b:d9:4b

2 :
 addr : 0.0.0.0
 netmask : 0.0.0.0
 broadcast : 255.255.255.255

\Device\NPF_{4AB0E7A8-ED96-40C8-9F7E-D78933F02405} :
 -1000 :
 addr : 00:50:56:c0:00:01

2 :
 addr : 192.168.64.1
 netmask : 255.255.255.0
 broadcast : 192.168.64.255

\Device\NPF_{9B1AD6F8-0BD9-4EE0-A2EC-64403CB51B4A} :
 -1000 :
 addr : 00:50:56:c0:00:08

2 :
 addr : 192.168.180.1
 netmask : 255.255.255.0
 broadcast : 192.168.180.255

\Device\NPF_{B8CD3325-6221-4AFC-A3EB-B1BD363D3BE2} :
 -1000 :
 addr : 00:24:2c:0b:07:33

2 :
 addr : 0.0.0.0
 netmask : 0.0.0.0
 broadcast : 255.255.255.255

\Device\NPF_{F65076A9-A7F1-4357-A08A-804E694187DC} :
 -1000 :
 addr : 08:00:27:00:c4:35

2 :
 addr : 192.168.56.1
 netmask : 255.255.255.0
 broadcast : 192.168.56.255

\Device\NPF_{FC3FE7B3-21B1-410F-AAFD-57F5E62EFDB3} :
 -1000 :
 addr : 80:00:60:0f:e8:00

2 :
 addr : 192.168.0.102
 netmask : 255.255.255.0
 broadcast : 192.168.0.255

....E....Pcaprub version: 0.9-dev
 .

Finished tests in 7.899207s, 1.6457 tests/s, 1.2659 assertions/s.

1) Error:
 test_pcap_next(Pcap::UnitTest):
 Errno::EBADF: Bad file descriptor
 test_pcaprub.rb:93:in `each'
 test_pcaprub.rb:93:in `block in test_pcap_next'

13 tests, 10 assertions, 0 failures, 1 errors, 0 skips

c:\Program Files (x86)\Rapid7\framework\msf3\external\pcaprub>

Reklamy
Kategorie:Metasploit Tagi:

VMware – Back Track 5 Start Up

Maj 29, 2012 3 Komentarze

Back Track 5 Start  Up

  • Power on/start up Backtrack
  • log in with the default user name and password ( user root, password toor)

root@bt~#

  • start x (the windows gUi)

root@bt~# startx

  • View all the network interfaces on your machine

root@bt~# ifconfig  -a

  • turn up (on) the desired network interface

root@bt~#eth0  ifconfig up

  • Assign an iP address manually

root@bt~# eth0 ifconfig up 192.168.0.1

  • View the manually assigned iP address

root@bt~# ifconfig

  • Assign an iP address through dHcP

root@bt~# dhclient eth0

  • View the dynamically assigned address

root@bt~# ifconfig

  • reboot the machine using the command line interface

root@bt~# reboot

  • Poweroff the machine using the command line interface

root@bt~# poweroff

StartUp.sh


#!/bin/bash

echo "Setting up the victim machine, this will take just a moment..."

ifconfig eth0 down

ifconfig eth0 172.16.45.$((( $RANDOM %254)  1)) up

# uncomment the following lines by removing the #, to start up services on your victim

# please note, you may need to change the location / path depending on your distro

/etc/init.d/ssh start

# note, you may have to generate your SSH key using sshd-generate

/etc/init.d/apache2 start

/etc/init.d/atftpd start

echo "This victim machine is now setup."

echo "The IP address is somewhere in the 172.16.45.0/24 network."

echo "You may now close this window and begin your attack...Good  luck!"

Kategorie:Back Track 5

PenTest lab. Training

Maj 12, 2012 Dodaj komentarz

Complete Operating System

Name: Damn Vulnerable Linux

Homepage: http://www.damnvulnerablelinux.org/

Name: De-ICE

Homepage: http://heorot.net/livecds/ or http://www.de-ice.net

Name: Hackademic

Homepage: http://ghostinthelab.wordpress.com/

Name: Holynix

Homepage: http://pynstrom.net/holynix.php

Name: Kioptrix

Homepage: http://www.kioptrix.com

Name: Metasploitable

Homepage: http://blog.metasploit.com/2010/05/introducing-metasploitable.html

and http://sourceforge.net/projects/metasploitable/files/Metasploitable2/

Name: NcN 2011

Homepage: http://noconname.org

Name: NETinVM

Homepage: http://informatica.uv.es/~carlos/docencia/netinvm/#id7

Name: pWnOS

Homepage: http://forums.heorot.net/viewtopic.php?f=21&t=149

Name: RuCTFE 2010

Homepage: http://ructf.org/e/2010/

FileName: vulnimage.zip

Homepage: http://ds.mathematik.unimarburg.de/~lbaumgaertner/vulnimage.zip

(Offline) Web Based

Name: BadStore

Homepage: http://www.badstore.net/

Name: BodgeIT

Homepage: https://code.google.com/p/bodgeit/

Name: Damn Vulnerable Web App

Homepage: http://www.dvwa.co.uk/

Name: HackUS HackFest Web CTF

Homepage: http://hackus.org/en/media/training/ & http://www.h3xstream.com/codeView.jspx?key=4001

Name: Hacme

Homepage: http://www.mcafee.com/us/downloads/free-tools/index.aspx

Name: Hackxor

Homepage: http://hackxor.sourceforge.net/cgi-bin/index.pl

Name: LAMPSecurity

Homepage: http://sourceforge.net/projects/lampsecurity/

Name: Moth

Homepage: http://www.bonsai-sec.com/en/research/moth.php

Name: Mutillidae

Homepage: http://www.irongeek.com/i.php?page=security/mutillidae-deliberately-vulnerable-php-owasp-top-10

Name: OWASP Broken Web Applications Project

Homepage: https://code.google.com/p/owaspbwa/ or https://www.owasp.org/index.php/OWASP_Broken_Web_Applications_Project

Name: OWASP Hackademic Challenges Project

Homepage: https://www.owasp.org/index.php/OWASP_Hackademic_Challenges_Project

Name: OWASP Insecure Web App Project

Homepage: https://www.owasp.org/index.php/Category:OWASP_Insecure_Web_App_Project

Name: OWASP Vicnum

Homepage: http://vicnum.ciphertechs.com/

Name: OWASP WebGoat

Homepage: http://www.owasp.org/index.php/Category:OWASP_WebGoat_Project

Name: PuzzleMall

Homepage: https://code.google.com/p/puzzlemall/

Name: SecuriBench

Homepage: http://suif.stanford.edu/~livshits/securibench/

Name: The ButterFly

Homepage: http://sourceforge.net/projects/thebutterflytmp/

Name: UltimateLAMP

Homepage: http://ronaldbradford.com/blog/ultimatelamp-2006-05-19/

Name: Virtual Hacking Lab

Homepage: http://virtualhacking.sourceforge.net/

Name: WackoPicko

Homepage: https://github.com/adamdoupe/WackoPicko

Name: WAVSEP – Web Application Vulnerability Scanner Evaluation Project

Homepage: https://code.google.com/p/wavsep/

Name: WebMaven/Buggy Bank

Homepage: http://www.mavensecurity.com/WebMaven/

Name: Web Security Dojo

Homepage: http://www.mavensecurity.com/web_security_dojo/

Kategorie:Hacking