View Full Version : batch file for share permissions


Shane
09-05-2006, 10:09 AM
Hi

I am looking for a way to change share permissions on folders via a batch
file . I have found xcacls works fine for security but not shares (as far as
I can tell). Any ideas?

Jerold Schulman
09-05-2006, 01:11 PM
On Tue, 5 Sep 2006 19:09:55 +1000, "Shane" <hccs@tpg.com.au> wrote:

>Hi
>
>I am looking for a way to change share permissions on folders via a batch
>file . I have found xcacls works fine for security but not shares (as far as
>I can tell). Any ideas?
>

Use RMTSHARE.EXE.
See tip 6353 » RMTShare.exe is in the public domain.
in the 'Tips & Tricks' at http://www.jsifaq.com

Jerold Schulman
Windows Server MVP
JSI, Inc.
http://www.jsiinc.com
http://www.jsifaq.com

Herb Martin
09-05-2006, 04:18 PM
"Shane" <hccs@tpg.com.au> wrote in message
news:44fd3e7e$1@dnews.tpgi.com.au...
> Hi
>
> I am looking for a way to change share permissions on folders via a
> batch file . I have found xcacls works fine for security but not shares
> (as far as I can tell). Any ideas?

SetAcl from SourceForge.net (free and practically always safe software.)

(Warning: SetAcl is very powerful with very few limitations but
due to this has one of the most complicated command lines of ANY
command line tool on any OS.*)

Maybe it is further complicated by being a 'Windows tool, designed
largely by Linux experts.'

--
Herb Martin, MCSE, MVP
Accelerated MCSE
http://www.LearnQuick.Com
[phone number on web site]

>

mutha
09-06-2006, 03:03 PM
Shane wrote:
Any ideas?

just use net share

Herb Martin
09-06-2006, 11:54 PM
"mutha" <muthamail@gmail.com> wrote in message
news:1157551386.644054.227130@p79g2000cwp.googlegroups.com...
>
> Shane wrote:
> Any ideas?
>
> just use net share

Net Share added "permissions" only recently, so using
this depends on the version of the OS you are using.

Win2000 and XP don't (seem to) have this; Win2003 does.

Do any of them support DENY or REMOVE? Help seems
to indicate that Win2003 does support remove either.


--
Herb Martin, MCSE, MVP
Accelerated MCSE
http://www.LearnQuick.Com
[phone number on web site]

>

Bertoldino
10-03-2006, 04:14 PM
Shane wrote:
> Hi
>
> I am looking for a way to change share permissions on folders via a
> batch file . I have found xcacls works fine for security but not
> shares (as far as I can tell). Any ideas?

search for "subinacl" :-)

but i remember something about win2003server... there is a native command,
right?

Mark V
10-03-2006, 05:40 PM
In microsoft.public.win2000.cmdprompt.admin Bertoldino wrote:

> Shane wrote:
>> Hi
>>
>> I am looking for a way to change share permissions on folders
>> via a batch file . I have found xcacls works fine for security
>> but not shares (as far as I can tell). Any ideas?
>
> search for "subinacl" :-)
>
> but i remember something about win2003server... there is a
> native command, right?

Thinking of regini.exe?
If that is included in other than a Resource Kit.
SUBINACL is better than regini from NT4 and 5.0 IMO.