feat: add docstrings

This commit is contained in:
HugoPBrito
2025-02-12 16:43:22 +01:00
parent 2b7dead1f8
commit 2ba1a5990a

View File

@@ -1,9 +1,29 @@
from typing import List
from prowler.lib.check.models import Check, Check_Report_Microsoft365
from prowler.providers.microsoft365.services.entra.entra_client import entra_client
class entra_security_defaults_disabled(Check):
def execute(self) -> Check_Report_Microsoft365:
"""Check if Entra Security Defaults are disabled.
This check verifies if the Entra Security Defaults are disabled in the Microsoft 365 environment.
The check passes if security defaults are disabled, and fails if they are enabled.
Attributes:
metadata: Metadata associated with the check (inherited from Check).
"""
def execute(self) -> List[Check_Report_Microsoft365]:
"""Execute the Entra Security Defaults disabled check.
This method checks the status of Entra Security Defaults and generates a report indicating
whether security defaults are disabled or not.
Returns:
List[Check_Report_Microsoft365]: A list containing the report of the check, indicating
whether the security defaults are disabled or enabled.
"""
findings = []
report = Check_Report_Microsoft365(
metadata=self.metadata(), resource=entra_client.security_defaults