StrataFrame Forum
Home      Members   Calendar   Who's On
Welcome Guest ( Login | Register )
      



Access to user password programmaticallyExpand / Collapse
Author
Message
Posted 03/26/2007 3:31:12 PM
StrataFrame VIP

StrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIP

Group: StrataFrame Users
Last Login: Yesterday @ 10:01:58 PM
Posts: 1,268, Visits: 3,234
As you might remember (or not... ) I have this whole "project" based app going. I just realized that when I allow the user to change projects, I need to login them in again in order to refresh there permission (that was a fun 3 hrs figuring out what was wrong). I'd prefer to just do this programmatically, logging the same user back on, which means I'd need their user name and password to pass to SetLoggedInUser. How do I retrieve this info? I know the password is encrypted in a field in the user table, but how do I get it?
Post #7713
Posted 03/27/2007 8:50:00 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 09/26/2008 8:30:36 AM
Posts: 2,685, Visits: 1,886
You can use the SFSUsersBO to retrieve the value.  The SecurityBasics.CurrentUser.UserPK will give you the primary key for the user and you can create a new SFSUsersBO and FillByPrimaryKey() to get the user record.  The password is then accessible through the PasswordPlainText property.  Of course, once you have the customer record in the SFSUsersBO, you could then just call LoggedInUser.SetLoggedOnUser() and just pass it the SFSUsersBO with the record... this will cause the permissions to be retrieved and the CurrentUser object (and therefore the permissions) to be refreshed; so you really don't need the password once you have the record.


www.bungie.net
Post #7730
Posted 03/27/2007 12:32:43 PM
StrataFrame VIP

StrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIPStrataFrame VIP

Group: StrataFrame Users
Last Login: Yesterday @ 10:01:58 PM
Posts: 1,268, Visits: 3,234
Cool! Thanks!
Post #7743
« Prev Topic | Next Topic »


Reading This TopicExpand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Ben Chase, Trent L. Taylor, Steve L. Taylor

PermissionsExpand / Collapse

All times are GMT -6:00, Time now is 9:09am

Powered by InstantForum.NET v4.1.4 © 2008
Execution: 0.109. 10 queries. Compression Enabled.
Site Map - Home - My Account - Forum - About Us - Contact Us - Try It - Buy It

Microsoft, Visual Studio, and the Visual Studio logo are trademarks or registered trademarks of Microsoft Corporation in the United States and/or other countries.