Boswell's Q&A

Keeping Users At Bay

A feature that's been available for decades on NetWare, here's a new Windows utility can be used to limit number of concurrent user logins.

Readers: Every week or so, I get an irate letter from an administrator who wants to limit the number of concurrent logons available to users. These administrators cite security concerns based on this argument: If users are logged on at multiple locations, they are much more likely to leave one of these locations open for compromise. The administrators also usually point out that NetWare has been able to do this since the 1980s. They often include an exclamation point or two. "The 1980's!!"

In the past, I've pointed these admins at a Windows 2000 Resource Kit utility called Cconnect but warned them that it's a fairly limited solution and urged them to spend time looking for third-party utilities that can give them the necessary functionality.



Well, that situation has changed. Microsoft Product Support Services released a utility called LimitLogin, which you can download by clicking here . I ran across the utility while reading John Howard's excellent Microsoft blog at http://blogs.msdn.com/jhoward/archive/2005/03/14/395135.aspx . (John's blog is always a great source of news; be sure to add his link to your RSS subscriptions.)

Get Help from Bill

Got a Windows or Exchange question or need troubleshooting help? Or maybe you want a better explanation than provided in the manuals? Describe your dilemma in an e-mail to Bill at mailto:boswell@101com.com; the best questions get answered in this column.

When you send your questions, please include your full first and last name, location, certifications (if any) with your message. (If you prefer to remain anonymous, specify this in your message but submit the requested information for verification purposes.)

LimitLogin requires a bit of effort to deploy. For one thing, it performs a Schema modification. For another, it creates a new partition in Active Directory. It also requires configuring a Web server with the .NET Framework and ASP.NET and setting it up to do delegated Kerberos authentication. Finally, it requires distributing client packages that support communicating with the Web server via SOAP (a lightweight protocol for exchanging structured information in a distributed environment).

Whoa. Don't stop reading. It's complicated, but not impossible. Really.

If you're put off by the need to do a Schema modification, take heart.

Yes, yes...I know you can't remove objects from the Schema once they've been added, but LimitLogin only adds five objects, which isn't exactly going to cause the galaxy to shift its orbit. Absolutely no changes are made to classes or attributes. You'll need Schema Admin permissions in the root domain of the forest to do the Schema modifications.

Because LimitLogin uses this assortment of fairly advanced technologies, it will only control interactive (console-based) logins from clients running the following operating systems:

  • Windows 2000 Professional Service Pack 4 and newer
  • Windows 2000 Server Service Pack 4 and newer (Including Terminal Server sessions)
  • Windows XP Professional Service Pack 1 and newer
  • Windows Server 2003 (Including Terminal Server sessions)

You'll need an Active Directory domain with at least one Windows Server 2003 domain controller. This domain controller must own the Domain Naming Master FSMO role, because LimitLogin creates an Application naming context (also called an Application Directory Partition). If you aren't familiar with this feature, click here to read a Microsoft white paper that explains it. or http://snipurl.com/9tdf.

You'll also need a Windows Server 2003 server with version 1.1 or newer of the .NET Framework where you can run IIS with ASP.NET. The security configuration for the ASP.NET extension needs to be set to Allow (see Figure 1).

Configuring security for ASP.NET extension
Figure 1. Set security for the ASP.NET extension to Allow from this dialog. (Click image to view larger version.)

Installing LimitLogin
LimitLogin consists of three MSI packages plus a Help file:

  • LimitLoginIISSetup.msi
  • LimitLoginADSetup.msi
  • LimitLoginClientSetup.msi
  • LimitLogin.chm

Start the installation by running the LimitLoginIISSetup package at the Web server. This adds a new virtual folder to the default Web site and installs a variety of files (see Figure 2).

Run LimitLoginIISSetup
Figure 2. Running LimitLoginIISSetup spawns a new folder on the default Web site, with some files.

Now run the LimitLoginADSetup package. This package does three things. First, it extends the Schema to add four new attributes and a new Structural class called LimitLoginUser (see Figure 3).

