Commit Graph

639 Commits

Author SHA1 Message Date
bcoles 431804ef15 Fix typos: Replace 'the the' with 'the' 2022-12-04 17:41:24 +11:00
Matthew Dunn 1e50ba3415 Move to Hashes module, address requested changes
Fix rubocop

Move identify to hashes module up one layer, use full reference to identify_hash instead of full include

Fix SMTP require

Remove hashes require statement

Remove hashes require statement

Remove hashes require statement

Remove hashes require statement

Address remaining requested changes, reference constants directly

Add all the missing direct references

Co-Authored-By: Jeffrey Martin <jeffrey_martin@rapid7.com>
2022-10-17 17:28:31 -04:00
Matthew Dunn 8b5223f53b Modularize Identify, Update referenced use cases
Modularize Identity.rb

Include new module style Identify

Update juniper.rb

Fix inadvertent change

Add new module to identify spec

Put the require back

Put back require line for juniper
2022-10-17 17:28:30 -04:00
adfoster-r7 3a281234df Add feature flagged datastore rewrite, with support for option fallback lookups 2022-09-16 12:59:02 +01:00
Ron Bowes 1e6924b19c Add better ID response 2022-07-29 12:58:55 -07:00
Ron Bowes 7c0bb35a4b Fix a crash from the original module if 'arg' was nil, and remove an errant space 2022-07-27 10:43:14 -07:00
Ron Bowes aa51353605 Move the arg-parsing logic out of the login request 2022-07-27 10:14:37 -07:00
Ron Bowes d53dc7ca90 Add support for RFC7888-style logins, which send the username/password as separate lines 2022-07-26 15:11:46 -07:00
Spencer McIntyre 1466506069 Update the docs to be accurate 2022-05-27 14:41:06 -04:00
Christophe De La Fuente 63dea932ad Land #16481, Update Msf::Exploit::Remote::SMB::Server::Share 2022-05-24 11:50:06 +02:00
adfoster-r7 2cbd64b759 Land #16487, fix deprecation warning in auxiliary/capture/server/mssql as well as updating johntheripper format 2022-05-19 00:40:03 +01:00
Spencer McIntyre edd977165c Revert option changes for the capture NTLM provider 2022-05-16 14:39:45 -04:00
Spencer McIntyre 7c15b144c4 Update the SMB capture server 2022-05-16 14:39:44 -04:00
Spencer McIntyre 906fdd6a05 Update the MSSQL capture module
Remove the apparently unused reference to the SMB server mixin.
2022-05-16 14:39:44 -04:00
Spencer McIntyre 475f6eee8c Capture hash when serving files over SMB 2022-05-16 14:39:44 -04:00
Redouane NIBOUCHA f6ff5dde75 Fix hash format (make it compatible with john the ripper) 2022-04-28 06:05:59 +02:00
Redouane NIBOUCHA 247ae89c43 Use constants for JTR formats instead of strings 2022-04-27 03:25:26 +02:00
Redouane NIBOUCHA 2043d96ae9 Update service_name 2022-04-22 07:22:33 +02:00
Redouane NIBOUCHA f21f786c06 Use #create_credential_login instead of the deprecated #report_auth_info 2022-04-22 06:06:05 +02:00
h00die ab382cddf0 change requireauth to authprompt 2022-04-11 14:26:25 -04:00
h00die f7b58e243c smtp server can prompt for auth 2022-04-10 11:55:07 -04: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
Grant Willcox 964f78fc69 Land #16341, Implement VNC hash types 2022-03-22 17:00:02 -05:00
Spencer McIntyre fd2d1c0784 Add and use the ListenerComm option for SOCKS 2022-03-22 09:23:09 -04:00
Spencer McIntyre a739083db9 Readd the missing SocketServer mixin for SMB 2022-03-21 11:51:10 -04:00
Spencer McIntyre 929e5d5e76 Update the SMB capture module with new options 2022-03-21 11:47:56 -04:00
sjanusz bbf9e3163a Fix file reads on Windows for binary files 2022-03-21 12:47:39 +00:00
Ashley Donaldson 972c260969 Fix double dereference by moving DNS cleanup into separate function, and force to run as job. 2022-03-17 08:12:25 +11:00
Spencer McIntyre 4dd7fc60e6 Land #16324, Fix broken DNS native_server 2022-03-15 09:06:03 -04:00
h00die a959725f7c implement vnc hash types 2022-03-13 13:27:38 -04:00
adfoster-r7 a62ca2259e Land #16316, deref services correctly 2022-03-11 12:08:42 +00:00
Ashley Donaldson 09b094cd64 DNS server: When there are multiple answers, set the answer, not the question, in the returned packet 2022-03-10 15:05:52 +11:00
Ashley Donaldson 6f159fa54e Consistent handling of DNS and LDAP servers wrt ServiceManager 2022-03-10 11:01:37 +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
adfoster-r7 6f2a7d6167 Add note that SMB v1 is not supported 2022-03-08 23:52:24 +00:00
adfoster-r7 53772fa366 Gracefully handle relay host timeout, fix typos, and move SMBHashCapture location 2022-03-08 23:52:24 +00:00
adfoster-r7 507b1dab2b Apply PR feedback 2022-03-08 23:52:22 +00:00
adfoster-r7 b4fe2502aa Update smb_relay to support smb 2 and smb3 2022-03-08 23:52:22 +00:00
h00die d5ba1afbec fix URLs not resolving
fix URLs not resolving

