running tomcat with root user

2009-01-31 Thread epicwin...@hotmail.com

I have the latest tomcat 6 installed under centos 5.2.  The problem I am having 
is that it appears that I have to run tomcat as root user, because the spring 
app that tomcat starts needs to write files to other users' home directories.  
The tomcat user doesn't have access to these directories.

I tried making these users part of a shared group, but to complicate the 
problem the users are jailed using jailkit.  So it doesn't appear that jailkit 
lets me add group write privileges to the home directories and maintain a 
working jail.

Can anyone suggest another alternative?  I am not linux user expert so maybe 
there is an obvious solution i am missing?
thanks




_
Windows Live™ Hotmail®…more than just e-mail. 
http://windowslive.com/howitworks?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_howitworks_012009

RE: running tomcat with root user

2009-02-01 Thread epicwin...@hotmail.com



> Date: Sun, 1 Feb 2009 11:04:10 +0100
> From: a...@ice-sa.com
> To: users@tomcat.apache.org
> Subject: Re: running tomcat with root user
> 
> epicwin...@hotmail.com wrote:
> > I have the latest tomcat 6 installed under centos 5.2.  The problem I am 
> > having is that it appears that I have to run tomcat as root user, because 
> > the spring app that tomcat starts needs to write files to other users' home 
> > directories.  The tomcat user doesn't have access to these directories.
> > 
> > I tried making these users part of a shared group, but to complicate the 
> > problem the users are jailed using jailkit.  So it doesn't appear that 
> > jailkit lets me add group write privileges to the home directories and 
> > maintain a working jail.
> > 
> > Can anyone suggest another alternative?  I am not linux user expert so 
> > maybe there is an obvious solution i am missing?
> 
> If you are courageous, you could try using ACL's.
> One pre-requisite is that the filesystem type on which the users's 
> directories are located, must support ACL. The other pre-requisite is 
> that ACLs be actually enabled on that filesystem. This has to do with 
> the "mount" command that mounts the filesystem.
> I am no specialist myself, and you'll have to get some help from a Linux 
> forum for that.
> The next part is to understand the commands that deal with ACL's, and 
> that is why I said that you have to be courageous. They are not for the 
> faint-hearted.
> Try :
> man setfacl
> man getfacl
> 
> Very briefly :
> ACL = Access Control List
> They are a possibility to set access permissions to files and 
> directories, in a more detailed and flexible way than Unix usual 
> "rwxrwxrwx"-style permissions.
> You can have a directory belonging to user X and group Y, but still 
> allow users of group Z (e.g. Tomcat) to write to it.
> 
> All of the above of course may or may not be compatible with the "jail" 
> you are mentioning. I make no guarantees there.
> And otherwise, you'll have to run Tomcat as root and that's it.
> 
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

Thanks for the reply and suggestion , i am doing some heavy reading right now 
on ACLs.  Very interesting, looks like a possible solution.  I am doing this on 
a remote server with one drive so I am a little nervous about making these 
changes and seeing if it comes back up.  I am also concerned if there would be 
a performance hit.  I really wish there was a simpler solution.  I wonder how 
insecure it really would be to run tomcat as root or if there was a way to make 
it "more" secure


_
Windows Live™: E-mail. Chat. Share. Get more ways to connect. 
http://windowslive.com/howitworks?ocid=TXT_TAGLM_WL_t2_allup_howitworks_012009

RE: running tomcat with root user

2009-02-01 Thread epicwin...@hotmail.com



> From: peter.crowt...@melandra.com
> To: users@tomcat.apache.org
> Date: Sun, 1 Feb 2009 12:59:33 +
> Subject: RE: running tomcat with root user
> 
> > From: epicwin...@hotmail.com [mailto:epicwin...@hotmail.com]
> > I have the latest tomcat 6 installed under centos 5.2.  The
> > problem I am having is that it appears that I have to run
> > tomcat as root user, because the spring app that tomcat
> > starts needs to write files to other users' home directories.
> >  The tomcat user doesn't have access to these directories.
> >
> > I tried making these users part of a shared group, but to
> > complicate the problem the users are jailed using jailkit.
> > So it doesn't appear that jailkit lets me add group write
> > privileges to the home directories and maintain a working jail.
> >
> > Can anyone suggest another alternative?  I am not linux user
> > expert so maybe there is an obvious solution i am missing?
> 
> Beyond Andre's solution of ACLs, there's another one that's more complex but 
> might be more secure.  It requires a slight shift in architecture.
> 
> 1) Run Tomcat as the tomcat user.  Change the way it writes files, so that 
> instead of writing to the user directory it writes the details to a queue 
> that you have control over.  That could be a database, or a chunk of 
> filestore.
> 
> 2) Write a second daemon that runs as root, that reads the queue, does 
> whatever checks you require so that it believes the queued requests are 
> genuine, then writes the queued items to the users' directories.
> 
> This reduces the attack surface of the system, in that tomcat's not running 
> as root.  You'd have to be careful with the security of the daemon and the 
> queue but, if well-designed, the overall security may be better than running 
> Tomcat as root.
> 
> - Peter
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

