Commit Graph

4333 Commits (9c8605813eb990998e96a6aedc54d60ae5566884)

Author SHA1 Message Date
HD Moore 9bbee65ebb Back to regularly scheduled development
git-svn-id: file:///home/svn/framework3/trunk@12644 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-17 14:03:05 +00:00
James Lee ad12dffe29 move help_to_s down into CommandDispatcher so each dispatcher will know how to print its own help. see #564
git-svn-id: file:///home/svn/framework3/trunk@12640 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-16 23:03:31 +00:00
Wei Chen db1684395f Added VirtualProtect feature for egghunter
git-svn-id: file:///home/svn/framework3/trunk@12637 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-16 19:00:56 +00:00
Tod Beardsley 5f3e451e4d Fixes #4441. I believe this will solve the empty element problem for the nmap parser, but I'm having trouble reproducing it. Basically it wraps tag_start in a begin/rescue, and will ignore bad calls to nil objects (and nil objects only).
git-svn-id: file:///home/svn/framework3/trunk@12634 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-16 13:49:35 +00:00
HD Moore 68ca98b225 Add the missing debug accessor
git-svn-id: file:///home/svn/framework3/trunk@12627 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-16 02:12:59 +00:00
HD Moore 9f2ac9ae9f Gracefully handle a failed socket write due to disconnect
git-svn-id: file:///home/svn/framework3/trunk@12626 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-16 02:00:47 +00:00
HD Moore e0ffab0e6c Move all db.import* calls to the same db.import backend call (as they should have been). Fix method casing to be ruby standard
git-svn-id: file:///home/svn/framework3/trunk@12625 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-16 00:51:26 +00:00
HD Moore 9d765d4d25 Change protected for private, add debug flag to MessagePack (with debug.methods call)
git-svn-id: file:///home/svn/framework3/trunk@12624 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-15 23:51:53 +00:00
Tod Beardsley 056cde292f Deprecate the exploited_host table. Vulns that indicate a successful exploit without opening a session should set the :exploited_at timestamp.
git-svn-id: file:///home/svn/framework3/trunk@12623 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-15 22:19:00 +00:00
HD Moore 26fe5f2c9f Detailed logging when something goes wonky
git-svn-id: file:///home/svn/framework3/trunk@12622 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-15 19:25:09 +00:00
HD Moore a6da350581 Treat timestamps as integers in all RPC calls. This fixes a inconsistency between methods (string vs DateTime object) and standardizing on Unix time stamps results in wider RPC transport support
git-svn-id: file:///home/svn/framework3/trunk@12621 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-15 18:24:52 +00:00
HD Moore aadee8460d Minor tweak helps syntax highlighters
git-svn-id: file:///home/svn/framework3/trunk@12620 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-15 18:23:40 +00:00
HD Moore c5c4c929b8 Clarify that partial is handled in HTTP
git-svn-id: file:///home/svn/framework3/trunk@12619 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-15 18:23:14 +00:00
HD Moore 80f71b441e This adds a basic RPC server that operates over HTTP and uses MessagePack. The client/server wrappers are still being finalized. MessagePack libraries are avavailable for all major languages ( http://msgpack.org/ ) and this implementation is ridiculous fast and binary safe, relative to XMLRPC.
git-svn-id: file:///home/svn/framework3/trunk@12616 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-14 18:38:44 +00:00
HD Moore aa98667a77 Two performance fixes for HTTP Servers. The first reduces latency from 0.25s to near-zero for back-to-back connections by using the Queue class as a notify system. The second switches the slow socket.get for the much faster socket.read
git-svn-id: file:///home/svn/framework3/trunk@12615 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-14 18:34:06 +00:00
Tod Beardsley 03549f0b15 Nessus imported vulns should reference themselves as a NSS- identifier.
git-svn-id: file:///home/svn/framework3/trunk@12610 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-13 17:00:03 +00:00
Tod Beardsley 7f21eb8406 Allows for nessus imports to grab the plugin name as well as the plugin ID.
git-svn-id: file:///home/svn/framework3/trunk@12609 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-13 16:29:07 +00:00
James Lee 369a2e898e mark version for minor release
git-svn-id: file:///home/svn/framework3/trunk@12608 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-13 16:14:05 +00:00
HD Moore 4500d09c2f Bubble up errors from socket.get_once() and trigger an EOFError when read() returns nil
git-svn-id: file:///home/svn/framework3/trunk@12607 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-13 06:37:15 +00:00
HD Moore c7439f5ba1 Remove the leftover autoloads
git-svn-id: file:///home/svn/framework3/trunk@12603 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 20:20:08 +00:00
HD Moore 1904e446b2 Change this back to cooincide with autoload revert
git-svn-id: file:///home/svn/framework3/trunk@12602 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 20:11:43 +00:00
HD Moore ecb726fb2c Rolling two changes through again (stomped on by the autoload revert)
git-svn-id: file:///home/svn/framework3/trunk@12601 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 20:08:33 +00:00
HD Moore 9ce47c01bd Reverting the autoload changes until we can upgrade to a new ActiveSupport library or find a workaround
git-svn-id: file:///home/svn/framework3/trunk@12600 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 20:03:55 +00:00
HD Moore 95d802754b Rework to avoid a warning
git-svn-id: file:///home/svn/framework3/trunk@12598 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 19:26:11 +00:00
Joshua Drake 3122c500a6 See #4371, add a missing autoload for :Script
git-svn-id: file:///home/svn/framework3/trunk@12597 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 19:12:00 +00:00
Joshua Drake fd4e6db85d Fixes 4373, Migrates lib/msf to use autoload instead of require (first try)
git-svn-id: file:///home/svn/framework3/trunk@12596 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 19:07:35 +00:00
Joshua Drake 7600f9110e remove some more unecessary requires
git-svn-id: file:///home/svn/framework3/trunk@12595 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 18:33:49 +00:00
HD Moore 664bbf7c3c Remove the requires now that autoload has been fixed
git-svn-id: file:///home/svn/framework3/trunk@12593 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 15:09:27 +00:00
Joshua Drake 025c68244b See #4371, fix uninitialized constant Rex::Exploitation::Egghunter
git-svn-id: file:///home/svn/framework3/trunk@12592 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 15:03:20 +00:00
HD Moore 78a2558142 Apply patch from chao-mu, fixes #4414
git-svn-id: file:///home/svn/framework3/trunk@12591 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 14:59:44 +00:00
HD Moore c9566da399 Add missing requires and autoload to make browser exploits work again.
git-svn-id: file:///home/svn/framework3/trunk@12590 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 05:23:32 +00:00
Joshua Drake 8bd4f463a6 See #4371, add autoload for PeParsey
git-svn-id: file:///home/svn/framework3/trunk@12589 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 01:26:58 +00:00
James Lee 06779bc8c0 remove unnecessary requires for stuff in rex. autoload and a high-level require 'rex' in lib/msf/core.rb should take care of everything. see #4371, #4373, r12587, and r12554.
git-svn-id: file:///home/svn/framework3/trunk@12588 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-12 00:53:33 +00:00
James Lee d0614a4be7 fix a few requires in rex in preparation of removing unneeded requires from msf
git-svn-id: file:///home/svn/framework3/trunk@12587 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-11 23:28:12 +00:00
James Lee 7837e64b85 remove cruft leftover from the dawn of time
git-svn-id: file:///home/svn/framework3/trunk@12586 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-11 22:55:25 +00:00
HD Moore a95186df6a Revert previous patch and handle via override instead
git-svn-id: file:///home/svn/framework3/trunk@12585 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-11 22:18:16 +00:00
HD Moore ea2da5f9ce Applies a patch to fix autoload + active_support conflicts: https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/2283-unnecessary-exception-raised-in-asdependenciesload_missing_constant
git-svn-id: file:///home/svn/framework3/trunk@12583 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-11 17:39:40 +00:00
Tod Beardsley 3e6d526eca Fixes #4391. Sorry! Ruby incompatability on method defs where if you set one option, you need to set them all (doesn't affect current 1.9 Rubies).
git-svn-id: file:///home/svn/framework3/trunk@12580 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-10 21:27:17 +00:00
James Lee 69d09113b5 use Metasm to parse elf templates and set appropriate header flags for marking .text as rwx, fixes #4384
git-svn-id: file:///home/svn/framework3/trunk@12579 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-10 21:06:19 +00:00
Joshua Drake cd5dbe7d58 See #4371, fix rex/file autoloads
git-svn-id: file:///home/svn/framework3/trunk@12577 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-10 20:15:16 +00:00
Tod Beardsley 50b26cb2d6 Adds another Qualys formatted XML importer for ASSET_DATA_REPORT files.
git-svn-id: file:///home/svn/framework3/trunk@12575 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-10 19:10:02 +00:00
Joshua Drake cdeb44747f huh? missing something important heh
git-svn-id: file:///home/svn/framework3/trunk@12574 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-10 18:33:38 +00:00
Joshua Drake af45f0166f re-unbreak omelet code
git-svn-id: file:///home/svn/framework3/trunk@12572 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-09 22:42:41 +00:00
David Rude 2de7f9eb30 fixes a stack trace in converting a char to hex in ruby 1.9.x
git-svn-id: file:///home/svn/framework3/trunk@12571 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-09 20:48:40 +00:00
James Lee 2e1d25dad7 store some state so we can associate scripts with the right port/host. fixes #4378
git-svn-id: file:///home/svn/framework3/trunk@12569 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-09 18:10:56 +00:00
Tod Beardsley ce90282884 See #4378 -- this should limit the nmap parser to script tags that are associated only with ports. egyp7 may have a better way with dealing with this though, so not calling it fixed yet.
git-svn-id: file:///home/svn/framework3/trunk@12568 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-09 17:24:43 +00:00
amaloteaux cb72073cd8 pcaprub: add a respond_to? in the capture mixin to ensure latest version
git-svn-id: file:///home/svn/framework3/trunk@12565 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-08 04:43:24 +00:00
amaloteaux 5d8db916d7 pcap_replay: small fix on th delay
git-svn-id: file:///home/svn/framework3/trunk@12563 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-08 01:44:09 +00:00
Matt Weeks 490471e129 Include necessary require.
git-svn-id: file:///home/svn/framework3/trunk@12558 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-07 02:16:09 +00:00
Joshua Drake cd4c38333d See #4371, Fixes logging error with LogLevel set in config
git-svn-id: file:///home/svn/framework3/trunk@12556 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 19:10:02 +00:00
Joshua Drake a2cf5c01b9 See #4371, oops, forgot to commit rex.rb!
git-svn-id: file:///home/svn/framework3/trunk@12555 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:55:41 +00:00
Joshua Drake 05f107f466 Fixes #4371, Converts many uses of require to autoload
git-svn-id: file:///home/svn/framework3/trunk@12554 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:47:10 +00:00
Joshua Drake 57b530ccf6 fix up test require path
git-svn-id: file:///home/svn/framework3/trunk@12553 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:41:38 +00:00
Joshua Drake d638586d1f fix up test require path
git-svn-id: file:///home/svn/framework3/trunk@12552 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:39:19 +00:00
Joshua Drake 3e59f77871 add require, get test running
git-svn-id: file:///home/svn/framework3/trunk@12551 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:17:41 +00:00
Joshua Drake 719576b7b9 fix a small bug in omelet hunter, test is now runnable
git-svn-id: file:///home/svn/framework3/trunk@12550 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:14:10 +00:00
Joshua Drake 849c2d682c remove crufty require
git-svn-id: file:///home/svn/framework3/trunk@12549 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 18:12:38 +00:00
James Lee c3d66f276f return the proper thing in add_route() and remove_route(), make sure each comm responds to :routes before trying to delete them. fixes several unit test failures.
git-svn-id: file:///home/svn/framework3/trunk@12548 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 17:30:25 +00:00
Joshua Drake 6e4049cb2c add some error messages to this test
git-svn-id: file:///home/svn/framework3/trunk@12547 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-06 17:22:09 +00:00
James Lee 47ef020c61 back to development. 3.8 here we come
git-svn-id: file:///home/svn/framework3/trunk@12541 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-04 23:12:43 +00:00
James Lee 27c1e757e1 add post count to the banner
git-svn-id: file:///home/svn/framework3/trunk@12537 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-04 08:50:38 +00:00
HD Moore decf71c4af Exceptions trying to determine DB status should simply return false
git-svn-id: file:///home/svn/framework3/trunk@12536 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-04 02:44:14 +00:00
James Lee 9c712f1481 cosmetic
git-svn-id: file:///home/svn/framework3/trunk@12534 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 18:25:55 +00:00
HD Moore 09f861736a Lets try this without breaking msfpayload
git-svn-id: file:///home/svn/framework3/trunk@12533 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 15:07:27 +00:00
Tod Beardsley 98831c3285 Clean up an SNMP rescue clause that makes Windows Ruby builds sad.
git-svn-id: file:///home/svn/framework3/trunk@12530 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 07:51:09 +00:00
HD Moore 4c84181c44 This adds a migrated flag to the framework.db object, to prevent a race condition between session_manager startup and db availability while the schema loads. This also makes the session_manager code try again (up to a max count) when it encounters an exception
git-svn-id: file:///home/svn/framework3/trunk@12529 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 07:09:34 +00:00
James Lee e621828cac check for a nil return value from write(), fixes #4329
git-svn-id: file:///home/svn/framework3/trunk@12528 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 06:55:15 +00:00
HD Moore 8d7e8620b2 Map write to syswrite for BufferSock
git-svn-id: file:///home/svn/framework3/trunk@12525 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 05:25:41 +00:00
HD Moore 93b0c5beb3 Check for the database first
git-svn-id: file:///home/svn/framework3/trunk@12523 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 04:49:18 +00:00
James Lee 73ba020547 release!
git-svn-id: file:///home/svn/framework3/trunk@12521 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 04:40:41 +00:00
James Lee 2192532a0c don't read from the rsock as that's already taken care of by monitor_rsock in StreamAbstraction. fixes EVERYTHING. also fixes #4321
git-svn-id: file:///home/svn/framework3/trunk@12520 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 04:12:41 +00:00
HD Moore 1c86441f12 This removes the abortive_close code for stream sockets, it was leading to inconsistencies in how dead sessions were cleaned up
git-svn-id: file:///home/svn/framework3/trunk@12519 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 03:59:02 +00:00
HD Moore fdc19b5e4a Add the second required argument to write()
git-svn-id: file:///home/svn/framework3/trunk@12518 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 03:09:20 +00:00
HD Moore 23c355ba2c Just use :mac not :host_mac
git-svn-id: file:///home/svn/framework3/trunk@12517 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-03 03:03:38 +00:00
HD Moore b93e134195 Use shell_write vs ring.put
git-svn-id: file:///home/svn/framework3/trunk@12516 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 23:07:02 +00:00
HD Moore d98f8dfd89 Make it clear that all Rex::IO::Stream implementations must accept a second parameter called opts for the read, write, and put methods
git-svn-id: file:///home/svn/framework3/trunk@12515 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 21:39:09 +00:00
James Lee 8fd84e3c3d fix cmd/unix/reverse by adding proper read() and write() methods to TcpReverseDoubleSessionChannel
git-svn-id: file:///home/svn/framework3/trunk@12514 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 20:42:53 +00:00
James Lee 259bf9695a don't kill a session when the user ctrl-C's during a command run by sessions -c or a script/postmod
git-svn-id: file:///home/svn/framework3/trunk@12513 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 20:40:19 +00:00
HD Moore 366bc8979d Only try to report to the database if the database driver is active. Fixes #4306
git-svn-id: file:///home/svn/framework3/trunk@12512 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 20:29:01 +00:00
HD Moore c668534105 This normalizes openssl non-blocking support across both 1.8.x/1.9.1 and 1.9.2+
git-svn-id: file:///home/svn/framework3/trunk@12509 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 17:25:26 +00:00
HD Moore eb78aac8dd Only try to catch the non-blocking exceptions if they are defined
git-svn-id: file:///home/svn/framework3/trunk@12508 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 16:30:45 +00:00
HD Moore d402ebf6fb Fix #3498 by showing post module options in the info output
git-svn-id: file:///home/svn/framework3/trunk@12506 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 16:06:37 +00:00
James Lee e81d3440b8 don't try to store session events for sessions without a db_record. fixes #4301
git-svn-id: file:///home/svn/framework3/trunk@12505 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 06:45:21 +00:00
HD Moore 732a1f3993 Skip empty vulnerability names
git-svn-id: file:///home/svn/framework3/trunk@12503 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 05:20:07 +00:00
Joshua Drake 1eee55b3cf remove a crufty require
git-svn-id: file:///home/svn/framework3/trunk@12502 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 03:42:26 +00:00
Joshua Drake e9372d0e51 add another require
git-svn-id: file:///home/svn/framework3/trunk@12501 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 03:40:34 +00:00
Joshua Drake ed86305675 add a require
git-svn-id: file:///home/svn/framework3/trunk@12500 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 03:40:03 +00:00
Joshua Drake 91658ac45e remove crufty require
git-svn-id: file:///home/svn/framework3/trunk@12497 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 01:35:21 +00:00
James Lee e30d2bbdd4 revert r12476, as it breaks interactive meterpreter channels. r12495 and r12494 should deal with what it was it was trying to solve in the first place. fixes #4293.
git-svn-id: file:///home/svn/framework3/trunk@12496 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 00:29:48 +00:00
James Lee 61ac192d0d read() instead of sysread(), fixes ssh sessions
git-svn-id: file:///home/svn/framework3/trunk@12495 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-02 00:23:42 +00:00
James Lee 178ae10e22 make sure telnet sessions use crlf for write() as well as put()
git-svn-id: file:///home/svn/framework3/trunk@12494 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-01 23:56:57 +00:00
James Lee a170d37c62 make it a little clearer what getprivs actually does
git-svn-id: file:///home/svn/framework3/trunk@12492 4d416f70-5f16-0410-b530-b9f4589650da
2011-05-01 22:28:09 +00:00
HD Moore 2c3e85af05 Major cleanups to the session manager, serialized processing of incoming connections, concurrent processing (up to a max scheduler thread count) of meterpreter initialization/scripts. This is to avoid a potential deadlock in openssl and ensure consistent, reliable session staging. This commit also fixes a bug that would mark database sessions as closed too early.
git-svn-id: file:///home/svn/framework3/trunk@12485 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 18:51:50 +00:00
HD Moore 39cab9b076 Correct use of select and expand the listen queue for TCP Servers
git-svn-id: file:///home/svn/framework3/trunk@12484 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 18:08:52 +00:00
Tod Beardsley 140a304032 Specify IO::select for sleep directly.
git-svn-id: file:///home/svn/framework3/trunk@12483 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 17:56:38 +00:00
HD Moore 22537ffbde A few more tweaks to non-blocking ssl mode
git-svn-id: file:///home/svn/framework3/trunk@12482 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 10:24:52 +00:00
HD Moore 96ac0fd51a Swap out exceptions
git-svn-id: file:///home/svn/framework3/trunk@12481 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 08:47:32 +00:00
HD Moore 5758f2ab46 Add support for non-blocking OpenSSL sockets when the Ruby version supports them (1.9.2+ or with openssl-nonblock gem).
git-svn-id: file:///home/svn/framework3/trunk@12480 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 07:59:33 +00:00
HD Moore 6bdf2a4e2b Proactively wrap each() in other Hash based classes to avoid situations that trigger modification during enumeration
git-svn-id: file:///home/svn/framework3/trunk@12479 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 04:59:27 +00:00
HD Moore 23d0c7d7d0 This overrides the framework.sessions.each method to use a temporary list instead of the native hash method. This avoids a rare race condition where a thread is enumerating sessions while another thread tries to register one.
git-svn-id: file:///home/svn/framework3/trunk@12478 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 04:50:06 +00:00
Tod Beardsley dfb8a9e24b Catching more nils in db_import.
git-svn-id: file:///home/svn/framework3/trunk@12477 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 04:33:52 +00:00
HD Moore 20c949d1fb Fix some bad copypasta from non-blocking write commit. This should make stream sessions happy again.
git-svn-id: file:///home/svn/framework3/trunk@12476 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 04:25:42 +00:00
HD Moore 321e5bd292 Qualify the exception namespace
git-svn-id: file:///home/svn/framework3/trunk@12475 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 03:33:45 +00:00
Tod Beardsley 94be33e8ee A little cleaner method for determining the nature of imported zip files.
git-svn-id: file:///home/svn/framework3/trunk@12472 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-30 01:49:55 +00:00
Matt Weeks e99b5a4f35 Un-break DHCP server when not using served_over.
Variable must be initialized before use regardless of whether HOSTNAME is defined.




git-svn-id: file:///home/svn/framework3/trunk@12471 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-29 22:58:55 +00:00
HD Moore d942442bcd Officially remove sqlite3 support (its been deprecated for approximately a year). SQLite3 has not been usable for a long time due to thread concurrency and stability issues. This is the final nail in the coffin now that the DB backend has gone through an overhaul.
git-svn-id: file:///home/svn/framework3/trunk@12469 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-29 17:22:53 +00:00
HD Moore 743a401a47 Add the ability to reset the last read pointer from the ringer buffer
git-svn-id: file:///home/svn/framework3/trunk@12467 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-29 16:02:24 +00:00
HD Moore 882c4b52f8 Monkey patch xmlrpc to handle 64-bit integers (meterpreter file sizes) and deal with nil more gracefully.
git-svn-id: file:///home/svn/framework3/trunk@12466 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-29 06:10:41 +00:00
Tod Beardsley 4053764f21 In the event an import file isn't an msf_zip, pcapfile, and doesn't have a newline, bail.
git-svn-id: file:///home/svn/framework3/trunk@12465 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-29 04:16:42 +00:00
Tod Beardsley 07e02ce44a When reporting a session from an import, :routes should always end up an an array.
git-svn-id: file:///home/svn/framework3/trunk@12464 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-29 04:10:46 +00:00
Tod Beardsley 1693a21b06 Fixes nessus_v2 imports to indicate a service name correctly.
git-svn-id: file:///home/svn/framework3/trunk@12463 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-28 18:52:35 +00:00
James Lee 0a638aebfc make modules' class.inspect useful. this has bugged me for *years*
git-svn-id: file:///home/svn/framework3/trunk@12462 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-28 16:50:57 +00:00
James Lee 0978047673 clean up help a little for several meterpreter file commands
git-svn-id: file:///home/svn/framework3/trunk@12451 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-27 00:38:15 +00:00
HD Moore 8ba356271f Fixes #4223 on Windows by catching the specific exception class
git-svn-id: file:///home/svn/framework3/trunk@12450 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-27 00:20:32 +00:00
James Lee 859fd9216f report module_run and script_run session events
git-svn-id: file:///home/svn/framework3/trunk@12448 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 21:57:01 +00:00
James Lee f04782904e move @@reload_opts to the correct class, fixes 'help reload' from a non-exploit module context
git-svn-id: file:///home/svn/framework3/trunk@12447 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 21:53:45 +00:00
James Lee f72c94b514 default last_seen to sane values so we don't orphan all sessions right away. =/
git-svn-id: file:///home/svn/framework3/trunk@12446 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 21:29:47 +00:00
James Lee 956dcfa6d2 deal with the odd 'No Service Pack' by normalizing to 'Service Pack 0', fixes odd 2003 detection
git-svn-id: file:///home/svn/framework3/trunk@12444 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 19:31:56 +00:00
James Lee 81391d6ebf fix a stupid bug where retina, nessus, and qualys os fingerpritns would not be saved; improve fingerprints for 2003, 2008
git-svn-id: file:///home/svn/framework3/trunk@12443 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 19:13:35 +00:00
Tod Beardsley 2031c0d288 Importing Nexpose reports should retain test keys (which are usually some kind of proof or expanded details about a vulnerability).
git-svn-id: file:///home/svn/framework3/trunk@12442 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 17:31:26 +00:00
James Lee 8cf4733535 change the close_reason to be more accurate now that the close isn't happening at startup
git-svn-id: file:///home/svn/framework3/trunk@12441 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 16:19:59 +00:00
HD Moore 1d8dca6268 Merge the stale session reaper code into the session manager
git-svn-id: file:///home/svn/framework3/trunk@12437 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 05:10:14 +00:00
HD Moore cc0904b27e Unbreak trunk for now, this code needs to be fixed, its throwing errors. Fixes #4218
git-svn-id: file:///home/svn/framework3/trunk@12436 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-26 02:22:05 +00:00
Tod Beardsley 905044b03b Sources credentials gained from exploits by a session ID directly, rather than going through the ExploitedHost table.
git-svn-id: file:///home/svn/framework3/trunk@12435 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-25 21:01:24 +00:00
James Lee 80fe4c22e3 don't bomb out when there are no stale sessions
git-svn-id: file:///home/svn/framework3/trunk@12433 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-25 17:18:29 +00:00
James Lee b61d83a0ae add a last-seen column to the sessions table so we can cull dead sessions on startup
git-svn-id: file:///home/svn/framework3/trunk@12432 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-25 16:11:02 +00:00
HD Moore b24b787e0a Add the right class wrappers
git-svn-id: file:///home/svn/framework3/trunk@12426 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-24 19:35:25 +00:00
HD Moore 4426a1b7f2 Port of the python Manifest.mbdb parser
git-svn-id: file:///home/svn/framework3/trunk@12424 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-24 18:21:13 +00:00
HD Moore bfe3c58d8b Correct the logic around Host object parameters
git-svn-id: file:///home/svn/framework3/trunk@12421 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-24 02:41:29 +00:00
HD Moore eacf1d3c8c Lets not break the trunk after all
git-svn-id: file:///home/svn/framework3/trunk@12420 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-24 02:32:43 +00:00
HD Moore 25971ff2ac Pass a host object into the nse parser from a host object cache.
git-svn-id: file:///home/svn/framework3/trunk@12416 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-24 00:54:43 +00:00
HD Moore 5918e6c0ac Allow report_auth_info() to accept a Host object instead of an address like all the other methods.
git-svn-id: file:///home/svn/framework3/trunk@12415 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-24 00:48:05 +00:00
HD Moore 9d715a1492 Switch from readpartial to read_nonblock, which works around an OpenSSL deadlock. This also adds support for the openssl-nonblock gem's specific exceptions
git-svn-id: file:///home/svn/framework3/trunk@12414 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-23 20:45:49 +00:00
Jonathan Cran 56049012cb remove my code out of the tree, tests all passing. thanks chao-mu!
git-svn-id: file:///home/svn/framework3/trunk@12413 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-23 02:49:14 +00:00
Jonathan Cran c9ab8f248d commit the rest of chao's patch :/
git-svn-id: file:///home/svn/framework3/trunk@12412 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-23 01:10:49 +00:00
HD Moore b0d81f4385 This mega-patch solves a few outstanding issues:
1) The database queue is no longer used, all threads have their own connection. This officially breaks sqlite3 support, even though sqlite3 was pretty broken to being with.
2) The report_* calls prefer a Host object in the :host parameter instead of :address. This lets it skip a lookup on the host table
3) The importers now pass in the Host object, significantly speeding up large imports
4) The host record is no longer updated by every change to a child object, this was too much of a bottleneck.

TL;DR: Database stuff is faster



git-svn-id: file:///home/svn/framework3/trunk@12409 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 20:16:55 +00:00
James Lee 53809926c1 the database *is* available at startup if there is a ~/.msf3/database.yml or if msfconsole was started with -y. There's a check for the db anyway, so this shouldn't ever bomb out
git-svn-id: file:///home/svn/framework3/trunk@12407 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 19:49:44 +00:00
HD Moore 4c0c282cf8 Fix a stack trace when one of these is nil
git-svn-id: file:///home/svn/framework3/trunk@12406 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 19:27:50 +00:00
HD Moore 5fc0f4eaf1 Fix typo
git-svn-id: file:///home/svn/framework3/trunk@12405 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 19:07:41 +00:00
James Lee 537e312c13 set RHOSTS directly when we have a short list
git-svn-id: file:///home/svn/framework3/trunk@12404 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 18:31:55 +00:00
amaloteaux 91bb4b0130 auxiliary: add a basic pcap replay module
git-svn-id: file:///home/svn/framework3/trunk@12403 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 18:25:19 +00:00
James Lee 96ee780967 merge the_listener's patch for adding ability to set RHOSTS from db_services. extends it by adding the same support in db_hosts and db_notes, see #308
git-svn-id: file:///home/svn/framework3/trunk@12401 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 05:08:08 +00:00
James Lee 1be4b0831b add support for dumping services as a csv file like hosts. merges partial patch from the_listener, thanks! fixes #3120
git-svn-id: file:///home/svn/framework3/trunk@12400 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-22 02:22:21 +00:00
HD Moore a61e7290b0 Do not modify the string passed to write() operations
git-svn-id: file:///home/svn/framework3/trunk@12394 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-21 17:29:11 +00:00
HD Moore 8b920a8f95 Dont modify the data buffer passed to write
git-svn-id: file:///home/svn/framework3/trunk@12393 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-21 17:17:26 +00:00
HD Moore 1a4d4340bf Make Ruby 1.8.7 happy
git-svn-id: file:///home/svn/framework3/trunk@12382 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 20:06:45 +00:00
HD Moore 545025dbea Add a warning when the imported vulnerability data is missing the service protocol/port (looks like just one vendor today has this problem).
git-svn-id: file:///home/svn/framework3/trunk@12381 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 18:33:27 +00:00
Tod Beardsley 41cc038eca Undoing r12379 in anticipation of a different version.
git-svn-id: file:///home/svn/framework3/trunk@12380 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 18:29:04 +00:00
Tod Beardsley 93a07df541 Add a :warning handler for db_import.
git-svn-id: file:///home/svn/framework3/trunk@12379 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 18:22:18 +00:00
HD Moore 07fb337ad9 Fix the actual thread cap
git-svn-id: file:///home/svn/framework3/trunk@12378 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 17:56:38 +00:00
James Lee 86bca6438f add a routes table; delete each comm's routes when flushing
git-svn-id: file:///home/svn/framework3/trunk@12377 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 17:49:27 +00:00
Joshua Drake 78d3998854 Fixes #4125, add hostname support to the Rex DHCP server & aux module
git-svn-id: file:///home/svn/framework3/trunk@12375 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-20 14:21:36 +00:00
Tod Beardsley b164ac6539 Actually store the title for Nexpose imports.
git-svn-id: file:///home/svn/framework3/trunk@12374 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-19 23:00:19 +00:00
Jonathan Cran 0437d20f9d Commit railgun tests from chao-mu: http://blog.minorcrash.com/2011/04/railgun-update-1st-milestone-almost.html
~/framework$ ruby lib/rex/post/meterpreter/extensions/stdapi/railgun.rb.ts.rb 
Loaded suite lib/rex/post/meterpreter/extensions/stdapi/railgun.rb.ts
Started
.............
Finished in 8.804126009 seconds.
13 tests, 30 assertions, 0 failures, 0 errors






