Return-Path: Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: (qmail 22279 invoked from network); 3 Jun 2010 21:22:29 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 3 Jun 2010 21:22:29 -0000 Received: (qmail 77127 invoked by uid 500); 3 Jun 2010 21:22:25 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 77075 invoked by uid 500); 3 Jun 2010 21:22:25 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 77066 invoked by uid 99); 3 Jun 2010 21:22:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Jun 2010 21:22:25 +0000 X-ASF-Spam-Status: No, hits=-1.1 required=10.0 tests=AWL,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of aw@ice-sa.com designates 212.85.38.228 as permitted sender) Received: from [212.85.38.228] (HELO tor.combios.es) (212.85.38.228) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Jun 2010 21:22:20 +0000 Received: from localhost (localhost [127.0.0.1]) by tor.combios.es (Postfix) with ESMTP id 886E5226158 for ; Thu, 3 Jun 2010 23:20:47 +0200 (CEST) Received: from tor.combios.es ([127.0.0.1]) by localhost (tor.combios.es [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hzB1R9pPGHVv for ; Thu, 3 Jun 2010 23:20:47 +0200 (CEST) Received: from [192.168.246.103] (montserrat.wissensbank.com [212.85.37.175]) by tor.combios.es (Postfix) with ESMTPA id C53CA226154 for ; Thu, 3 Jun 2010 23:20:46 +0200 (CEST) Message-ID: <4C081CEE.2040707@ice-sa.com> Date: Thu, 03 Jun 2010 23:21:50 +0200 From: =?ISO-8859-1?Q?Andr=E9_Warnier?= Reply-To: Tomcat Users List User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 To: Tomcat Users List Subject: Re: How can I get the user value in the request forwarded to my Tomcat in my Java app? References: <45572F79660DDC429F6B44582360A9AB010ABF57BB@PHDEXMB01.txhealth.org><4BFE8CD0.6020404@kippdata.de><45572F79660DDC429F6B44582360A9AB01084BEF9A@PHDEXMB01.txhealth.org><45572F79660DDC429F6B44582360A9AB01084BEF9E@PHDEXMB01.txhealth.org><45572F79660DDC429F6B44582360A9AB01084BEF9F@PHDEXMB01.txhealth.org>,<45572F79660DDC429F6B44582360A9AB010ABF5A84@PHDEXMB01.txhealth.org>,<4BFFF1F0.8090104@kippdata.de>,<45572F79660DDC429F6B44582360A9AB0108A45AA6@PHDEXMB01.txhealth.org> <45572F79660DDC429F6B44582360A9AB010ABF5CA4@PHDEXMB01.txhealth.org> <45572F79660DDC429F6B44582360A9AB010ABF61DC@PHDEXMB01.txhealth.org>,<4C06CD3D.7080606@ice-sa.com> <45572F79660DDC429F6B44582360A9AB0108A45AB5@PHDEXMB01.txhealth.org> <45572F79660DDC429F6B44582360A9AB010AD951B7@PHDEXMB01.txhealth.org> <45572F79660DDC429F6B44582360A9AB010AD9523B@PHDEXMB01.txhealth.org> <45572F79660DDC429F6B44582360A9AB010AD952F8@PHDEXMB01.txhealth.org> In-Reply-To: <45572F79660DDC429F6B44582360A9AB010AD952F8@PHDEXMB01.txhealth.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit Hi. Now we're cooking ! But by the way, now this is also OT for this list, because your problem now seems to be between the browser and the webserver. First, please do the following : using Google, find the the IE plugin named "Fiddler 2" and install it in your IE browser. That is a plugin which will allow you to view all the exchanges between the browser and the server (headers, errors, contents etc..). Second, check in the IE options that it is really allowed to use "Integrated Windows Authentication". That is somewhere in the long list of extended options. If you receive a login dialog when you try to access a resource under IIS, it is because either one of these conditions : - the IIS server requests the browser to authenticate using a specific method (e.g. NTLM), but the browser is not set up to do this and is trying a Basic authentication. - the version of NTLM required by the server and the one supported by the workstation are not compatible - your workstation is not logged into the same domain as the server - your workstation does not recognise the server as a "trusted" server Basically, if Integrated Windows Authentication was working, you should never see this login popup. It should all happen automatically behind the scenes. Savoy, Melinda wrote: > I think I was finally able to TEST that my tomcat connector and its respective config files have been setup correctly. > > I think I have narrowed my problem to an IIS Directory Security ISSUE on jakarta. If anyone has run into this issue can you please respond to the following problem: > > In IIS I have the Default Web Site setup with: > > ISAPI Filters: jakarta and it points to C:\Server\Tomcat 6.0\bin\isapi_redirect.dll > And the Directory Security is: Enable anonymous access (checked only) > > In IIS I have the jakarta virtual directory setup with: > > Where the local path is: C:\Server\Tomcat 6.0\bin > And the Directory Security is: Integrated Windows authentication (checked only) > > The result I get in my IE browser is: > > You are not authorized to view this page > You do not have permission to view this directory or page using the credentials that you supplied because your Web browser is sending a WWW-Authenticate header field that the Web server is not configured to accept. > -------------------------------------------------------------------------------- > > Please try the following: > > Contact the Web site administrator if you believe you should be able to view this directory or page. > Click the Refresh button to try again with different credentials. > HTTP Error 401.2 - Unauthorized: Access is denied due to server configuration. > Internet Information Services (IIS) > > But when I change the jakarta Directory Security to the following I am able to get to the ERROR.jsp page in my application on Tomcat: > > Directory Security changed to Anonymous access (checked only) > > The ERROR.jsp page comes up because I do not have a USER value in the request. It is empty as depicted from the isapi log: > > [Thu Jun 03 15:27:24.665 2010] [948:3148] [debug] jk_isapi_plugin.c (3108): Service protocol=HTTP/1.1 method=GET host=167.99.60.10 addr=167.99.60.10 name=scmisdev port=80 auth= user= uri=/pics/plus.jpg > > Any suggestions or direction on how I can remedy this issue would be appreciated. > > Thank you. > > > -----Original Message----- > From: Savoy, Melinda > Sent: Thursday, June 03, 2010 12:53 PM > To: 'Tomcat Users List' > Subject: RE: How can I get the user value in the request forwarded to my Tomcat in my Java app? > > Let me try to answer Andre's questions below as well as communicate the results I got given the settings I have in the Windows 2003 server and ANY HELP or DIRECTION would be GREATLY APPRECIATED : > > I spoke to the guy who had setup our Tomcat server and he said that the SECOND HOST in our server.xml file was there to define the virtual host that is in our enterprise DNS (see settings below). The baseapp="scmisapp" which is a directory in our tomcat server: C:\Server\Tomcat 6.0\scmisapp > > I removed the SECOND virtual directory as you instructed and now I'm getting Windows login dialog boxes when trying to go the URL: http://scmisdev. > > If we could start from the following settings and if someone could let me know what I'm doing wrong to get the error (see below) I'm getting it would be greatly appreciated: > > Workers.properties file: > > worker.scmisWorker.type=ajp13 > worker.scmisWorker.host=localhost (I'm not sure if this should match the host name="scmis" in my server.xml file or not) > worker.scmisWorker.port=8009 > > uriworkermap.properties file: > > /scmisdev/*=scmisWorker (this matches the virtual host that we have defined in the enterprise DNS and what we use to get to this server via the URL in our browsers (IE) http://scmisdev ). > > Server.xml: > > unpackWARs="false" autoDeploy="false" > xmlValidation="false" xmlNamespaceAware="false"> > > > > > > > > > unpackWARs="true" autoDeploy="false" > xmlValidation="false" xmlNamespaceAware="false"> > > scmisdev > scmisdev.texashealth.org > > > In IIS I have the Default Web Site setup with: > > ISAPI Filters: jakarta and it points to C:\Server\Tomcat 6.0\bin\isapi_redirect.dll > And the Directory Security is: Enable anonymous access (checked only) > > In IIS I have the jakarta virtual directory setup with: > > Where the local path is: C:\Server\Tomcat 6.0\bin > And the Directory Security is: Integrated Windows authentication (checked only) > > The result I get in my IE browser is: > > You are not authorized to view this page > You do not have permission to view this directory or page using the credentials that you supplied because your Web browser is sending a WWW-Authenticate header field that the Web server is not configured to accept. > -------------------------------------------------------------------------------- > > Please try the following: > > Contact the Web site administrator if you believe you should be able to view this directory or page. > Click the Refresh button to try again with different credentials. > HTTP Error 401.2 - Unauthorized: Access is denied due to server configuration. > Internet Information Services (IIS) > > -------------------------------------------------------------------------------- > > Technical Information (for support personnel) > > Go to Microsoft Product Support Services and perform a title search for the words HTTP and 401. > Open IIS Help, which is accessible in IIS Manager (inetmgr), and search for topics titled About Security, Authentication, and About Custom Error Messages. > > -----Original Message----- > From: Savoy, Melinda > Sent: Wednesday, June 02, 2010 5:12 PM > To: Tomcat Users List; Tomcat Users List > Subject: RE: How can I get the user value in the request forwarded to my Tomcat in my Java app? > > Andre, > > First my apologies for forgetting my earlier setup within my Windows XP box and therefore as you say not learning what I had done previously. > > Second - this Windows 2003 server was already setup and the second host was created in order that the user could enter a URL of http://scmisdev and then get to the application which is how it has been working. > > In your comment: > > "It seems that you have not learned a lot, or forgotten what you > previously learned. > > Why do you need this last "virtual directory" in IIS ? > The "jakarta" virtual directory will already re-direct (or rather > "proxy") all the calls to "/scmisdev/*" to Tomcat. > You do not want IIS to go directly put its nose in the Tomcat > directories. You want it to go through the isapi redirector for that, > which you already do with the jakarta virtual directory setup." > > What do I put in the uriworkermap.properties file that redirects to where the JSP's are? The directory path in Tomcat as to where the app is located is: > > C:\Server\Tomcat 6.0\scmisapp\ROOT\WEB-INF > > You are correct that I'm probably mixing up 2 things but I'm trying retain all the info that you and Ranier have each given but sometimes it would appear to me to be confusing. > > Lastly, let me state again my apologies. It is NOT my intent to waste the time of you or anyone else on this list just trying to get some help. > > I will try again in the morning. > > Regards. > > > ________________________________________ > From: Andr� Warnier [aw@ice-sa.com] > Sent: Wednesday, June 02, 2010 16:29 > To: Tomcat Users List > Subject: Re: How can I get the user value in the request forwarded to my Tomcat in my Java app? > > Savoy, Melinda wrote: >> I finally got my Windows 2003 development box setup with the Tomcat Connector and IIS 6.0. The following is my setup: >> >> In the server.xml file I have the following in the HOST element: >> >> >> > unpackWARs="false" autoDeploy="false" >> xmlValidation="false" xmlNamespaceAware="false"> >> >> >> >> >> >> >> >> >> >> > unpackWARs="true" autoDeploy="false" >> xmlValidation="false" xmlNamespaceAware="false"> >> >> scmisdev > > not necessary, since this is already the hostname > >> scmisdev.texashealth.org >> > > Why this second Host anyway ? > >> In my uriworkermap.properties file: >> >> /scmisdev/*=scmisWorker >> /scmisdev/*.jsp=scmisWorker >> /scmisdev/servlet/*=scmisWorker > > the first one covers the other 2, so why have them ? > >> In my workers.properties file: >> >> # workers.properties from = http://onjava.com/pub/a/onjava/2002/12/18/tomcat.html >> # >> # This file provides minimal jk configuration properties needed to >> # connect to Tomcat. >> # >> # The workers that jk should create and work with >> >> worker.list=scmisWorker >> >> # >> # Defining a worker named ajp13w and of type ajp13 >> # Note that the name and the type do not have to match. >> # >> worker.scmisWorker.port=8009 >> worker.scmisWorker.host=localhost >> worker.scmisWorker.type=ajp13 >> >> In IIS I have the Default Web Site setup with: >> >> ISAPI Filters: jakarta and it points to C:\Server\Tomcat 6.0\bin\isapi_redirect.dll >> And the Directory Security is: Enable anonymous access (checked only) >> >> In IIS I have the jakarta virtual directory setup with: >> >> Where the local path is: C:\Server\Tomcat 6.0\bin >> And the Directory Security is: Integrated Windows authentication (checked only) >> >> In IIS I have the scmisdev virtual directory setup with: >> >> Where the local path is: C:\Server\Tomcat 6.0\scmisapp\ROOT\WEB-INF (points to WEB-INF directory) >> And the Directory Security is: Integrated Windows authentication (checked only) > > It seems that you have not learned a lot, or forgotten what you > previously learned. > > Why do you need this last "virtual directory" in IIS ? > The "jakarta" virtual directory will already re-direct (or rather > "proxy") all the calls to "/scmisdev/*" to Tomcat. > You do not want IIS to go directly put its nose in the Tomcat > directories. You want it to go through the isapi redirector for that, > which you already do with the jakarta virtual directory setup. > >> However my result when going to URL http://localhost/scmisdev is: >> >> HTTP Status 404 - /scmisdev/ >> >> Type Status report >> >> Message /scmisdev/ >> >> Description The requested resource (/scmisdev/) is not available. >> >> Any suggestions or direction would be greatly appreciated. > > Ok, what does this error page look like ? Does it look like a Tomcat > error page ? > > Melinda, it seems that you are mixing two issues (again) : > - the first is in the basic setup of IIS+Tomcat, and how to set things > up so that the URLs which you are interested in are actually redirected > to Tomcat in the proper way. > - the second is, once the first one is working properly, to set things > up so that IIS authenticates users which request these URLs, and that > the isapi redirector forwards this authentication to Tomcat (which it > does, by default). > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > > > > The information contained in this message and any attachments is intended only for the use of the individual or entity to which it is addressed, and may contain information that is PRIVILEGED, CONFIDENTIAL, and exempt from disclosure under applicable law. If you are not the intended recipient, you are prohibited from copying, distributing, or using the information. Please contact the sender immediately by return e-mail and delete the original message from your system. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > > > > The information contained in this message and any attachments is intended only for the use of the individual or entity to which it is addressed, and may contain information that is PRIVILEGED, CONFIDENTIAL, and exempt from disclosure under applicable law. If you are not the intended recipient, you are prohibited from copying, distributing, or using the information. Please contact the sender immediately by return e-mail and delete the original message from your system. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > > > > The information contained in this message and any attachments is intended only for the use of the individual or entity to which it is addressed, and may contain information that is PRIVILEGED, CONFIDENTIAL, and exempt from disclosure under applicable law. If you are not the intended recipient, you are prohibited from copying, distributing, or using the information. Please contact the sender immediately by return e-mail and delete the original message from your system. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > > > > The information contained in this message and any attachments is intended only for the use of the individual or entity to which it is addressed, and may contain information that is PRIVILEGED, CONFIDENTIAL, and exempt from disclosure under applicable law. If you are not the intended recipient, you are prohibited from copying, distributing, or using the information. Please contact the sender immediately by return e-mail and delete the original message from your system. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org