50
•
Yangi hunarmandchilik
FileSystemAccessRule
topshirmoq
•
Mavjud ruxsatnomalar to'plamiga yangi ACL qoidasini qo'shing
•
Mavjud faylga yoki papkaga yangi ACL-ni qo'llang
Set-ACL
Qoidani o'zi ishlab
chiqish uchun biz uni yaratishimiz kerak
FileSystemAccessRule
shunga o'xshash
konstruktorga ega:
Identity String, FileSystemRights, AccessControlType
.
$ ACL = Get-ACL -Path "Test1.txt" $ AccessRule = New-Object
System.Security.AccessControl.FileSystemAccessRule ("TestUser1", "Read", "Allow") $
ACL.SetAccessRule ($ AccessRule) $ ACL | Set-Acl -Path "Test1.txt" (Get-ACL -Path
"Test1.txt"). Kirish | Format-Table IdentityReference, FileSystemRights, AccessControlType,
IsInherited, InheritanceFlags –AutoSize
13 – rasm. 2-command
Yuqoridagi jarayonda ko'rinib turganidek, uchun ruxsatlarni va tuzuvchilarni
o'zgartirish tez va oson
FileSystemAccessRule
ob'ekt to'g'ridan-to'g'ri.
Dostları ilə paylaş: