2006-03-10 18:39:22 +00:00

103 lines
3.2 KiB
C

/***********************************************************************
*
* Copyright (C) 2005-2006 Novell, Inc. All Rights Reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; version 2.1
* of the License.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, Novell, Inc.
*
* To contact Novell about this file by physical or electronic mail,
* you may find current contact information at www.novell.com.
*
***********************************************************************/
#ifndef NWLOGIN_H
# include <nwlogin.h>
#endif
#ifndef NWLGEXT_H
#define NWLGEXT_H
#ifdef __cplusplus
extern "C" {
#endif
typedef struct tagNWLGLoginExtInfo
{
nint loginExtIDLen; // ID buffer length (max allowed by api is 32)
pnstr loginExtID; // ID is the unique name for subkey in registry
nint loginExtDLLNameLen; // DLL file name length
pnstr loginExtDLLName; // DLL file name (may include path)
nint loginExtDescLen; // Descriptive text buffer length
pnstr loginExtDesc; // Any descriptive text
DWORD loginExtType; // Login extension in type, UI, Authentication, Script only,...
} NWLGLoginExtInfo;
typedef NWLGLoginExtInfo N_FAR * pNWLGLoginExtInfo;
/* some arbitrary limits set by API */
#define LOGIN_EXT_MAX_ID_BYTES 32
#define LOGIN_EXT_MAX_DLL_NAME MAX_PATH
#define LOGIN_EXT_MAX_DESC 64
/* definitions valid for loginExtType */
#define LOGIN_EXT_UI 0x0001
#define LOGIN_EXT_AUTHENTICATE 0x0002
#define LOGIN_EXT_SCRIPT 0x0004
#define LOGIN_EXT_ALL 0x00FF
#define LOGIN_EXT_MANDATORY 0x0100
#define LOGIN_EXT_OPTIONAL 0x0200
#define LOGIN_EXT_SECONDARY 0x4000
#define LOGIN_EXT_MASTER 0x8000
/* Login extension init (registration) entry point */
N_EXTERN_LIBRARY( NWCCODE )
NWLoginExtInit
(
pNWLGAccessRec * pAccess,
pNWVersion pCompiledVersion,
pNWVersion pRuntimeVersion,
nptr reserved1,
nptr reserved2
);
N_EXTERN_LIBRARY( NWCCODE )
NWLGLoginExtRegOpen
(
HKEY *hKey
);
N_EXTERN_LIBRARY( NWCCODE )
NWLGLoginExtRegGet
(
DWORD *iSubKey, // -1 = find from structure, 0 = read first, increment for next
pNWLGLoginExtInfo loginExtInfo
);
N_EXTERN_LIBRARY( NWCCODE )
NWLGLoginExtRegWrite
(
pNWLGLoginExtInfo
);
N_EXTERN_LIBRARY( NWCCODE )
NWLGLoginExtRegDelete
(
pNWLGLoginExtInfo loginExtInfo
);
#ifdef __cplusplus
}
#endif
#endif