File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
lib/metasploit/framework/login_scanner Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ module LoginScanner
11
11
class SNMP
12
12
include Metasploit ::Framework ::LoginScanner ::Base
13
13
14
+ DEFAULT_TIMEOUT = 2
14
15
DEFAULT_PORT = 161
15
16
DEFAULT_RETRIES = 0
16
17
DEFAULT_VERSION = 'all'
@@ -117,7 +118,7 @@ def has_write_access?(snmp_client, value)
117
118
# Sets the connection timeout appropriately for SNMP
118
119
# if the user did not set it.
119
120
def set_sane_defaults
120
- self . connection_timeout = 2 if self . connection_timeout . nil?
121
+ self . connection_timeout = DEFAULT_TIMEOUT if self . connection_timeout . nil?
121
122
self . port = DEFAULT_PORT if self . port . nil?
122
123
self . retries = DEFAULT_RETRIES if self . retries . nil?
123
124
self . version = DEFAULT_VERSION if self . version . nil?
You can’t perform that action at this time.
0 commit comments