git-svn-id: file:///home/svn/framework3/trunk@12366 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-19 14:15:45 +00:00
HD Moore b94d09cdf1 Try a little harder to make this module more reliable through TCP proxies
git-svn-id: file:///home/svn/framework3/trunk@12359 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 20:53:21 +00:00
HD Moore d2d66f3285 This patch changes how VNC sessions are handled, making them a now-unique type that is not registered in the normal sense. This works around a corner case due to recent session work.
git-svn-id: file:///home/svn/framework3/trunk@12358 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 20:07:53 +00:00
Tod Beardsley 8b5d004997 Adding an nmap version checker so NSE modules can tell if it's okay to run or not.
git-svn-id: file:///home/svn/framework3/trunk@12357 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 19:52:13 +00:00
HD Moore f1f15ba448 Allow socks4a to relay through meterpreter
git-svn-id: file:///home/svn/framework3/trunk@12353 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 18:17:49 +00:00
James Lee debc16bea5 vnc sessions don't have an arch
git-svn-id: file:///home/svn/framework3/trunk@12352 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 16:53:58 +00:00
James Lee 99d5affbc7 put session_* events back in until we can sort out some issues with the change
git-svn-id: file:///home/svn/framework3/trunk@12351 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 16:29:15 +00:00
James Lee 069eb808f1 store closed_at in utc to avoid discrepancies with opened_at
git-svn-id: file:///home/svn/framework3/trunk@12348 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 15:59:25 +00:00
HD Moore 1b63d36c85 Fix typo reported by mubix
git-svn-id: file:///home/svn/framework3/trunk@12346 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-18 04:40:06 +00:00
Mario Ceballos 1d0d6195bd fixes a load error
git-svn-id: file:///home/svn/framework3/trunk@12344 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-17 02:08:42 +00:00
James Lee 5effb0ca04 use Table#to_csv to generate csv a file that isn't broken when data contains commas
git-svn-id: file:///home/svn/framework3/trunk@12343 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-17 01:07:53 +00:00
James Lee 03fdd9a0d0 add support method used in previous commit (r12341)
git-svn-id: file:///home/svn/framework3/trunk@12342 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-17 00:35:32 +00:00
James Lee c14580adf3 add help for several meterp commands and allow the channel command to do everything the associated with channels (list, interact, read, write, close)
git-svn-id: file:///home/svn/framework3/trunk@12341 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-17 00:34:45 +00:00
Matt Weeks ff07d00b51 Simpler interrupt handling in RPC consoles.
git-svn-id: file:///home/svn/framework3/trunk@12339 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-16 23:03:30 +00:00
James Lee 05f0f3739f add help for several db commands
git-svn-id: file:///home/svn/framework3/trunk@12338 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-16 22:49:31 +00:00
Matt Weeks b53545e875 Seach post modules by default too.
git-svn-id: file:///home/svn/framework3/trunk@12336 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-16 18:03:13 +00:00
James Lee 827bec98d6 ljust the option names so we don't have funky alignment for multi-char option names
git-svn-id: file:///home/svn/framework3/trunk@12335 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-16 15:57:52 +00:00
James Lee 9c1b4ddca5 add a load command. this will later deprecate the use command under meterpreter for 3.7 release
git-svn-id: file:///home/svn/framework3/trunk@12334 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-16 13:59:57 +00:00
Matt Weeks a0cbbdfab0 Support 'jar' format when generating payloads.
git-svn-id: file:///home/svn/framework3/trunk@12331 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-16 02:11:12 +00:00
James Lee d294f511b6 add logging for interactive meterpreter channels
git-svn-id: file:///home/svn/framework3/trunk@12328 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-15 21:10:15 +00:00
Tod Beardsley f386a2c587 Adding an additional sessions mapping to workspaces.
git-svn-id: file:///home/svn/framework3/trunk@12327 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-15 20:36:10 +00:00
Mike Smith 175cae5047 Add associations between Host, Session & SessionEvent model objects.
git-svn-id: file:///home/svn/framework3/trunk@12325 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-15 18:54:27 +00:00
HD Moore 50155919ea Add File.exists? as a wrapper to File.stat
git-svn-id: file:///home/svn/framework3/trunk@12324 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-15 15:29:57 +00:00
Carlos Perez 904e7af88b added API call for extracting keystrokes from client.ui.keyscan_dump
git-svn-id: file:///home/svn/framework3/trunk@12323 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-15 02:21:40 +00:00
Tod Beardsley d63fe9a7ba Adding a column for local_id to the sessions table in order to better handle database-mediated session operations.
git-svn-id: file:///home/svn/framework3/trunk@12321 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-14 23:14:36 +00:00
Tod Beardsley 93ee866669 Prevent new sessions from being opened several hours in the past so that we don't accidentally create spatiotemporal paradoxes and erase ourselves from history.
git-svn-id: file:///home/svn/framework3/trunk@12319 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-14 21:53:03 +00:00
James Lee 96af5e2af6 store session info in the db
git-svn-id: file:///home/svn/framework3/trunk@12317 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-14 18:28:44 +00:00
James Lee d6edeebcef actually log errors from reporting the session fingerprint. would have helped greatly in tracking down #4128
git-svn-id: file:///home/svn/framework3/trunk@12313 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-13 23:03:00 +00:00
Jonathan Cran c5c7ca3657 loglevel max is actually 5
git-svn-id: file:///home/svn/framework3/trunk@12312 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-13 21:22:38 +00:00
Tod Beardsley f8be06bd88 See #4129. This patches up shell_read and shell_write to use the new ring buffer mechanisms with no significant API changes. Still need to run through a test on Armitage to ensure it's all still flowing smoothly, should be done within the hour.
git-svn-id: file:///home/svn/framework3/trunk@12310 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-13 17:02:45 +00:00
James Lee f43fe6e31b clarify the help for getprivs
git-svn-id: file:///home/svn/framework3/trunk@12309 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-13 16:01:40 +00:00
James Lee 361922c634 don't use in-place gsub, it breaks on 1.9.2 since the string was a hash key at one point and apparently gets frozen, fixes #4128
git-svn-id: file:///home/svn/framework3/trunk@12308 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-13 01:48:37 +00:00
James Lee 05e47166a3 push the check for msf up to the main meterpreter command dispatcher and fire events for file upload/download.
git-svn-id: file:///home/svn/framework3/trunk@12307 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-12 20:39:46 +00:00
James Lee 9831dd5ca6 take linux sysinfo into account for os fingerprints
git-svn-id: file:///home/svn/framework3/trunk@12303 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-11 23:15:05 +00:00
James Lee 857b5c786b don't store less accurate nmap fingerprints, see #4099
git-svn-id: file:///home/svn/framework3/trunk@12302 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-11 23:05:07 +00:00
James Lee b2eb5a4908 store the service pack from nexpose (previously not returned from the xml parser, see r12298); store hostname and more version info from nmap; see #4099
git-svn-id: file:///home/svn/framework3/trunk@12300 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-11 22:29:53 +00:00
James Lee 36367f8a67 save os version info (usually windows service packs) and close the names tag, so we don't store every xml tag's text as a hostname
git-svn-id: file:///home/svn/framework3/trunk@12298 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-11 22:16:25 +00:00
Patrick Webster e9e8026832 Fixed author name in modules for myself.
git-svn-id: file:///home/svn/framework3/trunk@12292 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-11 02:25:36 +00:00
James Lee a82c47789d silly debug print, see #4099
git-svn-id: file:///home/svn/framework3/trunk@12290 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-11 01:41:35 +00:00
Mike Smith d5d9d56081 Create a dedicated db table to track sessions & session events.
* Add new db tables for session & session_events
* Migrate existing session data from events db table
* Modify session report methods to log to the new tables


