<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; VBS: Win32_Trustee class]]></title>
	<link rel="self" href="https://forum.script-coding.com/extern.php?action=feed&amp;tid=7398&amp;type=atom" />
	<updated>2012-08-01T02:45:59Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.script-coding.com/viewtopic.php?id=7398</id>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62230#p62230" />
			<content type="html"><![CDATA[<p>И ведь точно - как часики всё работает ! <img src="//forum.script-coding.com/img/smilies/wink.png" width="15" height="15" /><br />Видать я не там смотрел наличие прав...</p>]]></content>
			<author>
				<name><![CDATA[Евген]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25253</uri>
			</author>
			<updated>2012-08-01T02:45:59Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62230#p62230</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62221#p62221" />
			<content type="html"><![CDATA[<p>Не обращал внимания, завтра обязательно гляну...</p>]]></content>
			<author>
				<name><![CDATA[Евген]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25253</uri>
			</author>
			<updated>2012-07-31T16:32:37Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62221#p62221</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62214#p62214" />
			<content type="html"><![CDATA[<p>Здравствуйте, <strong>Евген</strong>!<br />У меня сценарий №4 на указанной ОС и с указанными входными данными работает исправно.<br />Вы смотрели DACL только на вкладке &quot;Безопасность&quot; или заглядывали ещё и в раздел &quot;Дополнительно&quot;?<br />Дело в том, что при такой области действия обобщённый статус ACE (вне зависимости от маски) обозначается как &quot;Особые разрешения&quot; и иногда, попросту говоря, бывает &quot;не по глазам&quot;. Я сам попадал в такую ситуацию.</p>]]></content>
			<author>
				<name><![CDATA[Dmitrii]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=13351</uri>
			</author>
			<updated>2012-07-31T12:52:39Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62214#p62214</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62156#p62156" />
			<content type="html"><![CDATA[<p><strong>Dmitrii </strong> приветствую !<br />Есть вопрос по четвёртому <a href="http://forum.script-coding.com/viewtopic.php?id=5142">сценарию</a>, он у меня на XP SP3 не работает. Ввожу &quot;Все&quot;, выбираю корень диска C:\ ,затем 12, затем 2, потом выводит &quot;Успешное завершение&quot;<br />Но в просмотре прав только появляется учётка &quot;Все&quot; без прав <img src="//forum.script-coding.com/img/smilies/sad.png" width="15" height="15" /><br />Что делаю не так ?</p>]]></content>
			<author>
				<name><![CDATA[Евген]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=25253</uri>
			</author>
			<updated>2012-07-30T10:25:05Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62156#p62156</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62090#p62090" />
			<content type="html"><![CDATA[<p><strong>НеОчень</strong>, <a href="http://forum.oszone.net/post-1933457-10.html">здесь</a> есть ещё один пример, который, возможно, будет полезен.</p>]]></content>
			<author>
				<name><![CDATA[Dmitrii]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=13351</uri>
			</author>
			<updated>2012-07-27T18:38:25Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62090#p62090</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62085#p62085" />
			<content type="html"><![CDATA[<p>спасибо!!!</p>]]></content>
			<author>
				<name><![CDATA[НеОчень]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27967</uri>
			</author>
			<updated>2012-07-27T12:49:14Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62085#p62085</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62084#p62084" />
			<content type="html"><![CDATA[<p><strong>НеОчень</strong>, спросите там, где Вы нашли его. А я рекомендую посмотреть <a href="http://forum.oszone.net/post-1193502.html#post1193502">это</a>.</p>]]></content>
			<author>
				<name><![CDATA[alexii]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=1844</uri>
			</author>
			<updated>2012-07-27T12:42:57Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62084#p62084</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62083#p62083" />
			<content type="html"><![CDATA[<p><span style="color: Green"><strong>Н</strong></span>у так то да, это тож читал<span style="color: Green"><strong>.</strong></span><br /><span style="color: Green"><strong>Т</strong></span>огда подробнее <img src="//forum.script-coding.com/img/smilies/smile.png" width="15" height="15" /> вот это Array(1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0) , что за множество?<br /><span style="color: Green"><strong>К</strong></span>ак тогда преобразовать SIDString в SID?</p>]]></content>
			<author>
				<name><![CDATA[НеОчень]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27967</uri>
			</author>
			<updated>2012-07-27T12:21:07Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62083#p62083</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62080#p62080" />
			<content type="html"><![CDATA[<div class="quotebox"><blockquote><p>но все равно непонятно что это :</p></blockquote></div><p><a href="http://msdn.microsoft.com/en-us/library/windows/desktop/aa394501(v=vs.85).aspx">Win32_Trustee class</a>:<br /></p><div class="quotebox"><blockquote><p><strong>SID</strong></p><p>&nbsp; &nbsp; Data type: <span style="color: red"><strong>uint8 array</strong></span><br />&nbsp; &nbsp; Access type: Read/write<br />&nbsp; &nbsp; Qualifiers: WritePrivileges (SeSecurityPrivilege, SeRestorePrivilege)</p><p>&nbsp; &nbsp; SID that uniquely identifies a user or group.</p></blockquote></div>]]></content>
			<author>
				<name><![CDATA[alexii]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=1844</uri>
			</author>
			<updated>2012-07-27T12:03:51Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62080#p62080</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62079#p62079" />
			<content type="html"><![CDATA[<p>Прочитал, много в чем разобрался и много чего интересного узнал, но все равно непонятно что это : </p><p>objTrustee.Properties_.Item(&quot;SID&quot;) = Array(1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0)<br />?</p>]]></content>
			<author>
				<name><![CDATA[НеОчень]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27967</uri>
			</author>
			<updated>2012-07-27T11:28:19Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62079#p62079</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62061#p62061" />
			<content type="html"><![CDATA[<p>уууу, спасибо! иду читать</p>]]></content>
			<author>
				<name><![CDATA[НеОчень]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27967</uri>
			</author>
			<updated>2012-07-26T16:53:19Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62061#p62061</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62060#p62060" />
			<content type="html"><![CDATA[<p>Помнится уважаемый <strong>Dmitrii </strong><a href="http://forum.script-coding.com/viewtopic.php?id=5142">эту тему подробно осветил</a>.</p>]]></content>
			<author>
				<name><![CDATA[dab00]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27085</uri>
			</author>
			<updated>2012-07-26T16:52:08Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62060#p62060</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[VBS: Win32_Trustee class]]></title>
			<link rel="alternate" href="https://forum.script-coding.com/viewtopic.php?pid=62057#p62057" />
			<content type="html"><![CDATA[<p>Добрый день. Хочу написать скрипт, который будет для троих пользователей расшаривать диск p:\ на полный доступ , и для одного на чтение.<br />Нашел пример <br /></p><div class="codebox"><pre><code> Const PERM_READ           = 1179817
Const PERM_MODIFY         = 1245631
Const PERM_FULL           = 2032127
 
ShareName = &quot;ShareName&quot;
SharePath = &quot;D:\Install&quot;
ShareDescription = &quot;Description&quot;
 
Set objWMIService = GetObject(&quot;WINMGMTS:{impersonationLevel=impersonate,(Security)}!\\.&quot;)
 
Set objSecDescClass = objWMIService.Get(&quot;Win32_SecurityDescriptor&quot;)
Set objSecDesc = objSecDescClass.SpawnInstance_()
Set objTrustee = objWMIService.Get(&quot;Win32_Trustee&quot;).SpawnInstance_
objTrustee.Domain = Null
objTrustee.Name = &quot;User&quot;
objTrustee.Properties_.Item(&quot;SID&quot;) = Array(1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0)
Set objACE = objWMIService.Get(&quot;Win32_Ace&quot;).SpawnInstance_
objACE.Properties_.Item(&quot;AccessMask&quot;) = PERM_READ
objACE.Properties_.Item(&quot;AceFlags&quot;) = 3
objACE.Properties_.Item(&quot;AceType&quot;) = 0
objACE.Properties_.Item(&quot;Trustee&quot;) = objTrustee
objSecDesc.Properties_.Item(&quot;DACL&quot;) = Array(objACE)
 
Set objShare = objWMIService.Get(&quot;Win32_Share&quot;)
 
Set objInParam = objShare.Methods_(&quot;Create&quot;).InParameters.SpawnInstance_()
objInParam.Properties_.Item(&quot;Access&quot;) = objSecDesc
objInParam.Properties_.Item(&quot;Description&quot;) = ShareDescription
objInParam.Properties_.Item(&quot;Name&quot;) = ShareName
objInParam.Properties_.Item(&quot;Path&quot;) = SharePath
objInParam.Properties_.Item(&quot;Type&quot;) = 0
set objMy = objShare.ExecMethod_(&quot;Create&quot;, objInParam)</code></pre></div><p>Но не все моменты понятны...<br />Например, вот это<br /></p><div class="codebox"><pre><code>objTrustee.Properties_.Item(&quot;SID&quot;) = Array(1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0)</code></pre></div><p>? Подскажите, пжалуста, что здесь задается? </p><p>зы\ только не отправляйте читать про класс win32_Trustee, читал, не помогло</p>]]></content>
			<author>
				<name><![CDATA[НеОчень]]></name>
				<uri>https://forum.script-coding.com/profile.php?id=27967</uri>
			</author>
			<updated>2012-07-26T14:10:14Z</updated>
			<id>https://forum.script-coding.com/viewtopic.php?pid=62057#p62057</id>
		</entry>
</feed>
