Skip to content

Commit

Permalink
cis-dil-benchmark-5.3.4 should match spaces better
Browse files Browse the repository at this point in the history
5.3.3 uses this matching logic and it works, 

password        [success=1 default=ignore]      pam_unix.so obscure use_authtok try_first_pass sha512  remember=5

is matched by 5.3.3 regular expression, but  didn't match 5.3.4 because of a space between "1" and "default"
  • Loading branch information
fargburger authored Jan 25, 2022
1 parent 09ce465 commit 495689c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion controls/5_3_configure_pam.rb
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@
describe.one do
%w[common-password system-auth password-auth].each do |f|
describe file("/etc/pam.d/#{f}") do
its('content') { should match(/^password(\s+\S+\s+)+pam_unix\.so\s+(\S+\s+)*sha512/) }
its('content') { should match(/^password\s+(\S+\s+)+pam_unix\.so\s+(\S+\s+)*sha512/) }
end
end
end
Expand Down

0 comments on commit 495689c

Please sign in to comment.