Re: [T5] Form errors persisted in session?

2008-03-28 Thread Renat Zubairov
Hi

Thanks for the info, but generally IMHO it's a bug when error
validation status is stored in the session. How do you think?

Renat

On 27/03/2008, Angelo Chen [EMAIL PROTECTED] wrote:

  how about:

  @Component
private Form regForm;
  void cleanupRender() {
   regForm.clearErrors();

   }


  Renat Zubairov wrote:
  
   Hi
  
   Where are the validation results of the BeanEdit persisted in T5?
   I disabled javascript then submited empty form, then enabled
   javascript and opened empty form without any sumbit, but errors are
   still there. Only when I dropped the cookie error
   messages went away.
  
   --
   Best regards,
   Renat Zubairov
  

  -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  

  --

 View this message in context: 
 http://www.nabble.com/-T5--Form-errors-persisted-in-session--tp16339068p16340460.html
  Sent from the Tapestry - User mailing list archive at Nabble.com.



  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Best regards,
Renat Zubairov

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: T5: nested loops don't work (can't figure this one out)

2008-03-28 Thread Britske

Arghh. Thanks a lot! I missed that. I figured it couldn't be a Tapestry
thing. 

I traced back why I thought that the resulting sublist had an element (while
in fact it didn't): apparently a sublist is nothing but a wrapper around the
source-list (which I didn't know_, which is why burried in the debug
parameters the sublist still shows to have an element. Anyhow, 

Thanks again. 


Jonathan Barker wrote:
 
 Subtle logic error.
 
 outputlist.add(list.subList(counter,
 Math.min(counter+maxListsize,outputlist.size(;
 
 Should be 
 
 outputlist.add(list.subList(counter,
 Math.min(counter+maxListsize, list.size(;
 
 Gotta love those!
 
 
 -Original Message-
 From: Britske [mailto:[EMAIL PROTECTED]
 Sent: Thursday, March 27, 2008 2:25 PM
 To: users@tapestry.apache.org
 Subject: T5: nested loops don't work (can't figure this one out)
 
 
 Hi,
 
 I'm breaking my head on this one.
 I have  2 nested loops where the value of the outer loop is used as the
 source of the inner loop.
 
 The problem is that getCurPhotoAsThumb() is never called (as noticed by
 debugging) thus nothing is rendered.
 I've made sure that getCurThumbSublist() has at least 1 element.
 
 Anyone?
 
 I've supplied the relative template and class-parts:
 
 TEMPLATE
 -
 t:loop source=listOfThumbSubLists value=curThumbSublist
   div id=${currentThumbContainerId} class=thumbcontainer
t:loop source=curThumbSublist value=curPhotoAsThumb
${curPhotoAsThumb.url}
  /t:loop
/div
  /t:loop
 
 
 CLASS
 ---
 private int maxListsize = 6;
 private ListPhoto curThumbSublist;
 private Photo curPhotoAsThumb;
 private int curListCounter = 0;
 
  public ListPhoto getCurThumbSublist()
  {
  return curThumbSublist;
  }
 
  public void setCurThumbSublist(ListPhoto curThumbSublist)
  {
  this.curThumbSublist = curThumbSublist;
  curListCounter++;
  }
 
  public String getCurrentThumbContainerId()
  {
  return thumb_+curListCounter;
  }
 
  public ListListPhoto getListOfThumbSubLists(){
  curListCounter= 0;
  ListListPhoto outputlist = new ArrayListListPhoto();
 
  SetPhoto set = this.getPage().getPhotos();
  ListPhoto list = new ArrayListPhoto();
  for(Photo p: set){
  list.add(p);
  System.out.println(p.getUrl());
  }
  int counter = 0;
  boolean stop = false;
  while(!stop){
  outputlist.add(list.subList(counter,
 Math.min(counter+maxListsize,outputlist.size(;
  if(list.size()=counter+maxListsize){
  stop = true;
  }
  counter += maxListsize;
  }
  return outputlist;
  }
 
  public Photo getCurPhotoAsThumb()
  {
  return curPhotoAsThumb;
  }
 
  public void setCurPhotoAsThumb(Photo curPhotoAsThumb)
  {
  this.curPhotoAsThumb = curPhotoAsThumb;
  }
 --
 View this message in context: http://www.nabble.com/T5%3A-nested-loops-
 don%27t-work-%28can%27t-figure-this-one-out%29-tp16330163p16330163.html
 Sent from the Tapestry - User mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/T5%3A-nested-loops-don%27t-work-%28can%27t-figure-this-one-out%29-tp16330163p16347650.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [T5] Form errors persisted in session?

2008-03-28 Thread Kristian Marinkovic
hi,

this came up several times on this list... and i think there was also
a JIRA entry

the answers are:
1) add a @Meta annotation to change the strategy of @Persist 
without attribute (Howard)

2) clear the errors manually (as pointed out by Angelo)

3) pass in a own ValidationTracker instance to the Form being 
persisted with @Persist(flash) (tracker parameter)

4) more general solution to 3) create your own Form component
by extending Tapestry Form 

for more details search the list (www.nabble.com,...)

g,
kris




Renat Zubairov [EMAIL PROTECTED] 
28.03.2008 09:11
Bitte antworten an
Tapestry users users@tapestry.apache.org


An
Tapestry users users@tapestry.apache.org
Kopie

Thema
Re: [T5] Form errors persisted in session?







Hi

Thanks for the info, but generally IMHO it's a bug when error
validation status is stored in the session. How do you think?

Renat

On 27/03/2008, Angelo Chen [EMAIL PROTECTED] wrote:

  how about:

  @Component
private Form regForm;
  void cleanupRender() {
   regForm.clearErrors();

   }


  Renat Zubairov wrote:
  
   Hi
  
   Where are the validation results of the BeanEdit persisted in T5?
   I disabled javascript then submited empty form, then enabled
   javascript and opened empty form without any sumbit, but errors are
   still there. Only when I dropped the cookie error
   messages went away.
  
   --
   Best regards,
   Renat Zubairov
  

  -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  

  --

 View this message in context: 
http://www.nabble.com/-T5--Form-errors-persisted-in-session--tp16339068p16340460.html

  Sent from the Tapestry - User mailing list archive at Nabble.com.



  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Best regards,
Renat Zubairov

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: T5: How do I get session information?

2008-03-28 Thread Cordenier Christophe
Hello

You can inject the Request Tapestry service and then get the Session object 
from this service.
This is the Tapestry Session object that wraps the J2EE one and gives you 
access to the content of the session.

I Hope this helps

Christophe

-Message d'origine-
De : Joshua Jackson [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 09:37
À : Tapestry users
Objet : T5: How do I get session information?

Dear all,

How do I retrieved information that is stored in a session from my
Page component? I could not find this in the docs.

Thanks in advance

--
Let's show the world what we've got.

Blog: http://joshuajava.wordpress.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Ce message et les pièces jointes sont confidentiels et réservés à l'usage 
exclusif de ses destinataires. Il peut également être protégé par le secret 
professionnel. Si vous recevez ce message par erreur, merci d'en avertir 
immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant 
être assurée sur Internet, la responsabilité du groupe Atos Origin ne pourra 
être recherchée quant au contenu de ce message. Bien que les meilleurs efforts 
soient faits pour maintenir cette transmission exempte de tout virus, 
l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne 
saurait être recherchée pour tout dommage résultant d'un virus transmis.

This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos Origin group liability cannot be triggered 
for the message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable for any damages resulting from any virus 
transmitted.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: How do I get session information?

2008-03-28 Thread Joshua Jackson
On 3/28/08, Cordenier Christophe [EMAIL PROTECTED] wrote:
 Hello

 You can inject the Request Tapestry service and then get the Session object 
 from this service.
 This is the Tapestry Session object that wraps the J2EE one and gives you 
 access to the content of the session.

 I Hope this helps

 Christophe

Thanks. :)

I'm going to try it out.

Cheers,

-- 
Let's show the world what we've got.

Blog: http://joshuajava.wordpress.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



How to change t-error

2008-03-28 Thread osamuo

How can I change the 't-error' defined in 'default.css' to other CSS classes?

Thank you
-- 
View this message in context: 
http://www.nabble.com/How-to-change-t-error-tp16348102p16348102.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



T5: How do I get session information?

2008-03-28 Thread Joshua Jackson
Dear all,

How do I retrieved information that is stored in a session from my
Page component? I could not find this in the docs.

Thanks in advance

-- 
Let's show the world what we've got.

Blog: http://joshuajava.wordpress.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How to change t-error

2008-03-28 Thread Cordenier Christophe
I think you just have to add this CSS class in your own CSS file.
To add your own CSS you can use the PageRenderSupport service or use the 
@IncludeStylesheet annotation in your component class.

Hope this helps

Christophe

-Message d'origine-
De : osamuo [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 10:00
À : users@tapestry.apache.org
Objet : How to change t-error


How can I change the 't-error' defined in 'default.css' to other CSS classes?

Thank you
--
View this message in context: 
http://www.nabble.com/How-to-change-t-error-tp16348102p16348102.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Ce message et les pièces jointes sont confidentiels et réservés à l'usage 
exclusif de ses destinataires. Il peut également être protégé par le secret 
professionnel. Si vous recevez ce message par erreur, merci d'en avertir 
immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant 
être assurée sur Internet, la responsabilité du groupe Atos Origin ne pourra 
être recherchée quant au contenu de ce message. Bien que les meilleurs efforts 
soient faits pour maintenir cette transmission exempte de tout virus, 
l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne 
saurait être recherchée pour tout dommage résultant d'un virus transmis.

This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos Origin group liability cannot be triggered 
for the message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable for any damages resulting from any virus 
transmitted.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5 (5.0.11) - ready for production deployment

2008-03-28 Thread Rob Smeets
Howard,

I have 2 favorite adjectives about Tapestry 5: Over-engineerd and Volatile!!

Best wishes,

Rob

On Fri, Mar 28, 2008 at 1:35 AM, Howard Lewis Ship [EMAIL PROTECTED] wrote:

 Fun is one of my favorite adjectives for Tapestry.

 On Thu, Mar 27, 2008 at 5:20 PM, Josh Canfield [EMAIL PROTECTED]
 wrote:
   There is another public website, thedailytube.com, developed with T5
by some member of this list I can't recall his name. :P
 
   That'd be me :)
 
   The site went up with 5.0.5, and currently on 5.0.10.
 
   Tapestry 5 is rendering everything, the site, the RSS feeds, the
   content for the email newsletters and the CMS that runs the backend.
   It's been a fun framework to develop in.
 
   Josh
 
 
 
   On Thu, Mar 27, 2008 at 3:19 PM, Thiago HP [EMAIL PROTECTED] wrote:
In the company I worked for until two weeks ago, I developed an
internal application with T5 and it's already in production. That was
a very successful experience, so the same company is now developing
another one in T5.
   
There is another public website, thedailytube.com, developed with T5
by some member of this list I can't recall his name. :P
   
--
Thiago
   
   
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
   
   
 
 
 
   --
   --
   TheDailyTube.com. Sign up and get the best new videos on the internet
   delivered fresh to your inbox.
 
 
 
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
 
 



 --
 Howard M. Lewis Ship

 Creator Apache Tapestry and Apache HiveMind

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




RE: How to change t-error

2008-03-28 Thread osamuo

Is  the following available?

configuration.add( TapestryConstants.ERROR_CLASS, my-t-error );

Thanks.






Cordenier Christophe wrote:
 
 I think you just have to add this CSS class in your own CSS file.
 To add your own CSS you can use the PageRenderSupport service or use the
 @IncludeStylesheet annotation in your component class.
 
 Hope this helps
 
 Christophe
 
 -Message d'origine-
 De : osamuo [mailto:[EMAIL PROTECTED]
 Envoyé : vendredi 28 mars 2008 10:00
 À : users@tapestry.apache.org
 Objet : How to change t-error
 
 
 How can I change the 't-error' defined in 'default.css' to other CSS
 classes?
 
 Thank you
 --
 View this message in context:
 http://www.nabble.com/How-to-change-t-error-tp16348102p16348102.html
 Sent from the Tapestry - User mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 Ce message et les pièces jointes sont confidentiels et réservés à l'usage
 exclusif de ses destinataires. Il peut également être protégé par le
 secret professionnel. Si vous recevez ce message par erreur, merci d'en
 avertir immédiatement l'expéditeur et de le détruire. L'intégrité du
 message ne pouvant être assurée sur Internet, la responsabilité du groupe
 Atos Origin ne pourra être recherchée quant au contenu de ce message. Bien
 que les meilleurs efforts soient faits pour maintenir cette transmission
 exempte de tout virus, l'expéditeur ne donne aucune garantie à cet égard
 et sa responsabilité ne saurait être recherchée pour tout dommage
 résultant d'un virus transmis.
 
 This e-mail and the documents attached are confidential and intended
 solely for the addressee; it may also be privileged. If you receive this
 e-mail in error, please notify the sender immediately and destroy it. As
 its integrity cannot be secured on the Internet, the Atos Origin group
 liability cannot be triggered for the message content. Although the sender
 endeavours to maintain a computer virus-free network, the sender does not
 warrant that this transmission is virus-free and will not be liable for
 any damages resulting from any virus transmitted.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/How-to-change-t-error-tp16348102p16348989.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: How do I get session information?

2008-03-28 Thread Kristian Marinkovic
i assume you want to access the persistent property of a 
component somewhere else!?...

some tips you might find useful.. regarding state (there are
always advantages and disadvantages to these approaches):

- component parameters are bidirectional; if you assign a new
value to a parameter from within a component its value gets
available in the root component/page as well

- use an ApplicationStateObject to share state accross 
your application (multiple pages, components)

- utilize the Environment service to share state within 
a hierarchy of components

i hope this helps
g,
kris




Joshua Jackson [EMAIL PROTECTED] 
28.03.2008 09:54
Bitte antworten an
Tapestry users users@tapestry.apache.org


An
Tapestry users users@tapestry.apache.org
Kopie

Thema
Re: T5: How do I get session information?







On 3/28/08, Cordenier Christophe [EMAIL PROTECTED] 
wrote:
 Hello

 You can inject the Request Tapestry service and then get the Session 
object from this service.
 This is the Tapestry Session object that wraps the J2EE one and gives 
you access to the content of the session.

 I Hope this helps

 Christophe

Thanks. :)

I'm going to try it out.

Cheers,

-- 
Let's show the world what we've got.

Blog: http://joshuajava.wordpress.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: T5: How do I get session information?

2008-03-28 Thread Joshua Jackson
On 3/28/08, Kristian Marinkovic [EMAIL PROTECTED] wrote:
 i assume you want to access the persistent property of a
 component somewhere else!?...

Actually I want to get the login session info from Spring security 2.0
I though the best way is to get it manually from the Sessin object.



 some tips you might find useful.. regarding state (there are
 always advantages and disadvantages to these approaches):

 - component parameters are bidirectional; if you assign a new
 value to a parameter from within a component its value gets
 available in the root component/page as well

 - use an ApplicationStateObject to share state accross
 your application (multiple pages, components)

 - utilize the Environment service to share state within
 a hierarchy of components

-- 
Let's show the world what we've got.

Blog: http://joshuajava.wordpress.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: Cannot get org.acegisecurity.CredentialsExpiredException to work

2008-03-28 Thread Olle Hallin
Hi, I found the solution.

It was an empty AuthenticationProcessingFilter.exceptionMappings that caused
all
AuthenticationExceptions to be treated equally.

I added a default public static Properties
buildAuthenticationExceptionMappings() to SecurityModule.java, which maps
certain AuthenticationExceptions to ${acegi.accessDenied.url} if it is
defined, and then sets this mapping in
buildAuthenticationProcessingFilter().

The user of the tapestry5-acegi module can then override this default
mapping
in his own AppModule, e.g., to map CredentialsExpiredException and
LockedException to different URLs.

I've attached the modified SecurityModule.java, with my changes marked with
// patch

Regards,
Olle



2008/3/17, Robin Helgelin [EMAIL PROTECTED]:

 On Mon, Mar 17, 2008 at 8:40 AM, Olle Hallin [EMAIL PROTECTED]
 wrote:
   It properly catches the CredentialsExpiredException that was thrown by
 the
   UsernamePasswordAuthenticationToken and tries to publish the event, but
 the
   ProviderManager.applicationEventPublisher is null.
 
   I don't know the inner mechanics of Acegi nor tapestry-ioc well enough
 to
   inject that dependency myself, so help would be appreciated.


 Looking at the code it seems there must be an
 ApplicationEventPublished defined. I''m too green in spring for this,
 but I'll look into it.


 --

 regards,
   Robin

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Olle Hallin M.Sc.
+46 70 6653071
[EMAIL PROTECTED]
www.hit.se
/*
 * Copyright 2007 Ivan Dubrov
 * Copyright 2007 Robin Helgelin
 *
 * Licensed under the Apache License, Version 2.0 (the License);
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an AS IS BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package nu.localhost.tapestry.acegi.services;

import java.util.List;
import java.util.Properties;

import nu.localhost.tapestry.acegi.services.internal.AcegiExceptionTranslationFilter;
import nu.localhost.tapestry.acegi.services.internal.AcegiWorker;
import nu.localhost.tapestry.acegi.services.internal.HttpServletRequestFilterWrapper;
import nu.localhost.tapestry.acegi.services.internal.LogoutServiceImpl;
import nu.localhost.tapestry.acegi.services.internal.RequestFilterWrapper;
import nu.localhost.tapestry.acegi.services.internal.SecurityChecker;
import nu.localhost.tapestry.acegi.services.internal.StaticSecurityChecker;

import org.acegisecurity.AccessDecisionManager;
import org.acegisecurity.AccountExpiredException;
import org.acegisecurity.AuthenticationManager;
import org.acegisecurity.AuthenticationTrustResolver;
import org.acegisecurity.AuthenticationTrustResolverImpl;
import org.acegisecurity.CredentialsExpiredException;
import org.acegisecurity.LockedException;
import org.acegisecurity.context.HttpSessionContextIntegrationFilter;
import org.acegisecurity.context.SecurityContextImpl;
import org.acegisecurity.providers.AuthenticationProvider;
import org.acegisecurity.providers.ProviderManager;
import org.acegisecurity.providers.anonymous.AnonymousAuthenticationProvider;
import org.acegisecurity.providers.anonymous.AnonymousProcessingFilter;
import org.acegisecurity.providers.dao.DaoAuthenticationProvider;
import org.acegisecurity.providers.dao.SaltSource;
import org.acegisecurity.providers.dao.salt.SystemWideSaltSource;
import org.acegisecurity.providers.encoding.PasswordEncoder;
import org.acegisecurity.providers.rememberme.RememberMeAuthenticationProvider;
import org.acegisecurity.ui.AccessDeniedHandlerImpl;
import org.acegisecurity.ui.AuthenticationEntryPoint;
import org.acegisecurity.ui.ExceptionTranslationFilter;
import org.acegisecurity.ui.logout.LogoutHandler;
import org.acegisecurity.ui.logout.SecurityContextLogoutHandler;
import org.acegisecurity.ui.rememberme.RememberMeProcessingFilter;
import org.acegisecurity.ui.rememberme.RememberMeServices;
import org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices;
import org.acegisecurity.ui.webapp.AuthenticationProcessingFilter;
import org.acegisecurity.ui.webapp.AuthenticationProcessingFilterEntryPoint;
import org.acegisecurity.userdetails.UserDetailsService;
import org.acegisecurity.userdetails.memory.UserAttribute;
import org.acegisecurity.userdetails.memory.UserAttributeEditor;
import org.acegisecurity.vote.AccessDecisionVoter;
import org.acegisecurity.vote.AffirmativeBased;
import org.acegisecurity.vote.RoleVoter;
import org.acegisecurity.wrapper.SecurityContextHolderAwareRequestFilter;
import org.apache.tapestry.ioc.Configuration;
import 

Re: T5:Problem with Beaneditor and autobuilding

2008-03-28 Thread Andreas Pursian

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Thanks Howard, your hint did the trick.

cheers

Andreas

Howard Lewis Ship wrote:
| I think what's happened is that there's a subtle change in the order
| of operations inside BeanEditForm and BeanEditor.
|
| They now build the BeanModel from the bound property type ... in this
| case, your abstract bean.
|
| I think youre best bet is to inject the BeanModelSource service, and
| obtain the right bean model for the specific sub-class class, and
| provide that to the BeanEditor (or BeanEditForm) via the model
| parameter.
|
| On Thu, Mar 27, 2008 at 6:40 PM, Andreas Pursian [EMAIL PROTECTED] wrote:
| -BEGIN PGP SIGNED MESSAGE-
|  Hash: SHA1
|
|  Hi list,
|
|  i just updated my t5 app from an early 5.0.11 Snapshot to the finally
|  release version. Unfortunatly i experienced some problems. One of the
|  app pages is using the beaneditor component to display and edit
|  different data beans. Different means, that there is not one specific
|  bean staticly bound to the beaneditor but an abstract super class works
|  as a placeholder for the specific bean instance which is instanciated
|  through a factory class during onActivate(). So the following code
|  snippet worked fine before the new autobuiling feature of beaneditor was
|  introduced.
|
|  @Persist(Flash)
|  private AbstractTaskData taskData;
|
|  void onActivate(Long Id) throws InstantiationException,
| ccmCase = cw.getCaseById(Id);
| if (ccmCase != null){
|
| TaskDataFactory taskDataFactory = new TaskDataFactory();
| taskData =
taskDataFactory.getTaskData(ccmCase.getStateData());
|
| } else System.out.println(Case is null ...);
|  }
|
|  Right now no specific error is thrown but beside the action buttons no
|  bean properties are rendered anymore, the page is just empty. If i alter
|  the abstract beaneditor datasource (taskData) to a specific data bean,
|  everything works fine beside that this static behavior is not the
|  intended task of the page.
|  So my question is, which changes are necessary to get the beaneditor
|  working again with a abstract data source which represents a specific
|  bean instance?
|
|  thanks a lot ...
|
|  Andreas
|  -BEGIN PGP SIGNATURE-
|  Version: GnuPG v1.4.7 (Darwin)
|  Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
|
|  iD8DBQFH7EyZM14O/Esx/74RAuI6AJ9ux4HxbkhbSiYWSZ0SSbhwWwxdTQCbBp+f
|  KsxjdNmtPBrVy1v46/hhGOA=
|  =bFbV
|  -END PGP SIGNATURE-
|
|  -
|  To unsubscribe, e-mail: [EMAIL PROTECTED]
|  For additional commands, e-mail: [EMAIL PROTECTED]
|
|
|
|
|
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.7 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFH7Na1M14O/Esx/74RAmxdAKDGsguGtQuj2MnhTBuQ2eXML6oYdACff5xA
YGx+VyUl2ECggCVHphLi/Xo=
=VcX0
-END PGP SIGNATURE-

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: Cannot get org.acegisecurity.CredentialsExpiredException to work

2008-03-28 Thread Olle Hallin
Hi again,

I've made a new version of the SecurityModule.java that follows the usual
build + contribute pattern in tapestry-ioc.

Sorry for the changed formatting, I hit Ctrl-Shift-F by accident in Eclipse.

Regards,
Olle

2008/3/28, Olle Hallin [EMAIL PROTECTED]:

 Hi, I found the solution.

 It was an empty AuthenticationProcessingFilter.exceptionMappings that
 caused all
 AuthenticationExceptions to be treated equally.

 I added a default public static Properties
 buildAuthenticationExceptionMappings() to SecurityModule.java, which maps
 certain AuthenticationExceptions to ${acegi.accessDenied.url} if it is
 defined, and then sets this mapping in
 buildAuthenticationProcessingFilter().

 The user of the tapestry5-acegi module can then override this default
 mapping
 in his own AppModule, e.g., to map CredentialsExpiredException and
 LockedException to different URLs.

 I've attached the modified SecurityModule.java, with my changes marked
 with // patch

 Regards,
 Olle


/*
 * Copyright 2007 Ivan Dubrov
 * Copyright 2007 Robin Helgelin
 *
 * Licensed under the Apache License, Version 2.0 (the License);
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an AS IS BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package nu.localhost.tapestry.acegi.services;

import java.util.List;
import java.util.Map;
import java.util.Properties;

import nu.localhost.tapestry.acegi.services.internal.AcegiExceptionTranslationFilter;
import nu.localhost.tapestry.acegi.services.internal.AcegiWorker;
import nu.localhost.tapestry.acegi.services.internal.HttpServletRequestFilterWrapper;
import nu.localhost.tapestry.acegi.services.internal.LogoutServiceImpl;
import nu.localhost.tapestry.acegi.services.internal.RequestFilterWrapper;
import nu.localhost.tapestry.acegi.services.internal.SecurityChecker;
import nu.localhost.tapestry.acegi.services.internal.StaticSecurityChecker;

import org.acegisecurity.AccessDecisionManager;
import org.acegisecurity.AccountExpiredException;
import org.acegisecurity.AuthenticationManager;
import org.acegisecurity.AuthenticationTrustResolver;
import org.acegisecurity.AuthenticationTrustResolverImpl;
import org.acegisecurity.CredentialsExpiredException;
import org.acegisecurity.LockedException;
import org.acegisecurity.context.HttpSessionContextIntegrationFilter;
import org.acegisecurity.context.SecurityContextImpl;
import org.acegisecurity.providers.AuthenticationProvider;
import org.acegisecurity.providers.ProviderManager;
import org.acegisecurity.providers.anonymous.AnonymousAuthenticationProvider;
import org.acegisecurity.providers.anonymous.AnonymousProcessingFilter;
import org.acegisecurity.providers.dao.DaoAuthenticationProvider;
import org.acegisecurity.providers.dao.SaltSource;
import org.acegisecurity.providers.dao.salt.SystemWideSaltSource;
import org.acegisecurity.providers.encoding.PasswordEncoder;
import org.acegisecurity.providers.rememberme.RememberMeAuthenticationProvider;
import org.acegisecurity.ui.AccessDeniedHandlerImpl;
import org.acegisecurity.ui.AuthenticationEntryPoint;
import org.acegisecurity.ui.ExceptionTranslationFilter;
import org.acegisecurity.ui.logout.LogoutHandler;
import org.acegisecurity.ui.logout.SecurityContextLogoutHandler;
import org.acegisecurity.ui.rememberme.RememberMeProcessingFilter;
import org.acegisecurity.ui.rememberme.RememberMeServices;
import org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices;
import org.acegisecurity.ui.webapp.AuthenticationProcessingFilter;
import org.acegisecurity.ui.webapp.AuthenticationProcessingFilterEntryPoint;
import org.acegisecurity.userdetails.UserDetailsService;
import org.acegisecurity.userdetails.memory.UserAttribute;
import org.acegisecurity.userdetails.memory.UserAttributeEditor;
import org.acegisecurity.vote.AccessDecisionVoter;
import org.acegisecurity.vote.AffirmativeBased;
import org.acegisecurity.vote.RoleVoter;
import org.acegisecurity.wrapper.SecurityContextHolderAwareRequestFilter;
import org.apache.tapestry.ioc.Configuration;
import org.apache.tapestry.ioc.MappedConfiguration;
import org.apache.tapestry.ioc.OrderedConfiguration;
import org.apache.tapestry.ioc.ServiceBinder;
import org.apache.tapestry.ioc.annotations.Inject;
import org.apache.tapestry.ioc.annotations.InjectService;
import org.apache.tapestry.ioc.annotations.Marker;
import org.apache.tapestry.ioc.annotations.Value;
import org.apache.tapestry.services.ComponentClassTransformWorker;
import org.apache.tapestry.services.HttpServletRequestFilter;
import org.apache.tapestry.services.LibraryMapping;
import org.apache.tapestry.services.RequestFilter;
import 

RE: T5 (5.0.11) - ready for production deployment

2008-03-28 Thread Jonathan Barker
Rob,

I can't resist...

Your over-engineerd comment was under-engineered.  Howard would have
surely added in the required number of e's in the word. Then it would be
properly-engineered :-)

As for volatile... you do know that T5 was just voted BETA last week, right?
ALPHA software is generally pretty volatile.

Say, you never did reply to my posting in another thread.  I was looking
forward to your response.


Jonathan


 -Original Message-
 From: Rob Smeets [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 5:35 AM
 To: Tapestry users
 Subject: Re: T5 (5.0.11) - ready for production deployment
 
 Howard,
 
 I have 2 favorite adjectives about Tapestry 5: Over-engineerd and
 Volatile!!
 
 Best wishes,
 
 Rob
 
 On Fri, Mar 28, 2008 at 1:35 AM, Howard Lewis Ship [EMAIL PROTECTED]
 wrote:
 
  Fun is one of my favorite adjectives for Tapestry.
 
  On Thu, Mar 27, 2008 at 5:20 PM, Josh Canfield [EMAIL PROTECTED]
  wrote:
There is another public website, thedailytube.com, developed with T5
 by some member of this list I can't recall his name. :P
  
That'd be me :)
  
The site went up with 5.0.5, and currently on 5.0.10.
  
Tapestry 5 is rendering everything, the site, the RSS feeds, the
content for the email newsletters and the CMS that runs the backend.
It's been a fun framework to develop in.
  
Josh
  
  
  
On Thu, Mar 27, 2008 at 3:19 PM, Thiago HP [EMAIL PROTECTED]
 wrote:
 In the company I worked for until two weeks ago, I developed an
 internal application with T5 and it's already in production. That
 was
 a very successful experience, so the same company is now developing
 another one in T5.

 There is another public website, thedailytube.com, developed with
 T5
 by some member of this list I can't recall his name. :P

 --
 Thiago


 ---
 --
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


  
  
  
--
--
TheDailyTube.com. Sign up and get the best new videos on the internet
delivered fresh to your inbox.
  
  
  
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 
 
  --
  Howard M. Lewis Ship
 
  Creator Apache Tapestry and Apache HiveMind
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: T5: How do I get session information?

2008-03-28 Thread Jonathan Barker

That's likely stored in the WebContext that can be directly injected using
tapestry-spring.



 -Original Message-
 From: Joshua Jackson [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 6:06 AM
 To: Tapestry users
 Subject: Re: T5: How do I get session information?
 
 On 3/28/08, Kristian Marinkovic [EMAIL PROTECTED] wrote:
  i assume you want to access the persistent property of a
  component somewhere else!?...
 
 Actually I want to get the login session info from Spring security 2.0
 I though the best way is to get it manually from the Sessin object.
 
 
 
  some tips you might find useful.. regarding state (there are
  always advantages and disadvantages to these approaches):
 
  - component parameters are bidirectional; if you assign a new
  value to a parameter from within a component its value gets
  available in the root component/page as well
 
  - use an ApplicationStateObject to share state accross
  your application (multiple pages, components)
 
  - utilize the Environment service to share state within
  a hierarchy of components
 
 --
 Let's show the world what we've got.
 
 Blog: http://joshuajava.wordpress.com/
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

2008-03-28 Thread Mahen Perera
Thanks Jonathan for that. 

Unclear on some stuff tho.
Since we are using a LDAP based authentication provider do we need to
have a UserDetailsServiceImpl?


http://www.localhost.nu/java/tapestry5-acegi/ : If I am to use this,
then it assumes having a UserDetailsServiceImpl. 

Also, when we do
configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
r)
How does the Acegi framework get to know abt the LDAP authentication
provider.



-Original Message-
From: Jonathan Barker [mailto:[EMAIL PROTECTED] 
Sent: 27 March 2008 18:28
To: 'Tapestry users'
Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

Here are the relevant portions (with identifying info stripped out) for
authentication with Active Directory.  With AD, you need to use
bind-based
authentication.

If you are using something like OpenLDAP, you may have access to the
password or password hash, so you would change the authenticator.


I have also lumped together building the BindAuthenticator, UserSearch,
DefaultLdapauthoritiesPopulator into the
buildLdapAuthenticationProvider()
function.  These could be factored out.
 
I'm also using an InMemoryDaoImpl for some development logins.

 
public final InitialDirContextFactory
buildInitialDirContextFactory(){
DefaultInitialDirContextFactory factory = new
DefaultInitialDirContextFactory(ldap://server.domain.com:389/DC=domain,
DC=c
om);
factory.setManagerDn(cn=Ldap Account ,OU=Service
Accounts,OU=People,DC=domain,DC=com);
factory.setManagerPassword(password);
MapString,String extraEnvVars = new HashMapString,String();
extraEnvVars.put(java.naming.referral, follow);
factory.setExtraEnvVars(extraEnvVars);
return factory;

}

public static AuthenticationProvider
buildLdapAuthenticationProvider(InitialDirContextFactory factory )
throws
Exception {

FilterBasedLdapUserSearch userSearch = new
FilterBasedLdapUserSearch(ou=People,(sAMAccountName={0}),factory);
userSearch.setSearchSubtree(true);
userSearch.setDerefLinkFlag(true);

BindAuthenticator authenticator = new
BindAuthenticator(factory);
authenticator.setUserSearch(userSearch);
authenticator.afterPropertiesSet();

DefaultLdapAuthoritiesPopulator populator = new
DefaultLdapAuthoritiesPopulator(factory,);
populator.setGroupRoleAttribute(cn);
populator.setGroupSearchFilter(member={0});
populator.setDefaultRole(ROLE_ANONYMOUS);
populator.setConvertToUpperCase(true);
populator.setSearchSubtree(true);
populator.setRolePrefix(ROLE_);

LdapAuthenticationProvider provider = new
LdapAuthenticationProvider(authenticator,populator);
return provider;
}


public static void contributeProviderManager(
OrderedConfigurationAuthenticationProvider configuration,
@InjectService(DaoAuthenticationProvider) AuthenticationProvider
daoAuthenticationProvider, @InjectService(LdapAuthenticationProvider)
AuthenticationProvider ldapAuthenticationProvider){
 
configuration.add(daoAuthenticationProvider,daoAuthenticationProvider)
;
 
configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
r);
}

 -Original Message-
 From: Mahen Perera [mailto:[EMAIL PROTECTED]
 Sent: Thursday, March 27, 2008 10:14 AM
 To: users@tapestry.apache.org
 Subject: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Hi everybody.
 
 
 
 I am trying to integrate tapestry 5 with Acegi security.
 
 The authentication provider that I am using is LDAP based.
 
 
 
 I see that most of the examples refer to using DAOAuthentication
 provider.
 
 Just checking if there is someone who used LDAP for the
authentication.
 
 
 
 I went thru http://www.localhost.nu/java/tapestry5-acegi/
 
 , but looks like it is not using LDAP authentication.
 
 
 
 Cheers
 
 
 
 The information contained in this email is strictly confidential and
for
 the use of the addressee only, unless otherwise indicated. If you are
not
 the intended recipient, please do not read, copy, use or disclose to
 others this message or any attachment. Please also notify the sender
by
 replying to this email or by telephone (+44 (0)20 7896 0011) and then
 delete the email and any copies of it. Opinions, conclusions (etc.)
that
 do not relate to the official business of this company shall be
understood
 as neither given nor endorsed by it. IG Index plc is a company
registered
 in England and Wales under number 01190902. VAT registration number
761
 2978 07. Registered Office: Friars House, 157-168 Blackfriars Road,
London
 SE1 8EZ. Authorised and regulated by the Financial Services Authority.
FSA
 Register number 114059.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

The information contained in this email is strictly 

T5: Custom asset locator?

2008-03-28 Thread Andreas Pardeike

Hi everyone,

First: many many thanks to the list for all the valuable info I
get from it (either as passive reading or answers to my questions!)

My problem: I want to expand the virtual /assets mapping because
in the app I am writing, I use the current host name to run different
sites/layouts.

So I want to implement that

Host: www.SITE_A.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_A/i/test.gif

and

Host: www.SITE_B.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_B/i/test.gif

instead of the default way to do it by using

img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
or @Path(classpath:${host}/i/test.gif)

and have it dynamically expand to the same paths. The motivation behind
this is that

a) users at SITE_A could replace the url with 'SITE_B' and peek at other
   resources

b) the url's get very long and for some reason I don't want to go into
   here, I need to match the URLs style with some dynamic paths that
   fetch resources from a db - there, I automatically take care of the
   host name.

I couldn't find a example on how to expand/overwrite asset lookup (in
the same way I expanded template lookup). All I want is to add a
subfolder on the fly to the asset path and still use the same build
in asset service.

/Andreas Pardeike

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: T5: Custom asset locator?

2008-03-28 Thread Cordenier Christophe
Hello

I'm not sure this can help, this is just an idea,
but maybe it would be easier to create a new type of binding Factory upon the 
AssetBinding factory to add dynamic datas.

Best regards,
Christophe.

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 14:58
À : Tapestry users
Objet : T5: Custom asset locator?

Hi everyone,

First: many many thanks to the list for all the valuable info I
get from it (either as passive reading or answers to my questions!)

My problem: I want to expand the virtual /assets mapping because
in the app I am writing, I use the current host name to run different
sites/layouts.

So I want to implement that

Host: www.SITE_A.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_A/i/test.gif

and

Host: www.SITE_B.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_B/i/test.gif

instead of the default way to do it by using

img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
or @Path(classpath:${host}/i/test.gif)

and have it dynamically expand to the same paths. The motivation behind
this is that

a) users at SITE_A could replace the url with 'SITE_B' and peek at other
resources

b) the url's get very long and for some reason I don't want to go into
here, I need to match the URLs style with some dynamic paths that
fetch resources from a db - there, I automatically take care of the
host name.

I couldn't find a example on how to expand/overwrite asset lookup (in
the same way I expanded template lookup). All I want is to add a
subfolder on the fly to the asset path and still use the same build
in asset service.

/Andreas Pardeike

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Ce message et les pièces jointes sont confidentiels et réservés à l'usage 
exclusif de ses destinataires. Il peut également être protégé par le secret 
professionnel. Si vous recevez ce message par erreur, merci d'en avertir 
immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant 
être assurée sur Internet, la responsabilité du groupe Atos Origin ne pourra 
être recherchée quant au contenu de ce message. Bien que les meilleurs efforts 
soient faits pour maintenir cette transmission exempte de tout virus, 
l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne 
saurait être recherchée pour tout dommage résultant d'un virus transmis.

This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos Origin group liability cannot be triggered 
for the message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable for any damages resulting from any virus 
transmitted.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: Custom asset locator?

2008-03-28 Thread Andreas Pardeike

Thanks Christope, but it's not quite what I want. To illustrate
my problem, take a look at the request headers I want to process:

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_A.com

and

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_B.com

If I just create my own binding, the request urls would still contain
the real folder inside /assets and my requests would look like

GET /assets/SITE_A/i/test.gif HTTP/1.1
GET /assets/SITE_B/i/test.gif HTTP/1.1

which I rather not want.

/Andreas

On 28 mar 2008, at 15.10, Cordenier Christophe wrote:

Hello

I'm not sure this can help, this is just an idea,
but maybe it would be easier to create a new type of binding Factory  
upon the AssetBinding factory to add dynamic datas.


Best regards,
Christophe.

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 14:58
À : Tapestry users
Objet : T5: Custom asset locator?

Hi everyone,

First: many many thanks to the list for all the valuable info I
get from it (either as passive reading or answers to my questions!)

My problem: I want to expand the virtual /assets mapping because
in the app I am writing, I use the current host name to run different
sites/layouts.

So I want to implement that

Host: www.SITE_A.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_A/i/test.gif

and

Host: www.SITE_B.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_B/i/test.gif

instead of the default way to do it by using

img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
or @Path(classpath:${host}/i/test.gif)

and have it dynamically expand to the same paths. The motivation  
behind

this is that

a) users at SITE_A could replace the url with 'SITE_B' and peek at  
other

   resources

b) the url's get very long and for some reason I don't want to go into
   here, I need to match the URLs style with some dynamic paths that
   fetch resources from a db - there, I automatically take care of the
   host name.

I couldn't find a example on how to expand/overwrite asset lookup (in
the same way I expanded template lookup). All I want is to add a
subfolder on the fly to the asset path and still use the same build
in asset service.

/Andreas Pardeike

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Ce message et les pièces jointes sont confidentiels et réservés à  
l'usage exclusif de ses destinataires. Il peut également être  
protégé par le secret professionnel. Si vous recevez ce message par  
erreur, merci d'en avertir immédiatement l'expéditeur et de le  
détruire. L'intégrité du message ne pouvant être assurée sur  
Internet, la responsabilité du groupe Atos Origin ne pourra être  
recherchée quant au contenu de ce message. Bien que les meilleurs  
efforts soient faits pour maintenir cette transmission exempte de  
tout virus, l'expéditeur ne donne aucune garantie à cet égard et sa  
responsabilité ne saurait être recherchée pour tout dommage  
résultant d'un virus transmis.


This e-mail and the documents attached are confidential and intended  
solely for the addressee; it may also be privileged. If you receive  
this e-mail in error, please notify the sender immediately and  
destroy it. As its integrity cannot be secured on the Internet, the  
Atos Origin group liability cannot be triggered for the message  
content. Although the sender endeavours to maintain a computer virus- 
free network, the sender does not warrant that this transmission is  
virus-free and will not be liable for any damages resulting from any  
virus transmitted.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

2008-03-28 Thread Jonathan Barker

All of the classes are from Acegi.  The LdapAuthenticationProvider returns a
LdapUserDetails object.

There are a number of ways to get Acegi to authenticate you.  Here's part of
what I do from a Login form where I automatically add authenticated users to
a Users table (it needs a bit of cleaning up):

UsernamePasswordAuthenticationToken authRequest = 
new
UsernamePasswordAuthenticationToken(_username,_password);
Authentication authResult;

try {
authResult =
_authenticationManager.authenticate(authRequest);
logger.info(successful login for:  + _username);
// now see if they exist in the database:
User user = new User();
user.setUsername(_username);
ListUser matches = _userDao.findByExample(user);
if (matches.isEmpty()){
Object principal =
authResult.getPrincipal();
if (principal instanceof LdapUserDetails){
logger.info(adding new LDAP user
);
LdapUserDetails details =
(LdapUserDetails) principal;

logger.info(details.getAttributes().getIDs().toString());
Attribute nameAttr =
details.getAttributes().get(name);
Object o;
try {
o = nameAttr.get();
if (o!= null  o instanceof
String )

user.setLastName((String)o);
else

user.setLastName(_username);
 you get the idea




 -Original Message-
 From: Mahen Perera [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 9:50 AM
 To: Tapestry users
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Thanks Jonathan for that.
 
 Unclear on some stuff tho.
 Since we are using a LDAP based authentication provider do we need to
 have a UserDetailsServiceImpl?
 
 
 http://www.localhost.nu/java/tapestry5-acegi/ : If I am to use this,
 then it assumes having a UserDetailsServiceImpl.
 
 Also, when we do
 configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
 r)
 How does the Acegi framework get to know abt the LDAP authentication
 provider.
 
 
 
 -Original Message-
 From: Jonathan Barker [mailto:[EMAIL PROTECTED]
 Sent: 27 March 2008 18:28
 To: 'Tapestry users'
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Here are the relevant portions (with identifying info stripped out) for
 authentication with Active Directory.  With AD, you need to use
 bind-based
 authentication.
 
 If you are using something like OpenLDAP, you may have access to the
 password or password hash, so you would change the authenticator.
 
 
 I have also lumped together building the BindAuthenticator, UserSearch,
 DefaultLdapauthoritiesPopulator into the
 buildLdapAuthenticationProvider()
 function.  These could be factored out.
 
 I'm also using an InMemoryDaoImpl for some development logins.
 
 
 public final InitialDirContextFactory
 buildInitialDirContextFactory(){
   DefaultInitialDirContextFactory factory = new
 DefaultInitialDirContextFactory(ldap://server.domain.com:389/DC=domain,
 DC=c
 om);
   factory.setManagerDn(cn=Ldap Account ,OU=Service
 Accounts,OU=People,DC=domain,DC=com);
   factory.setManagerPassword(password);
   MapString,String extraEnvVars = new HashMapString,String();
   extraEnvVars.put(java.naming.referral, follow);
   factory.setExtraEnvVars(extraEnvVars);
   return factory;
 
 }
 
 public static AuthenticationProvider
 buildLdapAuthenticationProvider(InitialDirContextFactory factory )
 throws
 Exception {
 
   FilterBasedLdapUserSearch userSearch = new
 FilterBasedLdapUserSearch(ou=People,(sAMAccountName={0}),factory);
   userSearch.setSearchSubtree(true);
   userSearch.setDerefLinkFlag(true);
 
   BindAuthenticator authenticator = new
 BindAuthenticator(factory);
   authenticator.setUserSearch(userSearch);
   authenticator.afterPropertiesSet();
 
   DefaultLdapAuthoritiesPopulator populator = new
 DefaultLdapAuthoritiesPopulator(factory,);
   populator.setGroupRoleAttribute(cn);
   populator.setGroupSearchFilter(member={0});
   populator.setDefaultRole(ROLE_ANONYMOUS);
   populator.setConvertToUpperCase(true);
   populator.setSearchSubtree(true);
   populator.setRolePrefix(ROLE_);
 
   LdapAuthenticationProvider provider = new
 LdapAuthenticationProvider(authenticator,populator);
   return provider;
 }
 
 
 public static void contributeProviderManager(
 OrderedConfigurationAuthenticationProvider 

RE: T5: Custom asset locator?

2008-03-28 Thread Cordenier Christophe
And what about a custom AssetDispatcher ?

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 15:22
À : Tapestry users
Objet : Re: T5: Custom asset locator?

Thanks Christope, but it's not quite what I want. To illustrate
my problem, take a look at the request headers I want to process:

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_A.com

and

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_B.com

If I just create my own binding, the request urls would still contain
the real folder inside /assets and my requests would look like

GET /assets/SITE_A/i/test.gif HTTP/1.1
GET /assets/SITE_B/i/test.gif HTTP/1.1

which I rather not want.

/Andreas

On 28 mar 2008, at 15.10, Cordenier Christophe wrote:
 Hello

 I'm not sure this can help, this is just an idea,
 but maybe it would be easier to create a new type of binding Factory
 upon the AssetBinding factory to add dynamic datas.

 Best regards,
 Christophe.

 -Message d'origine-
 De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
 Envoyé : vendredi 28 mars 2008 14:58
 À : Tapestry users
 Objet : T5: Custom asset locator?

 Hi everyone,

 First: many many thanks to the list for all the valuable info I
 get from it (either as passive reading or answers to my questions!)

 My problem: I want to expand the virtual /assets mapping because
 in the app I am writing, I use the current host name to run different
 sites/layouts.

 So I want to implement that

 Host: www.SITE_A.com
 img src=${asset:classpath:/i/test.gif} /
 points to SITE_A/i/test.gif

 and

 Host: www.SITE_B.com
 img src=${asset:classpath:/i/test.gif} /
 points to SITE_B/i/test.gif

 instead of the default way to do it by using

 img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
 or @Path(classpath:${host}/i/test.gif)

 and have it dynamically expand to the same paths. The motivation
 behind
 this is that

 a) users at SITE_A could replace the url with 'SITE_B' and peek at
 other
resources

 b) the url's get very long and for some reason I don't want to go into
here, I need to match the URLs style with some dynamic paths that
fetch resources from a db - there, I automatically take care of the
host name.

 I couldn't find a example on how to expand/overwrite asset lookup (in
 the same way I expanded template lookup). All I want is to add a
 subfolder on the fly to the asset path and still use the same build
 in asset service.

 /Andreas Pardeike

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




 Ce message et les pièces jointes sont confidentiels et réservés à
 l'usage exclusif de ses destinataires. Il peut également être
 protégé par le secret professionnel. Si vous recevez ce message par
 erreur, merci d'en avertir immédiatement l'expéditeur et de le
 détruire. L'intégrité du message ne pouvant être assurée sur
 Internet, la responsabilité du groupe Atos Origin ne pourra être
 recherchée quant au contenu de ce message. Bien que les meilleurs
 efforts soient faits pour maintenir cette transmission exempte de
 tout virus, l'expéditeur ne donne aucune garantie à cet égard et sa
 responsabilité ne saurait être recherchée pour tout dommage
 résultant d'un virus transmis.

 This e-mail and the documents attached are confidential and intended
 solely for the addressee; it may also be privileged. If you receive
 this e-mail in error, please notify the sender immediately and
 destroy it. As its integrity cannot be secured on the Internet, the
 Atos Origin group liability cannot be triggered for the message
 content. Although the sender endeavours to maintain a computer virus-
 free network, the sender does not warrant that this transmission is
 virus-free and will not be liable for any damages resulting from any
 virus transmitted.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Ce message et les pièces jointes sont confidentiels et réservés à l'usage 
exclusif de ses destinataires. Il peut également être protégé par le secret 
professionnel. Si vous recevez ce message par erreur, merci d'en avertir 
immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant 
être assurée sur Internet, la responsabilité du groupe Atos Origin ne pourra 
être recherchée quant au contenu de ce message. Bien que les meilleurs efforts 
soient faits pour maintenir cette transmission exempte de tout virus, 
l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne 
saurait être recherchée pour tout dommage résultant d'un virus transmis.

This e-mail and the documents attached are confidential and intended solely for 

RE: Tapestry 5 - Acegi ,, using LDAP authentication provider - other half

2008-03-28 Thread Jonathan Barker

I realized I may not have answered your second question.

The configuration built up using 

configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvider);

is used in the SecurityModule of tapestry5-acegi for:

public static AuthenticationManager buildProviderManager(final List
AuthenticationProvider  providers)

This is just standard tapestry-ioc design.

If you read the Acegi docs, everything talks Spring.  But if every time you
see a build method in tapestry-ioc, you look for a bean definition in
Spring, things will suddenly make sense.  Then look at how lists are passed
to beans in Spring, and you will understand all of the contribute methods.


Jonathan


 -Original Message-
 From: Mahen Perera [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 9:50 AM
 To: Tapestry users
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Thanks Jonathan for that.
 
 Unclear on some stuff tho.
 Since we are using a LDAP based authentication provider do we need to
 have a UserDetailsServiceImpl?
 
 
 http://www.localhost.nu/java/tapestry5-acegi/ : If I am to use this,
 then it assumes having a UserDetailsServiceImpl.
 
 Also, when we do
 configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
 r)
 How does the Acegi framework get to know abt the LDAP authentication
 provider.
 
 
 
 -Original Message-
 From: Jonathan Barker [mailto:[EMAIL PROTECTED]
 Sent: 27 March 2008 18:28
 To: 'Tapestry users'
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Here are the relevant portions (with identifying info stripped out) for
 authentication with Active Directory.  With AD, you need to use
 bind-based
 authentication.
 
 If you are using something like OpenLDAP, you may have access to the
 password or password hash, so you would change the authenticator.
 
 
 I have also lumped together building the BindAuthenticator, UserSearch,
 DefaultLdapauthoritiesPopulator into the
 buildLdapAuthenticationProvider()
 function.  These could be factored out.
 
 I'm also using an InMemoryDaoImpl for some development logins.
 
 
 public final InitialDirContextFactory
 buildInitialDirContextFactory(){
   DefaultInitialDirContextFactory factory = new
 DefaultInitialDirContextFactory(ldap://server.domain.com:389/DC=domain,
 DC=c
 om);
   factory.setManagerDn(cn=Ldap Account ,OU=Service
 Accounts,OU=People,DC=domain,DC=com);
   factory.setManagerPassword(password);
   MapString,String extraEnvVars = new HashMapString,String();
   extraEnvVars.put(java.naming.referral, follow);
   factory.setExtraEnvVars(extraEnvVars);
   return factory;
 
 }
 
 public static AuthenticationProvider
 buildLdapAuthenticationProvider(InitialDirContextFactory factory )
 throws
 Exception {
 
   FilterBasedLdapUserSearch userSearch = new
 FilterBasedLdapUserSearch(ou=People,(sAMAccountName={0}),factory);
   userSearch.setSearchSubtree(true);
   userSearch.setDerefLinkFlag(true);
 
   BindAuthenticator authenticator = new
 BindAuthenticator(factory);
   authenticator.setUserSearch(userSearch);
   authenticator.afterPropertiesSet();
 
   DefaultLdapAuthoritiesPopulator populator = new
 DefaultLdapAuthoritiesPopulator(factory,);
   populator.setGroupRoleAttribute(cn);
   populator.setGroupSearchFilter(member={0});
   populator.setDefaultRole(ROLE_ANONYMOUS);
   populator.setConvertToUpperCase(true);
   populator.setSearchSubtree(true);
   populator.setRolePrefix(ROLE_);
 
   LdapAuthenticationProvider provider = new
 LdapAuthenticationProvider(authenticator,populator);
   return provider;
 }
 
 
 public static void contributeProviderManager(
 OrderedConfigurationAuthenticationProvider configuration,
 @InjectService(DaoAuthenticationProvider) AuthenticationProvider
 daoAuthenticationProvider, @InjectService(LdapAuthenticationProvider)
 AuthenticationProvider ldapAuthenticationProvider){
 
 configuration.add(daoAuthenticationProvider,daoAuthenticationProvider)
 ;
 
 configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
 r);
 }
 
  -Original Message-
  From: Mahen Perera [mailto:[EMAIL PROTECTED]
  Sent: Thursday, March 27, 2008 10:14 AM
  To: users@tapestry.apache.org
  Subject: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
  Hi everybody.
 
 
 
  I am trying to integrate tapestry 5 with Acegi security.
 
  The authentication provider that I am using is LDAP based.
 
 
 
  I see that most of the examples refer to using DAOAuthentication
  provider.
 
  Just checking if there is someone who used LDAP for the
 authentication.
 
 
 
  I went thru http://www.localhost.nu/java/tapestry5-acegi/
 
  , but looks like it is not using LDAP authentication.
 
 
 
  Cheers
 
 
 
  The information contained in this email is strictly confidential and
 for
  the use of the addressee only, unless otherwise indicated. If you are
 not
  the 

Re: T5: Custom asset locator?

2008-03-28 Thread Andreas Pardeike

Yes, I think that would work. Only problem there is that I still
want to have all benefits of caching that the build-in services
deliver. And I can't see how to just *modify* the asset path
inside the dispatcher and pass it on to Tapestry...

/Andreas

On 28 mar 2008, at 15.36, Cordenier Christophe wrote:


And what about a custom AssetDispatcher ?

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 15:22
À : Tapestry users
Objet : Re: T5: Custom asset locator?

Thanks Christope, but it's not quite what I want. To illustrate
my problem, take a look at the request headers I want to process:

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_A.com

and

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_B.com

If I just create my own binding, the request urls would still contain
the real folder inside /assets and my requests would look like

GET /assets/SITE_A/i/test.gif HTTP/1.1
GET /assets/SITE_B/i/test.gif HTTP/1.1

which I rather not want.

/Andreas

On 28 mar 2008, at 15.10, Cordenier Christophe wrote:

Hello

I'm not sure this can help, this is just an idea,
but maybe it would be easier to create a new type of binding Factory
upon the AssetBinding factory to add dynamic datas.

Best regards,
Christophe.

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 14:58
À : Tapestry users
Objet : T5: Custom asset locator?

Hi everyone,

First: many many thanks to the list for all the valuable info I
get from it (either as passive reading or answers to my questions!)

My problem: I want to expand the virtual /assets mapping because
in the app I am writing, I use the current host name to run different
sites/layouts.

So I want to implement that

Host: www.SITE_A.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_A/i/test.gif

and

Host: www.SITE_B.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_B/i/test.gif

instead of the default way to do it by using

img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
or @Path(classpath:${host}/i/test.gif)

and have it dynamically expand to the same paths. The motivation
behind
this is that

a) users at SITE_A could replace the url with 'SITE_B' and peek at
other
  resources

b) the url's get very long and for some reason I don't want to go  
into

  here, I need to match the URLs style with some dynamic paths that
  fetch resources from a db - there, I automatically take care of the
  host name.

I couldn't find a example on how to expand/overwrite asset lookup (in
the same way I expanded template lookup). All I want is to add a
subfolder on the fly to the asset path and still use the same build
in asset service.

/Andreas Pardeike


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: T5: Custom asset locator?

2008-03-28 Thread Cordenier Christophe
Maybe you can wrap the Request Tapestry object in a RequestFilter and then just 
modify the getPath() in the case of an asset URL.
Thereafter, You can use RequestGlobals service to put your wrapped object into 
the pipeline.

By doing this, you won't have to develop or hack the AssetDispatcher.

But there is still a caveat from my point of view,
I think that by doing this, we have to duplicate asset files in the differents 
directories, and then there will be no asset validation during rendering phase 
for the site dependent assets.

Sorry for my poor english, I hope this is understandable :)

Christophe

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 15:52
À : Tapestry users
Objet : Re: T5: Custom asset locator?

Yes, I think that would work. Only problem there is that I still
want to have all benefits of caching that the build-in services
deliver. And I can't see how to just *modify* the asset path
inside the dispatcher and pass it on to Tapestry...

/Andreas

On 28 mar 2008, at 15.36, Cordenier Christophe wrote:

 And what about a custom AssetDispatcher ?

 -Message d'origine-
 De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
 Envoyé : vendredi 28 mars 2008 15:22
 À : Tapestry users
 Objet : Re: T5: Custom asset locator?

 Thanks Christope, but it's not quite what I want. To illustrate
 my problem, take a look at the request headers I want to process:

 GET /assets/i/test.gif HTTP/1.1
 Host: www.SITE_A.com

 and

 GET /assets/i/test.gif HTTP/1.1
 Host: www.SITE_B.com

 If I just create my own binding, the request urls would still contain
 the real folder inside /assets and my requests would look like

 GET /assets/SITE_A/i/test.gif HTTP/1.1
 GET /assets/SITE_B/i/test.gif HTTP/1.1

 which I rather not want.

 /Andreas

 On 28 mar 2008, at 15.10, Cordenier Christophe wrote:
 Hello

 I'm not sure this can help, this is just an idea,
 but maybe it would be easier to create a new type of binding Factory
 upon the AssetBinding factory to add dynamic datas.

 Best regards,
 Christophe.

 -Message d'origine-
 De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
 Envoyé : vendredi 28 mars 2008 14:58
 À : Tapestry users
 Objet : T5: Custom asset locator?

 Hi everyone,

 First: many many thanks to the list for all the valuable info I
 get from it (either as passive reading or answers to my questions!)

 My problem: I want to expand the virtual /assets mapping because
 in the app I am writing, I use the current host name to run different
 sites/layouts.

 So I want to implement that

 Host: www.SITE_A.com
 img src=${asset:classpath:/i/test.gif} /
 points to SITE_A/i/test.gif

 and

 Host: www.SITE_B.com
 img src=${asset:classpath:/i/test.gif} /
 points to SITE_B/i/test.gif

 instead of the default way to do it by using

 img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
 or @Path(classpath:${host}/i/test.gif)

 and have it dynamically expand to the same paths. The motivation
 behind
 this is that

 a) users at SITE_A could replace the url with 'SITE_B' and peek at
 other
   resources

 b) the url's get very long and for some reason I don't want to go
 into
   here, I need to match the URLs style with some dynamic paths that
   fetch resources from a db - there, I automatically take care of the
   host name.

 I couldn't find a example on how to expand/overwrite asset lookup (in
 the same way I expanded template lookup). All I want is to add a
 subfolder on the fly to the asset path and still use the same build
 in asset service.

 /Andreas Pardeike

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Ce message et les pièces jointes sont confidentiels et réservés à l'usage 
exclusif de ses destinataires. Il peut également être protégé par le secret 
professionnel. Si vous recevez ce message par erreur, merci d'en avertir 
immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant 
être assurée sur Internet, la responsabilité du groupe Atos Origin ne pourra 
être recherchée quant au contenu de ce message. Bien que les meilleurs efforts 
soient faits pour maintenir cette transmission exempte de tout virus, 
l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne 
saurait être recherchée pour tout dommage résultant d'un virus transmis.

This e-mail and the documents attached are confidential and intended solely for 
the addressee; it may also be privileged. If you receive this e-mail in error, 
please notify the sender immediately and destroy it. As its integrity cannot be 
secured on the Internet, the Atos Origin group liability cannot be triggered 
for the message content. Although the sender endeavours to maintain a computer 
virus-free network, the sender does not warrant that this transmission is 
virus-free and will not be liable for any damages resulting from any virus 
transmitted.



RE: Tapestry 5 - Acegi ,, using LDAP authentication provider - other half

2008-03-28 Thread Mahen Perera
Thanks Jonathan. Both your e-mails are very helpful. I will try to get
something working based on this, and come back to you if I encounter any
issues.

-Original Message-
From: Jonathan Barker [mailto:[EMAIL PROTECTED] 
Sent: 28 March 2008 14:48
To: 'Tapestry users'
Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider -
other half


I realized I may not have answered your second question.

The configuration built up using 

configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
r);

is used in the SecurityModule of tapestry5-acegi for:

public static AuthenticationManager buildProviderManager(final List
AuthenticationProvider  providers)

This is just standard tapestry-ioc design.

If you read the Acegi docs, everything talks Spring.  But if every time
you
see a build method in tapestry-ioc, you look for a bean definition
in
Spring, things will suddenly make sense.  Then look at how lists are
passed
to beans in Spring, and you will understand all of the contribute
methods.


Jonathan


 -Original Message-
 From: Mahen Perera [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 9:50 AM
 To: Tapestry users
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Thanks Jonathan for that.
 
 Unclear on some stuff tho.
 Since we are using a LDAP based authentication provider do we need to
 have a UserDetailsServiceImpl?
 
 
 http://www.localhost.nu/java/tapestry5-acegi/ : If I am to use this,
 then it assumes having a UserDetailsServiceImpl.
 
 Also, when we do

configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
 r)
 How does the Acegi framework get to know abt the LDAP authentication
 provider.
 
 
 
 -Original Message-
 From: Jonathan Barker [mailto:[EMAIL PROTECTED]
 Sent: 27 March 2008 18:28
 To: 'Tapestry users'
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Here are the relevant portions (with identifying info stripped out)
for
 authentication with Active Directory.  With AD, you need to use
 bind-based
 authentication.
 
 If you are using something like OpenLDAP, you may have access to the
 password or password hash, so you would change the authenticator.
 
 
 I have also lumped together building the BindAuthenticator,
UserSearch,
 DefaultLdapauthoritiesPopulator into the
 buildLdapAuthenticationProvider()
 function.  These could be factored out.
 
 I'm also using an InMemoryDaoImpl for some development logins.
 
 
 public final InitialDirContextFactory
 buildInitialDirContextFactory(){
   DefaultInitialDirContextFactory factory = new

DefaultInitialDirContextFactory(ldap://server.domain.com:389/DC=domain,
 DC=c
 om);
   factory.setManagerDn(cn=Ldap Account ,OU=Service
 Accounts,OU=People,DC=domain,DC=com);
   factory.setManagerPassword(password);
   MapString,String extraEnvVars = new HashMapString,String();
   extraEnvVars.put(java.naming.referral, follow);
   factory.setExtraEnvVars(extraEnvVars);
   return factory;
 
 }
 
 public static AuthenticationProvider
 buildLdapAuthenticationProvider(InitialDirContextFactory factory )
 throws
 Exception {
 
   FilterBasedLdapUserSearch userSearch = new
 FilterBasedLdapUserSearch(ou=People,(sAMAccountName={0}),factory);
   userSearch.setSearchSubtree(true);
   userSearch.setDerefLinkFlag(true);
 
   BindAuthenticator authenticator = new
 BindAuthenticator(factory);
   authenticator.setUserSearch(userSearch);
   authenticator.afterPropertiesSet();
 
   DefaultLdapAuthoritiesPopulator populator = new
 DefaultLdapAuthoritiesPopulator(factory,);
   populator.setGroupRoleAttribute(cn);
   populator.setGroupSearchFilter(member={0});
   populator.setDefaultRole(ROLE_ANONYMOUS);
   populator.setConvertToUpperCase(true);
   populator.setSearchSubtree(true);
   populator.setRolePrefix(ROLE_);
 
   LdapAuthenticationProvider provider = new
 LdapAuthenticationProvider(authenticator,populator);
   return provider;
 }
 
 
 public static void contributeProviderManager(
 OrderedConfigurationAuthenticationProvider configuration,
 @InjectService(DaoAuthenticationProvider) AuthenticationProvider
 daoAuthenticationProvider,
@InjectService(LdapAuthenticationProvider)
 AuthenticationProvider ldapAuthenticationProvider){
 

configuration.add(daoAuthenticationProvider,daoAuthenticationProvider)
 ;
 

configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
 r);
 }
 
  -Original Message-
  From: Mahen Perera [mailto:[EMAIL PROTECTED]
  Sent: Thursday, March 27, 2008 10:14 AM
  To: users@tapestry.apache.org
  Subject: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
  Hi everybody.
 
 
 
  I am trying to integrate tapestry 5 with Acegi security.
 
  The authentication provider that I am using is LDAP based.
 
 
 
  I see that most of the examples refer to using DAOAuthentication
  provider.
 
  Just checking if 

Re: T5 (5.0.11) - ready for production deployment

2008-03-28 Thread Robert Zeigler

I'd have to agree.
I've been working on a T3 app a bit this week.  It's one I haven't  
touched in awhile.
It was pleasantly nice to work on... but I found myself itching to  
upgrade the app to T5, because T5 is more fun. :)


Robert

On Mar 27, 2008, at 3/277:35 PM , Howard Lewis Ship wrote:

Fun is one of my favorite adjectives for Tapestry.

On Thu, Mar 27, 2008 at 5:20 PM, Josh Canfield  
[EMAIL PROTECTED] wrote:

There is another public website, thedailytube.com, developed with T5
by some member of this list I can't recall his name. :P


That'd be me :)

The site went up with 5.0.5, and currently on 5.0.10.

Tapestry 5 is rendering everything, the site, the RSS feeds, the
content for the email newsletters and the CMS that runs the backend.
It's been a fun framework to develop in.

Josh



On Thu, Mar 27, 2008 at 3:19 PM, Thiago HP [EMAIL PROTECTED]  
wrote:

In the company I worked for until two weeks ago, I developed an
internal application with T5 and it's already in production. That  
was

a very successful experience, so the same company is now developing
another one in T5.

There is another public website, thedailytube.com, developed with T5
by some member of this list I can't recall his name. :P

--
Thiago


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






--
--
TheDailyTube.com. Sign up and get the best new videos on the internet
delivered fresh to your inbox.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






--
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



ACEGI Problem with anonymous

2008-03-28 Thread T. Papke

Hello,

I use Tapestry 5 (5.0.11) with acegi (tapestry-acegi 1.0.3).

Following code snipplet should explain my problem:

@Secured(ROLE_USER)
public class OrderConfirm {
   
   public void pageLoaded(){
   log.debug(creating order);
   log.debug(Authenticated isAuthenticated: 
+SecurityContextHolder.getContext().getAuthentication().isAuthenticated());
   log.debug(Authenticated getPrincipal: 
+SecurityContextHolder.getContext().getAuthentication().getPrincipal());

   
   }
   
}

If i navigate to that page (not-logged-in), the pageLoaded() method is 
invoked already before login (ok known todo of tapestry-acegi Secured 
class still allows access to action methods). So my workaround-idea was 
here, to use 
SecurityContextHolder.getContext().getAuthentication().isAuthenticated() 
to check if user is authenticated. But method return true - but before 
i was logged-in:

DEBUG - Authenticated isAuthenticated: true
DEBUG - Authenticated getPrincipal: anonymous

Anyone an idea why isAuthenticated() return true?
A anonymous user should be a non-authenticated user? Anyone a workaround?

Thank you,
Thomas

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: Custom asset locator?

2008-03-28 Thread Robert Zeigler

Shooting from the hip here, but...
One way of going about this would be to contribute a RequestFilter,  
rather than a Dispatcher.

RequestFilters get to pass on whatever request they want.
So you could wrap the request with a customized request that modifies  
the result of getPath() based on which host is being run.

Something like:

public class DynamicAssetRequestFilter implements RequestFilter {
   private final SymbolSource _source;
   public DynamicAssetRequestFilter(final SymbolSource source) {
_source=source;
   }

   public boolean service(Request request, Response response,  
RequestHandler handler) {
 if  
(request.getPath().startsWith(TapestryConstants.ASSET_PATH_PREFIX)) {

return handler.service(new 
DynamicAssetRequest(request),response);
 }
 return handler.service(request,response);
   }
  class DynamicAssetRequest implements Request {
  private final Request _request;
  private final String _path;

  DynamicAssetRequest(final Request request) {
  _request = request;
  String path = getPath();
   String host = source.valueForSymbol(host);
   _path = //process the path as appropriate to put host in  
where you need it



  }
  //implement the Request interface by calling through to the  
wrapped request

  ...
  //override getPath.
  public String getPath() {
 return _path;
  }
  }

}

On Mar 28, 2008, at 3/289:52 AM , Andreas Pardeike wrote:

Yes, I think that would work. Only problem there is that I still
want to have all benefits of caching that the build-in services
deliver. And I can't see how to just *modify* the asset path
inside the dispatcher and pass it on to Tapestry...

/Andreas

On 28 mar 2008, at 15.36, Cordenier Christophe wrote:


And what about a custom AssetDispatcher ?

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 15:22
À : Tapestry users
Objet : Re: T5: Custom asset locator?

Thanks Christope, but it's not quite what I want. To illustrate
my problem, take a look at the request headers I want to process:

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_A.com

and

GET /assets/i/test.gif HTTP/1.1
Host: www.SITE_B.com

If I just create my own binding, the request urls would still contain
the real folder inside /assets and my requests would look like

GET /assets/SITE_A/i/test.gif HTTP/1.1
GET /assets/SITE_B/i/test.gif HTTP/1.1

which I rather not want.

/Andreas

On 28 mar 2008, at 15.10, Cordenier Christophe wrote:

Hello

I'm not sure this can help, this is just an idea,
but maybe it would be easier to create a new type of binding Factory
upon the AssetBinding factory to add dynamic datas.

Best regards,
Christophe.

-Message d'origine-
De : Andreas Pardeike [mailto:[EMAIL PROTECTED]
Envoyé : vendredi 28 mars 2008 14:58
À : Tapestry users
Objet : T5: Custom asset locator?

Hi everyone,

First: many many thanks to the list for all the valuable info I
get from it (either as passive reading or answers to my questions!)

My problem: I want to expand the virtual /assets mapping because
in the app I am writing, I use the current host name to run  
different

sites/layouts.

So I want to implement that

Host: www.SITE_A.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_A/i/test.gif

and

Host: www.SITE_B.com
img src=${asset:classpath:/i/test.gif} /
points to SITE_B/i/test.gif

instead of the default way to do it by using

img src=${asset:classpath:/CURRENTSITE/i/test.gif} /
or @Path(classpath:${host}/i/test.gif)

and have it dynamically expand to the same paths. The motivation
behind
this is that

a) users at SITE_A could replace the url with 'SITE_B' and peek at
other
 resources

b) the url's get very long and for some reason I don't want to go  
into

 here, I need to match the URLs style with some dynamic paths that
 fetch resources from a db - there, I automatically take care of the
 host name.

I couldn't find a example on how to expand/overwrite asset lookup  
(in

the same way I expanded template lookup). All I want is to add a
subfolder on the fly to the asset path and still use the same build
in asset service.

/Andreas Pardeike


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: Custom asset locator?

2008-03-28 Thread Andreas Pardeike

Robert ,

Just coded that and it (sort of) works. The problem is, as Chris has
mentioned, that T5 complains about the assets being not present.

And when I dodge this by simply creating my own prefix, lets say
'/host_assets/' and fall back to not using assets at all, then my
servlet container will handle the request and it will look at the
original request and fail to find the file.

So I have a feeling that I need to implement the strategy in two
parts: the one that modifies the request AND and custom lookup for
an assets.

OR, I use a third strategy: my app is divided in content that
is semi-static (in form of t5-templates with their own assets) and
content that is database driven. The later is already working fine
and there I simply use the fact that a T5 page has context that
I can use to create fake URLs (.../t5page/context/path/here.gif).

The only thing is, that I would love to use the build in asset
caching and not reinvent the wheel. With the database, Cayenne does
it automatically for me...

Is there a simple way to serve files from either a folder at the
classpath or from the web context *including* caching? Either from
a T5 page or from a dispatcher.

/Andreas


On 28 mar 2008, at 17.51, Robert Zeigler wrote:


Shooting from the hip here, but...
One way of going about this would be to contribute a RequestFilter,  
rather than a Dispatcher.

RequestFilters get to pass on whatever request they want.
So you could wrap the request with a customized request that  
modifies the result of getPath() based on which host is being run.

Something like:

public class DynamicAssetRequestFilter implements RequestFilter {
  private final SymbolSource _source;
  public DynamicAssetRequestFilter(final SymbolSource source) {
   _source=source;
  }

  public boolean service(Request request, Response response,  
RequestHandler handler) {
if  
(request.getPath().startsWith(TapestryConstants.ASSET_PATH_PREFIX)) {

return handler.service(new 
DynamicAssetRequest(request),response);
}
return handler.service(request,response);
  }
 class DynamicAssetRequest implements Request {
 private final Request _request;
 private final String _path;

 DynamicAssetRequest(final Request request) {
 _request = request;
 String path = getPath();
  String host = source.valueForSymbol(host);
  _path = //process the path as appropriate to put host in  
where you need it



 }
 //implement the Request interface by calling through to the  
wrapped request

 ...
 //override getPath.
 public String getPath() {
return _path;
 }
 }

}


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: Cannot get org.acegisecurity.CredentialsExpiredException to work

2008-03-28 Thread Robin Helgelin
On Fri, Mar 28, 2008 at 2:13 PM, Olle Hallin [EMAIL PROTECTED] wrote:
 Hi again,

Hi!

 I've made a new version of the SecurityModule.java that follows the usual
 build + contribute pattern in tapestry-ioc.

Thanks for taking time to go to the bottom with this. I'll update and
release a new version when I'm back from vacation next week.

-- 
 regards,
 Robin

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

2008-03-28 Thread Mahen Perera
I understand your code. I need acegi take full control of the login and
security of my web application. Say for example, if the user tries to
directly go to a URL other than the login URL, then the user should be
redirected to the login URL if there is no valid user session. 


About the LdapUserDetails object..

Since the SecurityModule of tapestry5-acegi needs a
UserDetailsServiceImpl,,,
Is it correct to say that I have to write a UserDetailsServiceImpl class
which uses LDAP in order to retrieve the correct UserDetails Object?

-Original Message-
From: Jonathan Barker [mailto:[EMAIL PROTECTED] 
Sent: 28 March 2008 14:34
To: 'Tapestry users'
Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider


All of the classes are from Acegi.  The LdapAuthenticationProvider
returns a
LdapUserDetails object.

There are a number of ways to get Acegi to authenticate you.  Here's
part of
what I do from a Login form where I automatically add authenticated
users to
a Users table (it needs a bit of cleaning up):

UsernamePasswordAuthenticationToken authRequest = 
new
UsernamePasswordAuthenticationToken(_username,_password);
Authentication authResult;

try {
authResult =
_authenticationManager.authenticate(authRequest);
logger.info(successful login for:  +
_username);
// now see if they exist in the database:
User user = new User();
user.setUsername(_username);
ListUser matches =
_userDao.findByExample(user);
if (matches.isEmpty()){
Object principal =
authResult.getPrincipal();
if (principal instanceof
LdapUserDetails){
logger.info(adding new LDAP
user
);
LdapUserDetails details =
(LdapUserDetails) principal;

logger.info(details.getAttributes().getIDs().toString());
Attribute nameAttr =
details.getAttributes().get(name);
Object o;
try {
o = nameAttr.get();
if (o!= null  o
instanceof
String )

user.setLastName((String)o);
else

user.setLastName(_username);
 you get the idea




 -Original Message-
 From: Mahen Perera [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 9:50 AM
 To: Tapestry users
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Thanks Jonathan for that.
 
 Unclear on some stuff tho.
 Since we are using a LDAP based authentication provider do we need to
 have a UserDetailsServiceImpl?
 
 
 http://www.localhost.nu/java/tapestry5-acegi/ : If I am to use this,
 then it assumes having a UserDetailsServiceImpl.
 
 Also, when we do

configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
 r)
 How does the Acegi framework get to know abt the LDAP authentication
 provider.
 
 
 
 -Original Message-
 From: Jonathan Barker [mailto:[EMAIL PROTECTED]
 Sent: 27 March 2008 18:28
 To: 'Tapestry users'
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 Here are the relevant portions (with identifying info stripped out)
for
 authentication with Active Directory.  With AD, you need to use
 bind-based
 authentication.
 
 If you are using something like OpenLDAP, you may have access to the
 password or password hash, so you would change the authenticator.
 
 
 I have also lumped together building the BindAuthenticator,
UserSearch,
 DefaultLdapauthoritiesPopulator into the
 buildLdapAuthenticationProvider()
 function.  These could be factored out.
 
 I'm also using an InMemoryDaoImpl for some development logins.
 
 
 public final InitialDirContextFactory
 buildInitialDirContextFactory(){
   DefaultInitialDirContextFactory factory = new

DefaultInitialDirContextFactory(ldap://server.domain.com:389/DC=domain,
 DC=c
 om);
   factory.setManagerDn(cn=Ldap Account ,OU=Service
 Accounts,OU=People,DC=domain,DC=com);
   factory.setManagerPassword(password);
   MapString,String extraEnvVars = new HashMapString,String();
   extraEnvVars.put(java.naming.referral, follow);
   factory.setExtraEnvVars(extraEnvVars);
   return factory;
 
 }
 
 public static AuthenticationProvider
 buildLdapAuthenticationProvider(InitialDirContextFactory factory )
 throws
 Exception {
 
   FilterBasedLdapUserSearch userSearch = new
 FilterBasedLdapUserSearch(ou=People,(sAMAccountName={0}),factory);
   userSearch.setSearchSubtree(true);
   userSearch.setDerefLinkFlag(true);
 
   BindAuthenticator authenticator = new
 

Re: T5: Custom asset locator?

2008-03-28 Thread Robert Zeigler
Question: is the crux of the matter pretty urls, or is the cruz of  
the matter security?
If the crux is pretty urls, then we should think about this some  
more... trying to map a single url onto multiple resources, and cache  
all of those resources seems pretty tricky.
If, on the other hand, you just need to make sure that site_a users  
don't have access to site_b's assets, then maybe this isn't the best  
approach?
For instance, you could use a dispatcher to verify that the user in  
question has access to the asset in question.
For example, you could use the AssetProtectionDispatcher* that I wrote  
awhile back, and contribute your own AssetPathAuthorizer which looks  
at the asset path, and the current user, and determines if the user  
has access to the asset.


Then you're not beating your head over trying to map a single url to  
multiple assets, and you're using the built-in caching, and site b's  
users aren't peaking at site a's assets.


If you also want pretty urls to boot... I'll have to mull over it a  
bit when I have a bit more time.


Cheers,

Robert

* This is available from www.tapestrycomponents.com (I don't remember  
what version is in there at the moment). The most current version is  
0.0.9, dep on T5.0.11, and is available from the maven repo at:

www.saiwai-solutions.com/maven


On Mar 28, 2008, at 3/2812:08 PM , Andreas Pardeike wrote:

Robert ,

Just coded that and it (sort of) works. The problem is, as Chris has
mentioned, that T5 complains about the assets being not present.

And when I dodge this by simply creating my own prefix, lets say
'/host_assets/' and fall back to not using assets at all, then my
servlet container will handle the request and it will look at the
original request and fail to find the file.

So I have a feeling that I need to implement the strategy in two
parts: the one that modifies the request AND and custom lookup for
an assets.

OR, I use a third strategy: my app is divided in content that
is semi-static (in form of t5-templates with their own assets) and
content that is database driven. The later is already working fine
and there I simply use the fact that a T5 page has context that
I can use to create fake URLs (.../t5page/context/path/here.gif).

The only thing is, that I would love to use the build in asset
caching and not reinvent the wheel. With the database, Cayenne does
it automatically for me...

Is there a simple way to serve files from either a folder at the
classpath or from the web context *including* caching? Either from
a T5 page or from a dispatcher.

/Andreas


On 28 mar 2008, at 17.51, Robert Zeigler wrote:


Shooting from the hip here, but...
One way of going about this would be to contribute a RequestFilter,  
rather than a Dispatcher.

RequestFilters get to pass on whatever request they want.
So you could wrap the request with a customized request that  
modifies the result of getPath() based on which host is being run.

Something like:

public class DynamicAssetRequestFilter implements RequestFilter {
 private final SymbolSource _source;
 public DynamicAssetRequestFilter(final SymbolSource source) {
  _source=source;
 }

 public boolean service(Request request, Response response,  
RequestHandler handler) {
   if  
(request.getPath().startsWith(TapestryConstants.ASSET_PATH_PREFIX)) {

return handler.service(new 
DynamicAssetRequest(request),response);
   }
   return handler.service(request,response);
 }
class DynamicAssetRequest implements Request {
private final Request _request;
private final String _path;

DynamicAssetRequest(final Request request) {
_request = request;
String path = getPath();
 String host = source.valueForSymbol(host);
 _path = //process the path as appropriate to put host in  
where you need it



}
//implement the Request interface by calling through to the  
wrapped request

...
//override getPath.
public String getPath() {
   return _path;
}
}

}


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5 (5.0.11) - ready for production deployment

2008-03-28 Thread Koka Kiknadze
On Fri, Mar 28, 2008 at 5:48 PM, Jonathan Barker 
[EMAIL PROTECTED] wrote:

 Rob,

 I can't resist...


Please, do resist. Imo thats the only way to handle it...
http://article.gmane.org/gmane.comp.java.tapestry.user/59910


RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

2008-03-28 Thread Jonathan Barker


You do not need to write a UserDetails implementation for LDAP.  Acegi
already did it.  In fact, the only time I've hit where I needed to implement
a UserDetails object and UserDetailsService was creating my own custom
DAO-based authentication.

Now, if you're needing to save information to LDAP..., well that might be a
different story.

Also, you should read a related thread on the list: ACEGI Problem with
anonymous

And perhaps Re: T5: Cannot get
org.acegisecurity.CredentialsExpiredException to work


 -Original Message-
 From: Mahen Perera [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 2:29 PM
 To: Tapestry users
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 I understand your code. I need acegi take full control of the login and
 security of my web application. Say for example, if the user tries to
 directly go to a URL other than the login URL, then the user should be
 redirected to the login URL if there is no valid user session.
 
 
 About the LdapUserDetails object..
 
 Since the SecurityModule of tapestry5-acegi needs a
 UserDetailsServiceImpl,,,
 Is it correct to say that I have to write a UserDetailsServiceImpl class
 which uses LDAP in order to retrieve the correct UserDetails Object?
 
 -Original Message-
 From: Jonathan Barker [mailto:[EMAIL PROTECTED]
 Sent: 28 March 2008 14:34
 To: 'Tapestry users'
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 
 All of the classes are from Acegi.  The LdapAuthenticationProvider
 returns a
 LdapUserDetails object.
 
 There are a number of ways to get Acegi to authenticate you.  Here's
 part of
 what I do from a Login form where I automatically add authenticated
 users to
 a Users table (it needs a bit of cleaning up):
 
   UsernamePasswordAuthenticationToken authRequest =
   new
 UsernamePasswordAuthenticationToken(_username,_password);
   Authentication authResult;
 
   try {
   authResult =
 _authenticationManager.authenticate(authRequest);
   logger.info(successful login for:  +
 _username);
   // now see if they exist in the database:
   User user = new User();
   user.setUsername(_username);
   ListUser matches =
 _userDao.findByExample(user);
   if (matches.isEmpty()){
   Object principal =
 authResult.getPrincipal();
   if (principal instanceof
 LdapUserDetails){
   logger.info(adding new LDAP
 user
 );
   LdapUserDetails details =
 (LdapUserDetails) principal;
 
 logger.info(details.getAttributes().getIDs().toString());
   Attribute nameAttr =
 details.getAttributes().get(name);
   Object o;
   try {
   o = nameAttr.get();
   if (o!= null  o
 instanceof
 String )
 
 user.setLastName((String)o);
   else
 
 user.setLastName(_username);
    you get the idea
 
 
 
 
  -Original Message-
  From: Mahen Perera [mailto:[EMAIL PROTECTED]
  Sent: Friday, March 28, 2008 9:50 AM
  To: Tapestry users
  Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
  Thanks Jonathan for that.
 
  Unclear on some stuff tho.
  Since we are using a LDAP based authentication provider do we need to
  have a UserDetailsServiceImpl?
 
 
  http://www.localhost.nu/java/tapestry5-acegi/ : If I am to use this,
  then it assumes having a UserDetailsServiceImpl.
 
  Also, when we do
 
 configuration.add(ldapAuthenticationProvider,ldapAuthenticationProvide
  r)
  How does the Acegi framework get to know abt the LDAP authentication
  provider.
 
 
 
  -Original Message-
  From: Jonathan Barker [mailto:[EMAIL PROTECTED]
  Sent: 27 March 2008 18:28
  To: 'Tapestry users'
  Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
  Here are the relevant portions (with identifying info stripped out)
 for
  authentication with Active Directory.  With AD, you need to use
  bind-based
  authentication.
 
  If you are using something like OpenLDAP, you may have access to the
  password or password hash, so you would change the authenticator.
 
 
  I have also lumped together building the BindAuthenticator,
 UserSearch,
  DefaultLdapauthoritiesPopulator into the
  buildLdapAuthenticationProvider()
  function.  These could be factored out.
 
  I'm also using an InMemoryDaoImpl for some development logins.
 
 
  public final InitialDirContextFactory
  buildInitialDirContextFactory(){
  DefaultInitialDirContextFactory factory = new
 
 

Re: [T4.1] Setting the value of a DatePicker clientside

2008-03-28 Thread Andreas Andreou
Hi,
first you need to get the js reference to the calendar control...
The js variable to use is named like calendar_XXX where XXX
is the id of your DatePicker control.

After you know that, you can do:
calendar_XXX.setSelectedDate('15 Mar 2008')

On Thu, Mar 20, 2008 at 1:21 PM, Andy Pahne [EMAIL PROTECTED] wrote:

  I wonder how to set the date of a DatePicker in Javascript.

  I tried sth. like
 document.forms[0].departureDatePicker.value='x.x.x'

  which works partly. The text field is updated, but when I click on the
  DatePicker icon the picker is still set to the old value.

  I had a look at DatePicker.js and found the funtion

  Calendar.prototype.setCurrentDate = function(date) {
 ...
  }

  That one seems to be a good candidate for my task, but I don't have any
  idea, how to invoke it. (My knowledge about JavaScript is almost non
  existant).


  Andy

  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]





-- 
Andreas Andreou - [EMAIL PROTECTED] - http://blog.andyhot.gr
Tapestry / Tacos developer
Open Source / JEE Consulting

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Floating Pane and AjaxEventSubmit

2008-03-28 Thread Andreas Andreou
There's the EventListener annotation that replaces AjaxEventSubmit but
no similar
component.

As for the floating pane, I'd use tacos 4.1.2-SNAPSHOT
and its dojo:Widget component, see
http://tacos.sourceforge.net/tacos4.1/tacos-core/quick-start/downloading.html
http://tacos.sourceforge.net/tacos4.1/components/dojo/DojoWidget.html
and also tacos-demo has an example of it.


On Thu, Mar 27, 2008 at 1:30 PM, Rohan Kalyan [EMAIL PROTECTED] wrote:
 Hi all,
   we are migrating from tapestry 4.0.2 to  4.1.5
   we were using tacos 4.0 with the previous version and now in tapestry
  4.1we have deleted tacos and
   we are facing problem in changing tacos components (tacos:ajaxEventSubmit
  and tacos:FloatingPane)

  Please suggest us on this issue..




  thanks in advance.
  --
  Rohan Kalyan
  Indygo - www.indygosoft.com




-- 
Andreas Andreou - [EMAIL PROTECTED] - http://blog.andyhot.gr
Tapestry / Tacos developer
Open Source / JEE Consulting

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T4.1.5: Fill the autocompleter field from a popup window

2008-03-28 Thread Andreas Andreou
Probably you need to change the forceValidOption parameter of
http://tapestry.apache.org/tapestry4.1/components/dojo/autocompleter.html



On Sat, Mar 22, 2008 at 9:27 AM, Stef [EMAIL PROTECTED] wrote:
 Dear All!

  I upgraded my webapp from T4.0.2 to T4.1.5 and I have a problem with the 
 autocompleter.
  I created a popup window for each autocompleter field but from version 4.1.5 
 isn't works well.

  I used this javascript in the popup window for transfer the selected data:

  function closePopup(stringValue,formId,columnId){
  if (columnId == 1) {
  window.opener.document.forms[formId].fizikaiHelyseg.value = stringValue; }
  if (columnId == 2) {
  window.opener.document.forms[formId].levelezesiHelyseg.value = stringValue; }
  if (columnId == 3) {
  window.opener.document.forms[formId].szuletesiHelyseg.value = stringValue; }
  window.close();
  return false;
  }

  HTML:
  a href=javascript:closePopup('Szigetmonostor 2015', 
 'szemelyForm',1)2015/a

  --

  The effect is the autocompleter field didn't accept the data. If I typed 
 manually is OK.
  If I insert a value from clipboard to the empty autocompleter filed, don't 
 accept this value but it is a correct value. The value is inserted but about 
 2 seconds after the field drop my inserted data and show nothing...

  My question is how can I fill the autocompleter field from a popup window in 
 version 4.1.5. The autocompleter field why not accept the selected value? The 
 filed why drop the value that i insert from the clipboard?


  Thanks for any advice!


  Best regards,
  Stef

  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]





-- 
Andreas Andreou - [EMAIL PROTECTED] - http://blog.andyhot.gr
Tapestry / Tacos developer
Open Source / JEE Consulting

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

2008-03-28 Thread Jacob Bergoo

Hi Jonathan,
A quick question, how do you get the authenticationManager object into that
page that you are using???

thanks,
Jacob
-- 
View this message in context: 
http://www.nabble.com/Tapestry-5---Acegi-%2C%2C-using-LDAP-authentication-provider-tp16330496p16361117.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [T5] FormFragment doesn't work on IE6

2008-03-28 Thread Zheng, Xiahong
I had a look at the tapestry.js. The following function is used to
connect the checkbox with the fragment.

// Links a FormFragment to a checkbox, such that changing the
checkbox will hide
// or show the FormFragment. Care should be taken to render the page
with the
// checkbox and the FormFragment('s visibility) in agreement.

linkCheckboxToFormFragment : function(checkbox, element)
{
checkbox = $(checkbox);

checkbox.observe(change, function()
{
$(element).formFragment.setVisible(checkbox.checked);
});
},

I am not familiar with javascript function. But it seems to me that the
checkbox onchange event only toggles the visibility of the fragment.
There should be another line that toggels the hidden field value as
well.  

-Original Message-
From: Adam Zimowski [mailto:[EMAIL PROTECTED] 
Sent: Thursday, March 27, 2008 4:10 PM
To: Tapestry users
Subject: Re: [T5] FormFragment doesn't work on IE6

I recently posted e-mail to this list on this exact same topic. Here
is that post:

Per documentation, FormFragment decides if its content should be
submitted based on the hidden field [formfragmentname]:hidden:

// this is the relevant code from FormFragment source: void
beginRender(..)
   writer.element(input,

  type, hidden,

  name, _controlName,

  id, _clientId + :hidden,

  value, String.valueOf(_visible));
   writer.end();


However, that field being generated at render time is fairly static,
which defeats the very purpose of dynamic behavior provided by
Tapestry.ElementEffect sidedown/slideup functions. The problem is that
when the silide function is invoked on the client (triggered by click
on the checkbox), that inherently means that FormFragment should be
submitted, but it won't be if the hidden field was generated with
false value.

The solution to this problem should be Tapestry dynamically changing
hidden field's value to true/false based on the client side state of
the checkbox tied to the FormFragment. For those who need a
workaround, I can share mine. In onclick of submit button one can
execute the following function:

function setupFragment(fragment, checkbox) {
 var checked = document.getElementById(checkbox).value;
 var advanced = (checked == 'on');
 document.getElementById(fragment + ':hidden').value=advanced;
}


input t:id=submitButton
onclick=setupFragment('advancedFragment','advancedCheckbox');
type=submit t:type=submit value=Submit/

I believe this should be one of those plumbing tasks that Tapestry
should do for us. Should this be a JIRA improvement, or am I missing
something?

-adam
Reply

Forward


Howard Lewis Ship   
The code is already in place to set the hidden field to the correct
value whe...

Howard's Reply was: 

The code is already in place to set the hidden field to the correct
value when the form is submitted.

In fact, that code is already present in deepVisible stuff inside
tapestry.js

-adam




On Thu, Mar 27, 2008 at 3:02 PM, Zheng, Xiahong [EMAIL PROTECTED]
wrote:
 I found a workaround. It seems tapestry is not linking the checkbox
  event with the hidden field in this case

  addPositionFragment:hidden

  This value of this hidden field is used on the server side to
determine
  if binding of the fragment fields should happen. If I manually add a
  onchange event on the checkbox that toggles the value of the above
  field, it starts to work


  t:checkbox t:id=addPosition t:mixins=triggerfragment

onclick=document.getElementById('addPositionFragment:hidden').value=tru
  e
  fragment=addPositionFragment/

  Is this a bug or by design?



  -Original Message-
  From: Zheng, Xiahong
  Sent: Thursday, March 27, 2008 2:24 PM
  To: Tapestry users


 Subject: RE: [T5] FormFragment doesn't work on IE6

  I am not sure why it is not working for me. Here is my simple test
page,

  NewPosition.tml

  html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;

  body

  form t:type=Form t:id=addForm
 t:checkbox t:id=addPosition t:mixins=triggerfragment
  fragment=addPositionFragment/
 t:label for=addPositionAdd Position ?/t:label
 t:formfragment t:id=addPositionFragment
  visible=addPosition
 table
 tr
 td class=unlined
 Symbol
 /td
 td class=unlined
 Shares
 /td
 td class=unlined
 Price
 /td
 /tr
 tr
 td class=unlined
 t:TextField
  value=newPosition.symbol/
 /td
 td class=unlined

RE: Tapestry 5 - Acegi ,, using LDAP authentication provider

2008-03-28 Thread Jonathan Barker

@Inject
private AuthenticationManager _authenticationManager;

Isn't Tapestry great? :-)


 -Original Message-
 From: Jacob Bergoo [mailto:[EMAIL PROTECTED]
 Sent: Friday, March 28, 2008 4:13 PM
 To: users@tapestry.apache.org
 Subject: RE: Tapestry 5 - Acegi ,, using LDAP authentication provider
 
 
 Hi Jonathan,
 A quick question, how do you get the authenticationManager object into
 that
 page that you are using???
 
 thanks,
 Jacob
 --
 View this message in context: http://www.nabble.com/Tapestry-5---Acegi-
 %2C%2C-using-LDAP-authentication-provider-tp16330496p16361117.html
 Sent from the Tapestry - User mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5 Nested Link components and their urls

2008-03-28 Thread Howard Lewis Ship
I really have to ask ... why would you care?

And the issue here is enclosure vs. containment.  Containment is the
concrete structure of the components, it really is the component
hierarchy.  Enclosure is largely a factor in how the templates are
laid out (report encloses header), but can be much more dynamic
(witness the jumping around that BeanEditForm accomplishes, literally
pulling chunks of other pages into the mix).

On Fri, Mar 28, 2008 at 2:01 PM, Janko Muzykant [EMAIL PROTECTED] wrote:

  hi, i have a following problem with urls generated by nested links components
  - lets say, we have a reportUsers page and something like this inside:

  t:report t:id=report
 th t:type=header column=username/

  header is my component that creates ActionLink with parameter given in
  'column' attribute. Generated url looks like this:
  http://myhost:port/context/path/reportUsers.header/username. pretty cool,
  but it's not what I would like to achieve. As 'header' component is nested
  inside 'report' I would expect the url to look like:
  .../path/reportUsers.report.header/username. Could you give me a hint how to
  get it?

  thanks,
  jm.



  --
  View this message in context: 
 http://www.nabble.com/T5-Nested-Link-components-and-their-urls-tp16362062p16362062.html
  Sent from the Tapestry - User mailing list archive at Nabble.com.


  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]





-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T4.1.5: Fill the autocompleter field from a popup window

2008-03-28 Thread Stef
Hi!

Thank you the advice but it is not solved my problem and make an another 
problem: user can type invalid value into the field.

Any advice? :)

Best regards,
Stef

 -Original Message-
 From: [EMAIL PROTECTED]
 Sent: Fri, 28 Mar 2008 21:58:22 +0200
 To: users@tapestry.apache.org
 Subject: Re: T4.1.5: Fill the autocompleter field from a popup window
 
 Probably you need to change the forceValidOption parameter of
 http://tapestry.apache.org/tapestry4.1/components/dojo/autocompleter.html
 
 
 
 On Sat, Mar 22, 2008 at 9:27 AM, Stef [EMAIL PROTECTED] wrote:
 Dear All!
 
  I upgraded my webapp from T4.0.2 to T4.1.5 and I have a problem with
 the autocompleter.
  I created a popup window for each autocompleter field but from version
 4.1.5 isn't works well.
 
  I used this javascript in the popup window for transfer the selected
 data:
 
  function closePopup(stringValue,formId,columnId){
  if (columnId == 1) {
  window.opener.document.forms[formId].fizikaiHelyseg.value =
 stringValue; }
  if (columnId == 2) {
  window.opener.document.forms[formId].levelezesiHelyseg.value =
 stringValue; }
  if (columnId == 3) {
  window.opener.document.forms[formId].szuletesiHelyseg.value =
 stringValue; }
  window.close();
  return false;
  }
 
  HTML:
  a href=javascript:closePopup('Szigetmonostor 2015',
 'szemelyForm',1)2015/a
 
  --
 
  The effect is the autocompleter field didn't accept the data. If I
 typed manually is OK.
  If I insert a value from clipboard to the empty autocompleter filed,
 don't accept this value but it is a correct value. The value is inserted
 but about 2 seconds after the field drop my inserted data and show
 nothing...
 
  My question is how can I fill the autocompleter field from a popup
 window in version 4.1.5. The autocompleter field why not accept the
 selected value? The filed why drop the value that i insert from the
 clipboard?
 
 
  Thanks for any advice!
 
 
  Best regards,
  Stef
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 
 --
 Andreas Andreou - [EMAIL PROTECTED] - http://blog.andyhot.gr
 Tapestry / Tacos developer
 Open Source / JEE Consulting
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


GET FREE 5GB EMAIL - Check out spam free email with many cool features!
Visit http://www.inbox.com/email to find out more!

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Form with a Zone - ComponentEventException

2008-03-28 Thread petros

Sorry about the second post but this problem is killing me :)
I tried this example that works fine online and I am getting the same
exception as my previous post
http://lombok.demon.co.uk/tapestry5Demo/test/core/zonedemoone

In the example a Block is returned from an onAction or onSuccess methods but
in my case I am getting the exception that I am not allowed to return a
Block object. 

Is there any configuration I need to do ? I am using 5.0.11

Thanks, 
Petros



petros wrote:
 
 When the userSearchForm of the code below is submitted I am getting the
 following exception
 
 A component event handler method returned the value
 [EMAIL PROTECTED] Return type
 org.apache.internal.structure.BlockImpl can not be handled. Configured
 return types are java.lang.Class, java.lang.String, java.net.URL,
 org.apache.tapestry.Link, org.apache.tapestry.StreamResponse,
 org.apache.tapestry.runtime.Component. 
 
 I am trying to update the search results table when the form is submited
 as an Ajax call. Any ideas ?
 
 UserPicker.java
 @Inject
 private Block searchResultsBlock;
 
 Object onSuccessFromUserSearchForm()
 {
foundUsers = userManager.findUsers(...);
return searchResultsBlock;
 }
 
 UserPicker.tml
 ...
 html
body
form t:id=userSearchForm zone=searchResultsZone
...
input t:type=Submit value=Find Users/
/form
 
div t:type=Zone t:id=searchResultZone/
 
div t:type=Block t:id=searchResultsBlock
table t:type=Grid source=foundUsers/
/div
/body
 html
 

-- 
View this message in context: 
http://www.nabble.com/Form-with-a-Zone--%3E-ComponentEventException-tp16346150p16363943.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



T5: Problem with login form with Acegi

2008-03-28 Thread Jacob Bergoo

Hi All, 
In my project I use the Tapestry5-Acegi project and made that work following
the example and with some help from the forum, thanks... 
Now I'm trying to make a more realistic version of a login where I can
control the validation on the login form and also based on user roles
redirect the user to the right page.
I have created a page like this:
public class LoginPage {

/* PRIVATE MEMBERS */
@Persist
private String userName;
private String password;
@Component
private Form form;

/* INJECTED COMPONENTS, SERVICES ETC. */
@Component(id = password)
private PasswordField passwordField;

@Inject
private AuthenticationManager authenticationManager;

/* GETTERS AND SETTERS */
public String getPassword() {
return password;
}

public void setPassword(String password) {
this.password = password;
}

public String getUserName() {
return userName;
}

public void setUserName(String userName) {
this.userName = userName;
}

/* ACTION METHODS */
protected String onSuccess() {
UsernamePasswordAuthenticationToken authRequest = new
UsernamePasswordAuthenticationToken(userName, password);
Authentication authResult;

try {
authResult = 
authenticationManager.authenticate(authRequest);
if (!authResult.isAuthenticated()) {
form.recordError(passwordField,
Invalid user name or 
password.);
return null;
}
GrantedAuthority[] gratedAuthorityArray = 
authResult.getAuthorities();
SetGrantedAuthority grantedAuthoritySet = new
HashSetGrantedAuthority();
for (int i = 0; i  gratedAuthorityArray.length; i++) {

grantedAuthoritySet.add(gratedAuthorityArray[i]);
System.out.println(Adding  + 
gratedAuthorityArray[i] +  to set);
}

// DEBUGGING
System.out.println(successful login for:  + userName);
System.out.println(authResult.getCredentials() =  
+
authResult.getCredentials());
System.out.println(authResult.getPrincipal() =  +
authResult.getPrincipal());
System.out.println(authResult.getAuthorities(): );
for (int i = 0; i  gratedAuthorityArray.length; i++) {
System.out.println(Auth no  + (i + 1) +  = 
' +
gratedAuthorityArray[i] + ');
}
// END DEBUGGING...

if (grantedAuthoritySet.contains(ROLE_ADMIN)) {
System.out.println(Redirecting to Secure 
page...);
return Secure;
} else if 
(grantedAuthoritySet.contains(ROLE_SOME_OTHER_ROLE)) {
System.out.println(redirecting to some other 
page);
return SOME_OTHER_PAGE;
}

} catch (AuthenticationException authenticationException) {
System.out.println(user with username =  + userName
+ couldn't be authenticated with 
Acegi);
}

return null;
}

}

In my Jetty Console I can see that I get the Authetication:

Adding ROLE_ADMIN to set
Adding ROLE_MANAGER to set
Adding ROLE_USER to set
successful login for: jacob
authResult.getCredentials() = jacob
authResult.getPrincipal() = UserDetailsBean {
username = jacob
password = jacob
accountNonExpired = true
passwordaccountNonLocked = true
credentialsNonExpired = true
enabled = true
grantedAuthorities {
'ROLE_ADMIN'
'ROLE_MANAGER'
'ROLE_USER'
}
}

authResult.getAuthorities(): 
Auth no 1 = 'ROLE_ADMIN'
Auth no 2 = 'ROLE_MANAGER'
Auth no 3 = 'ROLE_USER'
[INFO] TimingFilter Request time: 26 ms
[INFO] TimingFilter Request time: 18 ms
[INFO] TimingFilter Request time: 2 ms

but the redirection to the pages doesn't work... and if I change the last
return null; to return Secure; then I get this exception instead:

[ERROR] Secure Render queue error in BeginRender[Secure]: Access is denied
org.apache.tapestry.ioc.internal.util.TapestryException: Access is denied
at
org.apache.tapestry.internal.structure.ComponentPageElementImpl.invoke(ComponentPageElementImpl.java:884)
at

Re: T5: Problem with login form with Acegi

2008-03-28 Thread Jacob Bergoo

Hi again,
I had an error in my code when I compared the SetGrantedAuthority with a
String value... I changed that so the Set takes a String as input instead.
Now it goes into the first if statement and try to call page Secure and I
get the same error as I posted in my previous posting... 

in the end the error states:
Caused by: org.acegisecurity.AccessDeniedException: Access is denied
at
org.acegisecurity.vote.AffirmativeBased.decide(AffirmativeBased.java:68)
at
$AccessDecisionManager_118f7af2115.decide($AccessDecisionManager_118f7af2115.java)
at
org.acegisecurity.intercept.AbstractSecurityInterceptor.beforeInvocation(AbstractSecurityInterceptor.java:323)
at
nu.localhost.tapestry.acegi.services.internal.StaticSecurityChecker.checkBefore(StaticSecurityChecker.java:43)
at
$SecurityChecker_118f7af20ce.checkBefore($SecurityChecker_118f7af20ce.java)
at com.bergoo.webshop.pages.Secure.beginRender(Secure.java)
at
org.apache.tapestry.internal.structure.ComponentPageElementImpl$11$1.run(ComponentPageElementImpl.java:338)
at
org.apache.tapestry.internal.structure.ComponentPageElementImpl.invoke(ComponentPageElementImpl.java:874)
... 98 more

I don't see the reason why I get the Access denied.
Thanks for any help...
Jacob
-- 
View this message in context: 
http://www.nabble.com/T5%3A-Problem-with-login-form-with-Acegi-tp16364295p16365723.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]