| 2 |
rsolanki |
1 |
=========================================================================
|
|
|
2 |
How to Build LoginAdmin.dll
|
|
|
3 |
=========================================================================
|
|
|
4 |
1. Open VB project file (LoginAdmin.vbp)
|
|
|
5 |
2. Build dll using File -> Make AdminLogin.dll menu option. This will create AdminLogin.dll
|
|
|
6 |
|
|
|
7 |
|
|
|
8 |
=========================================================================
|
|
|
9 |
Register LoginAdmin.dll
|
|
|
10 |
=========================================================================
|
|
|
11 |
NOTE: If this dll existed before on this machine, you need to unregister first.
|
|
|
12 |
|
|
|
13 |
1. Copy dll to required machine
|
|
|
14 |
2. Go to that machine and using command prompt go to location of that dll
|
|
|
15 |
3. Run regsvr32 LoginAdmin.dll to register your dll.
|
|
|
16 |
|
|
|
17 |
|
|
|
18 |
=========================================================================
|
|
|
19 |
Unregister LoginAdmin.dll
|
|
|
20 |
=========================================================================
|
|
|
21 |
NOTE: This dll will be in use by IIS and you need to Unload the application
|
|
|
22 |
using mmc.exe, before you can replace dll with new one.
|
|
|
23 |
|
|
|
24 |
1. Find which web applications use this dll by searching for string "LoginAdmin.ImpersonateUser"
|
|
|
25 |
in .asp source files.
|
|
|
26 |
2. Using Internet Information Server plug-in in mmc.exe, go to those applications and Unload them.
|
|
|
27 |
Do that by selecting the Properties of that application.
|
|
|
28 |
3. On Properties window, select Virtual Directory tab, and find Application Settings area.
|
|
|
29 |
4. Click on Unload button (Windows NT) to unload the application.
|
|
|
30 |
5. Using command prompt go to LoginAdmin.dll location.
|
|
|
31 |
6. Run regsvr32 /u LoginAdmin.dll to unregister dll.
|
|
|
32 |
7. Replace it with new dll and register again. Application will be loaded automatically when .asp page is ran.
|
|
|
33 |
|
|
|
34 |
|
|
|
35 |
=========================================================================
|
|
|
36 |
Installing LoginAdmin.dll
|
|
|
37 |
=========================================================================
|
|
|
38 |
NOTE: This dll uses some windows API which require certain privileges to run.
|
|
|
39 |
You need to go through this process only once when registering dll for the first time.
|
|
|
40 |
|
|
|
41 |
1. Application Protection
|
|
|
42 |
Run Internet Services Manager. Right-click the virtual directory in which your ASP script
|
|
|
43 |
is running and select Properties. On the "Virtual Directory" tab, set the Application Protection
|
|
|
44 |
option to Low (IIS Process) . If the option is disabled, click on the "Create" button first.
|
|
|
45 |
|
|
|
46 |
In Windows NT4 (IIS4), instead of the above, disable the option "Run in separate memory space".
|
|
|
47 |
|
|
|
48 |
2. User Privileges
|
|
|
49 |
Grant the "Act as Part of Operating System" privilege to the user context under which the ASP script runs.
|
|
|
50 |
By default, IIS is configured for anonymous access under the user account IUSR_machinename
|
|
|
51 |
although you may have configured it differently.
|
|
|
52 |
|
|
|
53 |
This is usually only necessary in Windows NT 4 (IIS 4). To grant a user this privilege, go to
|
|
|
54 |
User Manager, select Policies/User Rights, check "Show Advanced User Rights", select "Act as Part of Operating System",
|
|
|
55 |
and add your IIS user account.
|
|
|
56 |
|
|
|
57 |
This is usually not necessary in Windows 2000 or later, but here are the steps for that.
|
|
|
58 |
Go to Control Panel / Administrative Tools, and run Local Security Policy. Select User Rights Assignment
|
|
|
59 |
under Local Policies in the left pane. Double-click the "Act as part of the operating system" policy
|
|
|
60 |
in the right pane, and add your IIS user account.
|
|
|
61 |
|
|
|
62 |
Under some configurations, the IWAM_machinename account is also used. You can try adding this privilege to
|
|
|
63 |
that user account as well.
|
|
|
64 |
|
|
|
65 |
|