### List Exports Example Output Source: https://github.com/frida/frida-rust/blob/main/examples/core/list_exports/README.md Expected output when running the list exports example. ```text [*] Frida version: 17.5.1 [*] Device name: Local System [*] Info: "Logging message from JS" [*] Warning: "Warning message from JS" [*] Debug: "Debug message from JS" [*] Error: "Error message from JS" [*] Send: String("Send message from JS") [*] Send: String("Send message with data"), Data: [1, 2, 3] [*] Script loaded. ["increment", "getvalue"] ["increment", "getvalue"] ["increment", "getvalue"] [*] Script unloaded [*] Session detached Exiting... ``` -------------------------------- ### Run the example Source: https://github.com/frida/frida-rust/blob/main/examples/core/compile_script/README.md Command to run the example. ```bash cargo run -p compile_script ``` -------------------------------- ### Example Output Source: https://github.com/frida/frida-rust/blob/main/examples/core/rpc_execute_function/README.md Expected output when running the RPC execute function example. ```text [*] Frida version: 17.5.1 [*] Device name: Local System [*] Script loaded. ["increment", "nIncrement", "getValue", "sumVals", "bye"] [*] Info: "globalVar incremented by 1" [*] Info: "globalVar incremented by 2" js_global_var: 3 [*] Info: "Bye Potato" total: 10 This is an error from JS: Error on the JavaScript side: unable to find method 'NonExistentFunc' [*] Script unloaded [*] Session detached Exiting... ``` -------------------------------- ### Hook open on Linux Source: https://github.com/frida/frida-rust/blob/main/examples/gum/hook_open/README.md Use LD_PRELOAD to inject the library into a process on Linux. ```sh LD_PRELOAD=../../../target/release/libhook_open.so cat /tmp/test ``` -------------------------------- ### Hook open on MacOS Source: https://github.com/frida/frida-rust/blob/main/examples/gum/hook_open/README.md Use DYLD_INSERT_LIBRARIES to inject the library into a process on MacOS. ```sh DYLD_INSERT_LIBRARIES=hook_openlib.so somebinary" ``` -------------------------------- ### Preload Frida-Rust Library Source: https://github.com/frida/frida-rust/blob/main/examples/gum/process_check/README.md Execute a command by preloading the compiled Frida-Rust shared library. This allows the library to hook into the target process (`cat` in this case) and potentially modify or observe its behavior. ```sh LD_PRELOAD=../../../target/release/libprocess_check.so cat /tmp/test.txt ``` -------------------------------- ### Build Frida-Rust Library Source: https://github.com/frida/frida-rust/blob/main/examples/gum/process_check/README.md Compile the Frida-Rust library in release mode. This command is used to create an optimized binary for the Frida hook. ```sh cargo build --release ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.