Documentation
¶
Overview ¶
Package registrationurl validates the exact URLs that may be retained by browser-registration authoring and execution contracts.
Index ¶
Constants ¶
View Source
const ( MaxURLBytes = 4096 MaxQueryBytes = 1024 MaxQueryItems = 16 MaxQueryKeyBytes = 64 MaxQueryValueBytes = 256 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Facts ¶
Facts is the canonical URL plus the only facts safe for observation output. Query is deliberately absent.
func Parse ¶
func Parse(raw string, allowQuery bool, canonicalOrigin func(string) (string, error)) (Facts, error)
Parse accepts one canonical absolute, fragment-free URL. When allowQuery is false it preserves the v1 query rejection. When true it admits only a bounded canonical literal query with unique nonempty safe keys and values. Errors never include rejected URL material.
Click to show internal directories.
Click to hide internal directories.