Skip to content
Snippets Groups Projects
Commit 7e35e3da authored by Aleš Mrázek's avatar Aleš Mrázek
Browse files

manager: datamodel: tsig removed from view_schema

parent a3b268d7
Branches
Tags
1 merge request!1313manager: datamodel improvements
......@@ -23,18 +23,12 @@ class ViewSchema(ConfigSchema):
---
subnets: Identifies the client based on his subnet.
tsig: Identifies the client based on a TSIG key name (for testing purposes, TSIG signature is not verified!).
tags: Tags to link with other policy rules.
options: Configuration options for clients identified by the view.
answer: Direct approach how to handle request from clients identified by the view.
tags: Tags to link with other policy rules.
"""
subnets: Optional[Union[List[IPNetwork], IPNetwork]] = None
tsig: Optional[List[str]] = None
tags: Optional[List[IDPattern]] = None
answer: Optional[Literal["allow", "refused"]] = None
options: ViewOptionsSchema = ViewOptionsSchema()
def _validate(self) -> None:
if self.tsig is None and self.subnets is None:
raise ValueError("'subnets' or 'rsig' must be configured")
answer: Optional[Literal["allow", "refused"]] = None
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment