This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| This patched clr.dll ommits windows syscall via advapi32.dll to generate random numbers, insted it will always produce 0 as result | |
| can be tested with Get-Random in powershell | |
| DLL : https://drive.google.com/file/d/1NnMe7jjtOyQR8AeRptv75mquE6uGnsZe/view | |
| Put the dll file to C:\WINDOWS\Microsoft.NET\Framework64\v4.* and not forget to copy and backup the current version | |
| or inject the dll to the process directly | |
| Use at your own risk |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <unistd.h> | |
| ssize_t getrandom(void *buf, size_t buflen, unsigned int flags) { | |
| memset(buf, 0, buflen); | |
| return buflen;} | |
| //gcc -shared -fPIC -o libc-unrandom.so libc-unrandom.c -ldl | |
| //LD_PRELOAD=./libc-unrandom.so python -c "import random; print(random.random())" | |
| //LD_PRELOAD=./libc-unrandom.so shuf -e 1 2 3 | |
| //LD_PRELOAD=./libc-unrandom.so bash |
OlderNewer