DWORD NPLogon( HWND hwndOwner, LPLOGONINFO lpAuthentInfo, LPLOGONINFO lpPreviousAuthentInfo, LPTSTR lpLogonScript, DWORD dwBufferSize, DWORD dwFlags );
hwndOwner
A handle to a window which should be the owner for any dialog boxes or messages which the provider might display.
lpAuthentInfo
A structure describing the user who logged on.
lpPreviousAuthentInfo
A structure describing the user's previous authentication information, if a password change was required during the logon process. If no password change was required, this parameter will be NULL.
lpLogonScript
Points to a buffer to which the NP may copy the path of an executable program or batch file which should be run upon successful logon. This buffer is initialized by the MPR to be a null string. If the NP leaves the buffer that way, no logon script will be executed for that network.
dwBufferSize
Size of the lpLogonScript buffer in bytes. This is guaranteed to be at least as long as the maximum length of a MS-DOS pathname. Since this entrypoint should not be called multiple times for a single logon phase, the NP may not return WN_MORE_DATA if the buffer is not large enough. In this case, the NP should just provide a null string, and no logon script will be executed for that network.
dwFlags
Any combination of the following values:
LOGON_DONE | Logon is completed. |
LOGON_PRIMARY | This NP is the Primary Logon Provider. The provider should always display a user interface, and should return the user name and password in the lpAuthentInfo structure's buffers. The provider must return a non-blank user name; the password may or may not be blank. |
LOGON_MUST_VALIDATE | If LOGON_PRIMARY is also set, the user must either be successfully authenticated with the network, or must cancel the logon. An "unconfirmed" logon is not permitted. If the provider returns WN_NOT_VALIDATED, MPR will display an appropriate warning message. |
WN_CANCEL | The user canceled a logon dialog box displayed by the provider. |
WN_NOT_VALIDATED | The call is successful, but the user has not been authenticated with a network entity. It is not certain that the user's credentials are correct. |