Coverage for gws-app/gws/base/auth/method.py: 100%
11 statements
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-24 12:46 +0200
« prev ^ index » next coverage.py v7.15.4, created at 2026-08-24 12:46 +0200
1from typing import Optional
2import gws
5class Config(gws.Config):
6 """Auth method config."""
8 secure: bool = True
9 """Use only with SSL."""
10 allowInsecureFrom: Optional[list[str]]
11 """Allow insecure access from these IPs."""
14class Object(gws.AuthMethod):
15 def configure(self):
16 self.secure = self.cfg('secure')
17 self.allowInsecureFrom = self.cfg('allowInsecureFrom', default=[])