def METHOD_NAME(attachment):
    if (
        attachment["content_type"]
        not in (
            "application/json",
            "text/plain",
        )
        or "memory-report" in attachment["file_name"]
    ):
        return False
    content_bytes = base64.b64decode(attachment["data"])
    try:
        content = json.loads(content_bytes)
    except ValueError:
        return False
    return all(
        key in content
        for key in (
            "application",
            "processes",
            "addons",
            "startupCache",
            "modifiedPreferences",
        )
    )