please dont rip this site Prev Next

USER_INFO_22 info  Overview  Group

The USER_INFO_22 structure contains user information for network accounts.

typedef struct _USER_INFO_22 {
LPWSTR usri22_name;
BYTE usri22_password[ENCRYPTED_PWLEN];
DWORD usri22_password_age;
DWORD usri22_priv;
LPWSTR usri22_home_dir;
LPWSTR usri22_comment;
DWORD usri22_flags;
LPWSTR usri22_script_path;
DWORD usri22_auth_flags;
LPWSTR usri22_full_name;
LPWSTR usri22_usr_comment;
LPWSTR usri22_parms;
LPWSTR usri22_workstations;
DWORD usri22_last_logon;
DWORD usri22_last_logoff;
DWORD usri22_acct_expires;
DWORD usri22_max_storage;
DWORD usri22_units_per_week;
PBYTE usri22_logon_hours;
DWORD usri22_bad_pw_count;
DWORD usri22_num_logons;
LPWSTR usri22_logon_server;
DWORD usri22_country_code;
DWORD usri22_code_page;
}USER_INFO_22, *PUSER_INFO_22, *LPUSER_INFO_22;  

Members

usri22_name
Specifies the name of the user account. For the NetUserSetInfo function, this member is ignored.
usri22_password
Specifies a one-way encrypted LAN Manager 2.x-compatible password.
usri22_password_age
Specifies the number of seconds elapsed since the usri22_password member was last changed. The NetUserAdd and NetUserSetInfo functions ignore this member.
usri22_priv
One of three values specifying the level of privilege assigned the usri22_name member. For the NetUserAdd function, this member must be USER_PRIV_USER. For the NetUserSetInfo function, this member must be the value returned from NetUserGetInfo or NetUserEnum. This member can be one of the following values:

Value

Meaning

USER_PRIV_GUEST

Guest

USER_PRIV_USER

User

USER_PRIV_ADMIN

Administrator

usri22_home_dir
Points to a Unicode string containing the path of the home directory for the user specified in the user_name member. The string can be null.
usri22_comment
Points to a Unicode string that contains a comment. This string can be a null string, or it can have any number of characters before the terminating null character.
usri22_flags
Contains values that determine several features. This member can be any of the following values:

Value

Meaning

UF_SCRIPT

The logon script executed. This value must be set for LAN Manager 2.0 or Windows NT.

UF_ACCOUNTDISABLE

The user's account is disabled.

UF_HOMEDIR_REQUIRED

The home directory is required. This value is ignored in Windows NT.

UF_PASSWD_NOTREQD

No password is required.

UF_PASSWD_CANT_CHANGE

The user cannot change the password

UF_LOCKOUT

The account is currently locked out. For NetUserSetInfo, this value can be cleared to unlock a previously locked account. This value cannot be used to lock a previously locked account.

UF_DONT_EXPIRE_PASSWD

Represents the password, which should never expire on the account. This value is valid only for Windows NT.

The following values describe the account type. Only one value can be set. You cannot change the account type using the NetUserSetInfo function.

Value

Meaning

UF_NORMAL_ACCOUNT

This is a default account type that represents a typical user

UF_TEMP_DUPLICATE_ACCOUNT

This is an account for users whose primary account is in another domain. This account provides user access to this domain, but not to any domain that trusts this domain. The User Manager refers to this account type as a local user account.

UF_WORKSTATION_TRUST_ACCOUNT

This is a computer account for a Windows NT Workstation or Windows NT Server that is a member of this domain.

UF_SERVER_TRUST_ACCOUNT

This is a computer account for a Windows NT Backup Domain Controller that is a member of this domain.

UF_INTERDOMAIN_TRUST_ACCOUNT

This is a permit to trust account for a Windows NT domain that trusts other domains.

usri22_script_path
Points to a Unicode string specifying the path of the user's logon script, .CMD, .EXE, or .BAT file. The string can be null.
usri22_auth_flags
Specifies an unsigned long integer that contains values that specify the user's operator privileges.

For Windows NT servers, the following restrictions apply; for NetUserAdd, this member must be zero. For NetUserSetInfo, this member must be the value returned from NetUserGetInfo or NetUserEnum.

For NetUsrGetInfo or NetUserEnum, the appropriate value is returned based on the local group membership. If the user is a member of Print Operations, AF_OP_PRINT is set. If the user is a member of Server Operations, AF_OP_SERVER is set. If the user is a member of the Account Operations, AF_OP_ACCOUNTS is set. AF_OP_COMM is never set.

This member can be one of the following values:

Value

Meaning

AF_OP_PRINT

The print operator privilege is enabled.

AF_OP_COMM

The communiations operator privilege is enabled.

AF_OP_SERVER

The server operator privilege is enabled.

AF_OP_ACCOUNTS

The accounts operator privilege is enabled.

