‎05-25-2017 07:33 AM
Hi, I am struggling a bit with a problem that someone hopefully can help resolve...
I have users with no roles (ess users) logging in to the Service Portal, but I want to restrict their acess only to SP sites.
Meaning that if someone deletes/changes the url, e.g.
instance.service-now.com/sp
to
instance.service-now.com
or
instance.service-now.com/sys_user_list.do
They should see a blank page,or ideally end up back on service portal homepage.
Right now, they can see the application and some of the tables/pages - and those cannot be restricted using ACL.
I tried a global ui script,but this only redirects AFTER the whole page has loaded, which is really bad.
Do you know any way how such thing might be prevented?
Thanks!
‎05-25-2017 07:41 AM
‎05-25-2017 07:43 AM
Hi Tomasz,
Check in sys_properties for this property name:
glide.entry.page.script
This determines where user needs to redirect on logging in if has no roles.
In the sys_properties
table, add the following property:
Property | Type | Value | Description |
---|---|---|---|
glide.entry.first.page.script | string | new SPEntryPage().getFirstPageURL() | First page after authentication |
getFirstPageURL primarily does the following:
login_redirect.do
in order to break out of the frameset (if there is one).Mark Correct if this solves your issue and also hit Like and Helpful if you find my response worthy based on the impact.
Thanks
Ankur
‎05-25-2017 02:45 PM
Thanks, will give it a try tomorrow and will let you know how it went!
‎05-26-2017 05:12 AM
Hi Ankur,
I checked the proposed solution, however this would only work if the user is not yet logged in. If they are logged in to the portal, then they change the url or open a new one, it will not detect this.
I would need a solution which will basically run everytime someone accesses an instance URL - global UI script seems to be the only solution but still it runs only after the page is rendered. If there was anyway to access the script running BEFORE page content is loaded, that would be perfect...