Add a warning for second-level wildcards

Fixes #30
This commit is contained in:
Filippo Valsorda
2018-07-03 16:55:12 -04:00
parent 073ee25396
commit c4f873a371
2 changed files with 7 additions and 3 deletions

View File

@@ -113,10 +113,9 @@ Change the CA certificate and key storage location by setting $CAROOT.
log.Fatalf("ERROR: %q is not a valid hostname or IP: %s", name, err)
}
args[i] = punycode
if hostnameRegexp.MatchString(punycode) {
continue
if !hostnameRegexp.MatchString(punycode) {
log.Fatalf("ERROR: %q is not a valid hostname or IP", name)
}
log.Fatalf("ERROR: %q is not a valid hostname or IP", name)
}
m.makeCert(args)