1
mirror of https://github.com/rapid7/metasploit-payloads synced 2025-05-12 19:04:32 +02:00

739 Commits

Author SHA1 Message Date
Tod Beardsley
ef6411271b Land , adds Group Packets to Meterpreter 2014-03-19 08:39:24 -05:00
Tod Beardsley
bea18dd6f0 Land , Expand ADSI types 2014-03-19 08:39:04 -05:00
OJ
1a2023ee53 Force-add libs that were missing 2014-03-19 19:32:51 +10:00
OJ
32c7126793 Fixes, documentation and tidying of kiwi code 2014-03-19 17:48:44 +10:00
OJ
83d4d2b0b7 Fix leaking memory 2014-03-19 15:01:02 +10:00
OJ
1791ab8a3a Add kerberos ticket dump support
Also fix up a few other niggles.
2014-03-19 14:26:55 +10:00
OJ
b59676d28e Add SAM key output to the LSA secret dump 2014-03-18 09:50:48 +10:00
OJ
43d362fb1e Enable LSA secret dumping 2014-03-14 19:51:35 +10:00
OJ
e3628d0662 Change make script to work from correct folder
The existing make file would use `pwd` to figure out the current
folder instead of using the base directory of the script. This
causes issues when running commands from different locations (such
as in the case of from the meterpreter_binds folder).

This commit fixes this problem.
2014-03-12 17:25:22 +10:00
OJ
a54e37f301 Remove unused defintion 2014-03-12 06:58:47 +10:00
OJ
f7468732ec Fix incorrect comment for the WMI query function 2014-03-12 06:58:19 +10:00
OJ
49877fda24 Fix comment type and reverse ternary condition 2014-03-12 06:53:05 +10:00
OJ
f1fbf2064f Enable service control and status in queries.
This commit adds service status to the query functionality for a single
service so that it doesn't have to be found in the full list of services.

It also adds the ability for the caller to control services using the
typical start/stop/pause/resume/restart style functions. To use these
functions the caller has to have appropriate rights.
2014-03-11 14:49:19 +10:00
OJ
a4beeba7bc Rejig service initialisation
Gathering of function pointers is now done during initialisation. This
means that it doesn't have to be done each time a function is called
and allows for reuse across other functions.
2014-03-11 09:37:36 +10:00
OJ
063d370e86 Change thread creation to support x86->x64
The create thread functionality would work in all cases except where
the thread was being created in an x64 process from an x86 process.

This commit adds support for this by reusing the wow64 injection code
in this case.
2014-03-10 11:37:43 +10:00
OJ
d8f86c1806 Merge branch 'upstream/master' into wmi_query_support
Conflicts:
	make.bat
	workspace/ext_server_extapi/ext_server_extapi.vcxproj
2014-03-07 08:11:35 +10:00
OJ
a7927a4105 Added the notion of "group packets"
A group packet is a special packet that is to be used as a group of TLVs that
will live under another packet. Using this functionality means that we can
easily nest groupings of data to arbitrary depths, which wasn't something we
were able to do before easily.

The MSF side is easily capable of handling this scenario, but this side had
always been lacking.

The clipboard dump code has been updated to show how this can be used.
2014-03-04 19:38:15 +10:00
OJ
e202ce3959 Merge from source r107 2014-03-04 12:29:06 +10:00
OJ
c4d9ba567f Merge from source r106 2014-03-04 12:15:30 +10:00
OJ
386df98a08 Merge from source r105 2014-03-04 11:30:59 +10:00
OJ
2b2508b8c9 Merge from source r104, fix silly typo in file name 2014-03-04 11:07:58 +10:00
OJ
c3e57bb6c1 Merge changes from source r103 2014-03-04 10:45:15 +10:00
OJ
9622deaddf Merge changes from source r102 2014-03-04 10:41:31 +10:00
OJ
d8760fdf9a Merge branch 'upstream/master' into ext_server_kiwi 2014-03-03 17:30:37 +10:00
OJ
62140f8fa1 Pulled in master and added a fallback for the SID stuff
I just realised I shouldn't have done that in a merge commit.

Conflicts:
	workspace/ext_server_extapi/ext_server_extapi.vcxproj
2014-02-28 13:32:37 +10:00
OJ
256e43cde3 Change the binary->string converter, add SID, warnings as errors
The existing implementation wasn't really solid and I never liked it
anyway. Egypt rightfully pointed out flaws in the code, so it has
been changed so that it allocates the required memory up front
and returns that string to the caller, who then has to free it up.

Added a function to render SIDS.

