#tips of day #reverse: #x64dbg supports Python extensions. You simple need to install : https://github.com/x64dbg/x64dbgpy. Take the precompiled binaries and copy the files in the x64dbg Plugin repository.
Here is an example of script to switch from HTTPS (port 443) to HTTP (port 80) when InternetConnectW() is called. The logic is simple:
- I create a breakpoint on this API,
- I set a callback function
- this function will be called when the API is called
- if the 3rd argument of InternetConnectW() (stored in R8 in x64 arch) is 443, I change it by 80
- finally, the debugged file continues its execution.
Here is a screenshot:
