Minor post-merge refactor, mainly moved duplicated method ca_bundle_path into common.rb

This commit is contained in:
2025-08-04 10:50:07 -05:00
parent ad2544a56b
commit 48617b26da
5 changed files with 16 additions and 23 deletions

View File

@@ -32,6 +32,15 @@ class W3DHub
linux? || mac?
end
# Detect system CA bundle path for SSL verification
def self.ca_bundle_path
[
"/etc/ssl/certs/ca-certificates.crt", # Debian/Ubuntu
"/etc/pki/tls/certs/ca-bundle.crt", # RHEL/Fedora/CentOS
"/etc/ssl/ca-bundle.pem" # Some other distros
].find { |path| File.exist?(path) }
end
def self.url(path)
raise "Hazardous input: #{path}" if path.include?("&&") || path.include?(";")