usri22_full_name
Points to a Unicode string that contains the full name of the user. This string can be a null string, or it can have any number of characters before the terminating null character.
usri22_usr_comment
Points to a Unicode string that contains a user comment. This string can be a null string, or it can have any number of characters before the terminating null character.
usri22_parms
Points to a Unicode string that is set aside for use by applications. This string can be a null string, or it can have any number of characters before the terminating null character. Microsoft products use this member to store user configuration information. Do not modify this information.
usri22_workstations
Points to a Unicode string that contains the names of workstations from which the user can log on. As many as eight workstations can be specified; the names must be separated by commas (,). A null string indicates that there is no restriction. To disable logons from all workstations to this account, set the UF_ACCOUNTDISABLE value in the usri*_flags member.
usri22_last_logon
Specifies when the last logon occurred. This value is stored as the number of seconds elapsed since 00:00:00, January 1, 1970. This element is ignored in NetUserAdd and NetUserSetInfo calls. This member is maintained separately on each Backup Domain Controller (BDC) in the domain. To get an accurate value, each BDC in the domain must be queried, and the largest value is used.
usri22_last_logoff
Specifies when the last logoff occurred. This value is stored as the number of seconds elapsed since 00:00:00, January 1, 1970. A value of zero means that the last logoff time is unknown. This element is ignored in NetUserAdd and NetUserSetInfo calls.This member is maintained separately on each Backup Domain Controller (BDC) in the domain. To get an accurate value, each BDC in the domain must be queried and the largest value is used.
usri22_acct_expires
Specifies when the account will expire. This value is stored as the number of seconds elapsed since 00:00:00, January 1, 1970. A value of TIMEQ_FOREVER indicates that the account never expires.
usri22_max_storage
Specifies the maximum amount of disk space the user can use. Use the value specified in USER_MAXSTORAGE_UNLIMITED to use all available disk space.
usri22_units_per_week
Specifies the number of equal-length time units into which the week is divided. This member uses these time units to compute the length of the bit string in the usri22_logon_hours member. This value must be UNITS_PER_WEEK for LAN Manager 2.0. This element is ignored in the NetUserAdd and NetUserSetInfo functions. For Windows NT services, the units must be one of the following: SAM_DAYS_PER_WEEK, SAM_HOURS_PER_WEEK, or SAM_MINUTES_PER_WEEK.
usri22_logon_hours
Points to a 21-byte (168 bits) bit string that specifies the times during which the user can log on. Each bit represents a unique hour in the week. The first bit (bit 0, word 0) is Sunday, 0:00 to 0:59; the second bit (bit 1, word 0) is Sunday, 1:00 to 1:59; and so on. A null pointer in this element for NetUserAdd calls means that there is no time restriction. A null pointer in this element for NetUserSetInfo calls means that no change is to be made.
usri22_bad_pw_count
Specifies the number of times the user tried to log on to this account using an incorrect password. A value of 0xFFFFFFFF indicates that the value is unknown. This member is ignored in NetUserAdd and NetUserSetInfo calls. This member is maintained separately on each Backup Domain Controller (BDC) in the domain. To get an accurate value, each BDC in the domain must be queried, and the largest value is used.
usri22_num_logons
Counts the number of successful times the user tried to log on to this account. A value of 0xFFFFFFFF indicates that the value is unknown. This element is ignored in NetUserAdd and NetUserSetInfo calls. This member is maintained separately on each Backup Domain Controller (BDC) in the domain. To get an accurate value, each BDC in the domain must be queried, and the member uses the sum of the values.
usri22_logon_server
Points to a Unicode string that contains the name of the server to which logon requests are sent. Servernames should be preceded by two backslashes (\\). When a servername is represented by an asterisk (\\*), the logon request can be handled by any logon server. A null string indicates that requests are sent to the domain controller. For Windows NT Servers, the NetUserGetInfo and NetUserEnum functions return \\*. The NetUserAdd and NetUserSetInfo functions ignore this member.
usri22_country_code
Specifies the country code for the user's language of choice. Windows NT does not use the country code.
usri22_code_page
Specifies the code page for the user's language of choice. Windows NT does not use the code page.

See Also

NetUserAdd, NetUserEnum, NetUserGetInfo, NetUserSetInfo


file: /Techref/os/win/api/win32/struc/src/str23.htm, 15KB, , updated: 2000/4/7 11:20, local time: 2024/11/7 17:07,
TOP NEW HELP FIND: 
44.211.34.178:LOG IN
©2024 PLEASE DON'T RIP! THIS SITE CLOSES OCT 28, 2024 SO LONG AND THANKS FOR ALL THE FISH!

 ©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?
Please DO link to this page! Digg it! / MAKE!

<A HREF="http://www.piclist.com/techref/os/win/api/win32/struc/src/str23.htm"> USER_INFO_22</A>

After you find an appropriate page, you are invited to your to this massmind site! (posts will be visible only to you before review) Just type a nice message (short messages are blocked as spam) in the box and press the Post button. (HTML welcomed, but not the <A tag: Instead, use the link box to link to another page. A tutorial is available Members can login to post directly, become page editors, and be credited for their posts.


Link? Put it here: 
if you want a response, please enter your email address: 
Attn spammers: All posts are reviewed before being made visible to anyone other than the poster.
Did you find what you needed?

  PICList 2024 contributors:
o List host: MIT, Site host massmind.org, Top posters @none found
- Page Editors: James Newton, David Cary, and YOU!
* Roman Black of Black Robotics donates from sales of Linistep stepper controller kits.
* Ashley Roll of Digital Nemesis donates from sales of RCL-1 RS232 to TTL converters.
* Monthly Subscribers: Gregg Rew. on-going support is MOST appreciated!
* Contributors: Richard Seriani, Sr.
 

Welcome to www.piclist.com!

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

  .