Skip to content

Commit b6b5435

Browse files
author
HD Moore
committed
Fix service pack parsing
1 parent 90f3916 commit b6b5435

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

modules/post/windows/gather/enum_ad_computers.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,8 @@ def run
108108
if field.to_i > 0
109109
report[:os_sp] = 'SP' + field
110110
end
111-
if field =~ /(Service Pack|SP\s?)(\d+)/
112-
report[:os_sp] = 'SP' + $1
111+
if field =~ /(Service Pack|SP)\s?(\d+)/
112+
report[:os_sp] = 'SP' + $2
113113
end
114114

115115
when 'description'

0 commit comments

Comments
 (0)