> I was testing a script file and was not actually expecting it to run in the > way it did. It wrote to the c:\ drive when I fully expected it to write to > the user's profile. This stumped me.
Beware that the current user directory might be set at a later time during logon process. The default current directory for the system used to be %SystemDrive%. It was a well-known bug that if a "c:\explorer.exe" file does exist, it would run instead of "c:\windows\system32\explorer.exe", because the "shell" registry key equals "explorer.exe" (without full path). Regards, - Nicolas RUFF Security Researcher @ EADS-CCR --------------------------------------------------------------------------- ---------------------------------------------------------------------------
