authfilt

所属分类:网络编程
开发工具:Windows_Unix
文件大小:11KB
下载次数:1
上传日期:2013-09-30 15:40:46
上 传 者mindport
说明:  ISAPI利用过利器实现用户登录信息的验证。
(ISAPI availed tool to implement user login authentication.)

文件列表:
MAKEFILE (308, 1996-03-01)
DEFAULT.HTM (2633, 1996-03-02)
authfilt.c (6538, 1996-03-05)
authfilt.h (1747, 1996-03-05)
authfilt.def (143, 1996-03-05)
cache.c (8166, 1996-03-05)
db.c (8219, 1996-03-05)

Microsoft Internet Information Server AuthFilt - A Filter for Advanced Authentication AuthFilt demonstrates how to write an authentication filter based on an external datasource. Authentication is the process of accepting or denying a request from a client, so AuthFilt will be notified each time an authentication request comes in. This sample uses a file (c:\inetsrv\userdb.txt) to keep track of authorized users, but you might modify this sample to access a database which holds user info. For each authentication request, AuthFilt first looks in a cache of recently authenticated users, and when that fails, AuthFilt looks in the userdb.txt file. This shows an efficient way to authorize connections: a cache allows the filter to quickly authenticate users, and because each request comes in through the filter, speed is critical. Steps to build the sample: 1. Set the environment variables WWWROOT and WWWSCRIPTS to point to your c:\inetsrv\wwwroot and c:\inetsrv\scripts directory, respectively. 2. Make sure your INCLUDE variable points to both the Win32 SDK and the ISAPI header files, and make sure your LIB variable points to the Win32 SDK. 3. With your PATH variable set to your compiler, run nmake from the command line inside the AuthFilt directory. 4. Run REGEDT32.EXE and modify the server's registry as follows. Choose HKEY_LOCAL_MACHINE, CurrentControlSet, Services, W3SVC, Parameters, then Filter DLLs. Select the Edit menu, then String. This will bring up a dialog to modify the value of the key. Append a comma (,) and a local path to AuthFilt.Dll, usually C:\INetSrv\Scripts\SDK\AuthFilt.Dll. 5. Restart the WWW service. The build results will be copied to your WWW structure: AuthFilt.Dll will be copied to the SDK sub-directory off the path specified in WWWSCRIPTS, and Default.Htm will be copied to the AuthFilt sub- directory off the path specified in WWWROOT. The registry entry Filter DLLs is used by IIS to determine what filters to load when the WWW service is starting. The makefile that comes with the Internet SDK uses the DLL version of the C Runtime Library. You must have this DLL on your server in order for the samples to work. For example, if you are using Visual C++ 4.0 to build the DLL, it will need the debug version of the C Runtime Library DLL, named MSVCR40D.DLL. Verify that this file is in your server's SYSTEM32 directory.

近期下载者

相关文件


收藏者