Clément Notin
72672c82f9
Fix syntax
2019-09-03 15:17:28 +02:00
Clément Notin
caafac3455
meterpreter, fs/file.rb: use client's separator instead of '\\'
2019-08-27 18:12:47 +02:00
Tim W
c4ebf7b4f3
add meterpreter chmod command
2018-09-01 23:52:31 +08:00
Brent Cook
bd2af0143a
properly handle when there is no stat callback specified on upload
2018-02-16 16:14:09 -06:00
a1exdandy
7e03bf838b
Fix src_size view
2018-02-15 17:44:41 +05:00
a1exdandy
a0c473f29e
Upload memory usage optimization
...
Optimize xor_bytes memory usage, use small buffer for upload,
add verbosity
2018-02-15 17:05:22 +05:00
James Lee
5c17f363be
Default opts to an empty hash instead of nil
...
Fixes #8709
2017-07-13 15:40:08 -05:00
wchen-r7
d5d9e88851
Fix #8636 , [] for NilClass in session.fs.file.download_file
...
This fixes a [] for NilClass bug in the download_file API.
The opts argument is not checked for nil before the code looks for
the block_size key.
Fix #8636
2017-07-07 19:00:33 -05:00
OJ
6131e4bd82
Fix download lambda function to take correct param count
...
This is an emergency fix as a result of something being broken in
master. This is also being pushed straight to master because github is
down and the PR process isn't possible. This commit was reviewed by
@wvu-r7 prior to being pushed.
2017-06-07 09:37:24 +10:00
OJ
cc0ff8f3db
Enable adaptive download with variable block sizes
...
The aim of this commit is to allow users of Meterpreter in high-latency
environments have better control over the behaviour of the download
function. This code contains two new options that manage the block size
of the downloads and the ability to set "adaptive" which means that the
block size will adjust on the fly of things continue to fail.
2017-06-02 17:16:58 +10:00
Artem
9a7c0eb7b6
Fix cloe file
2016-12-08 21:28:39 +03:00
Tim
468bf4696f
stdapi_fs_file_copy
2016-11-29 13:56:27 +08:00
caye
efdf7c4c00
Clipboard now sets 'recursive' download option in new way. Improved download_file compatibility
2016-08-27 01:44:04 +00:00
caye
3545c5f8db
Rebase after #7125 . Changed tries to -l. Added 'opts' for all download options
2016-08-27 00:55:16 +00:00
William Vu
bebff786b7
Add timestamping to downloaded files
2016-07-25 17:18:27 -05:00
caye
3c2f0e814e
'Continue' and 'tries' wget-like options for meterpreter 'download'
2016-07-10 16:24:36 +00:00
Brent Cook
57ab974737
File.exists? must die
2016-04-21 00:47:07 -04:00
Brent Cook
93ba08738c
add backward compatibility for hash responses
2015-05-15 11:53:12 -05:00
Tim
d3ba84b378
Add TLV_TYPE_FILE_HASH
2015-05-10 14:18:16 +01:00
Brent Cook
8cab350275
use the search API when downloading recursive patterns
2015-05-04 03:56:17 -05:00
Brent Cook
eefc6f78c6
avoid redownloading files that have not changed
2015-05-04 03:56:16 -05:00
Brent Cook
9672a59b05
support download globbing
2015-05-04 03:56:16 -05:00
Brent Cook
24ce0118b8
reenable UTF filtering support where needed
...
revert d22231bdc8
2015-03-19 16:02:21 -05:00
Brent Cook
d22231bdc8
remove unicode_filter_encode calls
...
Let the underlying utf8 messages through to the console.
2015-03-17 11:07:07 -05:00
Brent Cook
212aeb9106
Improve utility of meterpreter file upload command
...
Rather than assume that the destination argument is a directory, check
first, and then do the same thing that 'cp' would do.
- If dest exists and is a directory, copy to the directory.
- If dest exists and is a file, copy over the file.
- If dest does not exist and is a directory, fail.
- If dest does not exist and is a file, create the file.
2015-01-29 13:45:15 -06:00
James Lee
4c557a1401
Add Post::Windows::Services#each_service
...
Also cleans up some style issues and adds yardoc comments for some stuff
in Post::File
Note that windows/local/service_permissions is still using
`service_list` because it now builds a Rex::Table, which has to have
all the data up front, anyway.
2014-02-18 18:24:23 -06:00
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
RageLtMan
d399093d80
Add Framework side of stdapi.fs.file.mv
...
Add the appropriate methods to Rex side of the FS extension and
the commensurate command dispatcher.
Requires https://github.com/rapid7/meterpreter/pull/6 from the
meterpreter repo as well as compiling fresh DLL for
ext_server_stdapi.
2013-03-12 02:06:38 -04:00
James Lee
e7dc8e5ac2
Add a File.open method for meterpreter
...
Same semantics as Ruby stdlib File.open - if you give it a block, yields
a new File object and closes it after the block, otherwise same as
File.new.
[FixRM #6481 ]
2012-08-29 16:19:03 -05:00
James Lee
5110aad0f3
Add better docs on some File methods
2012-07-17 17:32:27 -06:00
James Lee
62fe00866d
Add comments about what the block is for
2012-07-17 16:09:17 -06:00
HD Moore
d656e3185f
Mark all libraries as defaulting to 8-bit strings
2012-06-29 00:18:28 -05:00
James Lee
884550ce7c
Fix undefined constant bug in session.fs.seek
...
How did this ever work? Clearly nothing exercises this code.
2012-03-02 14:43:00 -07:00
James Lee
fa4dbf6783
move the client accessor back to the top so it's available when needed, use the session-specific separator, fixes #4892 again
...
git-svn-id: file:///home/svn/framework3/trunk@13350 4d416f70-5f16-0410-b530-b9f4589650da
2011-07-26 22:37:41 +00:00
James Lee
2212afcf31
un-remove an important include...
...
git-svn-id: file:///home/svn/framework3/trunk@13348 4d416f70-5f16-0410-b530-b9f4589650da
2011-07-26 20:58:23 +00:00
James Lee
0f95070f3f
add a request type for grabbing the host's directory separator, fixes #4892
...
git-svn-id: file:///home/svn/framework3/trunk@13346 4d416f70-5f16-0410-b530-b9f4589650da
2011-07-26 20:51:33 +00:00
HD Moore
7dfb74be10
See #4986 , make unicode encoding optional
...
git-svn-id: file:///home/svn/framework3/trunk@13275 4d416f70-5f16-0410-b530-b9f4589650da
2011-07-21 15:26:15 +00:00
HD Moore
cccbdf9fab
This patch allows meterpreter to work with file paths and user names that are not of the US-ASCII character set.
...
git-svn-id: file:///home/svn/framework3/trunk@13200 4d416f70-5f16-0410-b530-b9f4589650da
2011-07-17 17:32:52 +00:00
James Lee
7f743a5c1b
make meterpreter's File.basename() honor both kinds of directory seperators, use the remote basename as the dest when dest is implicit
...
git-svn-id: file:///home/svn/framework3/trunk@13124 4d416f70-5f16-0410-b530-b9f4589650da
2011-07-08 00:08:42 +00:00
HD Moore
92bb531af5
New bins, new functions, more info soon
...
git-svn-id: file:///home/svn/framework3/trunk@13059 4d416f70-5f16-0410-b530-b9f4589650da
2011-06-29 06:12:03 +00:00
HD Moore
9220506ba2
Merge in recent meterpreter work. These are not the commits you are looking for (more info on what all this is later this week).
...
git-svn-id: file:///home/svn/framework3/trunk@13053 4d416f70-5f16-0410-b530-b9f4589650da
2011-06-28 21:26:43 +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
HD Moore
3794ed35cc
Apply patches from Matthew Weeks (scriptjunkie) to fix traversal flaws outlined in his Black Hat DC talk:
...
https://media.blackhat.com/bh-dc-11/Weeks/BlackHat_DC_2011_Weeks_Counterattack-wp.pdf
https://media.blackhat.com/bh-dc-11/Weeks/BlackHat_DC_2011_Weeks_Counterattack-Slides.pdf
git-svn-id: file:///home/svn/framework3/trunk@11636 4d416f70-5f16-0410-b530-b9f4589650da
2011-01-25 02:24:37 +00:00
HD Moore
fba2cb6d2d
Remove the response wait for close calls triggered by the finalizer, should help in a few corner cases that currently result in a timeout or hang.
...
git-svn-id: file:///home/svn/framework3/trunk@10876 4d416f70-5f16-0410-b530-b9f4589650da
2010-11-03 03:03:29 +00:00
Stephen Fewer
a0f86c62e3
Meterpreter search support to leverage the index on older systems (2000/XP/2003) via Windows Desktop Search v2.
...
git-svn-id: file:///home/svn/framework3/trunk@10187 4d416f70-5f16-0410-b530-b9f4589650da
2010-08-30 09:50:41 +00:00
Stephen Fewer
fbf64adf2a
Commit the ruby side for meterpreter file search. If available, will leverage Windows Search to speed up searching an indexed directory. Examples of usage as follows:
...
Find all .PDF files on the host system:
meterpreter>search *.pdf
Find all files on bob's desktop:
meterpreter>search -d 'c:\users\bob\desktop' -f *
Find all files in the root drive c: but don't search subdirectories:
meterpreter>search -d c: -r false -f *
If Windows Search is available (Vista and above by default, XP/2003 by addon) we can also search any indexed IE history and indexed email
meterpreter>search -d iehistory -f *
meterpreter>search -d mapi -f *
git-svn-id: file:///home/svn/framework3/trunk@10167 4d416f70-5f16-0410-b530-b9f4589650da
2010-08-27 14:59:38 +00:00
HD Moore
5234fe8ff8
Fixes 416. Adds the rm/del commands to meterpreter, fixes build problems triggered by the POSIX code merge
...
git-svn-id: file:///home/svn/framework3/trunk@7291 4d416f70-5f16-0410-b530-b9f4589650da
2009-10-27 02:31:07 +00:00
HD Moore
304ed6b0a6
During a recursive download, ensure that the local directories are created properly
...
git-svn-id: file:///home/svn/framework3/trunk@7117 4d416f70-5f16-0410-b530-b9f4589650da
2009-10-02 14:57:25 +00:00
HD Moore
dc68188c3b
Patch may resolv slowdowns during local file reads
...
git-svn-id: file:///home/svn/framework3/trunk@6382 4d416f70-5f16-0410-b530-b9f4589650da
2009-03-23 21:04:39 +00:00