Permission issues in a debug session

Permission issues in a debug session

I've got some debugging issues when debugging 'over' multiple E-spaces.
We're using Platform Server 5.0.2.?? and Service Studio

Consider the following situation:

I want to debug a login process which is divided over Two E-spaces
- E-space 1 contains the stylesheet and exception handler
- E-space 2 contains a small web frontend which is referencing the Stylesheet and Exceptions from E-space 1

Here's what I do to debug.
I run the small web frontend E-space in the PersonalArea to debug.
In the  stylesheet E-space I select the small web frontend E-space as an Entry E-space and run the to start debugging in my PersonalArea.
(As service studio states)

Now the fact is that in the Public Area, I'm logged in and in the Personal Area I'm logged out and don't have any privileges.

When starting an Entry of the small web frontend E-space, I can see my empty Session.UserId.
The debugger steps to the first screen and given that permissions are set on that screen,
the debugger jumps directly to the Exception handler in the Stylesheet and Exceptions E-space. 

Two things I find strange about this:
1. It doesn't even touch the defined Security Exception in the Web Flow of the small web frontend E-space
2. It jumps from the small web frontend E-space in the Personal Area directly to the  (Unregistered Entry of the) Stylesheet and Exceptions E-space in the Public Area

Am I encountering a bug or am I mistaking about the way a webscreen permission is handled?
Hi Eric,

I am sorry but there are some things that are not clear to me in your description. What do you exactly mean by:
- Espace 1 is the exception handler?
- E-space 2 is referencing Exceptions?

Which is the exact exception flow? Is it caught at the webflow level of the Espace 2 and then redirected to a screen in eSpace 1? Can you post a screenshot that explains how this exception redirection is being done?


Daniel Lourenço
E-space 1 (which is referenced by E-space 2)

E-space 2; containing some webscreens

This is the defined Exception handler in E-space 2 that references the Espace 1 Exceptions WebFlow which I would expect to be triggered:

Hope this clearifies.

which one is your user-provider?

afaik, if you follow the template.oml (with the component-template) it works as intended.
I had some struggles as well, but that was mostly because I'm still thinking in master-child espaces, while they actually are not.
not in the OO-way

Hi Eric,

I do not clearly understand the Exception flow and dependencies in your situation. Can you clearly explain which are the dependencies between the two eSpaces?

You should only use producer debugging when you want to debug a public user action in a producer eSpace when it is called from the consumer eSpace - is this your situation? You can read about Producer Debugging in the Service Studio Online Help here.

If the dependency between you eSpaces is a "redirect", meaning that you jump from one to the other with HTTP redirections (the Go To Destination and External Site widgets will do that) you are simply accessing the two eSpaces directly from your browser in two different request. If this is the situation, you should not use producer debugging - you should simply run your two eSpaces and debug the different requests.

If this is the situation, it looks like your redirections are not taking into account the fact that hat they should include PTA of the user when jumping to eSpace 1. How is this redirection being done? Please bare in mind that you have available the built-in function AddPersonalAreaToURLPath when you want to add the current PTA to an URL.

Kind Regards,

Daniel Lourenço
Hi Joost,

Sorry for the late reply; "EnterpriseManager" is my user provider.
This is set in both E-spaces.
Hi Daniel, sorry for my late reply,

I think that if I specify more what exactly occurs this might clarify.

1. I execute a Run of an application which should start my app in my private area.
2. I open the page to my private area and see the debugger thread going from Product_Base_Start entry point tot the Product_Base_List webscreen
3. I guess the platform runs into the Webscreen permissions and wants to check my login.
    However, the login session of my private area is expired and Outsystems wants to raise an exception; as from this moment there is NO visible debugger activity
4. Instead of opening the login page in my Personal Area, the page is opened in the Public Area

This sounds to me like the AddPersonalAreaToURLPath function is missing, but because this occurs on the Webscreen's permissions, the prepare is never executed thus a different exception is raised.
I wouldn't know which exception is raised, but I guess it's the exception in the referenced E-space.
When calling the exception outsystem manages the references and I guess the AddPersonalAreaToURLPath function isn't used through the reference.

Does this clearify?