win 2k scripting
ok i need a command to change the file permissions on a folder
background: i need to lock down my computer so i wrote a script to first remove all shares (even c$, admin$ ipc$...) then it remaps them to random folders on my drive i then want to deny access to these folders to everyone so that they can not be acessed.
here is what i have so far.
md c:\goaway\A$
md c:\goaway\B$
...
md c:\goaway\Z$
REM this makes all the directories to be mapped they go to
net share A$ /delete
net share B$ /delete
...
net share Z$ /delete
net share ADMIN$ /delete
net share IPC$ /delete
REM this removes all the hidden shares
net share A$=c:\goaway\a$
net share B$=c:\goaway\b$
...
net share A$=c:\goaway\a$
REM this remaps all the shares to the folders.
Cacls c:\goaway\a$ /d everyone
Cacls c:\goaway\b$ /d everyone
...
Cacls c:\goaway\c$ /d everyone
REM this changes the permission to deny for the usergroup everyone the only problem is that i have to accept by pressing y and enter to confirm it, i cant have this confirm i need it to run with out confirmation. and help?
__________________
Donate Blood!
"Love is not finding the perfect person, but learning to see an imperfect person perfectly." -Sam Keen
|