Re: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-12 Thread Rangel Preis
Thanks Nino, you are correct.

In the Jetty tutorial says:

"...extending the Connector class of your choice, eg the
SelectChannelConnector, and implement the customize..."

public void customize(org.mortbay.io.EndPoint endpoint, Request
request) throws IOException
{
request.setScheme("https");
super.customize(endpoint, request);
}

but this don't work and i change to:

public void customize(final EndPoint endpoint, final Request
request) throws IOException {
super.customize(endpoint, request);
if ("https".equals(request.getHeader("scheme"))) {
request.setScheme("https");
}
}

Now this works. Thanks Nino.



2009/11/11 nino martinez wael :
> I think last time this came up it ended out being some issue with jetty?
>
> 2009/11/11 Rangel Preis 
>
>> I extends HttpsRequestCycleProcessor and SwitchProtocolRequestTarget
>> to make my custom HttpsRequestCycleProcessor
>> In the method getUrl from SwitchProtocolRequestTarget i just remove the
>> port:
>>
>>         if (port != null) {
>>          result.append(":");
>>          result.append(port);
>>         }
>>
>> But don't work, the url are correct but the page don't load i think i
>> miss something in apache.
>>
>> Anyone make something like this?
>>
>> Thanks.
>>
>> 2009/11/10 Rangel Preis :
>> > The unique solution that i found is extends HttpsRequestCycleProcessor
>> > to change only the protocol.
>> >
>> > Any other ideia? Thanks All.
>> >
>> > 2009/11/10 Rangel Preis :
>> >> The situation here is:
>> >>
>> >> https                          http
>> >> ->   Apache   ---> Jetty
>> >>
>> >>
>> >> Using wicket in my WicketApplication I put
>> >>
>> >>  private static final HttpsConfig HTTPS_CONFIG = new
>> >> HttpsConfig(HTTP_PORT, HTTPS_PORT);
>> >>
>> >>   �...@override
>> >>    protected IRequestCycleProcessor newRequestCycleProcessor() {
>> >>        return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
>> >>    }
>> >>
>> >> And in my LoginPage.java i have @RequireHttps
>> >>
>> >> When i try to run the system with this config i get a error because
>> >> Wicket assumes the HTTPS control and try to change the URL (port and
>> >> replace http to https)
>> >>
>> >> How i say to wicket to just change the protocol to HTTPS? And don't
>> >> change the port?
>> >>
>> >> Thanks
>> >>
>> >
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-11 Thread nino martinez wael
I think last time this came up it ended out being some issue with jetty?

2009/11/11 Rangel Preis 

> I extends HttpsRequestCycleProcessor and SwitchProtocolRequestTarget
> to make my custom HttpsRequestCycleProcessor
> In the method getUrl from SwitchProtocolRequestTarget i just remove the
> port:
>
> if (port != null) {
>  result.append(":");
>  result.append(port);
> }
>
> But don't work, the url are correct but the page don't load i think i
> miss something in apache.
>
> Anyone make something like this?
>
> Thanks.
>
> 2009/11/10 Rangel Preis :
> > The unique solution that i found is extends HttpsRequestCycleProcessor
> > to change only the protocol.
> >
> > Any other ideia? Thanks All.
> >
> > 2009/11/10 Rangel Preis :
> >> The situation here is:
> >>
> >> https  http
> >> ->   Apache   ---> Jetty
> >>
> >>
> >> Using wicket in my WicketApplication I put
> >>
> >>  private static final HttpsConfig HTTPS_CONFIG = new
> >> HttpsConfig(HTTP_PORT, HTTPS_PORT);
> >>
> >>@Override
> >>protected IRequestCycleProcessor newRequestCycleProcessor() {
> >>return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
> >>}
> >>
> >> And in my LoginPage.java i have @RequireHttps
> >>
> >> When i try to run the system with this config i get a error because
> >> Wicket assumes the HTTPS control and try to change the URL (port and
> >> replace http to https)
> >>
> >> How i say to wicket to just change the protocol to HTTPS? And don't
> >> change the port?
> >>
> >> Thanks
> >>
> >
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-11 Thread Rangel Preis
I extends HttpsRequestCycleProcessor and SwitchProtocolRequestTarget
to make my custom HttpsRequestCycleProcessor
In the method getUrl from SwitchProtocolRequestTarget i just remove the port:

 if (port != null) {
  result.append(":");
  result.append(port);
 }

But don't work, the url are correct but the page don't load i think i
miss something in apache.

Anyone make something like this?

Thanks.

2009/11/10 Rangel Preis :
> The unique solution that i found is extends HttpsRequestCycleProcessor
> to change only the protocol.
>
> Any other ideia? Thanks All.
>
> 2009/11/10 Rangel Preis :
>> The situation here is:
>>
>> https                          http
>> ->   Apache   ---> Jetty
>>
>>
>> Using wicket in my WicketApplication I put
>>
>>  private static final HttpsConfig HTTPS_CONFIG = new
>> HttpsConfig(HTTP_PORT, HTTPS_PORT);
>>
>>   �...@override
>>    protected IRequestCycleProcessor newRequestCycleProcessor() {
>>        return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
>>    }
>>
>> And in my LoginPage.java i have @RequireHttps
>>
>> When i try to run the system with this config i get a error because
>> Wicket assumes the HTTPS control and try to change the URL (port and
>> replace http to https)
>>
>> How i say to wicket to just change the protocol to HTTPS? And don't
>> change the port?
>>
>> Thanks
>>
>

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-10 Thread Rangel Preis
The unique solution that i found is extends HttpsRequestCycleProcessor
to change only the protocol.

Any other ideia? Thanks All.

2009/11/10 Rangel Preis :
> The situation here is:
>
> https                          http
> ->   Apache   ---> Jetty
>
>
> Using wicket in my WicketApplication I put
>
>  private static final HttpsConfig HTTPS_CONFIG = new
> HttpsConfig(HTTP_PORT, HTTPS_PORT);
>
>   �...@override
>    protected IRequestCycleProcessor newRequestCycleProcessor() {
>        return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
>    }
>
> And in my LoginPage.java i have @RequireHttps
>
> When i try to run the system with this config i get a error because
> Wicket assumes the HTTPS control and try to change the URL (port and
> replace http to https)
>
> How i say to wicket to just change the protocol to HTTPS? And don't
> change the port?
>
> Thanks
>

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-10 Thread Rangel Preis
The situation here is:

https  http
->   Apache   ---> Jetty


Using wicket in my WicketApplication I put

  private static final HttpsConfig HTTPS_CONFIG = new
HttpsConfig(HTTP_PORT, HTTPS_PORT);

@Override
protected IRequestCycleProcessor newRequestCycleProcessor() {
return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
}

And in my LoginPage.java i have @RequireHttps

When i try to run the system with this config i get a error because
Wicket assumes the HTTPS control and try to change the URL (port and
replace http to https)

How i say to wicket to just change the protocol to HTTPS? And don't
change the port?

Thanks

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org