Thanks. After several hours, i finally figured this out. The second
thing is still an issue
though, though I've modified my Default.vm file to not display the
navigation menu if the
user is not really logged in. By the way, this leads me to another
point. The User.hasLoggedIn()
method returns true if the user enters nothing, and hits the submit
button. Is this intended
behavior? My isAuthorized routine now looks like:
if (user.hasLoggedIn() && user.getUserName() != null)
isAuthorized = true;
....
But it led me to a screen where the navigation controls were there, but
the content
was the login page. So i modifed Default.vm as above so that the nav
controls
weren't there.
How have other people dealt with this problem? Is it possible to have
the Login.vm
page explicitly say that it has no layout? And have it work in the
above case?
I've tried short curcuiting the layout in the SecureScreen, and
SecureAction to set
the template to null, but this doesn't seem to work in that case.
Thoughts? Suggestions....
Basically, I'm trying to create a site where there is NO anonymous
access. It is a
fraternity alumni website, and there will be sensitive information on
there, such
as contact information and so forth, that we don't want accessible to
the general
public. So I want every screen to check for a validated login before
displaying.
Andres Portillo wrote:
>Look for the classes SecureScreen and SecureAction inside your app. There must
>be in a package like this:
>
> your.domain..modules.screens and your.domain.modules.actions
>
>Inside those classes there is a function "protected boolean isAuthorized(
>RunData data )", where you can define the correct
>authorization policy for your app. I think I saw this info in a HOWTO in the
>jakarta site, but I can't remember which one right now. I hope this helps...
>
>andres
>
>Matthew Inger wrote:
>
>>I am looking to use turbine to power my alumni website.
>>However, I'm running into the following problem: I build the
>>default application as instructed on the jakarta-turbine page.
>>I direct it to use hypersonic sql, and connect to a local database
>>on the filesystem. Everything works all well and good at first.
>>The problems I run into:
>> 1) When I create another use, I can never get that user past the
>> login page unless i put them in the turbine_root role. I have
>> verified that the user is authenticated in the LoginUser action
>> (I put some debug statements in there). But still nothing shows.
>>
>> 2) I've noticed that if you have nothing in the user/password fields
>> in the login screen, and hit the ok button, it will show the
>>login page
>> again, but this time, it will appear inside of the default layout.
>>
>>So i guess I'm wondering what i'm doing wrong. Do i have to do something
>>special so that a non "turbine_root" user can log in? Are these above
>>problems
>>known problems, and are there workarounds?
>>
>>--
>>Matt Inger ([EMAIL PROTECTED])
>>Sedona Corporation
>>455 S. Gulph Road, Suite 300
>>King of Prussia, PA 19406
>>(484) 679-2213
>>"Self-respect - the secure feeling that no one,
>> as yet, is suspicious." -H.L. Mencken
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>For additional commands, e-mail: [EMAIL PROTECTED]
>>
>
>--
>=============================================
>Andres G. Portillo D.
>Software Engineer
>Veratech (www.veratech.com.mx)
>=============================================
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>
>
--
Matt Inger ([EMAIL PROTECTED])
Sedona Corporation
455 S. Gulph Road, Suite 300
King of Prussia, PA 19406
(484) 679-2213
"Self-respect - the secure feeling that no one,
as yet, is suspicious." -H.L. Mencken
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]