Peter- I am considering options like this, the problem which complicates my 
situation more is that the remote client accesses the files written immediately 
after they are written and I don't want to deal with timing issues of the 
daemon running before the client needs to access the files.  

_
Windows Live™ Hotmail®:…more than just e-mail. 
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_explore_012009

RE: running tomcat with root user.....umask in jsvc?

2009-02-02 Thread epicwin...@hotmail.com

You are correct, I found a setting that relaxes the group access permissions on 
the jailkit.  

Now I just have one more problem.  When tomcat creates files in these user 
directories I need the permissions to be set appropriately.  What is the best 
way to set the umask value when running tomcat using jsvc?

> Date: Sun, 1 Feb 2009 21:58:11 -0800
> From: rusty.wri...@gmail.com
> To: users@tomcat.apache.org
> Subject: Re: running tomcat with root user
> 
> Are you sure about the group write permissions?  I glanced at the jailkit web 
> page and it looks like it's sugar coating and chrome around a chroot.  So I 
> would think that using unix groups would work.  And on the flip side, if unix 
> groups don't work, it seems to me that ACLs wouldn't either.
> 
> 
> epicwin...@hotmail.com wrote:
> > I have the latest tomcat 6 installed under centos 5.2.  The problem I am 
> > having is that it appears that I have to run tomcat as root user, because 
> > the spring app that tomcat starts needs to write files to other users' home 
> > directories.  The tomcat user doesn't have access to these directories.
> > 
> > I tried making these users part of a shared group, but to complicate the 
> > problem the users are jailed using jailkit.  So it doesn't appear that 
> > jailkit lets me add group write privileges to the home directories and 
> > maintain a working jail.
> > 
> > Can anyone suggest another alternative?  I am not linux user expert so 
> > maybe there is an obvious solution i am missing?
> > thanks
> > 
> > 
> > 
> > 
> > _
> > Windows Live™ Hotmail®…more than just e-mail. 
> > http://windowslive.com/howitworks?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_howitworks_012009
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

_
Windows Live™ Hotmail®…more than just e-mail. 
http://windowslive.com/howitworks?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_howitworks_012009

RE: running tomcat with root user.....umask in jsvc?

2009-02-02 Thread epicwin...@hotmail.com

That is a possible solution.  There is a fairly heavy amount of files uploaded 
from many different users so it would mean a lot of configuration and a lot of 
maintenance to that config as i add new users.  So I am trying to avoid the 
operating system chmod commands in my code.  
If i add umask 002 in my ./etc/init.d/tomcat start up script it seems to fix 
the problem but i think this is setting that umask for more than just tomcat so 
i am not sure how safe that is.


