sous-chefs / java

Development repository for the java cookbook
https://supermarket.chef.io/cookbooks/java
Apache License 2.0
386 stars 637 forks source link

Fixed java_certificate regex where it checks if cert exists in cacert file #562

Closed bill538 closed 4 years ago

bill538 commented 5 years ago

Description

In testing openjdk 11 with this java cookbook I found that the regex used to determine if a cacert is installed and should be deleted before being re-added incorrectly matches similarly named cacerts. Cert comapanyenterpriserootca2 is matching another cert called comapanyenterpriserootca2.1 see https://rubular.com/r/ITi0qdT26D6RWg for broken example. The certificate resource then attempts to delete comapanyenterpriserootca2 which doesn't exist and fails with fatal error "Error deleting existing certificate comapanyenterpriserootca2". See https://rubular.com/r/iF81EPJjw7d8Sv for the proposed fixed example"

Issues Resolved

Check List