Resource validation¶
A collection of functions used in both server and client reference implementations.
-
RestAuthCommon.
resource_validator
(name)[source]¶ Check the name of a resource for some really bad characters that shouldn’t be used anywhere in RestAuth.
This filters names containing a slash (“/”) or colon (“:”) and those starting with ‘.’. It also filters control characters etc., including those from unicode.
Parameters: name (str) – The name to validate Returns: False if the name contains any invalid characters, True otherwise. Return type: bool