UnamBinder
UnamBinder copied to clipboard
Execute in current folder
Hello, is possible to somehow execute binded files in the current folder?
Not currently no, since it requires some code that does make it more detected.
And will you release that version with that feature?
Maybe, I have to create some good method of adding that since it's not very easy to do in a good way. Usually you never want to use the current directory since then anyone that runs it will see the files being dropped.
Unfortunately, my files won't run if there are not dropped in the current folder. I am currently using your amazing unam downloader but it's not very effective for bigger files since it takes too long until the file is executed.
Maybe, I have to create some good method of adding that since it's not very easy to do in a good way. Usually you never want to use the current directory since then anyone that runs it will see the files being dropped.
Isn't it fairly easy to do with CreateProcessA in C? Even powershell has -WorkingDirectory option. I didn't have any problems with detection's when running powershell commands with WinExec. I made a similar program in C that just writes binary data from an array to files in %temp% and runs them with powershell.
Isn't it fairly easy to do with CreateProcessA in C? Even powershell has -WorkingDirectory option. I didn't have any problems with detection's when running powershell commands with WinExec. I made a similar program in C that just writes binary data from an array to files in %temp% and runs them with powershell.
To get the current directory you would use something like GetCurrentDirectory https://docs.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-getcurrentdirectory and then you would have to create some dynamic code so that it only adds that part of the code to the program if it has to be used by any of the bound files. The biggest problem I have so far with GetCurrentDirectory is that it always adds up to 8 detections.
You have to store the current directory so that you can first use it when writing the file and then for when it will run it.
Isn't it fairly easy to do with CreateProcessA in C? Even powershell has -WorkingDirectory option. I didn't have any problems with detection's when running powershell commands with WinExec. I made a similar program in C that just writes binary data from an array to files in %temp% and runs them with powershell.
To get the current directory you would use something like GetCurrentDirectory https://docs.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-getcurrentdirectory and then you would have to create some dynamic code so that it only adds that part of the code to the program if it has to be used by any of the bound files. The biggest problem I have so far with GetCurrentDirectory is that it always adds up to 8 detections.
You have to store the current directory so that you can first use it when writing the file and then for when it will run it.
You don't need to add dynamic code to the binded executable you can set its current directory when starting it? I used this in C and had no increased detections:
HMODULE hModule = GetModuleHandle(NULL);
if (hModule != NULL)
{
GetModuleFileName(hModule, lists2, (sizeof(lists2)));
char *pos = strrchr(lists2, '\\');
if (pos != NULL) *pos = '\0';
SetCurrentDirectory(lists2);
}
Im surprised using GetCurrentDirectory gets flagged so much.
I meant that I need to make it "dynamic" code due to each files output location and name being configurable, it's fully possible that no file added will use the current directory in which case none of the current directory code should be added to the program. Even then I'm currently working on the miner and the web panel (with the little time that I have) so I wouldn't be able to add it in a while.
I meant that I need to make it "dynamic" code due to each files output location and name being configurable, it's fully possible that no file added will use the current directory in which case none of the current directory code should be added to the program. Even then I'm currently working on the miner and the web panel (with the little time that I have) so I wouldn't be able to add it in a while.
Can you add me on discord i sent you a request