google.cloud.forseti.scanner.scanners.audit_logging_scanner module

Scanner for Audit Logging.

class AuditLoggingScanner(global_configs, scanner_configs, service_config, model_name, snapshot_timestamp, rules)[source]

Bases: google.cloud.forseti.scanner.scanners.base_scanner.BaseScanner

Scanner for Audit Logging.

_abc_cache = <_weakrefset.WeakSet object>
_abc_negative_cache = <_weakrefset.WeakSet object>
_abc_negative_cache_version = 207
_abc_registry = <_weakrefset.WeakSet object>
_find_violations(audit_logging_data)[source]

Find violations in the audit log configs.

Parameters:audit_logging_data (list) – audit log data to find violations in.
Returns:A list of all violations
Return type:list
static _flatten_violations(violations)[source]

Flatten RuleViolations into a dict for each violation.

Parameters:violations (list) – The RuleViolations to flatten.
Yields:dict – Iterator of RuleViolations as a dict per member.
_output_results(all_violations)[source]

Output results.

Parameters:all_violations (list) – A list of violations
_retrieve()[source]

Retrieves the data for scanner.

Returns:List of projects’ audit logging config data.
Return type:list
run()[source]

Runs the data collection.