📄 net.html
字号:
<p>Sets the information for <code>group</code> according to <code>level</code>.</p>
<dl>
<dt><strong><code>server</code> - Scalar String</strong>
<dd>
<p>The <code>server</code> on which to set the <code>group</code> information.</p>
</dd>
</li>
<dt><strong><code>group</code> - Scalar String</strong>
<dd>
<p>The <code>group</code> whose information you wish to set.</p>
</dd>
</li>
<dt><strong><code>level</code> - Scalar Int</strong>
<dd>
<p>The <code>level</code> of information you are supplying in <code>hash</code>.
Level can be one of 0 or 1. See <a href="#local_group_info_levels">LOCAL GROUP INFO LEVELS</a>.</p>
</dd>
</li>
<dt><strong><code>hash</code> - Hash Reference</strong>
<dd>
<p>The hash containing the required key/value pairs for <code>level</code>.</p>
</dd>
</li>
<dt><strong><code>error</code> - Scalar String</strong>
<dd>
<p>On failure, the <code>error</code> parameter will contain a value which specifies
which field caused the error. See <a href="#local_group_field_errors">LOCAL GROUP FIELD ERRORS</a>.</p>
</dd>
</li>
</dl>
<p>
</p>
<h2><a name="localgroupsetmembers__"><code>LocalGroupSetMembers()</code></a></h2>
<p>This function has not been implemented at present.</p>
<p>
</p>
<hr />
<h1><a name="net_get_functions">NET GET FUNCTIONS</a></h1>
<p>
</p>
<h2><a name="getdcname_server__domain__domaincontroller_">GetDCName(server, domain, domain-controller)</a></h2>
<p>Gets the <code>domain-controller</code> name for <code>server</code> and <code>domain</code>.</p>
<dl>
<dt><strong><code>server</code> - Scalar String</strong>
<dd>
<p>The <code>server</code> whose domain controller you wish to locate.</p>
</dd>
</li>
<dt><strong><a name="item_domain__2d_scalar_string"><code>domain</code> - Scalar String</a></strong>
<dd>
<p>The <code>domain</code> that <code>server</code> is a member of whose domain-controller
you wish the locate.</p>
</dd>
</li>
<dt><strong><a name="item_string"><code>domain-controller</code> - Scalar String (output)</a></strong>
<dd>
<p>The name of the <code>domain-controller</code> for the requested <code>domain</code>.</p>
</dd>
</li>
</dl>
<p>Note: This module does not implement the <code>NetGetAnyDCName()</code>API function
as this is obsolete.</p>
<p>
</p>
<hr />
<h1><a name="user_info_levels">USER INFO LEVELS</a></h1>
<p>Most of the <code>User*()</code> functions take a <code>level</code> parameter. This <code>level</code>
specifies how much detail the corresponding <code>hash</code> should contain (or in
the case of a <code>UserGet*()</code> function, will contain after the call). The
following <code>level</code> descriptions provide information on what fields should
be present for a given level. See <a href="#user_info_fields">USER INFO FIELDS</a> for a description of
the fields.</p>
<dl>
<dt><strong><a name="item_level_0">Level 0</a></strong>
<dd>
<p>name</p>
</dd>
</li>
<dt><strong><a name="item_level_1">Level 1</a></strong>
<dd>
<p>name, password, passwordAge, priv, homeDir, comment, flags, scriptPath</p>
</dd>
</li>
<dt><strong><a name="item_level_2">Level 2</a></strong>
<dd>
<p>name, password, passwordAge, priv, homeDir, comment, flags, scriptPath,
authFlags, fullName, usrComment, parms, workstations, lastLogon,
lastLogoff, acctExpires, maxStorage, unitsPerWeek, logonHours, badPwCount,
numLogons, logonServer, countryCode, codePage</p>
</dd>
</li>
<dt><strong><a name="item_level_3">Level 3</a></strong>
<dd>
<p>name, password, passwordAge, priv, homeDir, comment, flags, scriptPath,
authFlags, fullName, usrComment, parms, workstations, lastLogon, lastLogoff,
acctExpires, maxStorage, unitsPerWeek, logonHours, badPwCount, numLogons,
logonServer, countryCode, codePage, userId, primaryGroupId, profile,
homeDirDrive, passwordExpired</p>
</dd>
</li>
<dt><strong><a name="item_level_10">Level 10</a></strong>
<dd>
<p>name, comment, usrComment, fullName</p>
</dd>
</li>
<dt><strong><a name="item_level_11">Level 11</a></strong>
<dd>
<p>name, comment, usrComment, fullName, priv, authFlags, passwordAge, homeDir,
parms, lastLogon, lastLogoff, badPwCount, numLogons, logonServer,
countryCode, workstations, maxStorage, unitsPerWeek, logonHours, codePage</p>
</dd>
</li>
<dt><strong><a name="item_level_20">Level 20</a></strong>
<dd>
<p>name, fullName, comment, flags, userId</p>
</dd>
</li>
<dt><strong><a name="item_level_21">Level 21</a></strong>
<dd>
<p><strong>Not available in this implementation</strong></p>
</dd>
</li>
<dt><strong><a name="item_level_22">Level 22</a></strong>
<dd>
<p><strong>Not available in this implementation</strong></p>
</dd>
</li>
<dt><strong><a name="item_level_1003">Level 1003</a></strong>
<dd>
<p>password</p>
</dd>
</li>
<dt><strong><a name="item_level_1005">Level 1005</a></strong>
<dd>
<p>priv</p>
</dd>
</li>
<dt><strong><a name="item_level_1006">Level 1006</a></strong>
<dd>
<p>homeDir</p>
</dd>
</li>
<dt><strong><a name="item_level_1007">Level 1007</a></strong>
<dd>
<p>comment</p>
</dd>
</li>
<dt><strong><a name="item_level_1008">Level 1008</a></strong>
<dd>
<p>flags</p>
</dd>
</li>
<dt><strong><a name="item_level_1009">Level 1009</a></strong>
<dd>
<p>scriptPath</p>
</dd>
</li>
<dt><strong><a name="item_level_1010">Level 1010</a></strong>
<dd>
<p>authFlags</p>
</dd>
</li>
<dt><strong><a name="item_level_1011">Level 1011</a></strong>
<dd>
<p>fullName</p>
</dd>
</li>
<dt><strong><a name="item_level_1012">Level 1012</a></strong>
<dd>
<p>usrComment</p>
</dd>
</li>
<dt><strong><a name="item_level_1013">Level 1013</a></strong>
<dd>
<p>parms</p>
</dd>
</li>
<dt><strong><a name="item_level_1014">Level 1014</a></strong>
<dd>
<p>workstations</p>
</dd>
</li>
<dt><strong><a name="item_level_1017">Level 1017</a></strong>
<dd>
<p>acctExpires</p>
</dd>
</li>
<dt><strong><a name="item_level_1018">Level 1018</a></strong>
<dd>
<p>maxStorage</p>
</dd>
</li>
<dt><strong><a name="item_level_1020">Level 1020</a></strong>
<dd>
<p>unitsPerWeek, logonHours</p>
</dd>
</li>
<dt><strong><a name="item_level_1023">Level 1023</a></strong>
<dd>
<p>logonServer</p>
</dd>
</li>
<dt><strong><a name="item_level_1024">Level 1024</a></strong>
<dd>
<p>countryCode</p>
</dd>
</li>
<dt><strong><a name="item_level_1025">Level 1025</a></strong>
<dd>
<p>codePage</p>
</dd>
</li>
<dt><strong><a name="item_level_1051">Level 1051</a></strong>
<dd>
<p>primaryGroupId</p>
</dd>
</li>
<dt><strong><a name="item_level_1052">Level 1052</a></strong>
<dd>
<p>profile</p>
</dd>
</li>
<dt><strong><a name="item_level_1053">Level 1053</a></strong>
<dd>
<p>homeDirDrive</p>
</dd>
</li>
</dl>
<p>
</p>
<hr />
<h1><a name="user_info_fields">USER INFO FIELDS</a></h1>
<p>The following is an alphabetical listing of each possible field, together
with the data type that the field is expected to contain.</p>
<dl>
<dt><strong><code>acctExpires</code> - Scalar Int (UTC)</strong>
<dd>
<p>The time (as the number of seconds since 00:00:00, 1st January 1970) when
the account expires. A -1 in this field specifies that the account never
expires.</p>
</dd>
</li>
<dt><strong><code>authFlags</code> - Scalar Int (See USER_AUTH_FLAGS).</strong>
<dd>
<p>The level of authority that this use has. The value this can take depends
on the users group membership - this value is therefore read only and
cannot be set using <code>UserAdd()</code> or <code>UserSetInfo()</code>. Its value can be one
of:</p>
</dd>
</li>
</dl>
<pre>
User belongs to group Flag value
--------------------- ----------
Print Operators Win32API::Net::AF_OP_PRINT()
Server Operators Win32API::Net::AF_OP_SERVER()
Account Operators Win32API::Net::AF_OP_ACCOUNTS()</pre>
<dl>
<dt><strong><a name="item_badpwcount__2d_scalar_int"><code>badPwCount</code> - Scalar Int</a></strong>
<dd>
<p>The number of times that the user has failed to logon by specifying an
incorrect password.</p>
</dd>
</li>
<dt><strong><a name="item_codepage__2d_scalar_int"><code>codePage</code> - Scalar Int</a></strong>
<dd>
<p>The code page that this user uses.</p>
</dd>
</li>
<dt><strong><a name="item_comment__2d_scalar_string"><code>comment</code> - Scalar String</a></strong>
<dd>
<p>The comment associated with this user account. This can be any string
(apparently of any length).</p>
</dd>
</li>
<dt><strong><a name="item_countrycode__2d_scalar_int"><code>countryCode</code> - Scalar Int</a></strong>
<dd>
<p>The country code that this user uses.</p>
</dd>
</li>
<dt><strong><a href="../../lib/Pod/perlfunc.html#item_flags"><code>flags</code></a> - Scalar Int (Bitwise OR of USER_FLAGS)</strong>
<dd>
<p>The flags for this user. See <a href="#user_flags">USER FLAGS</a>.</p>
</dd>
</li>
<dt><strong><a name="item_fullname__2d_scalar_string"><code>fullName</code> - Scalar String</a></strong>
<dd>
<p>The users' full name.</p>
</dd>
</li>
<dt><strong><a name="item_homedir__2d_scalar_string"><code>homeDir</code> - Scalar String</a></strong>
<dd>
<p>The home directory of the user. This can be either a UNC path or an
absolute path (drive letter + path). Can be the empty string ("").</p>
</dd>
</li>
<dt><strong><a name="item_homedirdrive__2d_scalar_string"><code>homeDirDrive</code> - Scalar String</a></strong>
<dd>
<p>The home directory drive that the users home directory is mapped to
(assuming that the specified home directory is a UNC path).</p>
</dd>
</li>
<dt><strong><code>lastLogon</code> - Scalar Int (UTC)</strong>
<dd>
<p>The time (as the number of seconds since 00:00:00, 1st January 1970)
that the user last logged on.</p>
</dd>
</li>
<dt><strong><code>lastLogoff</code> - Scalar Int (UTC)</strong>
<dd>
<p>The time (as the number of seconds since 00:00:00, 1st January 1970)
that the user last logged off .</p>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -