Commit Graph

21 Commits

Author SHA1 Message Date
shellspawn 18b2eec1db fixed a swap typo in credential documentation 2024-01-15 04:10:49 -06:00
k0pak4 8affc0e91a Add in proper realm reporting cred abilities 2021-02-15 18:20:56 -05:00
Jeffrey Martin 07cbe426e2 Rails 5, all models inherit from ApplicationRecord
ApplicationRecord is a new superclass for all app models, analogous to app controllers subclassing ApplicationController instead of ActionController::Base. This gives apps a single spot to configure app-wide model behavior.
https://edgeguides.rubyonrails.org/upgrading_ruby_on_rails.html#active-record-models-now-inherit-from-applicationrecord-by-default

Deprecated Relation#uniq use Relation#distinct instead.
https://edgeguides.rubyonrails.org/5_0_release_notes.html#active-record-deprecations
2020-07-31 11:56:49 -05:00
Jeffrey Martin 8fac591f7a rails 5.2 update 2020-07-31 11:56:42 -05:00
Auxilus 892cab094a remove spaces at EOL 2020-03-24 18:07:18 +05:30
David Maloney 7376d4d94e account for public only credentials in #to_s
SNMP in particular will only have a public, so we need
to account for this so we don't output poorly formed text
with a trailing ':' char

5266
2015-05-18 13:42:15 -05:00
David Maloney c836078292 allow credentials to have a type of postgres_md5
add postgres_md5 to the type validation on
Metasploit::Framework::Credential to account
for the new Private type

MSP-12244
2015-03-03 16:35:30 -06:00
David Maloney fcfce9efec Merge branch 'staging/electro-release' into feature/MSP-10992/scanner-dry 2014-08-12 11:22:51 -05:00
David Maloney dbde046f44 use to_h instead of to_hash
apparently ruby 2 adds this as a standard method so
we should stay compliant
2014-08-01 09:45:51 -05:00
David Maloney 374c6532fa add to_hash to Credential
begining of the chain to DRYing up
credential reporting in the loginscanner
2014-07-31 18:10:48 -05:00
darkbushido ad6eed01a2 .to_credential now assigns a parent
Metasploit::Credential::Core#to_credential will set the parent to the original core objext
Metasploit::Framework::Credential#to_credential also sets the parent to itself.
2014-07-31 14:52:27 -05:00
David Maloney 78a3263cfe have Credentials remember their aprents
a Credential object can be created from several
other types of objects. Keep a reference to the originating
'parent' so we can find our way back
2014-07-29 11:20:52 -05:00
darkbushido 064d624322 changing Credential == operator
it should no longer raise no method errors when comparing a credential to
an object that doesnt respond to public, private, or realm
2014-07-23 16:17:09 -05:00
James Lee 097d5d68ce Display 'realm\user' for AD instead of 'user@realm' 2014-07-10 14:31:42 -05:00
David Maloney b52c13228c make private_type validation conditional
there are times when this won't be filled in
but the credential is still valid
2014-07-07 15:40:52 -05:00
James Lee b7cfc927c4 Add private_type and realm_key accessors 2014-07-07 13:07:28 -05:00
Lance Sanchez b5351eec2b adding .to_credential
Metasploit::Framework::Credential and Metasploit::Credential::Core
need to be consumable by the login scanners. the easiest way to do this
was to create a shared to_credential method on both that return Metasploit::Framework::Credential

MSP-9912
2014-06-26 11:05:59 -05:00
David Maloney e9d9806408 invalidate_login
added invalidate_login call
also made to_s on credential drop the @
if there is no realm present
2014-06-10 11:07:15 -05:00
James Lee b1136752be Add Credential#== to facilitate specs 2014-06-05 11:37:48 -05:00
James Lee 8b6e188ba8 Add support for realm in CredentialCollection
MSP-9988
2014-06-04 17:03:52 -05:00
James Lee 41644970bf Add a CredentialCollection
Also moves Metasploit::Framework::LoginScanner::Credential to
Metasploit::Framework::Credential
2014-06-04 13:01:09 -05:00