luci-base: add a strict flag to the hostname validator