Made the build set warnings as errors. Still no idea why this wasn't
the case already.
2014-02-28 13:21:33 +10:00
OJ
ce9cfa6c2e Fix silly typo in header comment 2014-02-21 13:01:59 +10:00
James Lee
7ea5d4d35a Land , create_remote_thread fixes 2014-02-19 16:14:09 -06:00
OJ
f74962cf2f Reinstate stack size parameter
Previous commits removed the stack size parameter from the remote thread
creation function call. This caused issues in systems prior to Vista/2k8.

This fix puts that value back in and now everything is honky dory.

Tested on 2k/XP/2k3/Vista/7/2k8
2014-02-12 13:27:41 +10:00
James Lee
2c9a8cf9ab Whitespace 2014-02-10 16:45:58 -06:00
James Lee
7d823d1634 Land , hashdump fixes 2014-02-10 15:26:54 -06:00
sinn3r
f0be562baf Merge branch 'clipboard_monitor' of github.com:OJ/meterpreter into OJ-clipboard_monitor 2014-02-05 19:44:28 -06:00
OJ
94468e1313 One last tweak to remove all evidence of stupidity 2014-02-05 23:06:10 +10:00
OJ
cca2f14835 Fix number of issues revealed in x64 testing
Thanks to sinner being on the ball, x64 was broken and causing some
crazy things to happen. The CPU would peg at 100% despite x86 being
quite happy. It turns out, I suck at C, so I had to fix that up.

This commit includes the following changes:

* Fix up the WNDPROC callback so that the parameters are in the right
  order.
* Specify the correct array size for wait handles in the monitor thread.
* Add extra debugging.
* Handle WM_* messages correctly and add WM_NCCREATE.
* Correctly use the CREATESTRUCT to pass in the state.

"How on earth did this ever work?"

Fixed now, thanks again sinner!
2014-02-05 22:37:55 +10:00
OJ
2cebe3c19e INCLUDE the resume event in the monitored array
I am clearly stupid. How did this ever work? This change tells the
wait call to include the signal handle for the resume event.
2014-02-05 07:54:08 +10:00
Tod Beardsley
3b5dd66b81 Emphasise the correct version of VS2013.
cc @wchen-r7
2014-02-03 10:22:31 -06:00
OJ
2c56a1bcb1 Add documentation to the functionality 2014-01-29 15:51:57 +10:00
OJ
54b596674d Add purge and dump functionality, remove dup caps
This no longer captures duplicate content if the user does the same
thing twice.
2014-01-29 14:51:27 +10:00
DiabloHorn
6041f973c5 added default multi monitor support 2014-01-27 22:51:40 +01:00
OJ
b03c074bf1 Comment out debug tracing 2014-01-26 08:13:28 +10:00
OJ
633851be56 Updated other uses of CreateRemoteThread
Make use of the new create_remote_thread function so that it
is used by other areas of the code, including migration.
2014-01-24 23:11:47 +10:00
OJ
a7f2458a4e Force "warnings as errors" in stdapi
This should have been done ages ago, not sure why I need to do it again.
2014-01-24 21:53:50 +10:00
OJ
3e8025eae8 Fix hashdump so it works without migrating
Hashdumping on Windows XP and earlier worked fine for processes
running as SYSTEM because CreateRemoteThread didn't have security
in place that Vista and later operating systems do. However, Vista
onwards required migration to SYSTEM processes (which behind the
scenes uses injection via APC) before hashdumping would succeed.

This commit fixes this so that in those cases the hidden API function
RtlCreateUserThread() to create the remote thread in lsass exe. The
result is that hashdumping works without having to migrate first.

Win.
2014-01-24 20:23:43 +10:00
OJ
e85ff80bb4 Reformatting of code to make it a bit more readable 2014-01-24 11:01:56 +10:00
OJ
3ec5aaca3f Fix small indexing issue resulting in a crash 2014-01-23 10:19:33 +10:00
OJ
5b1007e940 Merge branch 'upstream/master' into clipboard_monitor
Conflicts:
	source/ReflectiveDLLInjection
	source/extensions/extapi/extapi.c
	source/extensions/extapi/extapi.h
	workspace/ext_server_extapi/ext_server_extapi.vcxproj
2014-01-22 22:53:29 +10:00
OJ
2918920b15 Handle NULL values when clipboard is cleared 2014-01-22 22:49:03 +10:00
OJ
d691124cd3 Changes and tweaks to make clipboard monitor work 2014-01-22 22:07:33 +10:00
OJ
e12b0e2dce Add a bit of debug info 2014-01-22 10:31:16 +10:00
OJ
3cde9b69c2 Update ADSI code to support more types
When non-supported types were returned in queries, ADSI just pooped
itself and tore down the Meterpreter session. This a happy tester
Meterpreter does not make!

This code includes more support for ADSI types with attempts to be
semi-sane in stringifying them.

Plus, Meterpreter no longer crashes.
2014-01-22 10:09:42 +10:00