package utils

var wellKnown = map[string]struct{}{
	"/.well-known/acme-challenge":                 {},
	"/.well-known/amphtml":                        {},
	"/.well-known/api-catalog":                    {},
	"/.well-known/appspecific":                    {},
	"/.well-known/ashrae":                         {},
	"/.well-known/assetlinks.json":                {},
	"/.well-known/broadband-labels":               {},
	"/.well-known/brski":                          {},
	"/.well-known/caldav":                         {},
	"/.well-known/carddav":                        {},
	"/.well-known/change-password":                {},
	"/.well-known/cmp":                            {},
	"/.well-known/coap":                           {},
	"/.well-known/coap-eap":                       {},
	"/.well-known/core":                           {},
	"/.well-known/csaf":                           {},
	"/.well-known/csaf-aggregator":                {},
	"/.well-known/csvm":                           {},
	"/.well-known/did.json":                       {},
	"/.well-known/did-configuration.json":         {},
	"/.well-known/dnt":                            {},
	"/.well-known/dnt-policy.txt":                 {},
	"/.well-known/dots":                           {},
	"/.well-known/ecips":                          {},
	"/.well-known/edhoc":                          {},
	"/.well-known/enterprise-network-security":    {},
	"/.well-known/enterprise-transport-security":  {},
	"/.well-known/est":                            {},
	"/.well-known/genid":                          {},
	"/.well-known/gnap-as-rs":                     {},
	"/.well-known/gpc.json":                       {},
	"/.well-known/gs1resolver":                    {},
	"/.well-known/hoba":                           {},
	"/.well-known/host-meta":                      {},
	"/.well-known/host-meta.json":                 {},
	"/.well-known/hosting-provider":               {},
	"/.well-known/http-opportunistic":             {},
	"/.well-known/idp-proxy":                      {},
	"/.well-known/jmap":                           {},
	"/.well-known/keybase.txt":                    {},
	"/.well-known/knx":                            {},
	"/.well-known/looking-glass":                  {},
	"/.well-known/masque":                         {},
	"/.well-known/matrix":                         {},
	"/.well-known/mercure":                        {},
	"/.well-known/mta-sts.txt":                    {},
	"/.well-known/mud":                            {},
	"/.well-known/nfv-oauth-server-configuration": {},
	"/.well-known/ni":                             {},
	"/.well-known/nodeinfo":                       {},
	"/.well-known/nostr.json":                     {},
	"/.well-known/oauth-authorization-server":     {},
	"/.well-known/oauth-protected-resource":       {},
	"/.well-known/ohttp-gateway":                  {},
	"/.well-known/openid-federation":              {},
	"/.well-known/open-resource-discovery":        {},
	"/.well-known/openid-configuration":           {},
	"/.well-known/openorg":                        {},
	"/.well-known/oslc":                           {},
	"/.well-known/pki-validation":                 {},
	"/.well-known/posh":                           {},
	"/.well-known/privacy-sandbox-attestations.json": {},
	"/.well-known/private-token-issuer-directory": {},
	"/.well-known/probing.txt":                    {},
	"/.well-known/pvd":                            {},
	"/.well-known/rd":                             {},
	"/.well-known/related-website-set.json":       {},
	"/.well-known/reload-config":                  {},
	"/.well-known/repute-template":                {},
	"/.well-known/resourcesync":                   {},
	"/.well-known/sbom":                           {},
	"/.well-known/security.txt":                   {},
	"/.well-known/ssf-configuration":              {},
	"/.well-known/sshfp":                          {},
	"/.well-known/stun-key":                       {},
	"/.well-known/terraform.json":                 {},
	"/.well-known/thread":                         {},
	"/.well-known/time":                           {},
	"/.well-known/timezone":                       {},
	"/.well-known/tdmrep.json":                    {},
	"/.well-known/tor-relay":                      {},
	"/.well-known/tpcd":                           {},
	"/.well-known/traffic-advice":                 {},
	"/.well-known/trust.txt":                      {},
	"/.well-known/uma2-configuration":             {},
	"/.well-known/void":                           {},
	"/.well-known/webfinger":                      {},
	"/.well-known/webweaver.json":                 {},
	"/.well-known/wot":                            {},
}

// Check if a path is a well-known URI
// e.g. /.well-known/acme-challenge
// https://www.iana.org/assignments/well-known-uris/well-known-uris.xhtml
func IsWellKnownURI(path string) bool {
	_, exists := wellKnown[path]

	return exists
}
