AuditLog (audit_log.py)

claude-bug-bounty · analytics

Audit log — tracks every outbound request made during autopilot sessions. Append-only JSONL file at hunt-memory/audit.jsonl. Used for post-session review and scope compliance verification.

# Source: https://github.com/shuvonsec/claude-bug-bounty | License: MIT | Copyright 2026 Claude Bug Bounty Hunter Contributors
# Provided via justclaw.it.com; keep this notice with the code.
"""
Audit log — tracks every outbound request made during autopilot sessions.

Append-only JSONL file at hunt-memory/audit.jsonl.
Used for post-session review and scope compliance verification.
"""

import fcntl
import json
import os
import sys
import time
from pathlib import Path

from memory.rotation import DEFAULT_KEEP, DEFAULT_MAX_BYTES, rotate_if_needed
from memory.schemas import validate_audit_entry, make_audit_entry, SchemaError


class AuditLog:
    """Append-only audit log for tracking outbound requests."""

    def __init__(
        self,
        path: str | Path,
        max_bytes: int = DEF

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search 40K more like it.

Get a free API key