It is currently Tue Jul 22, 2014 1:18 am




Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
 User Authentication - Deny Login to Repeat Username 
Author Message
Trooper
Trooper

Joined: Wed Jun 20, 2012 5:56 am
Posts: 12
Post User Authentication - Deny Login to Repeat Username
I've been working with several different authentication types (all working well) but I've not been able to find a method for denying login to a user already logged in. Ideally I'd like to stick with AD/Hybrid type but I'm open to others.

Say I have a user "User01", I would like to deny future clients the ability to login as "User01" as this user is already active. Once "User01" is no longer active within a client it could again be allowed to start a new client. Is anything along these lines possible?

Thanks!


Wed Jun 20, 2012 6:06 am
Profile
Moderator
Moderator

Joined: Sun Apr 02, 2006 2:46 pm
Posts: 1982
Location: Sacramento, CA
Post Re: User Authentication - Deny Login to Repeat Username
Yes, it is possible but you have to do it through the startup script. So basically we will use AD to login but once they are logged in we will check to see if they are already logged in and if they are we will log them out. The startup script will look something like this:
Code:
sessions = system.util.getSessionInfo("User01", "ProjectName")
if len(sessions) > 1:
    system.gui.messageBox("You can only be logged in once")
    system.security.logout()
By the way you can edit the startup script from the designer under Project > Event Scripts (Client) from the menu at the top. Select the Startup tab and put the script in.

_________________
Travis Cox
Inductive Automation
Technical Support Rep.


Wed Jun 20, 2012 6:50 am
Profile WWW
Trooper
Trooper

Joined: Wed Jun 20, 2012 5:56 am
Posts: 12
Post Re: User Authentication - Deny Login to Repeat Username  Topic is solved
Perfect, thank you.


Wed Jun 20, 2012 7:31 am
Profile
Display posts from previous:  Sort by  
Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 


Who is online

Users browsing this forum: Majestic-12 [Bot] and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: