thank you for setting this up. To configure a central login application for a workspace,
- make sure the URLs all have session IDs in your application menu list
- make sure the cookie names of application authentications are the same (e.g. SHARED_WORKSPACE_COOKIE)
That way, the same APEX session can be shared between the applications. I configured that in your demo workspace.
App 9308 has a custom authentication that redirects to the login app 58564, if the session is invalid and an empty authentication function (important!). On page 9308:101, a dynamic action automatically submits on loading the page. 101 has a process that calls wwv_flow_custom_auth_std.login.
In the call to login(), APEX throws an error, because no authentication function is defined and login() is called in a submit process. This is a security enhancement in 4.1. We do not allow that anymore, because it could be used to circumvent custom authentications.
There's a work around for your scenario. I defined an authentication function in 9308 that always returns true, since you were implementing a kind of open door authentication anyway. Btw, if you unify the cookie names and always pass the shared session id in URLs, you could probably remove page 101 in 9308 and simply link to the start page.
Thank you for your answer.
There is one thing that doesnt work the way want now.
We want it to be possible to run the applications also stanalone.
So when you run 9308 directly, when you didn't login via the menu, you should be redirected to 9308:1 after logging in
on 58564:101. What happens now is, that after you run 9308 directly, you stay in 58564 and have to go to 9308 by clicking the menu.
Is there a way to solve like this worked in 4.0?
I just want to keep you updated about the second bug in this thread. Bug# 13359643 - CUSTOM AUTHENTICATION: ERROR IF PL/SQL CODE CONTAINS :APP_USER AND USER CHANGES
has been fixed in 4.1.1 and will be included in the first patch set for APEX 4.1
My Blog: http://www.inside-oracle-apex.com
APEX Plug-Ins: http://apex.oracle.com/plugins