New Schema additions
Figure 3. See the new Schema additions with ADSIEdit. (Click image to view larger version.)

Second, it adds a new naming context to the forest root namespace. The container for this naming context is called LimitLogin.

Third, it adds an extension to Active Directory Users and Computers (ADUC) to expose a new property menu item called LimitLogin Tasks. Selecting this option for a user opens a Properties interface for configuring LimitLogin settings (see Figure 4).

Configure LimitLogin
Figure 4. Now you can configure LimitLogin.

During this portion of LimitLogin setup, you'll have to do some hacking. After all, this is a 1.0 release of a Resource Kit-style utility.

LimitLogin comes with two scripts, one each for logon and logoff, and a wsdl file for XML formatting. You'll need to create a share to hold these files and create a Group Policy Object configured to run the scripts (see Figure 5).

Running llogin.vbs
Figure 5. Logon script that runs the llogin.vbs script. You're just about done with the installation and configuration.

That pretty much takes care of the initial setup and configuration. When you use the ADUC extension to limit a user's concurrent logins, the extension creates a new object in the LimitLogin naming context. Figure 6 shows the Microsoft LDAP Browser, depicting the LimitLogin naming context after it has been populated with an msLimitLoginUser object that represents a user in the Domain naming context. Note that this object is only linked to the User object in the domain via a name. No changes are made to the Schema that associates the msLimitLoginUser class or its attributes with the User class.

LimitLogin, from LDAP Browser
Figure 6. What limiting logins looks like from the LDAP Browser. (Click image to view larger version.)

The final steps involve configuring the clients. You then need to run LimitLoginClientSetup.msi on any desktop or terminal server where you want to limit users' concurrent logins. This client installs the required plumbing so that the logon and logoff scripts can generate the required SOAP requests when communicating with the Web server. In other words, the script uses an XML class that isn't present until you install the client piece.

The client comes in an MSI so you can deploy it using GPOs. It requires local admin rights, so assign the package to the Software settings on the Computer side of a GPO that is linked to the OUs that contain your desktops and terminal servers. You'll need to wait for the computers to restart to apply this setting and install the package.

With all this in place, here's what happens when a user logs in at a configured client.

Let's say you configure a user to have a login limit of 1. This value is written to the msLimitLogin object in Active Directory.

The user reports for work in the morning and logs on at a desktop. The Login.vbs logon script communicates with the Web server. The Web server does a lookup in Active Directory to determine if the user has been configured with a login limit and, if so, has the user already logged in somewhere else.

In this case, the user has no other concurrent logons, so the Web server records the identity of the machine where the user has logged on and then the login process continues as normal. The user has no indication that the llogin.vbs logon script has executed.

When the user attempts to log in at a second workstation or a terminal server session, the logon script communicates with the Web server. The Web server checks Active Directory and discovers that the user is already logged in somewhere else. It compares the number of current logins with the user's limit. In this case, the limit is 1 so the Web server informs the client that the user has met or exceeded the limit and the user is logged off. In the default configuration, there are no errors messages; the limitlogin client simply forces a logoff and puts the user back at a logon window.

There is an additional feature in LimitLogin that runs a small executable to show the user the location of the other logins. This is handy information and you should include this feature in any production deployment of LimitLogin.

Because LimitLogin uses logon and logoff scripts, it is not effective in stopping VPN connections or command-line connections. But it's a step in the right direction. If your organization has been looking for a way to restrict concurrent logins, then you should certainly download and test the LimitLogin utility. Like other Resource Kit style utilities, LimitLogin is not directly supported by Microsoft PSS.

If you try the utility, be sure to write and let me know how you like it.

Until next week!

Reader Comments:

Sun, Jun 14, 2009 FDAS DSA