> Date: Mon, 2 Feb 2009 21:05:15 +0100
> From: a...@ice-sa.com
> To: users@tomcat.apache.org
> Subject: Re: running tomcat with root user.umask in jsvc?
> 
> André Warnier wrote:
> > epicwin...@hotmail.com wrote:
> >> You are correct, I found a setting that relaxes the group access 
> >> permissions on the jailkit. 
> >> Now I just have one more problem.  When tomcat creates files in these 
> >> user directories I need the permissions to be set appropriately.  What 
> >> is the best way to set the umask value when running tomcat using jsvc?
> >>
> > That's a good question.
> > I don't think jsvc would take any account of the Tomcat user's .profile 
> > file.
> > ACLs would allow you to do that however :-)
> > (Seriously, I believe you can set an ACL on the target directory that 
> > would make it so that when this particular user (Tomcat) creates a file 
> > there, it has by default a given set of permissions).
> > Otherwise, you might have to do some kind of chmod from within your 
> > webapp itself, after it creates the file. I don't know what Java method 
> > that would be.
> > 
> Replying to myself : upon further reflection, I am not even sure that 
> Java would have a method to do this, since it is supposed to be 
> platform-independent, and setting filesystem permissions and group 
> ownership is rather on the platform-dependent side.
> How often do such upload requests come in ? I'm thinking that if this is 
> a single-platform solution, and file uploads don't come up tens per 
> second at a time, it may be possible (though I also don't know how) to 
> simply execute an OS-level command (chmod 0xxx filename; chgroup x 
> filename) from within a Tomcat webapp, or a servlet filter that would 
> run after the webapp.
> 
> Otherwise, ACLs are complicated in terms of understanding the 
> documentation of setfacl; but once you have it down, it is after all 
> only a matter of running a single setfacl command once on each of your 
> target directories. And it has the advantage of being done totally 
> outside of your webapp, once and for all. It "sticks" to the directory, 
> not to your code.
> 
> 
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

_
Windows Live™ Hotmail®:…more than just e-mail. 
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_explore_012009

RE: running tomcat with root user.....umask in jsvc?

2009-02-02 Thread epicwin...@hotmail.com



> Date: Mon, 2 Feb 2009 22:00:24 +0100
> From: a...@ice-sa.com
> To: users@tomcat.apache.org
> Subject: Re: running tomcat with root user.umask in jsvc?
> 
> epicwin...@hotmail.com wrote:
> > That is a possible solution.  There is a fairly heavy amount of files 
> > uploaded from many different users so it would mean a lot of configuration 
> > and a lot of maintenance to that config as i add new users.  So I am trying 
> > to avoid the operating system chmod commands in my code.  
> I don't really like that either, and it does break if you ever (yuk) 
> would decide to run your code on some other platform.
> 
> > If i add umask 002 in my ./etc/init.d/tomcat start up script it seems to 
> > fix the problem but i think this is setting that umask for more than just 
> > tomcat so i am not sure how safe that is.
> As far as I can tell, it would only change the umask for the current 
> process (the shell executing your startup script) and all its offsprings 
> (jsvc, tomcat).  But it will do it for *everything* that these processes 
> do (such as creating temporary files, logfiles, etc..).  That may indeed 
> not be very secure. For instance, one thing which Tomcat to my knowledge 
> does (if you have not disabled it) is to rewrite the "conf/users.xml" 
> file each time it starts up (or stops ?).  That particular file is not 
> essential, and maybe Tomcat does not do that anymore in recent versions, 
> but there might be other such things lurking around unexpectedly.
>
That was my concern, I think it is a very mild security concern but still an 
issue nonetheless.  Since the tomcat user doesn't have shell access or root 
access I can't see it being a big issue, it would be nice if you could set the 
umask for just the class loader or running java process.

> 
> I'm still a bit curious about how you did organise the upload 
> directories and their rights and groups etc.. finally, because you want 
> this one Tomcat user to be able to write into upload directories owned 
> originally by other users, right ? Or at least, you want these other 
> users afterward to have access to these files somehow.
> So you must have established some common group or groups between the 
> Tomcat user, and these other users, right ?
> I am just wondering if by doing this, you have not "weakened" the 
> general protection of all that stuff.
>
You got it.  Here is how i have it set up  let me know what you think:
I created a shared group :
groupadd sharedgroup
Then i changed it so all my users were members of this group:
usermod -g sharedgroup tomcat
usermod -g sharedgroup jaileduser1

usermod -g sharedgroup jaileduser2 ...etc

Then I found some settings in the jailkit ( http://olivier.sessink.nl/jailkit/ 
) that allow for the jailed users to have group read/write permissions:
in /etc/jailkist/jk_chrootsh.ini
relax_home_group=1
relax_home_group_permissions=1
relax_home_other_permissions=1

Then in the jail jk_lsh.ini i set up the umask for the shared group:

[group sharedgroup]
paths= /usr/bin, /usr/lib/
executables= /usr/bin/scp, /usr/libexec/openssh/sftp-server
umask= 002

Finally I added the umask 002 line to my tomcat startup script

The external jailed users only have sftp access and aren't able to move outside 
their home directories.  Since the jailed user shares a group with tomcat they 
can all incestially read and write files to these home directories and since 
the umask is set the permissions are retained as new directories are created 
and so forth.

What do you think?
 
> I had a quite similar case to resolve not so long ago (with Apache, not 
> Tomcat), and only ended up with ACLs after being forced to use them, 
> because no other solution would really provide the security I wanted.
> 
Yeah the ACLs look very effective but like yourself i am trying to avoid extra 
complications

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

_
Windows Live™ Hotmail®…more than just e-mail. 
http://windowslive.com/howitworks?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_howitworks_012009

RE: running tomcat with root user.....umask in jsvc?

2009-02-02 Thread epicwin...@hotmail.com



> Date: Tue, 3 Feb 2009 00:10:30 +0100
> From: a...@ice-sa.com
> To: users@tomcat.apache.org
> Subject: Re: running tomcat with root user.umask in jsvc?
> 
> epicwin...@hotmail.com wrote:
> [...]
> I'm not a great security specialist, but your setup looks indeed safe 
> enough, if the users are chrooted to their home directories.
> I can't imagine how they could break out and access things they shouldn't.
> 
> Just one more question : how do you arrange to know who is uploading a 
> file, and thus where to put it ?

Well each customer gets assigned it's own jailed user.  The uploading facility 
is completely underneath a swing gui so all the customer knows is that the 
upload button works.  When the customer logs in to their swing client they load 
some settings requested from the server, one of these settings happens to be 
their sftp login for the server and the other is the upload directory.  So the 
server holds all this info in config files and the ysers don't even ever know 
what their login is.  

> 
> 
> 
> As a footnote : having a basic problem similar to yours (under Apache, 
> not Tomcat), I ended up with a solution like this, implemented with 
> Apache and mod_perl, but which should be also transposable to Tomcat 
> with servlet filters and such :
> 
> To allow users to upload their files, I implemented the standard DAV 
> module in Apache (which also exists in Tomcat). This way, they can do 
> drag-and-drop directly from within their Windows Explorer, to one 
> directory structure on the server. And, I did not have to re-invent the 
> wheel for uploading files.
> 
> But that did not at first allow me to know who was uploading the file, 
> and what to do with it.
> To know who was doing it, I thus added an HTTP authentication.
> But still, DAV doesn't care, and uploads all the files under the user 
> Apache (Tomcat) runs under.
> 
> So I added a couple of filters, one in front and one behind DAV. The 
> front-end filter takes note of who this is (from the Apache 
> authentication), and where the user thinks he is uploading the file to 
> (from the URL), then changes the "PUT" URL sneakily (a la mod_rewrite), 
> so that DAV now uploads the file in fact somewhere completely different, 
> outside of the directories where the user thinks he is uploading.
> 
> Then right after DAV, another filter picks up the uploaded file from the 
> known place where DAV put it, and moves it to the real destination and 
> with the correct ownership and permissions (which it gets from where the 
> first filter saved them).
> 
> It is a bit like another solution suggested earlier based on a separate 
> daemon, only here everything happens in real-time.
> 
> I am sure this could be done in Tomcat with a servlet filter around the 
> DAV webapp.
> 
I haven't done much with those filters, but i like the idea of using the 
filters for something like this, it is nice that it is at least somewhat 
external to core code.
> 
> 
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

_
Windows Live™ Hotmail®:…more than just e-mail. 
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t2_hm_justgotbetter_explore_012009

WEB-INF/classes vs WEB-INF/lib/classes.jar file

2009-02-04 Thread epicwin...@hotmail.com

Is there any advantage why I should not just jar all my class files and put 
them in WEB-INF/lib rather than exploding the jar file to the classes directory?


I like developing with the classes and I understand it is nice to let tomcat 
deploy a .war file but it also creates some problems for me because i deploy to 
multiple production servers with different settings that get overwritten every 
time my war file is expanded.




_
Windows Live™: Keep your life in sync. 
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t1_allup_explore_022009

RE: WEB-INF/classes vs WEB-INF/lib/classes.jar file

2009-02-05 Thread epicwin...@hotmail.com

Thanks for all the replies.  Nice to know i can do this without any side 
effects.  I think I will have to look into maven and see if that fits my 
deployment needs.


_
Windows Live™: E-mail. Chat. Share. Get more ways to connect. 
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t2_allup_explore_022009

ssl problems

2009-02-12 Thread epicwin...@hotmail.com

First off unfortunately on this install I am using tomcat on windows, i know 
boo hiss...  But I just installed the latest tomcat 6.0.18 and am having a 
problem with ssl.

All I did was added these lines to the originally installed server.xml file:


And I get this weird error telling me it can't find this .keystore file i never 
even reference in my config.  I even tried without adding this and get the same 
error:




Here is the full text of the error:

Feb 12, 2009 4:27:19 PM org.apache.tomcat.util.net.jsse.JSSESocketFactory 
getStore
SEVERE: Failed to load keystore type JKS with path C:\Documents and 
Settings\Ryan/.keystore due to C:\Documents and Settings\Ryan\.keystore (The 
system cannot find the file specified)
java.io.FileNotFoundException: C:\Documents and Settings\Ryan\.keystore (The 
system cannot find the file specified)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.(FileInputStream.java:106)
at 
org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocketFactory.java:337)
at 
org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESocketFactory.java:259)
at 
org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:444)
at 
org.apache.tomcat.util.net.jsse.JSSESocketFactory.init(JSSESocketFactory.java:409)
at 
org.apache.tomcat.util.net.jsse.JSSESocketFactory.createSocket(JSSESocketFactory.java:125)
at org.apache.tomcat.util.net.JIoEndpoint.init(JIoEndpoint.java:496)
at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:176)
at org.apache.catalina.connector.Connector.initialize(Connector.java:1058)
at 
org.apache.catalina.core.StandardService.initialize(StandardService.java:677)
at 
org.apache.catalina.core.StandardServer.initialize(StandardServer.java:795)
at org.apache.catalina.startup.Catalina.load(Catalina.java:530)
at org.apache.catalina.startup.Catalina.load(Catalina.java:550)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:260)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:412)
Feb 12, 2009 4:27:19 PM org.apache.coyote.http11.Http11Protocol init