git-svn-id: file:///home/svn/framework3/trunk@12273 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-07 21:59:32 +00:00
Joshua Drake 875858e78e See #4089, fix method definitions
git-svn-id: file:///home/svn/framework3/trunk@12267 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-07 13:19:43 +00:00
Joshua Drake 1a7cc50530 Fixes #4089, Pass DECODERSTUB advopt when calling generate_stager too
git-svn-id: file:///home/svn/framework3/trunk@12266 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-07 13:17:03 +00:00
Joshua Drake 8057c7e969 sync up with metasm tip, yay for Yoann and autoload
git-svn-id: file:///home/svn/framework3/trunk@12252 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-06 17:40:01 +00:00
HD Moore f3717302cd Fixes #4073 by applying a patch from Francois Ropert for parsing DMVPN keys from Cisco configuration files
git-svn-id: file:///home/svn/framework3/trunk@12248 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-05 15:45:01 +00:00
Tod Beardsley b91c81a182 Fixes #4074 -- corrects the affected regexes.
git-svn-id: file:///home/svn/framework3/trunk@12238 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-04 22:19:59 +00:00
James Lee 485211288f doc formatting
git-svn-id: file:///home/svn/framework3/trunk@12237 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-04 18:06:41 +00:00
James Lee cd8866d22f add doc for initialize
git-svn-id: file:///home/svn/framework3/trunk@12235 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-04 17:32:17 +00:00
James Lee dcefdc5f28 whitespace and rdoc fixes
git-svn-id: file:///home/svn/framework3/trunk@12234 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-04 17:27:12 +00:00
James Lee 7444436750 fix directives for rdoc
git-svn-id: file:///home/svn/framework3/trunk@12233 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-04 17:06:59 +00:00
amaloteaux 3e0982a792 enable ntlmv2 by default for smb, mssql and http
git-svn-id: file:///home/svn/framework3/trunk@12227 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-03 21:06:50 +00:00
amaloteaux f9680c854b reworj http ntlm authentificaion and correct some bug
git-svn-id: file:///home/svn/framework3/trunk@12225 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-03 20:38:27 +00:00
amaloteaux b38a187631 mssql login : enable ntlmv2 authentification
git-svn-id: file:///home/svn/framework3/trunk@12223 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-03 17:02:23 +00:00
James Lee 16eac54a39 and now back to your regular scheduled msfconsole
git-svn-id: file:///home/svn/framework3/trunk@12220 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-02 15:51:48 +00:00
amaloteaux c5e137d7d3 correct a bug on ntlm signing
git-svn-id: file:///home/svn/framework3/trunk@12211 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-01 20:58:11 +00:00
James Lee 0c9dbbf9f3 a few more cosmetic changes
git-svn-id: file:///home/svn/framework3/trunk@12201 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-01 06:48:36 +00:00
James Lee a305d3bd27 deprecate windows. What day is it today?
git-svn-id: file:///home/svn/framework3/trunk@12200 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-01 06:35:25 +00:00
HD Moore fea84dccda Text alignment
git-svn-id: file:///home/svn/framework3/trunk@12199 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-01 06:03:42 +00:00
HD Moore f97790ec8b Cosmetic change
git-svn-id: file:///home/svn/framework3/trunk@12198 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-01 06:01:25 +00:00
James Lee ae1d3b78bc add host.imported notes for import types other than nmap, see r9277; don't double-report hosts for nessus and ip360 imports
git-svn-id: file:///home/svn/framework3/trunk@12197 4d416f70-5f16-0410-b530-b9f4589650da
2011-04-01 01:01:11 +00:00
Tod Beardsley e1499657c9 Overhaul the nexpose vuln importer to be a little more friendly to all the XML data we can gather about vulns, beyond just their ID and references.
git-svn-id: file:///home/svn/framework3/trunk@12182 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-29 22:22:58 +00:00
HD Moore e0e8d986e7 Fix up psexec by adding a reqwuire for the wbemexec mixin
git-svn-id: file:///home/svn/framework3/trunk@12180 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-29 16:35:26 +00:00
James Lee b823ea9876 fix undefined method error by using the correct class
git-svn-id: file:///home/svn/framework3/trunk@12169 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-28 18:42:22 +00:00
amaloteaux 19a4a2d88a move some code from lib/rex/proto/smb/client to lib/rex/proto/ntlm/util and add a mini mixin for ntlm
git-svn-id: file:///home/svn/framework3/trunk@12162 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-27 20:14:56 +00:00
Jonathan Cran 3c6b33bd80 continuation of tests / fixes from chao.
git-svn-id: file:///home/svn/framework3/trunk@12155 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-27 00:37:54 +00:00
amaloteaux 08df8179cc mssql login : enable windows authentification and add an encrypion check through tds prelogin mechanism
see issue #402 for some comment on the implementation and the todo's


