Control Admin Access for portal visibility

Rahul Talreja
Mega Sage
Mega Sage

Hi All,

We have a requirement, in which we created a custom portal, and it should be visible to only particular users containing role "xyz". 
We are able to achieve this. But users with "admin" role without "xyz" role are able to see it. 
We desire to restrict the visibility purely based on "xyz" role irrespective of admin.

Thanks and Regards,
Rahul

Please mark my response correct/helpful as applicable!
Thanks and Regards,
Rahul
4 REPLIES 4

Paul Curwen
Giga Sage

I would achieve this by amending theSPEntryPage Script Include which controls login redirection and which you can easily amend for admin using g_user.hasRoleExactly(). Be careful though as restricting Admins to a portal would limit their ability when performing support duties related to the Portal.

 

There is a decent blog on the process here:  https://www.servicenow.com/community/now-platform-blog/6-ways-to-set-up-your-service-portal-for-redi...

 

 

***If Correct/Helpful please take time mark as Correct/Helpful. It is much appreciated.***

Regards

Paul

Mohan raj
Mega Sage

Hi @Rahul Talreja ,

 

To restrict access to admin for custom portal page, Navigate to page designer and add role or remove role. It will restrict the access to portal page.

 

Link : https://docs.servicenow.com/bundle/xanadu-platform-user-interface/page/build/service-portal/task/con...

 

 

 
 

 

 
 

 

This would not stop them jumping to any other known same Portal page though, surely SPEntryPage redirect is the better solution here.

***If Correct/Helpful please take time mark as Correct/Helpful. It is much appreciated.***

Regards

Paul

Hi @Mohan raj ,

Thanks for reply, 
We did same, but its not stooping users with only "admin" role to see the page.
They are still able to see the page.

 Thanks @Paul Curwen , request you to please guide here as spEntryPage solution will be having instance wide effect?

Please mark my response correct/helpful as applicable!
Thanks and Regards,
Rahul