Class: Mdm::ExploitAttempt

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
app/models/mdm/exploit_attempt.rb

Overview

An attempt to exploit #host.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#attempted_atDateTime

When the attempt was made.

Returns:

  • (DateTime)


# File 'app/models/mdm/exploit_attempt.rb', line 48


#exploitedtrue, false

Whether the attempt was successful.

Returns:

  • (true)

    attempt was successful.

  • (false)

    attempt was not successful.



# File 'app/models/mdm/exploit_attempt.rb', line 53


#fail_detailString?

A more verbose reason (compared to #fail_reason for the failure.

Returns:

  • (String, nil)


# File 'app/models/mdm/exploit_attempt.rb', line 59


#fail_reasonString?

Summary of why the attempt failed if #exploited is false. For more details see #fail_detail.

Returns:

  • (String, nil)


# File 'app/models/mdm/exploit_attempt.rb', line 64


#host_idInteger

Foreign key to look up #host.

Returns:

  • (Integer)


# File 'app/models/mdm/exploit_attempt.rb', line 69


#moduleString

TODO:

Remove deprecated Mdm::Exploit#module (MSP-9281)

The full name of the exploit module that made the attempt.

Returns:

  • (String)


# File 'app/models/mdm/exploit_attempt.rb', line 74


#portInteger

TODO:

Mdm::ExploitAttempt#port and Mdm::ExploitAttempt#proto are obsolete and should be removed (MSP-9284)

The port on #host which the exploit was attempted.

Returns:

  • (Integer)


# File 'app/models/mdm/exploit_attempt.rb', line 80


#protoString

TODO:

Mdm::ExploitAttempt#port and Mdm::ExploitAttempt#proto are obsolete and should be removed (MSP-9284)

The protocol name used on #port.

Returns:

  • (String)


# File 'app/models/mdm/exploit_attempt.rb', line 86


#usernameString

Name of user that made the attempt. May be an User#name or a system username.

Returns:

  • (String)


# File 'app/models/mdm/exploit_attempt.rb', line 92


Instance Method Details

#hostMdm::Host

Host that was attempted to be exploited.

Returns:



10
11
12
13
# File 'app/models/mdm/exploit_attempt.rb', line 10

belongs_to :host,
class_name: 'Mdm::Host',
counter_cache: :exploit_attempt_count,
inverse_of: :exploit_attempts

#lootMdm::Loot?

Loot gathers from the successful exploit.

Returns:



18
19
20
# File 'app/models/mdm/exploit_attempt.rb', line 18

belongs_to :loot,
class_name: 'Mdm::Loot',
inverse_of: :exploit_attempt

#serviceMdm::Service?

The service being exploited on #host.

Returns:



25
26
27
# File 'app/models/mdm/exploit_attempt.rb', line 25

belongs_to :service,
class_name: 'Mdm::Service',
inverse_of: :exploit_attempts

#sessionMdm::Session?

The session that was established when this attempt was successful.

Returns:



33
34
35
# File 'app/models/mdm/exploit_attempt.rb', line 33

belongs_to :session,
class_name: 'Mdm::Session',
inverse_of: :exploit_attempt

#vulnMdm::Vuln?

The vulnerability that was attempted to be exploited.

Returns:



40
41
42
# File 'app/models/mdm/exploit_attempt.rb', line 40

belongs_to :vuln,
class_name: 'Mdm::Vuln',
inverse_of: :exploit_attempts