Skip to content

Commit

Permalink
Update definitions/checks/check_sha1_certificate_authority.rb
Browse files Browse the repository at this point in the history
Co-authored-by: Evgeni Golov <[email protected]>
  • Loading branch information
ehelms and evgeni authored Jan 8, 2025
1 parent 3733b11 commit e4f19b0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions definitions/checks/check_sha1_certificate_authority.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ def load_fullchain(bundle_pem)
# Can be removed when only Ruby with load_file support is supported
File.binread(bundle_pem).
lines.
slice_after(/END CERTIFICATE/).
filter { |pem| pem.join.include?('END CERTIFICATE') }.
slice_after(/^-----END CERTIFICATE-----/).
filter { |pem| pem.join.include?('-----END CERTIFICATE-----') }.
map { |pem| OpenSSL::X509::Certificate.new(pem.join) }
end
end
Expand Down

0 comments on commit e4f19b0

Please sign in to comment.