Here's the situation: you want to run a program on your PC, but a nasty error message pops up which may read something like this:
This operation has been cancelled due to restrictions in effect on this computer. Please contact your system administrator.
Isn't this annoying? It's a Windows feature called Software Restriction Policies that sysadmins use to stop you running certain programs. Thankfully there are a couple of tricks you can use to defeat this unreasonable restriction. The first task is to figure out why the program has been blocked. Windows allows a list of programs to be blocked based on the name of the program - this list is located in the registry at the following location:
HKEY_CURRENT_USER\Software\Microsoft\Windows\Policies\Explorer\DisallowRun
So, you can either remove the entry (although your sysadmin's policy may mean it will be replaced the next time you log in to your domain - and this might trigger some alert(!)), but the simplest way is to just rename the executable that you want to run. So if you see that Skype.exe is blocked, simply rename this to Skype2.exe and it should work.
However, as this is far too simple to circumvent, your crafty sysadmin might have enforced another Windows feature which blocks the program based on its size on disk, or a digest hash of the file contents. This appears to be very difficult to get around, but with a bit of creativity it is possible to defeat this restriction. A feature of Windows executable programs means that you can append a number of additional bytes at the end of the file without affecting the program functionality at all - the program will run just as before and ignores the excess bytes. So by appending say 10k of random bytes at the end of the file this will completely change the digest hash and also the file size, meaning the program can be run. For your reference, the list of files and their hashes/sizes are stored in this registry location:
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Safer\CodeIdentifiers\0\Hashes\{GUIDs}
Adding bytes to the end of a file is not straightforward and would be very tedious and time-consuming to do manually, and you will probably need to add a significant number of bytes to change the digest hash. This is where this little utility I wrote comes in handy. It allows you to select a file, enter the number of random bytes to append and will then create a completely new executable with an underscore character '_' at the beginning of the file (your original executable is unchanged). For example, if you select eMule.exe a new file called _eMule.exe will be created with the additional bytes at the end. You should be able to run this without any problems.
Here's the program and full Delphi source code. Use it entirely at your own risk - if your boss/sysadmin finds that you are using this and you get fired this is your problem. I cannot guarantee 100% that the program is free of bugs and that the created executable will function in a way that is 100% identical to the original. All I can say is that I have run this on a number of different programs with no obvious problems. As always, if you want to confirm this is safe - use the source, Luke!
I'm open to suggestions about what to do if this program itself ends up being blocked!
Final note: I don't condone the use of this program to run file-sharing programs at work, these programs are blocked for a good reason as they consume enormous amounts of bandwidth and if you run them your sysadmin is likely to spot the additional traffic and investgate anyway. I created fileappender for 2 reasons, firstly it was the pure challenge and satisfaction of beating Microsoft's security, and secondly so I could run file-sharing programs when stuck in a hotel on a business trip so I could download movies/music to pass the time. I have never run file-sharing programs at work and have no intention of ever doing so.
If you have any questions or want to report a bug please drop me a line at wuul [at] lycos.co.uk