Any thoughts?




_
Windows Live™: Keep your life in sync. 
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t1_allup_explore_022009

RE: ssl connector

2009-02-12 Thread epicwin...@hotmail.com

Thanks.  So I don't understand the docs where they suggest defining connectors 
with apr and without.  They show examples of 3 different connectors:  
org.apache.coyote.http11.Http11Protocol,org.apache.coyote.http11.Http11NioProtocol
 and org.apache.coyote.http11.Http11AprProtocol.

Do I need to define all three?  Is there a performance difference?

And the APR one doesn't seem to define the keystore, is it not necessary for 
that?
thanks


> Date: Fri, 13 Feb 2009 00:38:02 +
> Subject: Re: ssl problems
> From: anuragka...@gmail.com
> To: users@tomcat.apache.org
> 
> You also need a .keystore  file (if you are on default settings, then in the
> users home directory).
> Read more on it here: http://tomcat.apache.org/tomcat-6.0-doc/ssl-howto.html
> 
> Anurag
> --
> Anurag Kapur
> Associate - Technology,
> Sapient Corporation India.
> ------
> 
> 
> On Fri, Feb 13, 2009 at 12:30 AM, epicwin...@hotmail.com <
> epicwin...@hotmail.com> wrote:
> 
> >
> > First off unfortunately on this install I am using tomcat on windows, i
> > know boo hiss...  But I just installed the latest tomcat 6.0.18 and am
> > having a problem with ssl.
> >
> > All I did was added these lines to the originally installed server.xml
> > file:
> >  >   maxThreads="150" scheme="https" secure="true"
> >   clientAuth="false" sslProtocol="TLS"
> >   SSLEngine="on"
> >SSLCertificateFile="C:\Documents and Settings\Ryan\My
> > Documents\work\project1\ssl\mycert.pem"
> >SSLCertificateKeyFile="C:\Documents and Settings\Ryan\My
> > Documents\work\project1\ssl\mykey.pem"
> >SSLPassword="mypass"
> >   />
> >
> > And I get this weird error telling me it can't find this .keystore file i
> > never even reference in my config.  I even tried without adding this and get
> > the same error:
> >
> >  >
> >   maxThreads="150" scheme="https" secure="true"
> >
> >   clientAuth="false" sslProtocol="TLS"
> >
> > />
> >
> >
> > Here is the full text of the error:
> >
> > Feb 12, 2009 4:27:19 PM org.apache.tomcat.util.net.jsse.JSSESocketFactory
> > getStore
> > SEVERE: Failed to load keystore type JKS with path C:\Documents and
> > Settings\Ryan/.keystore due to C:\Documents and Settings\Ryan\.keystore (The
> > system cannot find the file specified)
> > java.io.FileNotFoundException: C:\Documents and Settings\Ryan\.keystore
> > (The system cannot find the file specified)
> >at java.io.FileInputStream.open(Native Method)
> >at java.io.FileInputStream.(FileInputStream.java:106)
> >at
> > org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocketFactory.java:337)
> >at
> > org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESocketFactory.java:259)
> >at
> > org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeyManagers(JSSESocketFactory.java:444)
> >at
> > org.apache.tomcat.util.net.jsse.JSSESocketFactory.init(JSSESocketFactory.java:409)
> >at
> > org.apache.tomcat.util.net.jsse.JSSESocketFactory.createSocket(JSSESocketFactory.java:125)
> >at org.apache.tomcat.util.net.JIoEndpoint.init(JIoEndpoint.java:496)
> >at org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:176)
> >at
> > org.apache.catalina.connector.Connector.initialize(Connector.java:1058)
> >at
> > org.apache.catalina.core.StandardService.initialize(StandardService.java:677)
> >at
> > org.apache.catalina.core.StandardServer.initialize(StandardServer.java:795)
> >at org.apache.catalina.startup.Catalina.load(Catalina.java:530)
> >at org.apache.catalina.startup.Catalina.load(Catalina.java:550)
> >at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> >at
> > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> >at
> > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> >at java.lang.reflect.Method.invoke(Method.java:585)
> >at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:260)
> >at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:412)
> > Feb 12, 2009 4:27:19 PM org.apache.coyote.http11.Http11Protocol init
> >
> > Any thoughts?
> >
> >
> >
> >
> > _
> > Windows Live™: Keep your life in sync.
> > http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t1_allup_explore_022009

