Skip to content

Commit a83401f

Browse files
committed
Clean up perms and whitespace after msftidy run
2 parents ba03890 + c37dbd1 commit a83401f

File tree

1 file changed

+10
-13
lines changed

1 file changed

+10
-13
lines changed

modules/auxiliary/scanner/http/owa_login.rb

100755100644
Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ def initialize
3030
'Brandon Knight',
3131
'Pete (Bokojan) Arzamendi, #Outlook 2013 updates'
3232
],
33-
3433
'License' => MSF_LICENSE,
3534
'Actions' =>
3635
[
@@ -61,7 +60,7 @@ def initialize
6160
'InboxCheck' => /Inbox|location(\x20*)=(\x20*)"\\\/(\w+)\\\/logoff\.owa|A mailbox couldn\'t be found|\<a .+onclick="return JumpTo\('logoff\.aspx.+\">/
6261
}
6362
],
64-
[
63+
[
6564
'OWA_2013',
6665
{
6766
'Description' => 'OWA version 2013',
@@ -72,9 +71,9 @@ def initialize
7271
]
7372
],
7473
'DefaultAction' => 'OWA_2010',
75-
'DefaultOptions' => {
76-
'SSL' => true
77-
}
74+
'DefaultOptions' => {
75+
'SSL' => true
76+
}
7877
)
7978

8079

@@ -162,8 +161,6 @@ def try_user_pass(opts)
162161
vhost = opts["vhost"]
163162
domain = opts["domain"]
164163

165-
166-
167164
user = domain + '\\' + user if domain
168165

169166
headers = {
@@ -208,8 +205,8 @@ def try_user_pass(opts)
208205
return :abort
209206
end
210207
if action.name == "OWA_2013"
211-
#Check for a response code to make sure login was valid. Changes from 2010 to 2013.
212-
#Check if the password needs to be changed.
208+
#Check for a response code to make sure login was valid. Changes from 2010 to 2013.
209+
#Check if the password needs to be changed.
213210
if res.headers['location'] =~ /expiredpassword/
214211
print_good("#{msg} SUCCESSFUL LOGIN. '#{user}' : '#{pass}': NOTE password change required")
215212
report_hash = {
@@ -225,13 +222,13 @@ def try_user_pass(opts)
225222
return :next_user
226223
end
227224

228-
#No password change required moving on.
225+
#No password change required moving on.
229226
reason = res.headers['location'].split('reason=')[1]
230-
if reason == nil
227+
if reason == nil
231228
headers['Cookie'] = 'PBack=0;' << res.get_cookies
232-
else
229+
else
233230
#Login didn't work. no point on going on.
234-
vprint_error("#{msg} FAILED LOGIN. '#{user}' : '#{pass}'")
231+
vprint_error("#{msg} FAILED LOGIN. '#{user}' : '#{pass}'")
235232
return :Skip_pass
236233
end
237234
else

0 commit comments

Comments
 (0)