One problem that is facing you from time to time as a dotnetnuke professional is the burning desire of customers to have a single sign-on solution for their multi-portal system. Often they have different portals for their company departments or separate intranet and internet portals or some other multiportal needs. But none of these customers understand the necessity of logging seperatly into every single portal! And for the system administrators it is a nightmare to keep all these user accounts in sync! A lot of commercial and open source modules and providers helped to solve this problem in the past.
Another annoyance is the impossibility to share content between portals. Think of a desktop browser website and his mobile companion (realized as two portals). If you write an article in the desktop portal and you want to show this special article on the mobile portal too, what did you have to do ? Yes, copy and paste! Possible, but not very elegant!
Since Version 6.1 of DotNetNuke there is a solution for this in the Professional Version (PE). Unfortunately this is supposed to be not included in the community edition of DNN. But you should know that the functionality is implemented in the core and only the administration module is lacking in the CE version! So you are able to use this, even in CE, with minimal changes directly in the database:
Base of all the functionality is the new table “PortalGroups”:
For every group of portals we need to insert here one record:
Beside the PortalGroupName and the PortalGroupDescription, which are selfexplaining, and the common fields CreatedOnDate, CreatedByUserID etc. , only MasterPortalID and AuthenticationDomain are interesting. MasterPortalID should be replaced with the portalid of the portal which should be used as the portal where the user logs in in the future. AuthenticationDomain should be filled with the domain name of the master portal (e.g. www.yourdomain.com)
Now we have to fill in the PortalGroupID of the newly created portalgroup into the field with the same name in the corresponding Portal records and our SSO solution is complete:
Tip: Eventually you have to recycle the Applicationpool to see your results!
And now see how this affects your portal administration:
Add an existing module – before
Add an existing module – after
And after login in the main portal the user is also automatically logged in into the child portal and all users of both portals show up together in the user administration!
Edit (08.05.2014) Please be aware of this:
- A user created on the master portal is known on all portals of the portal group
- Login at a portal automatically logs you in to all portals with the same domain (incl. subdomains + childportals). SSO for other domains does NOT work (but you can log in with the same user credentials).
Many thanks to Stefan Cullmann (@SCullman) who told me about this nice little “trick” !