Commit Graph

30 Commits (611b8a1b6d8a90779d1bfa9e844a4256dd53d14c)

Author SHA1 Message Date
Jonathan 575072585f removed shebangs from files within rex 2013-11-07 18:51:59 -05:00
Tab Assassin 7e5e0f7fc8 Retab lib 2013-08-30 16:28:33 -05:00
James Lee c3fa62cd59 Whitespace at EOL 2013-03-07 18:16:57 -06:00
James Lee d0650dfb25 Put a bandaid over getsockname
Depending on how a socket was created, #getsockname will return either a
struct sockaddr as a String (the default ruby Socket behavior) or an
Array (the extend'd Rex::Socket::Tcp behavior). Avoid the ambiguity when
generating SSL certificates for meterpreter handlers by always picking a
random hostname.

This is by no means a proper fix for the underlying problem of
Socket#getsockname having ambiguous behavior before and after being
extended with Rex::Socket::Tcp. It does, however, solve the immediate
problem of not being able to create tunneled meterpreter sessions over
http(s) sessions.

[SeeRM #7350]
2012-10-29 22:45:46 -05:00
HD Moore d656e3185f Mark all libraries as defaulting to 8-bit strings 2012-06-29 00:18:28 -05:00
James Lee 5f5c024193 supress a useless exception (trying to close a closed stream)
git-svn-id: file:///home/svn/framework3/trunk@13071 4d416f70-5f16-0410-b530-b9f4589650da
2011-06-30 05:12:07 +00:00
James Lee 9d99b9de22 fix a logic error that results in sockets closing instead of resending data, really fixes #4642; also fixes a nil error when read() failed, makes logs actually useful
git-svn-id: file:///home/svn/framework3/trunk@12885 4d416f70-5f16-0410-b530-b9f4589650da
2011-06-08 21:36: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
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
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 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 c28ad8ea0c Minor improvements and corner case bug fixes to session handling. This fixes issues that can come up when a stream is shut down
git-svn-id: file:///home/svn/framework3/trunk@11371 4d416f70-5f16-0410-b530-b9f4589650da
2010-12-18 03:00:26 +00:00
James Lee b89fe64e74 whitespace
git-svn-id: file:///home/svn/framework3/trunk@11209 4d416f70-5f16-0410-b530-b9f4589650da
2010-12-02 22:13:39 +00:00
HD Moore 29073a519a Small tweaks to the thread code, add an update method
git-svn-id: file:///home/svn/framework3/trunk@11011 4d416f70-5f16-0410-b530-b9f4589650da
2010-11-12 17:28:40 +00:00
HD Moore a12d9f8dbf This patch adds detailed thread tracking across the metasploit framework, along with a new console command (threads) to manage these. This level of tracking is required to accurately monitor background tasks, assist with debugging, and kill orphaned threads.
git-svn-id: file:///home/svn/framework3/trunk@11003 4d416f70-5f16-0410-b530-b9f4589650da
2010-11-12 06:19:49 +00:00
HD Moore 6bd2a954cf Lots of small changes, the big one is moving from sysread -> readpartial in the stream base class
git-svn-id: file:///home/svn/framework3/trunk@8764 4d416f70-5f16-0410-b530-b9f4589650da
2010-03-10 06:43:46 +00:00
Stephen Fewer 6335fde3e1 Commit the Ruby side for the UDP socket pivoting. Change the TCP client channel so the respective StreamAbstraction is responsible for monitoring its own rsock.
git-svn-id: file:///home/svn/framework3/trunk@8431 4d416f70-5f16-0410-b530-b9f4589650da
2010-02-09 16:45:46 +00:00
Ramon de C Valle f124597a56 Code cleanups
git-svn-id: file:///home/svn/framework3/trunk@5773 4d416f70-5f16-0410-b530-b9f4589650da
2008-10-19 21:03:39 +00:00
HD Moore 6df557c8a7 Support for bidirectional pipe on windows uses a hacked up socket_pair()
git-svn-id: file:///home/svn/framework3/trunk@4291 4d416f70-5f16-0410-b530-b9f4589650da
2007-01-21 20:21:58 +00:00
Matt Miller cc6900d2ec fix to bind_tcp handler where it wouldn't use the proper comm
git-svn-id: file:///home/svn/framework3/trunk@3834 4d416f70-5f16-0410-b530-b9f4589650da
2006-08-17 01:57:52 +00:00
Matt Miller 1931181ef2 remove dbg messages
git-svn-id: file:///home/svn/incoming/trunk@3324 4d416f70-5f16-0410-b530-b9f4589650da
2006-01-07 19:08:03 +00:00
Matt Miller b6395069ee fixed a few bugs for px
git-svn-id: file:///home/svn/incoming/trunk@3323 4d416f70-5f16-0410-b530-b9f4589650da
2006-01-07 18:59:04 +00:00
Matt Miller ae5c816e85 various enhancements to support passivex, seems to be functional, somewhat
git-svn-id: file:///home/svn/incoming/trunk@3322 4d416f70-5f16-0410-b530-b9f4589650da
2006-01-07 10:04:30 +00:00
HD Moore 88658064df /usr/bin/ruby vs /usr/bin/env ruby
git-svn-id: file:///home/svn/incoming/trunk@3242 4d416f70-5f16-0410-b530-b9f4589650da
2005-12-17 06:46:23 +00:00
Matt Miller 95f8210853 major doc update
git-svn-id: file:///home/svn/incoming/trunk@3029 4d416f70-5f16-0410-b530-b9f4589650da
2005-11-15 05:22:13 +00:00
Matt Miller 6a5870ddcd updated comments to be more uniformed in class definition
git-svn-id: file:///home/svn/incoming/trunk@3004 4d416f70-5f16-0410-b530-b9f4589650da
2005-11-02 16:49:45 +00:00
Matt Miller 550080bcfb refactored socket api a bit, expect bugs
git-svn-id: file:///home/svn/incoming/trunk@2915 4d416f70-5f16-0410-b530-b9f4589650da
2005-09-27 05:31:48 +00:00
Matt Miller 7eb2c68d58 fix interactive channels
git-svn-id: file:///home/svn/incoming/trunk@2833 4d416f70-5f16-0410-b530-b9f4589650da
2005-07-26 04:08:01 +00:00
Matt Miller 632a97823f moved some code around for interactive channels, still not functional yet, boohoo
git-svn-id: file:///home/svn/incoming/trunk@2797 4d416f70-5f16-0410-b530-b9f4589650da
2005-07-19 04:21:15 +00:00
Matt Miller 266cd54088 stream IO classes, not complete
git-svn-id: file:///home/svn/incoming/trunk@2539 4d416f70-5f16-0410-b530-b9f4589650da
2005-05-31 12:56:36 +00:00