add csv export to references

fix URLs not resolving

pdf not pd

missed a url change

remove extra recirectedfrom fields

remove extra file

fix ovftool url accidental replacement
2022-02-16 17:22:40 -06:00
Spencer McIntyre d82b9ecb47 Add module docs for the ldap server module 2021-12-28 13:52:12 -05:00
RageLtMan 60fdf2a7da Rubocop pass on LDAP pieces 2021-12-18 09:03:56 -05:00
RageLtMan 0e90c3e573 Address @adfoster-r7's change requests
Due to how this stack is being broken up into LDAP core, scanner
update, and exploit work, changes requested in #15972 actually
apply in this branch and get rebased to the remaining ones.

Address requests to clean up the textual messages, LDIF file read,
sourcing of LDAP methods from net-ldap, and YARD-related placement
of attr_* annotations.
2021-12-18 07:52:33 -05:00
RageLtMan 0cb381e35d Address the easy parts of @zeroSteiner's review 2021-12-16 19:32:04 -05:00
RageLtMan db8f4ffa6f Native LDAP infrastructure to support log4shell
In order to detect scan callbacks, serve payloads, and otherwise
interact with the LDAP protocol handler in JNDI, Metasploit needs
a native LDAP service properly exposed to various parts of the
Framework and users/consumers.

Implement Rex::Protocol::LDAP::Server with TCP and UDP socket
handlers abstracted to a common access pattern between L4 stacks.
Extend the socket clients to hold a state attibute for LDAP bind
authentication, and use the UDP client abstraction to implement
consistent callback semantics for data receipt from a client and
handling response on the other side. The server utilizes Rex'
native sockets, permitting full pivot and proxy support over the
Switchboard.

Implement the Msf::Exploit::Remote::LDAP::Server mixin to manage
service abstraction and shared methods exposed to Metasploit
modules.
Note: during implementation of this functionality, it was
discovered that the Scanner mixin's :replicant method resulted in
:dup calls to the Rex::ServiceManager service created by this new
mixin (and any others leveraging ServiceManager). As a result,
double-bind attempts created failures in service instantiation from
the duplicated MetasploitModules which also dropped the @service
instance variable reference to the actual running service; leaving
the socket inexorably bound until Framework was halted and Ruby
released the FDs. See https://github.com/rapid7/rex-core/pull/19
and the Issues/Pull Requests sections of R7's MSF GitHub.

Expose the new LDAP infrastructure to users by way of a basic LDAP
server MetasploitModule which consumes a tiny sample LDIF (provided)
and performs queries against it. This is intended to be a template
for future work such as LDAP authentication capture, protocol proxy
for MITM and intercept, and other more specific implementations for
exploits and auxiliary modules.

For feature completeness, provide a Rex::Socket override for
Net::LDAP::Connection until we have a proper, native to Rex, LDAP
client class implemented.

Testing:
  Basic functionality only, this is an early effort which will be
extended for feature-completeness over time
2021-12-16 18:47:52 -05:00
adfoster-r7 ded8200396 Land #15537, Add support for ruby 3 2021-09-01 10:30:54 +01:00
Spencer McIntyre 8317a484a3 Land #15548, Overhaul SMB auth capture server 2021-08-30 10:01:55 -04:00
sjanusz ab596dc13d Adds realm, host and service for core credentials 2021-08-27 17:33:17 +01:00
adfoster-r7 4a9a15e638 Run Rubocop layout rules on modules 2021-08-27 17:19:43 +01:00
agalway-r7 4bcfe81ddb replace magic value with constant
Co-authored-by: Spencer McIntyre <58950994+smcintyre-r7@users.noreply.github.com>
2021-08-25 14:35:16 +01:00