git-svn-id: file:///home/svn/framework3/trunk@12154 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-27 00:24:19 +00:00
Jonathan Cran d18f14de4e add a test suite for railgun
git-svn-id: file:///home/svn/framework3/trunk@12152 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-26 19:49:08 +00:00
Jonathan Cran 35c33020ca merge in test updates from chao-mu
git-svn-id: file:///home/svn/framework3/trunk@12150 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-26 19:29:59 +00:00
Jonathan Cran 4892a67fa1 small tweaks, remove model - no longer necessary
git-svn-id: file:///home/svn/framework3/trunk@12143 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-26 00:46:55 +00:00
James Lee cf3fbdad71 unneeded require in comments
git-svn-id: file:///home/svn/framework3/trunk@12142 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-26 00:45:52 +00:00
Jonathan Cran 50d573f282 doh! commit the rest of chao's railgun work
git-svn-id: file:///home/svn/framework3/trunk@12141 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-26 00:33:05 +00:00
Jonathan Cran 29061c5799 merge in chao-mu's changes. all tests passing :)
git-svn-id: file:///home/svn/framework3/trunk@12138 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-25 21:16:41 +00:00
amaloteaux 695bd76a30 typo fix
git-svn-id: file:///home/svn/framework3/trunk@12134 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-25 18:28:27 +00:00
Tod Beardsley 9895d01d51 Moving lib_mysqludf_sys*.dll to a more obvious subdirectory of the exploit binaries.
git-svn-id: file:///home/svn/framework3/trunk@12128 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-24 17:48:19 +00:00
James Lee c09be5561d this should have been a raise all along, see r9752
git-svn-id: file:///home/svn/framework3/trunk@12119 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 23:15:11 +00:00
James Lee ad5073d6b1 only close the session when we get socket-related exceptions, fixes #4005
git-svn-id: file:///home/svn/framework3/trunk@12118 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 22:21:59 +00:00
amaloteaux ec5e61966d oops revert the unwanted early commit on mssql
git-svn-id: file:///home/svn/framework3/trunk@12114 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 20:53:57 +00:00
Tod Beardsley 2b4acb3b6c Misplaced (and redundant) functon in the postgres library, removed.
git-svn-id: file:///home/svn/framework3/trunk@12113 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 20:52:07 +00:00
amaloteaux 46cf938475 fix typo
git-svn-id: file:///home/svn/framework3/trunk@12112 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 20:47:49 +00:00
Tod Beardsley b1178686cf Fixes #3988. Adds a command execution module for PostgreSQL by uploading a UDF library and adding sys_exec() as a temporary function. Requires the target to be Windows, uses Bernardo Damele A. G.'s binaries.
Also fixes a typo in the arguments to handler which clears up a heretofore mysterious exception (see exploit.rb).



git-svn-id: file:///home/svn/framework3/trunk@12111 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 19:36:07 +00:00
James Lee 8bb95f02c5 load the config after adding any module paths so we can start msfconsole using a module from a non-default path
git-svn-id: file:///home/svn/framework3/trunk@12105 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 16:19:55 +00:00
HD Moore ac75160741 Add sinn3r and bannedit to authors
git-svn-id: file:///home/svn/framework3/trunk@12084 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-23 03:28:19 +00:00
Tod Beardsley 02165304c2 Adding an additional error code for postgresql, new as of version 9.
git-svn-id: file:///home/svn/framework3/trunk@12071 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-22 17:43:36 +00:00
Tod Beardsley 3ed59574e1 Another postgresql fingerprint, now when auths are enabled.
git-svn-id: file:///home/svn/framework3/trunk@12070 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-22 17:39:19 +00:00
Tod Beardsley 8bca6d4d54 Adding a quickie fingerprint for PostgreSQL on windows (9.0.3)
git-svn-id: file:///home/svn/framework3/trunk@12069 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-22 17:26:57 +00:00
HD Moore 3395ee226e Associate the replicant exploit instance with the replicant payload, otherwise the wrong exploit instance will be used by the payload handler. Fixes #4004.
git-svn-id: file:///home/svn/framework3/trunk@12065 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-22 03:19:56 +00:00
Tod Beardsley 46dfafa81f Fixes #3987. Don't raise on the attr set, raise when the command actually wants to get run.
git-svn-id: file:///home/svn/framework3/trunk@12063 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-21 20:52:08 +00:00
David Rude cf04b2f387 fix a stack trace if nmap is not installed
git-svn-id: file:///home/svn/framework3/trunk@12062 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-21 20:11:12 +00:00
HD Moore 7043e25ae9 Clarify the license and the usability
git-svn-id: file:///home/svn/framework3/trunk@12061 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-21 19:00:35 +00:00
James Lee e72a4e36bd add 'show actions' for post mods, oversight from r12008. see #3965
git-svn-id: file:///home/svn/framework3/trunk@12058 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-21 17:07:11 +00:00
James Lee 3527aa2472 correct width calculation for sysinfo
git-svn-id: file:///home/svn/framework3/trunk@12057 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-21 16:58:24 +00:00
HD Moore c6b3bfacfe Merge in an openvas-bridge update from kost
git-svn-id: file:///home/svn/framework3/trunk@12056 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-21 05:02:14 +00:00
HD Moore 3d59be3586 This patch adds a 'reload_all' command to msfconsole. This will flush and reload all modules from all module paths
git-svn-id: file:///home/svn/framework3/trunk@12040 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-20 22:22:07 +00:00
HD Moore 2e267bdca3 This patch removes the unimplemented "persist" command. This has been sitting in half-done state for too many years and its time to go.
git-svn-id: file:///home/svn/framework3/trunk@12039 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-20 21:41:09 +00:00
Joshua Drake 12ea375d25 See #3183: Pad the plain text before trying DES on it.
git-svn-id: file:///home/svn/framework3/trunk@12033 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-20 08:55:12 +00:00
Jonathan Cran d45b2aaa20 bugfix & cleanup of the vm loading and a speedup / bugfix for the regex lib
git-svn-id: file:///home/svn/framework3/trunk@12032 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-20 02:33:39 +00:00
Matt Weeks a31eadc554 Change IPs before offer instead of between offer and ack. Fixes #3973.
git-svn-id: file:///home/svn/framework3/trunk@12030 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-20 00:33:02 +00:00
Carlos Perez b5bd7599fd Updated usage message to reflect that more than one resource file can be used
git-svn-id: file:///home/svn/framework3/trunk@12017 4d416f70-5f16-0410-b530-b9f4589650da
2011-03-18 02:47:58 +00:00