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



Question about a special scenarioExpand / Collapse
Author
Message
Posted 09/05/2007 7:45:08 AM


StrataFrame Novice

StrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame Novice

Group: StrataFrame Users
Last Login: 2 days ago @ 2:42:57 PM
Posts: 112, Visits: 665
I think if is posible to use the RBS on this scenario:

I try to develop a Mini - ERP, this have a ConfigDB Database with the RBS Tables (users,permission,etc), but have multiple DB (1 for each "enterprise", Enterprise1, Enteprise2, EnterpriseN, etc)

Questions:
1) I like to have the same users but not same permission
ex: on enterprise 1 the user "pepe" can make a invoice, but not on enterprise 2
- about this I think about if I can have the users on the ConfigDB and the permission on ConfigDB, and also if the permission need to be customized to enterpriseN, I have a copy of this permission on EnterpriseN DB and use it (something like on RBS how the user permissions have priority over the role permissions)
then if I found a same permission on the actual enterpriseN DB, I take that (if it no exist I use the configDB permission)

I have something on RBS to make this or have to check the permission on my actual db (on a copy of SFSRolesXPermission and SFSUsersXPermission) and see if this exist there, and if it not, use the one on configDB?

I not sure If I can explain the stuff correctly, I try to be clear but I speak in spanish and are newbie on .net and strataframe

thanks guys for the great patience


Post #11337
Posted 09/05/2007 9:23:11 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 08/01/2008 8:53:41 AM
Posts: 2,671, Visits: 1,879
The RBS is designed so that all of the SFS* tables reside in the same database so that the tables can be joined and such.  So, splitting the permissions off and placing them in a different database would not be possible.  If all of the enterpriseN applications use the same permissions, then you would need to have to store the SFS* tables in the enterpriseN database so that each would have its own UsersXPermissions records to determine which user has which permissions for that database.  The closest you would get to having a shared users table would be to handle the AfterSave event of the SFSUsersBO and duplicate/update the user on the additional databases.


www.bungie.net
Post #11345
Posted 09/05/2007 1:20:22 PM


StrataFrame Novice

StrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame Novice

Group: StrataFrame Users
Last Login: 2 days ago @ 2:42:57 PM
Posts: 112, Visits: 665
If I handle the aftersave and duplicate from one DB to another EXACTLY the SFS_users row, not having problems with us_data?

Can I change "online" the securitykey and get a permission from one or another DB?

Thanks for all the help.

- Fabian
Post #11354
Posted 09/06/2007 8:52:30 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 08/01/2008 8:53:41 AM
Posts: 2,671, Visits: 1,879
Can I change "online" the securitykey and get a permission from one or another DB?

No, the security key is used as the seed for the byte[] that is the key used to encrypt/decrypt the us_Data field.  So, if you change the key, suddenly, you won't be able to see anyones passwords and the users will all become invalid.  Hence why the key exists within the SecurityMaintenance editor for adding users at design-time.  The data must be encrypted using the same key to be decrypted at runtime.

If I handle the aftersave and duplicate from one DB to another EXACTLY the SFS_users row, not having problems with us_data?

Yes, you can copy a user from one database to another with no problem copying the us_Data field, IF (as I mentioned above) the MicroFour.StrataFrame.Security.SecurityBasics.SetSecurityKeyAndVectorForUserAuthentication() method was called with the same security key for all .EXEs that use the access the users.


www.bungie.net
Post #11361
Posted 09/06/2007 1:26:52 PM


StrataFrame Novice

StrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame Novice

Group: StrataFrame Users
Last Login: 2 days ago @ 2:42:57 PM
Posts: 112, Visits: 665
I Apologize for the last post that I made, I like to say "SecurityDataSourceKey" not "securitykey", I try to say if I can change the SecurityDataSourceKey to read another DB entirely and see the permisions of that database (with the logged user that exist on both databases with same user data but changed permission)

Sorry Ben, between my english and my knowledge of .net and strataframe, I´m making a mixture

I attemp to not waste your time, but some things escape to me

I am thankful for your patience
Post #11372
Posted 09/07/2007 9:58:34 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 08/01/2008 8:53:41 AM
Posts: 2,671, Visits: 1,879
I attemp to not waste your time

Oh don't worry, you're certainly not wasting my time

Yeah, you can swap out the SecurityDataSourceKey at runtime to swap between databases.  The only thing is that a users permissions will be cached when created, so, you'll need to refresh the user after you swap to a new database.

You can get a new ISecurityUser object by calling MicroFour.StrataFrame.Security.LoggedInUser() and pass the SFSUsersBO that you populate with the user from the correct database.


www.bungie.net
Post #11380
Posted 09/07/2007 2:22:18 PM


StrataFrame Novice

StrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame NoviceStrataFrame Novice

Group: StrataFrame Users
Last Login: 2 days ago @ 2:42:57 PM
Posts: 112, Visits: 665
Then It is posible.

I will test it and post here some aditional questions about this topic thankyou so much
Post #11385
Posted 09/10/2007 8:50:24 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 08/01/2008 8:53:41 AM
Posts: 2,671, Visits: 1,879
Yep, just let me know when you have new questions


www.bungie.net
Post #11396
« 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 7:43pm

Powered by InstantForum.NET v4.1.4 © 2008
Execution: 0.094. 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.