[url=http://www.cnyouxiang.com/ypsjhf.html]杭州数据恢复[/url] [url=http://www.360google.cn]google排名[/url][url=http://www.qsnet.cn/google.asp]google排名[/url][url=http://www.360google.cn/googlebm.htm]google左侧排名[/url][url=http://www.qsnet.cn/google.asp]google左侧排名[/url][url=http://www.360google.cn]google优化[/url][url=http://www.360google.cn]google推广[/url][url=http://www.360google.cn/googlebm.htm]google左侧推广[/url][url=http://www.gzbanjia8.com.cn/]广州搬家公司[/url] [url=http://www.gzbanjia8.com.cn/]广州搬家[/url][url=http://www.360google.cn/googlebm.htm]google左侧优化[/url][url=http://www.sh28.com.cn]上海搬家[/url][url=http://www.sh28.com.cn]上海搬家公司[/url] [url=http://www.sh28.com.cn/about.htm]上海搬场[/url][url=http://www.sh28.com.cn/about.htm]上海搬场公司[/url] [url=http://www.021banjiagongsi.com.cn]上海搬家公司[/url] [url=http://www.021banjiagongsi.com.cn]搬家公司[/url] [url=http://www.sh28.com.cn/shwlgs.htm]上海物流公司[/url]
[url=http://www.tian-rui.com.cn]广告灯箱[/url]
[url=http://www.tglaser.net/index01.html]激光打标机[/url]
[url=http://www.yimixian.com/yimixian.html]一米线[/url][url=http://www.chinapetfilm.com]pet热收缩膜[/url]
[url=http://www.rzdvdcreator.com]avi to dvd[/url]
[url=http://www.shanghaiescort.com.cn]shanghai escort[/url]
[url=http://www.shanghaiescorts.net.cn]shanghai escort[/url]
[url=http://www.huayihats.com/felthats.html]felt hats[/url]
[url=http://www.nbuico.com/product-list-info-58.html]烘箱[/url]
[url=http://www.lvbao8.com.cn/lvbao.html]lv包[/url]
[url=http://www.usegps.cn/gps]GPS[/url]
[url=http://www.usegps.cn]陀螺仪[/url]
[url=http://www.usegps.cn] 倾角传感器, 惯性导航[/url]
[url=http://www.siyinji88.com.cn]丝网印刷机[/url]
[url=http://www.siyinji88.com.cn]丝印机[/url]
[url=http://www.siyinji88.com.cn/guangguji]光固机[/url]
[url=http://www.siyinji88.com.cn/guangguji]晒版机[/url]
[url=http://www.wanyuanbj.com/product.html]制袋机[/url]
http://www.hc86.com/p DOT eijian.html
[url=http://www.bagmakingmachine.net.cn/]吹膜机,制袋机[/url]
[url=http://www.bagmakingmachine.net.cn/eabout.html]bag making machine[/url]
[url=http://www.bagmakingmachine.net.cn/eabout.html]film blowing machine[/url]
[url=http://www.bhbzjx.cn/eproduct.html]plastic machine[/url]

Sun, Jun 14, 2009 youbo fdsa

[url=http://www.bhbzjx.cn/eproduct.html]bag making machine[/url]
[url=http://www.guowang.com/en/eabout.html]paper cutting machine[/url]
[url=http://www.wanyuanbj.com/product.html]制袋机[/url]
[url=http://www.rahuaxin.com/wfbzdj.html]无纺布制袋机[/url]
[url=http://www.zhengdongcn.com/103.htm]无纺布制袋机[/url]
[url=http://www.zhengdongcn.com/eproduct.htm]slitting machine[/url]
[url=http://www.dilicn.com/cold-drawn-steel-bar.html]Cold Drawn Steel Bar[/url]
[url=http://www.sinsobond.com/aluminum-composite-panel.html]aluminum composite panel[/url]
[url=http://www.weddingdresses.net.cn]wedding dresses[/url]
[url=http://www.weddingdresses.net.cn]wedding dress[/url]
[url=http://www.weddingdresses.net.cn]wedding gowns[/url]
[url=http://www.weddingdresses.net.cn]cheap wedding dress[/url]
[url=http://www.weddingdresses.net.cn/cheap_bridal_gowns.html]Cheap Bridal Gowns[/url]
[url=http://www.weddingdresses.net.cn/cheap_bridal_gowns.html]bridal gowns[/url]

Sun, Jun 14, 2009 youbo fdsa

[url=http://www.bhbzjx.cn/eproduct.html]bag making machine[/url]
[url=http://www.guowang.com/en/eabout.html]paper cutting machine[/url]
[url=http://www.wanyuanbj.com/product.html]制袋机[/url]
[url=http://www.rahuaxin.com/wfbzdj.html]无纺布制袋机[/url]
[url=http://www.zhengdongcn.com/103.htm]无纺布制袋机[/url]
[url=http://www.zhengdongcn.com/eproduct.htm]slitting machine[/url]
[url=http://www.dilicn.com/cold-drawn-steel-bar.html]Cold Drawn Steel Bar[/url]
[url=http://www.sinsobond.com/aluminum-composite-panel.html]aluminum composite panel[/url]
[url=http://www.weddingdresses.net.cn]wedding dresses[/url]
[url=http://www.weddingdresses.net.cn]wedding dress[/url]
[url=http://www.weddingdresses.net.cn]wedding gowns[/url]
[url=http://www.weddingdresses.net.cn]cheap wedding dress[/url]
[url=http://www.weddingdresses.net.cn/cheap_bridal_gowns.html]Cheap Bridal Gowns[/url]
[url=http://www.weddingdresses.net.cn/cheap_bridal_gowns.html]bridal gowns[/url]

Wed, Nov 8, 2006 mndsqetnewq2q85 mndsqetnewq2q

than a fifth of the World's population, China represents the largest growing market in www.021fy.com the new millennium. Now, translating your message into www.zhongguofanyi.com www.oktrans.net Chinese and local www.jiayinte.com cultures effectively is critical in determining www.paper-translation.com the success or failure of your www.xinyitong.net.cn business www.88translation.com,www.acmetranslation.com,www.bodt.com.cn

Sun, Nov 5, 2006 einqnewq2q69 einqnewq2q

than a fifth of the World's population, China represents the largest growing market in www.021fy.com the new millennium. Now, translating your message into www.zhongguofanyi.com www.oktrans.net Chinese and local www.jiayinte.com cultures effectively is critical in determining www.paper-translation.com the success or failure of your www.xinyitong.net.cn business www.acmetranslation.com

Tue, Jun 14, 2005 favirobok Anonymous

Sorry to My ENGLISH!!!!!!
If Limitlogin have any program to logoff
users from AD??? I have 5000 users and
5-6 operators.Don't want give to operators access visually to Active Directory Users and Computers.
How can I do it this?????????

Tue, May 24, 2005 TheKid72 New Mexico

Great Article. Bad Product. M$ has yet to think outside the box and examine the house that they themselves built. I give you an example. W2K3 designed for the largest organizations to allow multiple sites and domains. In this case, lets assume that a child domain wants the functionality of limitlogon but since they do not control the schema master or domain naming master, they are at the mercy of someone else. So, if the schema admins say "Nah, no one else needs it so we will not deploy it." then the child domain suffers. It would seem that this was another thoughtless attempt from M$ to build a bridge out of toothpicks and wood glue.

Mon, Apr 25, 2005 Jean ANDERSEN Anonymous

Sorry Anonymous, but UserLock does not require a service installed on every machine, it just automatically deploys a 100 KB dll with almost no impact on clients ressources.
You are right about the price, but UserLock, contrary to LimitLogin :
- does not require AD schema modification
- does not require an IIS server
- comes with an integrated deployer
- supports Windows NT 4.0 domains
- provides E-mail & popup notifications
- logs lock/unlock events
- defines login limits by group
- allows you to customize messages displayed to the user
- allows you to set workstation restrictions

I thoroughly tested both solutions and UserLock by far gives me the most bang for my buck !

Tue, Apr 19, 2005 Anonymous Anonymous

We're currently evaluating this tool and I think although it's a kluge in it's setup and everything, it seems to be working pretty well, Plus the issue that was raised in another post (users not logging off) is perfectly handled within the app. yes, UserLock is ok, but it requires a Service install in every machine AND will cost you 12K for 4000 users, and this tool is for free.

Thu, Mar 31, 2005 Mark Ukotic Anonymous

I absolutely agree with all the comments above. I think the vast majority of administrators out there will agree that this MS solution isn't worth the pixels it's written in. For a second generation attempt it still appears that MS have missed the mark. As with previous comments, a well written and concise article, hats of to you Boswell. While I can't vouge for the robustness of this solution (I'm sure will find out in time). There appears to be a large amount of single points of failure in this setup. Not to also mention the extra administration involved in supporting this solution. Ultimately though you can see that Microsoft's inherent logon method is the cause of all this pain. While there's nothing wrong with it (works greats) I don't see a flawless solution arriving soon, not until MS gives us an integrated OS solution. From personal painful experiences they can start with a central security event log (in real-time) for domain controllers.

Wed, Mar 30, 2005 Mark Ukotic Anonymous

I absolutely aggress with all the comments above. I think the vast majority of administrators out there will agree that this MS solution isn’t worth the pixels it’s written in. For a second generation attempt it still appears that MS have missed the mark.

As with previous comments, a well written and concise article, hats of to you Boswell. While I can’t vouge for the robustness of this solution (I’m sure will find out in time). There appears to be a large amount of single points of failure in this setup. Not to also mention the extra administration involved in supporting this solution.

Ultimately though you can see that Microsoft’s inherent logon method is the cause of all this pain. While there’s nothing wrong with it (works greats) I don’t see a flawless solution arriving soon, not until MS gives us an integrated OS solution. From personal painful experiences they can start with a central security event log (in real-time) for domain controllers.

Wed, Mar 30, 2005 Mike Reilly Anonymous

While I don't mean this as a slight against Mr. Boswell - quite the contrary, I admire him for outlining a process most people would have abandoned in disgust - I'm amazed by how much work is required to achieve what NDS offered with a simple user property setting. IIS. Schema modifications. Special logon scripts. A client installation requirement. This is like trying to get across Queens by taking a flight from JFK to Philadelphia, Chicago and then to Pittsburgh and finally Laguardia. Yes, you'll get there, but who knows how many hours and miles you will sacrifice to do it.

While I enjoy a challenge as much as the next IT professional, time is precious. I think we will wait for the next Windows server release so Microsoft can add this feature right onto the user properties page where it ought to have been ever since Windows 3.51 debuted.

Wed, Mar 30, 2005 Anonymous Anonymous

What a Kluge, I stopped reading at Schema modifications somewhere near the 7th paragraph. Anything this complicated to deploy (and it is..) will be a nightmare to fix when (not if) something goes wrong. I mean for Pete's sake it relies on Web server! and more pieces than a Lego House. MS needs to go back to the drawing board. Is it a step in the right direction..sure but it needs to go back to the drawing board.

Wed, Mar 30, 2005 Eric NC

the column is fine, the solution from MS is a cluge at best. I would at the management issues in this solution, an additional IIS box, licensing, doesn't seem worth it to me

Wed, Mar 30, 2005 Terry Anonymous

What about the single point of failure problems? I take it that the app partition can be replicated to another DC but what about a failure (or downtime) on the IIS server?

Wed, Mar 30, 2005 Jean ANDERSEN Anonymous

LimitLogin is certainly better than the pathetic and flawfull Cconnect, but is still a very limited tool and a nightmare to try and deploy ...:-(((

Anyone wanting to seriously manage user sessions on a Windows network should look at UserLock (http:www.userlock.com).

I have been using this software for 18 months now (for 4,000 users sharing 600 stations) and it is definitely worth its 3 bucks per station.

Tue, Mar 29, 2005 Mike Tampa

Sounds like a step in the right direction but I see a huge flaw that can cause major headaches in large organizations. If a user logs onto a workstation and that workstation gets turned off without a logoff or it crashes etc etc. Then the user will be stuck because the logoff script did not run. If there is no timeout or active check with the workstation itself to see if a user is STILL logged on, this can cause huge issues.

Add Your Comment Now:

Your Name:(optional)
Your Email:(optional)
Your Location:(optional)
Comment:
Please type the letters/numbers you see above