You can buy a certificate if you need a valid one, but you can
generate a test certificate.
keytool -genkey -keyalg RSA -alias tomcat -keystore [nameofkeystore]
It will be created in bin directory of the JDK
You will then need to configure a connector supporting ssl in web.xml
<Connector port="8443"
maxThreads="150" minSpareThreads="25"
maxSpareThreads="75"
enableLookups="false" disableUploadTimeout="true"
acceptCount="100" debug="0" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" />
Then tomcat supports https.
Now for Tapestry You just need a redirect, for that I use a class
that implements PageValidateListener :
public void pageValidate(PageEvent event)
{
// ssl?
RequestContext requestContext = event.getRequestCycle
().getRequestContext();
if (!requestContext.getScheme().equals("https"))
{
// no, so redirect
String url = "https://" + requestContext.getServerName();
if (requestContext.getServerPort() == 8080)
{
url += ":8443"; // to handle debugging
}
url += requestContext.getRequestURI();
if (requestContext.getRequest().getQueryString() != null)
url += "?" + requestContext.getRequest().getQueryString();
throw new RedirectException(url);
}
All pages that must be behind https must subclass this class. And
that's all
I hope that will help.
Nuam
Le 1 févr. 07 à 12:06, [EMAIL PROTECTED] a écrit :
Hello,
I develop application with tapestry 3 and now my customer would
like used
https://
I never put this protocol in practice. My application server is
tomcat
5.0.28 and Redhat.
Have you preconization to do this ?
I searched on the web, I think that I must install Apache and buy
VerySign
Certificat .. yes or no ?
my second question is which must I make with Tapestry ?
Cordialement - Best regards
BRAJUS Cédric
SETVAL-CTIV
http://www.ctiv.vallourec.fr/
Office : + 33 (0)3 27 22 76 67
Fax : + 33 (0)3 27 22 23 00
<[EMAIL PROTECTED]>
01/02/2007 09:34
Veuillez répondre à
"Tapestry users" <users@tapestry.apache.org>
A
<users@tapestry.apache.org>
cc
Objet
RE: Redirect after Post = no parameters, no save
Depends on what kind of Tapestry/Hibernate Integration you're actually
using. Where is you session committed? Do you throw a
RedirectException
to redirect or do you return an ILink?
-----Original Message-----
From: Matt Brock [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 31, 2007 5:52 PM
To: users@tapestry.apache.org
Subject: Redirect after Post = no parameters, no save
Using: Tap 4.02 / Hibernate
I've tried to implement the redirect-after-post method
mentioned on Howard's blog, but have only been marginally successful.
It redirects just fine. But it doesn't actually commit any
changes to the database. Further, page parameters are not
passed to the subsequent page when using the the PAGE
service, thus I'm forced to use the external page service and
manually encode the parameters. If that were the only
problem I could deal with it, but the not saving issue is a
show-stopper.
Is this because the Hibernate listeners are not being fired
by the ILink service? Do I have to create my own custom
ILink implementation that fires all the listeners like the
IPage service does? Has anyone come up with any way to get
redirect-after-post working with Tap4/Hibernate?
--
View this message in context:
http://www.nabble.com/Redirect-after-Post-%3D-no-parameters%2C
-no-save-tf3149787.html#a8732557
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]