Skip to content

Latest commit

 

History

History
90 lines (59 loc) · 1.82 KB

File metadata and controls

90 lines (59 loc) · 1.82 KB

Python Protector

class PythonProtector:
    def __init__(
        self,
        debug: Optional[bool],
        modules: Set[str],
        logs_path: Optional[Union[Path, str]],
        webhook_url: Optional[str],
        on_detect: Optional[Set[str]],
    ) -> None:

Arguments

  • debug (bool) - Whether Or Not PythonProtector Should Log Actions.
  • modules (Set[str]) - List Of Modules You Would Like To Enable.
  • logs_path (Union[Path, str]) - Path For PythonProtector Logs.
  • webhook_url (str) - Webhook URL For Reporting Remotely.
  • on_detect (Set[str], optional) - List of Things PyProtector Does When Detections Are Caused

Raises

  • ModulesNotValid - Raises If Modules Are Not Valid
  • DetectionsNotValid - Raises If on_detect parameters are invalid
  • LogsPathEmpty - Raises If Debug Is Enabled But No Logs Path Are Provided

Methods

start

Main Function Of PythonProtector, Initializes Everything.

Raises
  • DeprecationWarning - If Python Version < 3.11

Properties

version

Returns The Current PythonProtector Version

Type

str

user

Returns a Tuple of User Information

Type

tuple

ip

Returns The Current Users IP

Type

str

computer

Returns The Current Users WMI Computer Object

Type

typing.Any

Extra Notes

List of Valid Modules:

Modules: Final[Set[str]] = {
    "Miscellaneous",
    "AntiProcess",
    "AntiDLL",
    "AntiVM",
    "AntiAnalysis",
    }

List of Valid Detections:

Detections: Final[Set[str]] = {"Screenshot", "Exit", "Report"}