freeze_prototype
Prevent page JavaScript from overriding prototype methods by making them non-overridable. Use after installing hooks to maintain control over browser APIs during reverse engineering.
Instructions
Make a prototype method non-overridable by page scripts.
After calling this, any attempt by page JS to reassign the method will silently fail (or throw in strict mode). Use after installing hooks to prevent the target site from restoring original methods.
Args: class_name: The class/constructor name, e.g. "XMLHttpRequest", "Document", "Navigator". method_name: The method name on the prototype, e.g. "open", "send".
Returns: dict with status and the frozen target.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| class_name | Yes | ||
| method_name | Yes |