feat: add NetBox plugin store
CI / php-store (push) Waiting to run
CI / python-components (push) Waiting to run

This commit is contained in:
2026-08-24 20:51:25 +02:00
commit f36d6be511
135 changed files with 15160 additions and 0 deletions
@@ -0,0 +1,18 @@
from __future__ import annotations
from typing import Protocol
class PermissionUser(Protocol):
is_authenticated: bool
is_superuser: bool
def has_perm(self, permission_name: str) -> bool: ...
def has_store_access(user: PermissionUser, permission_name: str) -> bool:
"""Authorize NetBox users without relying on the removed ``is_staff`` field."""
return bool(
user.is_authenticated
and (user.is_superuser or user.has_perm(permission_name))
)