It is possible to launch an exe file using a third party program through the context menu.
My problem is that an exe file might be triggered by a script or by another application on which I don't have control.
How can I force every executable files to run using a third party program/script ?
Comodo Programs Manager has a running service that automatically monitor any installation of exe file. How do they proceed ? Is it possible to listen to specific events ?
I thought I could use a BATCH script by :
replacing the default registry key of
HKEY_CLASSES_ROOT\exefile\shell\open\commandby something like
path\to\my\script.bat "%1 %*"
in the script, do custom stuff like logging and then call the executable :
... echo %DATE% %TIME% %* >> "somewhere\logging.txt" ... :2 @REM Monitor file (same as context menu open with ...) path/to/monitoring.exe %* goto end ...
This would work for a PDF file for example. But it obviously doesn't work for executables because
path/to/monitoring.exe %*, when executed, is running the script again ... and I can't find a way to launch an executable without going through the registry file association.
Is it something possible ?