← Về thư mục
openai4s/security/audit_hook.py
- _writable_roots · function · L38-L65 — def _writable_roots() -> list[str]
- add · function · L42-L50 — def add(p: str | None) -> None
- _allowed_prefixes · function · L68-L108 — def _allowed_prefixes() -> list[str]
- add · function · L72-L80 — def add(p: str | None) -> None
- install · function · L111-L390 — def install( *, enabled: bool = True, skill_event_sink: Callable[[dict], None] | None = None, skill_event_origin: Callable[[], str] | None = None, skill_event_key: bytes | None = None, ) -> bool
- _signed_skill_event · function · L145-L161 — def _signed_skill_event( event: dict, *, _dumps=json.dumps, _hmac_new=hmac.new, _sha256=hashlib.sha256, _key=skill_event_key, ) -> dict
- _under · function · L163-L167 — def _under(path: str, roots: tuple) -> bool
- _trusted_recovery_path · function · L169-L188 — def _trusted_recovery_path( value: object, *, _realpath=os.path.realpath, _allowed=allowed, ) -> bool
- _dlopen_guard · function · L192-L384 — def _dlopen_guard( event, args, *, _realpath=os.path.realpath, _normpath=_posixpath.normpath, _getcwd=_posix.getcwd, _lexists=os.path.lexists, _blocked=blocked, _allowed=allowed, _perm=PermissionError, _dlopen_enabled=bool(enabled), _skill_sink=skill_event_sink, _skill_origin=skill_event_origin, _registered_skill_loaders=registered_skill_loaders, _pending_skill_loads=pending_skill_loads, _code_type=code_type, _getframe=sys._getframe, _sha256=hashlib.sha256, _urandom=os.urandom, _signed_skill_event=_signed_skill_event, _trusted_recovery_path=_trusted_recovery_path, ): # noqa: ANN001