modify_smali_file
Modify smali class files in an APKTool project with automatic validation and optional backup for safe reverse engineering.
Instructions
Modify smali file content with validation and backup support.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"project_dir": "<project_dir>",
"class_name": "<class_name>",
"new_content": "<new_content>"
},
"name": "modify_smali_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| class_name | Yes | Full class name (e.g., com.example.MyClass) | |
| new_content | Yes | New content for the smali file | |
| project_dir | Yes | Path to the APKTool project directory | |
| create_backup | No | Whether to create a backup of the original file |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||