File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed
lib/github-pages-health-check
spec/github_pages_health_check Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -449,8 +449,11 @@ def enforces_https?
449449 def https_eligible?
450450 # Can't have any IP's which aren't GitHub's present.
451451 return false if non_github_pages_ip_present?
452- # Must be a CNAME or point to our IPs.
453452
453+ # Can't have underscores in the domain name (Let's Encrypt does not allow it)
454+ return false if host . include? ( "_" )
455+
456+ # Must be a CNAME or point to our IPs.
454457 # Only check the one domain if a CNAME. Don't check the parent domain.
455458 return true if cname_to_github_user_domain?
456459
Original file line number Diff line number Diff line change 22
33module GitHubPages
44 module HealthCheck
5- VERSION = "1.18.0 "
5+ VERSION = "1.18.1 "
66 end
77end
Original file line number Diff line number Diff line change 10421042
10431043 it { is_expected . to be_https_eligible }
10441044
1045+ context "with underscore domain" do
1046+ let ( :domain ) { "foo_bar.com" }
1047+
1048+ it { is_expected . not_to be_https_eligible }
1049+ end
1050+
10451051 context "with bad CAA records" do
10461052 let ( :caa_domain ) { "digicert.com" }
10471053 before ( :each ) { allow ( subject . send ( :caa ) ) . to receive ( :query ) { [ caa_packet ] } }
You can’t perform that action at this time.
0 commit comments