_
Windows Live™: E-mail. Chat. Share. Get more ways to connect. 
http://windowslive.com/online/hotmail?ocid=TXT_TAGLM_WL_HM_AE_Faster_022009

RE: ssl connector

2009-02-12 Thread epicwin...@hotmail.com

Thanks it makes sense now, i have made lots of progress.  But of course, like 
usual,  there are some complications.  The application I am developing uses 
tomcat on the back end and a swing client on the front with the Spring 
HttpInvoker.  

So first I got it working without apr.  After I set up the connector I changed 
it so when i ran my java client using this vm parameter
-Djavax.net.ssl.trustStore="keystore.jks" 

Everything worked.  So next, I moved on to APR.  I got apr properly 
compiled/installed.  Then I set up the connector like so:
 From: chuck.caldar...@unisys.com
> To: users@tomcat.apache.org
> Date: Thu, 12 Feb 2009 21:47:45 -0600
> Subject: RE: ssl connector
> 
> > From: epicwin...@hotmail.com [mailto:epicwin...@hotmail.com]
> > Subject: RE: ssl connector
> >
> > So I don't understand the docs where they suggest
> > defining connectors with apr and without.
> 
> APR is an additional, non-Java Tomcat component that utilizes code from httpd 
> for increased SSL performance.  It uses OpenSSL, not Java, for the SSL 
> negotiation and encryption, so there's no keystore file, and the  
> configuration is very different from that for the standard or NIO options.  
> The drawback of APR is that you typically have to compile it from source for 
> the specific platform you're running on (some binary downloads are 
> available), so it's not something for the casual or first-time Tomcat 
> administrator.
> 
> The table at the bottom of this page:
> http://tomcat.apache.org/tomcat-6.0-doc/config/http.html
> gives you a comparison of the three forms of connector; pick just one for 
> your usage.
> 
>  - Chuck
> 
> 
> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY 
> MATERIAL and is thus for use only by the intended recipient. If you received 
> this in error, please contact the sender and delete the e-mail and its 
> attachments from all computers.
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 

_
Windows Live™: E-mail. Chat. Share. Get more ways to connect. 
http://windowslive.com/online/hotmail?ocid=TXT_TAGLM_WL_HM_AE_Faster_022009