PC Review Forums Newsgroups Microsoft AntiSpyware Spyware Application Compatibility Batch file looses directory context

Reply

Batch file looses directory context

 
Thread Tools Rate Thread
Old 07-01-2005, 10:20 AM   #1
Simon
Guest
 
Posts: n/a
Default Batch file looses directory context


When a batch file is launched from the run command, a
popup comes up asking for permission to allow it.

On allowing it the script runs but from the system32
directory, rather than the directory of the batch file
which is the behaviour or the run command

Once the batch file has been run once and the "remember
this action" is selected the command runs correctly.

Put this in a batch file
cd
pause

save to not your system32 directory. and run from the
start|run look at the output on the first run (when
antispyware intevenes) and the subsequent runs (when it
doesn't)

Regards

Simon
  Reply With Quote
Old 07-01-2005, 01:04 PM   #2
Bill Wates
Guest
 
Posts: n/a
Default Catastrophic bug !!!

>On allowing it the script runs but from the system32
>directory, rather than the directory of the batch file
>which is the behaviour or the run command


This bug is potentially catastrophic - a script could
completely mess up the system32 directory.

I disabled the script blocking feature immediately upon
noticing it.
  Reply With Quote
Old 09-01-2005, 05:52 AM   #3
Bill Sanderson
Guest
 
Posts: n/a
Default Re: Batch file looses directory context

Thanks - that's a good catch!

"Simon" <Simon@cmg.noemail> wrote in message
news:044e01c4f4aa$de2c0120$a501280a@phx.gbl...
> When a batch file is launched from the run command, a
> popup comes up asking for permission to allow it.
>
> On allowing it the script runs but from the system32
> directory, rather than the directory of the batch file
> which is the behaviour or the run command
>
> Once the batch file has been run once and the "remember
> this action" is selected the command runs correctly.
>
> Put this in a batch file
> cd
> pause
>
> save to not your system32 directory. and run from the
> start|run look at the output on the first run (when
> antispyware intevenes) and the subsequent runs (when it
> doesn't)
>
> Regards
>
> Simon



  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off