This is a patch to go from libwin32 v0.171 to v0.172. This is yet another
unofficial patch that corresponds to the libwin32 that ships with ActivePerl
build 626. Apply using GNU patch as follows:
# get libwin32-0.16.zip, libwin32-0.171.patch, libwin32-0.172.patch first
unzip libwin32-0.16.zip
rename libwin32-0.16 libwin32-0.172
cd libwin32-0.172
patch -p1 -N < ../libwin32-0.171.patch
patch -p1 -N < ../libwin32-0.172.patch
Note that the patch for v0.171 must be applied first.
Enjoy.
Gurusamy Sarathy
gsar@ActiveState.com
------------------------------------8<------------------------------------
diff -urN libwin32-0.171/APIFile/File.pm libwin32-0.172/APIFile/File.pm
--- libwin32-0.171/APIFile/File.pm Mon May 14 00:12:25 2001
+++ libwin32-0.172/APIFile/File.pm Mon May 14 00:14:07 2001
@@ -839,7 +839,7 @@
C<$sOldFileName> is the path to the file to be copied.
C<$sNewFileName> is the path to where the file should be copied.
-Note that you can E
- Win32API::Net - Perl interface to the Windows NT LanManager API account management functions.
-Win32API::Net - Perl interface to the Windows NT LanManager API account
-management functions.
-
-
-use Win32API::Net;
-
+ use Win32API::Net;
-As of version 0.08 of this module, the behaviour relating to empty strings
+ As of version 0.08 of this module, the behaviour relating to empty strings
in input hashes has changed. The old behaviour converted such strings to
the NULL pointer. The underlying API uses this value as an indication to
not change the value stored for a given field. This meant that you were not
-able to clear (say) the logonScript field for a user using
-
-The new behaviour is to leave the string as an empty C string which will
+able to clear (say) the logonScript field for a user using UserSetInfo(). The new behaviour is to leave the string as an empty C string which will
allow fields to be cleared. To pass a NULL pointer to the underlying
API call (and thus, to leave the field as it was), you need to set the
-corresponding field to
-WARNING: THIS IS AN INCOMPATIBLE CHANGE.
-EXISTING SCRIPTS THAT RELIED ON PRIOR BEHAVIOR MAY NEED TO BE MODIFIED.
-
+corresponding field to WARNING: THIS IS AN INCOMPATIBLE CHANGE.
+EXISTING SCRIPTS THAT RELIED ON PRIOR BEHAVIOR MAY NEED TO BE MODIFIED.
-Win32API::Net provides a more complete wrapper for the account management
+ Win32API::Net provides a more complete wrapper for the account management
parts of the NT LanManager API than do other similar packages. Most of what
-you can achieve with the native C++ API is possible with this package -
-albeit in a more Perl like manner by using references to pass information
-to and from functions.
-
-
-For an understanding of the environment in which these functions operate
-see
-DATA STRUCTURES.
-
-
-The following groups of functions are available:
-
-
-All functions return 0 on failure and 1 on success. Use the
-
-
-References to hashes and arrays are used throughout this package to pass
-information into and out of functions.
-
+you can achieve with the native C++ API is possible with this package - albeit
+in a more Perl like manner by using references to pass information to and
+from functions. For an understanding of the environment in which these functions operate see
+DATA STRUCTURES. The following groups of functions are available: All functions return 0 on failure and 1 on success. Use the
+
+ References to hashes and arrays are used throughout this package to pass
+information into and out of functions.
+
-
-Or more directly:
-
-
-
+ Or more directly:
-
-Or more directly:
-
-
-
-Please note: Any
-See EXAMPLES and the test.pl script for examples of usage.
-
+ Or more directly: Please note: Any See EXAMPLES and the test.pl script for examples of usage.
-Most the the functions in the underlying API allow the programmer to pass
+ Most the the functions in the underlying API allow the programmer to pass
specify at runtime the amount of information that is supplied to the
-function. For example, the
-For any function that takes a reference to a hash as input, the programmer
+function. For example, the For any function that takes a reference to a hash as input, the programmer
is expected to provide appropriate keys and corresponding values as well as
the level parameter. The called function will then takes the values out of
the supplied hash and build the approprite structure to pass to the
-underlying API function.
-
-
-For any function that takes a reference to a hash to recieve output, the
+underlying API function. For any function that takes a reference to a hash to recieve output, the
function will first clear any keys an corresponding values in the supplied
hash. It will call the underlying API call and will then return in the hash
-any keys and values that are applicable at the requested level.
-
-
-Example:
-
-
-The Example: The
-
-By default, Win32API::Net exports no symbols into the callers namespace.
-The following tags can be used to selectively import symbols into the main
-namespace.
-
-
-Exports all symbols needed for the
-Exports all symbols needed for the
-Exports all symbols needed for the
-Exports all symbols needed for the
-
-The
-Administrator or Account Operator group membership is required to
+and value - namely name/requested-users-name. If called with a level
+of
+ By default, Win32API::Net exports no symbols into the callers namespace.
+The following tags can be used to selectively import symbols into the
+main namespace.
+ The Administrator or Account Operator group membership is required to
successfully execute most of these functions on a remote server or on a
computer that has local security enabled. Administrator privileges are
-required to add an Administrator Privilege account. There are some
+required to add an Administrator Privilege account. There are some
exceptions to this whereby a user can change some of their own settings
where these don't conflict with 'administrative information' (e.g. full
-name).
-
-
-The server field can be the empty string, in which case the function defaults to
-running on the local computer. If you leave this field blank then you
-should ensure that you are running the function on a PDC or BDC for your
-current domain. Use the support function
-All functions in this section are 'DOMAIN functions'. This means that, for
-example, the
-The following functions are available.
-
-
-
-Add a new user account. The user name is taken from the name-key's value in the supplied hash.
-
+name). The All functions in this section are 'DOMAIN functions'. This means that,
+for example, the The following functions are available.
+ Add a new user account. The user name is taken from the
+
-Level of information provided in hash. This can be either 1, 2 or 3. See USER INFO LEVELS.
-
-
+
+appropriate keys and values required for
-
-Changes the password for user. If the policy of the machine/domain only allows password changes if the user is logged on then the user
+See USER FIELD ERRORS for more information about what values this can
+take.
+
+ Changes the password for
-The server on which to change the password.
-
-
-The name of the user whose password is being changed.
-
-
-The existing password for user.
-
-
-The new password for user.
-
-
-
-Deletes the specified user account. Administrator or Account Operator privilege is required to execute
-this function.
-
-
-The user account to delete.
-
-
-
-Enumerates all the accounts on server that satisfy filter. Unlike the
-
-The server on which to enumerate the accounts satisfying filter.
-
-
-The array that will hold the names of all users on server whose accounts match filter.
-
-
-The filter to apply (see USER ENUM FILTER). This argument is optional and if not present a default of FILTER_NORMAL_ACCOUNT is used.
-
-
-
-Get the global groups for which user is a member. It returns the group names in array. Unlike the
-The server from which to get the groups of which user is a member.
-
-
-The user whose group membership you wish to examine.
-
-
-The array that will contain the group names to which user belongs.
-
-
-
-Returns the information at the specified level for the named user
-in hash.
-
+
+ Deletes the specified
+ Enumerates all the accounts on server that satisfy
+ Get the global groups for which
-The server from which to get the requested information about user.
-
-
-The user whose information you want.
-
-
-One of: 0, 1, 2, 3, 10, 11 and 20. See USER INFO LEVELS.
-
-
+
+ Returns the information at the specified
-
-Gets the names of the local groups of which user is a member. Unlike the
-The server from which to get the local groups of which user is a member.
-
-
-The user whose local group membership you wish to enumerate.
-
-
-The array that will hold the names of the local groups to which user
+requested. See USER INFO FIELDS for information about which keys are
+present in a given level.
+
+ Gets the names of the local groups of which
-Either
-This field can take no other values.
-
-
-
-This function is not currently implemented.
-
-
-
-This function is not currently implemented.
-
-
-
-Sets the (global) group membership for user to the specified groups. Unlike the API function
-The server on which you wish to set the group membership for user.
-
-
-The user whose group membership you wish to set.
-
-
-The array containing the (global) group names to set the users membership of.
-
-
-This function will fail if any of the group names specified do not exist.
-
-
-
-Sets the info for user according to the information contained in hash
-for level (see USER INFO LEVELS).
-
-
-The server on which you wish to change the info for user.
-
-
-The user whose info you wish to change.
-
-
+ This field can take no other values.
+ This function is not currently implemented.
+ This function is not currently implemented.
+ Sets the (global) group membership for This function will fail if any of the group names specified do not exist.
+ Sets the info for
+individual properties of the named
-Provides information on which field in hash were not properly specified. See USER FIELD ERRORS for more information about what values can be returned in this field.
-
-
-
-The
-Administrator or Account Operator group membership is required to
-successfully execute most of these functions on a remote server or on a
-computer that has local security enabled.
-
-
-The server field can be the empty string, in which case the function defaults to
-running on the local computer. If you leave this field blank then you
-should ensure that you are running the function on a PDC or BDC for your
-current domain. Use the support function
-The following functions are available.
-
-
-
-Adds the specified group.
-
-
-The server on which to add the group.
-
-
-The level of information contained in hash. This can be one of 0, 1 or 2. See GROUP INFO LEVELS.
-
-
-A hash containing the required key/value pairs for level.
-
-
-Provides information on which field in hash was not properly specified. See GROUP FIELD ERRORS for more information about what values can be returned in this field.
-
-
-
-Adds the specified user to the specified group.
-
-
-
-Deletes the specified global group.
-
-
-The group to delete.
-
-
-
-Deletes the specified user from the specified group.
-
-
-
-Enumerates all the global groups on the server. Unlike the API call
-
+ The Administrator or Account Operator group membership is required to
+successfully execute most of these functions on a remote server or on
+a computer that has local security enabled. The The following functions are available.
+ Adds the specified group.
+ Adds the specified
+ Deletes the specified global group.
+ Deletes the specified user from the specified group.
+ Enumerates all the global groups on the server. Unlike the API call
+
+
-An array that, on return, will contain the group names.
-
-
-
-Retrieves level information for group returning information in
-hash.
-
-
-The server from which to get the group information.
-
-
-The group whose information you wish to obtain.
-
-
-The level of information you wish to retrieve. This can be one of 1, 2 or 3. See GROUP INFO LEVELS.
-
-
+
+ Retrieves
-
-Returns (in array) the users belonging to group. Unlike the API call
-The server from which to get the group information.
-
-
-The group whose users you wish to obtain.
-
-
+ Returns (in
-
-Sets the information for group according to level.
-
-
-The group whose information you wish to set.
-
-
-The level of information you are supplying in hash. Level can be one of 0, 1 or 2. See GROUP INFO LEVELS.
-
-
-The hash containing the required key/value pairs for level.
-
-
-On failure, the error parameter will contain a value which specifies which field caused the
-error. See GROUP FIELD ERRORS.
-
-
-
-
-Sets the membership of group to contain only those users specified in array. This function will fail if any user names contained in the array are not
-valid users on server. On successful completion
-group will contain only the users specified in array. Use the functions Sets the information for
-The group to set the membership of.
-
-
-The array containing the names of all users who will be members of group.
-
-
-
-The
-Administrator or Account Operator group membership is required to
+
+ Sets the membership of
+ The Administrator or Account Operator group membership is required to
successfully execute most of these functions on a remote server or on a
-computer that has local security enabled.
-
-
-The server field can be the empty string, in which case the function defaults to
-running on the local computer. If you leave this field blank then you
-should ensure that you are running the function on a PDC or BDC for your
-current domain. Use the support function
-The following functions are available.
-
-
-
-Adds the specified group. The name of the group is contained in the name
-key of hash.
-
-
-The server on which to add the group.
-
-
-The level of information contained in hash. This can be one of 0 or 1. See LOCAL GROUP INFO LEVELS.
-
-
-A hash containing the required key/value pairs for level.
-
-
-Provides information on which field in hash wasn't properly specified. See LOCAL GROUP FIELD ERRORS for more information about what values this can take.
-
-
-
-This function is obselete in the underlying API and has therefore not been
-implemented. Use
-
-Adds the specified users (members) to the local group. Unlike the API
-function
-The group to add the members to.
-
-
-The array containing the members to add to group.
-
-
-
-Delete the specified local group.
-
-
-The group to delete.
-
-
-
-This function is obselete in the underlying API and has therefore not been
-implemented. Use
-
-Delete the specified users (members) of the local group. Unlike the API
-function
-The group to delete the members from.
-
-
-The array containing the members to delete from group.
-
-
-
-Enumerates all the local groups on the server. Unlike the API call
- The The following functions are available.
+ Adds the specified group. The name of the group is contained in the
+ This function is obselete in the underlying API and has therefore not
+been implemented. Use
+ Adds the specified users (members) to the local group. Unlike the API
+function
+ Delete the specified local group.
+ This function is obselete in the underlying API and has therefore not
+been implemented. Use
+ Delete the specified users (members) of the local group. Unlike the API
+function
+ Enumerates all the local groups on the server. Unlike the API call
+
+
-The array to hold the group names.
-
-
-
-Retrieves level information for group.
-
-
-The server from which to get the group information.
-
-
-The group whose information you wish to obtain.
-
-
-The level of information you wish to retrieve. This can be 0 or 1. See LOCAL GROUP INFO LEVELS.
-
-
+
+ Retrieves
-
-Retrieves the users belonging to group. Unlike the API call
-
-The server from which to retrieve the group information.
-
-
-The group whose users you wish to obtain.
-
-
+ Retrieves the users belonging to
-
-Sets the information for group according to level.
-
-
-The group whose information you wish to set.
-
-
-The level of information you are supplying in hash. Level can be one of 0 or 1. See LOCAL GROUP INFO LEVELS.
-
-
-The hash containing the required key/value pairs for level.
-
-
-On failure, the error parameter will contain a value which specifies which field caused the
-error. See LOCAL GROUP FIELD ERRORS.
-
-
-
-This function has not been implemented at present.
-
-
-
-
-Gets the Sets the information for
-The server whose domain controller you wish to locate.
-
-
-The domain that server is a member of whose domain-controller you wish the locate.
-
-
-The name of the
-Note: This module does not implement the
-
-Most of the
+ This function has not been implemented at present.
+
+ Gets the Note: This module does not implement the
+ Most of the
+
+
+
+
+authFlags, fullName, usrComment, parms, workstations, lastLogon, lastLogoff,
+acctExpires, maxStorage, unitsPerWeek, logonHours, badPwCount, numLogons,
+logonServer, countryCode, codePage, userId, primaryGroupId, profile,
+homeDirDrive, passwordExpired
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-The following is an alphabetical listing of each possible field, together
-with the data type that the field is expected to contain.
-
+ The following is an alphabetical listing of each possible field, together
+with the data type that the field is expected to contain.
+
+
-
+
+
+
+
-The flags for this user. See USER FLAGS.
-
-
+
+
+
-The time (as the number of seconds since 00:00:00, 1st January 1970) that
-the user last logged on.
-
-
-The time (as the number of seconds since 00:00:00, 1st January 1970) that
-the user last logged off .
-
-
-The times at which the user can logon. This should be an integer array with
-21 elements. Each element represents an 8 hour period and each bit
-represents represents an hour. Only the lower byte of each integer is used.
-If this is left undefined then no restrictions are placed on the account.
-
-
-The logon server for this user. Under Windows NT, this value cannot be set
-and will always have the value '\\*' when queried.
-
-
-The current release of Windows NT does not implement disk quotas so it is
-believed that the value of this key is ignored.
-
-
-The user name that this request applies to. Most of the functions take the
-user name as a separate argument. In general, the user name provided should
-be the same as that in the one provided in the hash.
-
-
-The number of times that the named user has successfully logged on to this
-machine/domain.
-
-
-The value of this key can be used by applications. There are none known to
-to author that use it, although it could be used to hold adminitrative
+
+
+
+
+
+
-The profile that is associated with the named user. This can be UNC path, a
-local path or undefined.
-
-
+
+
+
-A comma-separated string containing upto 8 workstation that the named user
-can login to. Setting a value for this key will then allow the named user
-to login to only those computers named.
-
-
-The user id associated with this user This value is generated by the system
-and cannot be set or changed using the
-The following is an alphabetical listing of the user flags. The flags key (see USER INFO FIELDS) should be the bitwise OR of one or more of these values.
-
+ The following is an alphabetical listing of the user flags.
+The
+
+
+
+
-Lock out this account (or this account has been locked out due to security
-policy - i.e. badLogonCount is greater than your policy allows). This value
-can be cleared but not set by a
+
+
+
+
-The account represents a Windows NT Backup Domain Controller account in the
-domain.
-
-
-To quote the Microsoft Documentation <em>"This is an account
-for users whose primary account is in another domain. This account provides
+
+
-Please note that these are implemented as functions and are therefore
+ Please note that these are implemented as functions and are therefore
called in the same way as other functions. You should typically use them
-like:
-
-
-
-
-
- UserModalsGet()
UserModalsSet()
-
-
-
- LocalGroupAddMember()
LocalGroupDelMember()
LocalGroupSetMembers()
NAME
+NAME
+
-SYNOPSIS
-SYNOPSIS
+
-NOTE ON VERSIONS PRIOR TO 0.08
-NOTE ON VERSIONS PRIOR TO 0.08
+UserSetInfo().
-
-undef
.
-
-undef
.
-DESCRIPTION
-DESCRIPTION
+
-
-Win32::GetLastError()
function to find out more information on why a function failed. In
-addition, some functions that take a hash reference to pass information in
-(e.g. UserAdd()
) have a last argument that will allow more detailed information on which
-key/value pair was not properly specified.
-
-
-Using References
-Win32::GetLastError()
function to find out more information on why a
+function failed. In addition, some functions that take a hash reference
+to pass information in (e.g. UserAdd()
) have a last argument that will
+allow more detailed information on which key/value pair was not properly
+specified.Using References
+
-
-
+ $href = \%someHash;
- UserAdd(server, 2, $hRef);
-
- UserAdd(server, 2, \%someHash);
-
-
+ $href = \%someHash;
+ UserAdd(server, 2, $hRef);
+
+ UserAdd(server, 2, \%someHash);
+
+
+ $aref = \@someArray;
- UserEnum(server, $aref);
-
- UserEnum(server, \@someArray);
-
-*Get*()
or *Enum()
operation will first clear the contents of the input hash or array being
-referenced.
-
-
+ $aref = \@someArray;
+ UserEnum(server, $aref);
+
+ UserEnum(server, \@someArray);
+
+*Get*()
or *Enum()
operation will first clear the
+contents of the input hash or array being referenced.
-DATA STRUCTURES
-DATA STRUCTURES
+NetUserGetInfo()
call allows the programmer to specify levels of 0, 1, 2, 3 (and others).
-Having specified this level, the function returns a structure that will
-contain different fields. For a level 0
, the function returns a structure that has only one field. For a supplied
-level of 1, the function returns a structure with 8
fields. The programmer needs to know in advance what fields should be
-provided or will be returned for a given level. This mechanism works very
-will since it effectively overloads functions without having to use
-different function prototypes. Perl provides better higher level data
-structures in the form of arrays and hashes. This package uses hashes as
-the means to pass these variable size structure into and out of functions.
-
-NetUserGetInfo()
call allows the programmer to
+specify levels of 0, 1, 2, 3 (and others). Having specified this level, the
+function returns a structure that will contain different fields. For a
+level 0
, the function returns a structure that has only one field. For a
+supplied level of 1, the function returns a structure with 8
fields. The
+programmer needs to know in advance what fields should be provided or will
+be returned for a given level. This mechanism works very will since it
+effectively overloads functions without having to use different function
+prototypes. Perl provides better higher level data structures in the form
+of arrays and hashes. This package uses hashes as the means to pass these
+variable size structure into and out of functions.UserGetInfo()
can takes a number of levels. If called with level 0
+any keys and values that are applicable at the requested level.UserGetInfo()
can takes a number of levels. If called with level 0
the supplied hash will, on return from the function, contain a single key
-and value - namely name/requested-users-name. If called with a level of 1
the supplied hash will, on return from the function, contain 8 keys and
-values. The returned keys are name, password
, passwordAge,
-priv, homeDir, comment, flags, scriptPath. See
-USER INFO FIELDS for more information on what these represent.
-
-
-Exports
-
-
-User*()
functions. See NET USER FUNCTIONS.
-
-Get*()
functions. See NET GET FUNCTIONS.
-
-Group*()
functions. See NET GROUP FUNCTIONS.
-
-LocalGroup*()
functions. See NET LOCAL GROUP FUNCTIONS.
-
-
-NET USER FUNCTIONS
-User*()
functions operate on NT user accounts.
-
-1
the supplied hash will, on return from the function, contain 8 keys
+and values. The returned keys are name, password
, passwordAge
,
+priv
, homeDir
, comment
, flags
, scriptPath
. See
+USER INFO FIELDS for more information on what these represent.
+EXPORTS
+
+
+:User
+User*()
functions.
+See NET USER FUNCTIONS.
+
+:Get
+Get*()
functions.
+See NET GET FUNCTIONS.
+
+:Group
+Group*()
functions.
+See NET GROUP FUNCTIONS.
+
+:LocalGroup
+LocalGroup*()
functions.
+See NET LOCAL GROUP FUNCTIONS.
+
+NET USER FUNCTIONS
+User*()
functions operate on NT user accounts.GetDCName()
to find out what the domain controller is, should you not be running this
-on the PDC.
-
-UserGetLocalGroups()
function actually lists the domain's local groups of which the named user
-is a member.
-
-
-UserAdd(server, level, hash, error)
-server
field can be the empty string, in which case the function
+defaults to running on the local computer. If you leave this field blank
+then you should ensure that you are running the function on a PDC or BDC
+for your current domain. Use the support function GetDCName()
to find out
+what the domain controller is, should you not be running this on the PDC.UserGetLocalGroups()
function actually lists the
+domain's local groups of which the named user is a member.UserAdd(server, level, hash, error)
+name
-key's
+value in the supplied hash.
-
-server
- Scalar String
+level
- Scalar Int
+hash
- Hash Reference
+level
.
+error
- Scalar Int
+
-UserChangePassword(server, user, old, new)
-UserChangePassword(server, user, old, new)
+user
. If the policy of the machine/domain
+only allows password changes if the user
is logged on then the user
must be logged on to execute this function. With Administrator or Account
Operator privilege you can use this function to change anyone's password,
-so long as you know the old password.
-
-
-
-
-UserDel(server, user)
-
-
-
-UserEnum(server, array[, filter])
-NetUserEnum()
function in the API, this function does not allow you to specify a level
-(internally it is hardcoded to 0). In Perl it is trivial to implement the
-equivalent function (should you need it) - see
-Example 1.
-
-
-
-
-UserGetGroups(server, user, array)
-NetUserGetGroups()
function in the API, this function does not allow you to specify a level
-(internally is hardcoded to 0). In Perl it is trivial to implement the
-equivalent function (in the unlikely event that you might need it).
-
+so long as you know the old password.
-
-
-UserGetInfo(server, user, level, hash)
-server
- Scalar String
+server
on which to change the password.
+
+user
- Scalar String
+user
whose password is being changed.
+
+old
- Scalar String
+user
.
+
+new
- Scalar String
+user
.
+
+UserDel(server, user)
+user
account. Administrator or Account Operator
+privilege is required to execute this function.
+
+server
- Scalar String
+server
on which to delete the user
.
+
+user
- Scalar String
+user
account to delete.
+UserEnum(server, array[, filter])
+filter
. Unlike the
+NetUserEnum()
function in the API, this function does not allow you
+to specify a level (internally it is hardcoded to 0). In Perl it is
+trivial to implement the equivalent function (should you need it) - see
+Example 1.
+
+server
- Scalar String
+server
on which to enumerate the accounts satisfying filter
.
+
+array
- Array Reference
+server
whose
+accounts match filter
.
+
+filter
- Scalar Int (optional)
+FILTER_NORMAL_ACCOUNT
is used.
+UserGetGroups(server, user, array)
+user
is a member. It returns the group
+names in array
. Unlike the NetUserGetGroups()
function in the API,
+this function does not allow you to specify a level (internally is
+hardcoded to 0). In Perl it is trivial to implement the equivalent function
+(in the unlikely event that you might need it).
-
+server
- Scalar String
+server
from which to get the groups of which user
is a member.
+
+user
- Scalar String
+user
whose group membership you wish to examine.
+
+array
- Scalar String
+user
belongs.
+UserGetInfo(server, user, level, hash)
+level
for the named user
+in hash
.
+
-server
- Scalar String
+server
from which to get the requested information about user
.
+
+user
- Scalar String
+user
whose information you want.
+
+level
- Scalar Int
+hash
- Hash Reference
+
-UserGetLocalGroups(server, user, array[, flags])
-NetUserEnum()
function in the API, this function does not allow you to specify a level.
-Since the underlying API restricts you to level 0 there really isn't any
-need to include it...
-
-
-
+UserGetLocalGroups(server, user, array[, flags])
+user
is a member. Unlike
+the NetUserEnum()
function in the API, this function does not allow you
+to specify a level. Since the underlying API restricts you to level 0 there
+really isn't any need to include it...
+
-server
- Scalar String
+user
is a member.
+
+user
- Scalar String
+user
whose local group membership you wish to enumerate.
+
+array
- Array Reference
+user
belongs.
-
-Win32API::Net::LG_INCLUDE_INDIRECT()
or 0. if flags is omitted, the function internally uses 0. Specifying LG_INCLUDE_INDIRECT()
-will include in the list the names of the groups of which the user is indirectly a member (e.g. by being in a global group that is a member of
-a local group).
-
-
-UserModalsGet()
-
-UserModalsSet()
-
-UserSetGroups(server, user, array)
-NetUserSetGroups()
, this function does not take a
-level parameter (mainly because this option is largely redundant).
-
-
-
-
-UserSetInfo(server, user, level, hash, error)
-
-
+flags
- Scalar Int <em>(optional)</em>
+Win32API::Net::LG_INCLUDE_INDIRECT()
or 0. if flags
is
+omitted, the function internally uses 0. Specifying LG_INCLUDE_INDIRECT()
+will include in the list the names of the groups of which the user
is
+indirectly a member (e.g. by being in a global group that is a member of a
+local group).
+
+UserModalsGet()
+UserModalsSet()
UserSetGroups(server, user, array)
+user
to the specified groups.
+Unlike the API function NetUserSetGroups()
, this function does not take a
+level
parameter (mainly because this option is largely redundant).
+
+server
- Scalar String
+server
on which you wish to set the group membership for user
.
+
+user
- Scalar String
+user
whose group membership you wish to set.
+
+array
- Array Reference
+user
s
+membership of.
+UserSetInfo(server, user, level, hash, error)
+user
according to the information contained in hash
+for level
(see USER INFO LEVELS).
+
-server
- Scalar String
+server
on which you wish to change the info for user
.
+
+user
- Scalar String
+user
whose info you wish to change.
+
+level
- Scalar Int
+user
- although this may not be
+supported in future...
+hash
- Hash Reference
+
-NET GROUP FUNCTIONS
-Group*()
functions all operate only on global groups. To modify local groups, use
-the corresponding LocalGroup*()
functions.
-
-GetDCName()
to find out what the domain controller is, should you not be running this
-on the PDC.
-
-
-GroupAdd(server, level, hash, error)
-
-
-
-GroupAddUser(server, group, user)
-
-
-
-GroupDel(server, group)
-
-
-
-GroupDelUser(server, group, user)
-
-
-
-GroupEnum(server, array)
-NetGroupEnum()
, this function does not allow you to specify a level (internally it is
-hardcoded to 0). In Perl it is trivial to implement the equivalent function
-(should you need it).
-
+level
(see USER INFO LEVELS).
+error
- Scalar Int
+hash
were not properly
+specified. See USER FIELD ERRORS for more information about what
+values can be returned in this field.
+
+
+NET GROUP FUNCTIONS
+Group*()
functions all operate only on global groups. To modify
+local groups, use the corresponding LocalGroup*()
functions.server
field can be the empty string, in which case the function
+defaults to running on the local computer. If you leave this field blank
+then you should ensure that you are running the function on a PDC or BDC
+for your current domain. Use the support function GetDCName()
to find out
+what the domain controller is, should you not be running this on the PDC.GroupAdd(server, level, hash, error)
+
+
+server
- Scalar String
+server
on which to add the group.
+
+level
- Scalar String
+level
of information contained in hash
. This can be one of 0, 1
+or 2. See GROUP INFO LEVELS.
+
+hash
- Hash Reference
+level
.
+
+error
- Scalar Int
+hash
was not properly specified.
+See GROUP FIELD ERRORS for more information about what values can be
+returned in this field.
+GroupAddUser(server, group, user)
+user
to the specified group
.
+
+server
- Scalar String
+server
on which to add the user
to group
.
+
+group
- Scalar String
+group
to add the user
to.
+
+user
- Scalar String
+user
to add to group
.
+GroupDel(server, group)
+
+
+server
- Scalar String
+server
on which to delete the named group
.
+
+group
-Scalar String
+group
to delete.
+GroupDelUser(server, group, user)
+
+
+server
- Scalar String
+server
on which to delete user
from group
.
+
+group
- Scalar String
+group
from which to delete user
.
+
+user
- Scalar String
+user
to delete from group
.
+GroupEnum(server, array)
+NetGroupEnum()
, this function does not allow you to specify a level
+(internally it is hardcoded to 0). In Perl it is trivial to implement
+the equivalent function (should you need it).
-
-server
- Scalar String
+groups
.
-
-
-GroupGetInfo(server, group, level, hash)
-
-
+array
- Array Reference
+group
names.
+GroupGetInfo(server, group, level, hash)
+level
information for group
returning information in
+hash
.
+
-server
- Scalar String
+server
from which to get the group information.
+
+group
- Scalar String
+group
whose information you wish to obtain.
+
+level
- Scalar Int
+level
of information you wish to retrieve. This can be one of 1, 2
+or 3. See GROUP INFO LEVELS.
+
+hash
- Hash Reference
+
-GroupGetUsers(server, group, array)
-NetGroupGetUsers()
, this function does not allow you to specify a level (internally it is
-hardcoded to 0). In Perl it is trivial to implement the equivalent function
-(should you need it).
-
-
-
GroupGetUsers(server, group, array)
+array
) the users belonging to group
. Unlike the API
+call NetGroupGetUsers()
, this function does not allow you to specify
+a level (internally it is hardcoded to 0). In Perl it is trivial to
+implement the equivalent function (should you need it).
+
-server
- Scalar String
+server
from which to get the group information.
+
+group
- Scalar String
+group
whose users you wish to obtain.
+
+array
- Array Reference
+
-GroupSetInfo(server, group, level, hash, error)
-
-
-GroupSetUsers(server, group, array)
-GroupAddUser()/GroupDelUser()
to add and delete individual users from a group.
-
+GroupSetInfo(server, group, level, hash, error)
+group
according to level
.
-
-
-NET LOCAL GROUP FUNCTIONS
-LocalGroup*()
functions operate on local groups. If these functions are run on a PDC then
-these functions operate on the domains local groups.
-
-server
- Scalar String
+server
on which to set the group
information.
+
+group
- Scalar String
+group
whose information you wish to set.
+
+level
- Scalar Int
+level
of information you are supplying in hash
. Level can be
+one of 0, 1 or 2. See GROUP INFO LEVELS.
+
+hash
- Hash Reference
+level
.
+
+error
- Scalar String
+error
parameter will contain a value which specifies
+which field caused the error. See GROUP FIELD ERRORS.
+
+GroupSetUsers(server, group, array)
+group
to contain only those users specified
+in array
. This function will fail if any user names contained in the
+array are not valid users on server
. On successful completion
+group
will contain only the users specified in array
. Use the
+functions GroupAddUser()/GroupDelUser()
to add and delete individual
+users from a group.
+
+server
- Scalar String
+server
on which to set the group
membership.
+
+group
- Scalar String
+group
to set the membership of.
+
+array
- Array Reference
+group
.
+
+NET LOCAL GROUP FUNCTIONS
+LocalGroup*()
functions operate on local groups. If these
+functions are run on a PDC then these functions operate on the domains
+local groups.GetDCName()
to find out what the domain controller is, should you not be running this
-on the PDC.
-
-
-LocalGroupAdd(server, level, hash, error)
-
-
-
-LocalGroupAddMember()
-LocalGroupAddMembers
instead.
-
-
-LocalGroupAddMembers(server, group, array)
-NetLocalGroupAddMembers()
, this function does not allow you to specify a level (internally it is
-hardcoded to 3). This was done to simplify the implementation. To add a
-'local' user, you need only specify the name. You can also specify users using the
-DOMAIN\user
syntax.
-
-
-
-
-LocalGroupDel(server, group)
-
-
-
-LocalGroupDelMember()
-LocalGroupDelMembers()
instead.
-
-
-LocalGroupDelMembers(server, group, array)
-NetLocalGroupDelMembers()
, this function does not allow you to specify a level (internally it is
-hardcoded to 3). This was done to simplify the implementation. To delete a
-'local' user, you need only specify the name. You can also specify users using the DOMAIN\user
-syntax.
-
-
-
-
-LocalGroupEnum(server, array)
-NetLocalGroupEnum()
, this function does not allow you to specify a level (internally it is
-hardcoded to 0). In Perl it is trivial to implement the equivalent function
-(should you need it).
-
+computer that has local security enabled.server
field can be the empty string, in which case the function
+defaults to running on the local computer. If you leave this field blank
+then you should ensure that you are running the function on a PDC or BDC
+for your current domain. Use the support function GetDCName()
to find
+out what the domain controller is, should you not be running this on the PDC.LocalGroupAdd(server, level, hash, error)
+name
+key of hash
.
+
+server
- Scalar String
+server
on which to add the group.
+
+level
- Scalar String
+level
of information contained in hash
. This can be one of 0 or 1.
+See LOCAL GROUP INFO LEVELS.
+
+hash
- Hash Reference
+level
.
+
+error
- Scalar Int
+hash
wasn't properly specified.
+See LOCAL GROUP FIELD ERRORS for more information about what values
+this can take.
+
+LocalGroupAddMember()
LocalGroupAddMembers
instead.LocalGroupAddMembers(server, group, array)
+NetLocalGroupAddMembers()
, this function does not allow you
+to specify a level (internally it is hardcoded to 3).
+This was done to simplify the implementation. To add a 'local' user, you
+need only specify the name
. You can also specify users using the
+DOMAIN\user
syntax.
+
+server
- Scalar String
+server
on which to add the members to group
.
+
+group
- Scalar String
+group
to add the members to.
+
+array
- Array Reference
+group
.
+LocalGroupDel(server, group)
+
+
+server
- Scalar String
+server
on which to delete the named group
.
+
+group
-Scalar String
+group
to delete.
+
+LocalGroupDelMember()
LocalGroupDelMembers()
instead.LocalGroupDelMembers(server, group, array)
+NetLocalGroupDelMembers()
, this function does not allow you
+to specify a level (internally it is hardcoded to 3). This was done to
+simplify the implementation. To delete a 'local' user, you need only
+specify the name
. You can also specify users using the DOMAIN\user
+syntax.
+
+server
- Scalar String
+server
on which to delete the members from group
.
+
+group
- Scalar String
+group
to delete the members from.
+
+array
- Array Reference
+group
.
+LocalGroupEnum(server, array)
+NetLocalGroupEnum()
, this function does not allow you to specify a
+level (internally it is hardcoded to 0). In Perl it is trivial to
+implement the equivalent function (should you need it).
-
-server
- Scalar String
+groups
.
-
-
-LocalGroupGetInfo(server, group, level, hash)
-
-
+array
- Array Reference
+group
names.
+LocalGroupGetInfo(server, group, level, hash)
+level
information for group
.
+
-server
- Scalar String
+server
from which to get the group information.
+
+group
- Scalar String
+group
whose information you wish to obtain.
+
+level
- Scalar Int
+level
of information you wish to retrieve. This can be 0 or 1.
+See LOCAL GROUP INFO LEVELS.
+
+hash
- Hash Reference
+
-LocalGroupGetMembers(server, group, hash)
-NetLocalGroupGetUsers()
, this function does not allow you to specify a level (internally it is
-hardcoded to 0). In Perl it is trivial to implement the equivalent function
-(should you need it).
-
-
-
LocalGroupGetMembers(server, group, hash)
+group
. Unlike the API call
+NetLocalGroupGetUsers()
, this function does not allow you to specify
+a level (internally it is hardcoded to 0). In Perl it is trivial to
+implement the equivalent function (should you need it).
+
-server
- Scalar String
+server
from which to retrieve the group information.
+
+group
- Scalar String
+group
whose users you wish to obtain.
+
+array
- Array Reference
+
-LocalGroupSetInfo(server, level, hash, error)
-
-
-
-LocalGroupSetMembers()
-
-NET GET FUNCTIONS
-
-GetDCName(server, domain, domain-controller)
+
domain-controllder
name for server and domain.
-
+LocalGroupSetInfo(server, level, hash, error)
+group
according to level
.
-
-domain-controller
for the requested domain.
-
-NetGetAnyDCName()
API function as this is obsolete.
-
-
-USER INFO LEVELS
-User*()
functions take a level parameter. This level
-specifies how much detail the corresponding hash should contain (or in the case of a UserGet*()
function, will contain after the call). The following level descriptions provide information on what fields should be present for a
-given level. See USER INFO FIELDS for a description of the fields.
-
+server
- Scalar String
+server
on which to set the group
information.
+
+group
- Scalar String
+group
whose information you wish to set.
+
+level
- Scalar Int
+level
of information you are supplying in hash
.
+Level can be one of 0 or 1. See LOCAL GROUP INFO LEVELS.
+
+hash
- Hash Reference
+level
.
+
+error
- Scalar String
+error
parameter will contain a value which specifies
+which field caused the error. See LOCAL GROUP FIELD ERRORS.
+
+
+LocalGroupSetMembers()
+NET GET FUNCTIONS
+GetDCName(server, domain, domain-controller)
+domain-controller
name for server
and domain
.
+
+server
- Scalar String
+server
whose domain controller you wish to locate.
+
+domain
- Scalar String
+domain
that server
is a member of whose domain-controller
+you wish the locate.
+
+domain-controller
- Scalar String (output)
+domain-controller
for the requested domain
.
+NetGetAnyDCName()
API function
+as this is obsolete.
+USER INFO LEVELS
+User*()
functions take a level
parameter. This level
+specifies how much detail the corresponding hash
should contain (or in
+the case of a UserGet*()
function, will contain after the call). The
+following level
descriptions provide information on what fields should
+be present for a given level. See USER INFO FIELDS for a description of
+the fields.
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-USER INFO FIELDS
-USER INFO FIELDS
+
-
-acctExpires
- Scalar Int (UTC)
+authFlags
- Scalar Int (See USER_AUTH_FLAGS).
+UserAdd()
or UserSetInfo()
. Its value can be one of:
-
- User belongs to group Flag value
+cannot be set using
UserAdd()
or UserSetInfo()
. Its value can be one
+of:
+
+
+ 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()
-
+ Account Operators Win32API::Net::AF_OP_ACCOUNTS()
-
+
badPwCount
- Scalar Int
+codePage
- Scalar Int
+comment
- Scalar String
+countryCode
- Scalar Int
+flags
- Scalar Int (Bitwise OR of USER_FLAGS)
+fullName
- Scalar String
+homeDir
- Scalar String
+homeDirDrive
- Scalar String
+lastLogon
- Scalar Int (UTC)
+lastLogoff
- Scalar Int (UTC)
+logonHours
- Reference to Array of Integers (length 21 elements)
+logonServer
- Scalar String
+maxStorage
- Scalar Int
+name
- Scalar String
+numLogons
- Scalar Int
+parms
- Scalar String
+password
- Scalar String
+UserGet()
operation.
-
-passwordAge
- Scalar Int (UTC)
+passwordExpired
- Scalar Int
+UserGetInfo()
the return value is 0 is the password has not expired and 1 if it has. When
-setting the value via UserAdd()
or
-UserSetInfo()
a value of 0 indicates that the users' password has not expired whereas a
-value of 1 will force the user to change their password at the next logon.
-
-UserGetInfo()
the return value is 0 is the password has not expired
+and 1 if it has. When setting the value via UserAdd()
or
+UserSetInfo()
a value of 0 indicates that the users' password has
+not expired whereas a value of 1 will force the user to change their
+password at the next logon.
+primaryGroupId
- Scalar Int
+UserAdd()
you should use a value of 0x201.
-
-priv
- Scalar Int (Bitwise OR of USER_PRIVILEGE_FLAGS)
+UserGet()
call. See USER PRIVILEGE FLAGS.
-
-UserGet()
call. See USER PRIVILEGE FLAGS.
+profile
- Scalar String
+scriptPath
- Scalar String
+unitsPerWeek
- Scalar Int
+usrComment
- Scalar String
+UserAdd()
or
+workstations
- Scalar String
+userId
- Scalar Int
+UserAdd()
or
UserSetInfo()
calls.
-
-
-USER FLAGS
-USER FLAGS
+flags
key (see USER INFO FIELDS) should be the bitwise OR of one
+or more of these values.
-
-UF_ACCOUNTDISABLE()
+UF_DONT_EXPIRE_PASSWD()
+UF_HOMEDIR_REQUIRED()
+UF_INTERDOMAIN_TRUST_ACCOUNT()
+UserSetInfo()
call.
-
-UF_LOCKOUT()
+UserSetInfo()
call.
+
+UF_NORMAL_ACCOUNT()
+UF_PASSWD_CANT_CHANGE()
+UF_PASSWD_NOTREQD()
+UF_SCRIPT()
+UF_SERVER_TRUST_ACCOUNT()
+UF_TEMP_DUPLICATE_ACCOUNT()
+UF_WORKSTATION_TRUST_ACCOUNT()
+ $ufScript = Win32API::Net::UF_SCRIPT();
-
+like:
+ $ufScript = Win32API::Net::UF_SCRIPT();
-These following values are used in the priv key. This field is never initialised on a UserGet*()
call and once set cannot be changed in a
-UserSetInfo()
call.
-
+
These following values are used in the priv
key. This field is never
+initialised on a UserGet*()
call and once set cannot be changed in a
+UserSetInfo()
call.
+
USER_PRIV_ADMIN()
+
+USER_PRIV_GUEST()
+
+USER_PRIV_USER()
-Please note that these are implemented as functions and are therefore +
+Please note that these are implemented as functions and are therefore called in the same way as other functions. You should typically use them -like: - -
-
$userPrivUser = Win32API::Net::USER_PRIV_USER(); -+like: +
+ $userPrivUser = Win32API::Net::USER_PRIV_USER();
-These flags are used in the UserEnum()
function to specify which accounts to retrieve. It should be a bitwise OR
-of some (or all) of the following.
-
+
These flags are used in the UserEnum()
function to specify which
+accounts to retrieve. It should be a bitwise OR of some (or all) of
+the following.
+
FILTER_TEMP_DUPLICATE_ACCOUNT()
+
+FILTER_NORMAL_ACCOUNT()
+
+FILTER_INTERDOMAIN_TRUST_ACCOUNT()
+
+FILTER_WORKSTATION_TRUST_ACCOUNT()
+
+FILTER_SERVER_TRUST_ACCOUNT()
-Please note that these are implemented as functions and are therefore +
+Please note that these are implemented as functions and are therefore called in the same way as other functions. You should typically use them -like: - -
-
$filterNormalAccounts = Win32API::Net::FILTER_NORMAL_ACCOUNT(); --
-
-For the User*()
functions that take an error parameter this variable will, on failure, contain one of the following
-constants. Note that the function may fail because more than one key/value
-was missing from the input hash. You will only find out about the first one
-that was incorrectly specified. This is only really useful in debugging.
-
-
-acctExpires field was absent or not correctly specified. - -
-authFlags field was absent or not correctly specified. - -
+like:
++ $filterNormalAccounts = Win32API::Net::FILTER_NORMAL_ACCOUNT();+
+
For the User*()
functions that take an error
parameter this variable
+will, on failure, contain one of the following constants. Note that the
+function may fail because more than one key/value was missing from the
+input hash. You will only find out about the first one that was incorrectly
+specified. This is only really useful in debugging.
USER_ACCT_EXPIRES_PARMNUM()
acctExpires
field was absent or not correctly specified.
+
+USER_AUTH_FLAGS_PARMNUM()
authFlags
field was absent or not correctly specified.
+
+USER_BAD_PW_COUNT_PARMNUM()
badPasswordCount
field was absent or not correctly specified.
-
--codePage field was absent or not correctly specified. - -
-comment field was absent or not correctly specified. - -
-countryCode field was absent or not correctly specified. - -
-flags field was absent or not correctly specified. - -
-fullName field was absent or not correctly specified. - -
-homeDirDrive field was absent or not correctly specified. - -
-homeDir field was absent or not correctly specified. - -
-lastLogoff field was absent or not correctly specified. - -
-lastLogon field was absent or not correctly specified. - -
-logonHours field was absent or not correctly specified. - -
-logonServer field was absent or not correctly specified. - -
-maxStorage field was absent or not correctly specified. - -
-name field was absent or not correctly specified. - -
-numLogons field was absent or not correctly specified. - -
-parms field was absent or not correctly specified. - -
-passwordAge field was absent or not correctly specified. - -
-password field was absent or not correctly specified. - -
+
+USER_CODE_PAGE_PARMNUM()
codePage
field was absent or not correctly specified.
+
+USER_COMMENT_PARMNUM()
comment
field was absent or not correctly specified.
+
+USER_COUNTRY_CODE_PARMNUM()
countryCode
field was absent or not correctly specified.
+
+USER_FLAGS_PARMNUM()
flags
field was absent or not correctly specified.
+
+USER_FULL_NAME_PARMNUM()
fullName
field was absent or not correctly specified.
+
+USER_HOME_DIR_DRIVE_PARMNUM()
homeDirDrive
field was absent or not correctly specified.
+
+USER_HOME_DIR_PARMNUM()
homeDir
field was absent or not correctly specified.
+
+USER_LAST_LOGOFF_PARMNUM()
lastLogoff
field was absent or not correctly specified.
+
+USER_LAST_LOGON_PARMNUM()
lastLogon
field was absent or not correctly specified.
+
+USER_LOGON_HOURS_PARMNUM()
logonHours
field was absent or not correctly specified.
+
+USER_LOGON_SERVER_PARMNUM()
logonServer
field was absent or not correctly specified.
+
+USER_MAX_STORAGE_PARMNUM()
maxStorage
field was absent or not correctly specified.
+
+USER_NAME_PARMNUM()
name
field was absent or not correctly specified.
+
+USER_NUM_LOGONS_PARMNUM()
numLogons
field was absent or not correctly specified.
+
+USER_PARMS_PARMNUM()
parms
field was absent or not correctly specified.
+
+USER_PASSWORD_AGE_PARMNUM()
passwordAge
field was absent or not correctly specified.
+
+USER_PASSWORD_PARMNUM()
password
field was absent or not correctly specified.
+
+USER_PRIMARY_GROUP_PARMNUM()
primaryGroup
field was absent or not correctly specified.
-
--priv field was absent or not correctly specified. - -
-profile field was absent or not correctly specified. - -
-scriptPath field was absent or not correctly specified. - -
+
+USER_PRIV_PARMNUM()
priv
field was absent or not correctly specified.
+
+USER_PROFILE_PARMNUM()
profile
field was absent or not correctly specified.
+
+USER_SCRIPT_PATH_PARMNUM()
scriptPath
field was absent or not correctly specified.
+
+USER_UNITS_PER_WEEK_PARMNUM()
unitPerWeek
field was absent or not correctly specified.
-
--usrComment field was absent or not correctly specified. - -
-workstations field was absent or not correctly specified. - -
-
-Some of the Group*()
functions take a level parameter. This level
-specifies how much detail the corresponding hash should contain (or in the case of a GroupGetInfo()
function, will contain after the call). The following level descriptions provide information on what fields should be present for a
-given level. See GROUP INFO FIELDS
-for a description of the fields.
-
+
USER_USR_COMMENT_PARMNUM()
usrComment
field was absent or not correctly specified.
+
+USER_WORKSTATIONS_PARMNUM()
workstations
field was absent or not correctly specified.
++
Some of the Group*()
functions take a level
parameter. This level
+specifies how much detail the corresponding hash
should contain (or in
+the case of a GroupGetInfo()
function, will contain after the call).
+The following level
descriptions provide information on what fields
+should be present for a given level. See GROUP INFO FIELDS
+for a description of the fields.
+
Level 0
+
+Level 1
+
+Level 2
+
+Level 1002
+
+Level 1005
+
attributes
- Scalar Int-The comment that applies to this group. This is the only value that can be set via a -GroupSetInfo call. - -
+
+comment
- Scalar Stringcomment
that applies to this group. This is the only value that
+can be set via a GroupSetInfo call.
+
+groupId
- Scalar Int+
+name
- Scalar String
-For the Group*()
functions that take an error parameter this variable will, on failure, contain one of the following
-constants. Note that the function may fail because more than one key/value
-was missing from the input hash. You will only find out about the first one
+
For the Group*()
functions that take an error
parameter
+this variable will, on failure, contain one of the following constants.
+Note that the function may fail because more than one key/value was
+missing from the input hash. You will only find out about the first one
that was incorrectly specified. This is only really useful for debugging
-purposes.
-
+purposes.
-attributes field was absent or not correctly specified. - -
-comment field was absent or not correctly specified. - -
-name field was absent or not correctly specified. - -
-
-The GroupGetUsers()
function can take a level of 0 or 1. These will return the following:
-
+
GROUP_ATTRIBUTES_PARMNUM()
attributes
field was absent or not correctly specified.
+
+GROUP_COMMENT_PARMNUM()
comment
field was absent or not correctly specified.
+
+GROUP_NAME_PARMNUM()
name
field was absent or not correctly specified.
+
++
The GroupGetUsers()
function can take a level of 0 or 1. These will
+return the following:
+
Level 0
+
+Level 1
+
name
- Scalar String-The attributes of the group. These are no longer settable in Windows NT 4.0 -and they are not currently supported in this package either. - -
attributes
- Scalar Int
+
Level 0
+
+Level 1
+
+Level 1002
+
name
- Scalar String+
+comment
- Scalar String-
-For the LocalGroup*()
functions that take an error parameter this variable will, on failure, contain one of the following
-constants. Note that the function may fail because more than one key/value
-was missing or incorrectly specified in the input hash. You will only find
-out about the first one that was incorrectly specified. This is only really
-useful for debugging purposes.
-
-
-The name field was absent or not correctly specified. - -
-The comment field wasabsent or not correctly specified. - -
-The following example shows how you can create a function in Perl that has
-the same functionality as the NetUserEnum()
API call. The Perl version doesn't have the level parameter so you must
-first use the
-UserEnum()
function to retrieve all the account names and then iterate through the
-returned array issuing UserGetInfo()
calls.
-
-
-
sub userEnumAtLevel { +LOCAL GROUP FIELD ERRORS
+For the
+LocalGroup*()
functions that take anerror
parameter this +variable will, on failure, contain one of the following constants. Note +that the function may fail because more than one key/value was missing +or incorrectly specified in the input hash. You will only find out about +the first one that was incorrectly specified. This is only really useful +for debugging purposes.
LOCALGROUP_NAME_PARMNUM()
name
field was absent or not correctly specified.
+
+LOCALGROUP_COMMENT_PARMNUM()
comment
field wasabsent or not correctly specified.
++
The following example shows how you can create a function in Perl that
+has the same functionality as the NetUserEnum()
API call. The Perl
+version doesn't have the level parameter so you must first use the
+UserEnum()
function to retrieve all the account names and then iterate
+through the returned array issuing UserGetInfo()
calls.
+ sub userEnumAtLevel { my($server, $level, $filter) = @_; my(@array); Win32API::Net::UserEnum($server, \@array, $filter); @@ -1757,35 +1566,25 @@ print "This could access all level $level settings for $user - eg fullName $hash{fullName}\n"; } } - userEnumAtLevel("", 2, 0); -+ userEnumAtLevel("", 2, 0);
-Bret Giddings, <bret@essex.ac.uk> - +
Bret Giddings, <bret@essex.ac.uk>
-perl(1)
-
-
-
+
perl(1)
-This work was built upon work done by HiP Communications along with -modifications to HiPs code by <michael@ecel.uwa.edu.au> and -<rothd@roth.net> In addition, I -would like to thank Jenny Emby at GEC Marconi, U.K. for proof reading this -manual page and making many suggestions that have led to its current -layout. Last but not least I would like to thank Larry Wall and all the -other Perl contributors for making this truly wonderful language. +
This work was built upon work done by HiP Communications along with +modifications to HiPs code by <michael@ecel.uwa.edu.au> and <rothd@roth.net>. +In addition, I would like to thank Jenny Emby at GEC Marconi, U.K. for +proof reading this manual page and making many suggestions that have led +to its current layout. Last but not least I would like to thank Larry Wall +and all the other Perl contributors for making this truly wonderful +language.
diff -urN libwin32-0.171/APINet/Net.pm libwin32-0.172/APINet/Net.pm --- libwin32-0.171/APINet/Net.pm Mon May 14 00:12:25 2001 +++ libwin32-0.172/APINet/Net.pm Mon May 14 00:14:08 2001 @@ -64,7 +64,7 @@ } $EXPORT_TAGS{ALL}= \@EXPORT_OK; -$VERSION = '0.081'; +$VERSION = '0.09'; sub AUTOLOAD { my $constname; @@ -219,7 +219,7 @@ L
+ Win32::OLE - Type Library Browser + |
Show hidden elements: | |
Group elements by type: |
+ onclick="parent.Footer.selectLibrary" + onmouseover="parent.Footer.rollon('Libraries')" + onmouseout="parent.Footer.rolloff('Libraries')"> $Library[$id]->[libNAME] | $Library[$id]->[libMAJOR].$Library[$id]->[libMINOR] | HTML } $html .= "
$doc->{HelpFile}" if HelpFile; @@ -337,7 +341,7 @@ } 0..@Type-1; # Create a table of available types - my $html = "
+ onmouseover="parent.Footer.rollon('Types')" + onmouseout="parent.Footer.rolloff('Types')" + onclick="parent.Footer.selectType"> $name | HTML } @@ -392,8 +396,9 @@ for my $impltype (0 .. $Type[$Type]->[typeATTR]->{cImplTypes}-1) { my $tflags = $tinfo->_GetImplTypeFlags($impltype); next unless $tflags & IMPLTYPEFLAG_FDEFAULT; - ($tflags & IMPLTYPEFLAG_FSOURCE ? $event : $dispatch) = - $tinfo->_GetImplTypeInfo($impltype); + my $impltinfo = $tinfo->_GetImplTypeInfo($impltype); + next unless defined $impltinfo; + ($tflags & IMPLTYPEFLAG_FSOURCE ? $event : $dispatch) = $impltinfo; } addFunctions($dispatch); addFunctions($event, 'Event'); @@ -461,7 +466,7 @@ my $html = ''; $html .= <{HelpFile}; + STYLE="cursor:hand" onclick="parent.Footer.showHelpfile"> HTML my $type = $icon[$Type[$Type]->[typeATTR]->{typekind}] || '???'; $html .= "$type $doc->{Name}"; @@ -492,7 +497,7 @@ } 0..@Member-1; # Create a table of all members - my $html = "
+ onmouseover="parent.Footer.rollon('Members')" + onmouseout="parent.Footer.rolloff('Members')" + onclick="parent.Footer.selectMember"> $default $Member[$id]->[membDOC]->{Name} | @@ -559,7 +564,7 @@ my $html = ''; $html .= <{HelpFile}; + STYLE="cursor:hand" onclick="parent.Footer.showHelpfile"> HTML my $type = $Member[$Member]->[membICON]; diff -urN libwin32-0.171/OLE/browser/Browser.html libwin32-0.172/OLE/browser/Browser.html --- libwin32-0.171/OLE/browser/Browser.html Mon May 14 00:12:26 2001 +++ libwin32-0.172/OLE/browser/Browser.html Mon May 14 00:14:16 2001 @@ -4,12 +4,12 @@