You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Robert Andersson <ro...@profundis.nu> on 2003/07/07 15:18:21 UTC

Re: [users@httpd] UseCanonicalName question

Mark A. Marcello wrote:
> I thought setting UseCanonicalName to off would make this happenen,
> but it did not.  I also tried setting it to DNS, which again, didnt work.
> Is there another setting someone in the httpd.conf file that allows me to
> let the URL be the one typed in by the user?

That is what UseCanonicalName Off is supposed to do; create self-referential
URIs using the hostname provided by the client. Are you sure you restarted
properly and made sure it isn't a caching issue?

Regards,
Robert Andersson




---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by Robert Andersson <ro...@profundis.nu>.
Mark A. Marcello wrote:
> also, if i just type in the ip address, it too brings me to
> dev.instruct.rhnet.org/index.html, with
> dev.instruct.rhnet.org/index.html as the URL, not the IP address

Hmm. You mean, that if you issue this request:

GET / HTTP/1.1

You'll get a response like this:

HTTP/1.1 301 Moved
Location: http://dev.instruct.rhnet.org/index.html

If that is so, what is causing the redirect? Study your config, and perhaps
strip it some and see if you can make this behaviour go away. I cannot throw
a good guess on what it is.

Regards,
Robert Andersson




---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


[users@httpd] Multiple requests for username/pW

Posted by w...@evjohn.com.
When I use Front Page Extensions (FPE) to create a protected folder I am
often prompted for the password many times before access is granted.
My hosting service has the following installed:
	Linix:RedHat 7.3
	Apache: 1.3.27
	Front Page Extensions: 5
	mod-dav (Allows read/write access to files)
	   (All security handled by Apache, not mod_dav)

I have uploded an Excel spreadsheet (.xls) file to a folder in my web site.
The .xls file is not password protected by Excel.  Using FPE, I set the
folder to:
	Use unique permissions
	Only registered users can browse
	One username/password (just called "pw" below) with browse only
	Another pw with browse & author permissions.

When I use Excel to open the file (File/Open http://MyDomain/path/jnk.xls)
I am prompted for the pw.  If I enter the pw with author permission, the
spreadsheet immediately opens with read/write access as it should.
However, if I enter the browse only pw I am asked tor the pw many times,
and then finally read-only access is granted as it should be.

The question is why I am prompted for the pw so many times and what can I
do  so I am only prompted once?

I have tried all sorts of changes to .htaccess in the folder where the .xls
file is.  Some changes caused it not to work at all, but all the working
ones I tried failed in the same way.

In case they are helpful, here are 5 different scenarios which may help to
understand just what is happening:

Scenario 1 - Enter pw at every prompt: 
1.pw request for Resource http://MyDomain/t/jnk.xls, I enter correct pw 
(do above a total of three times.  Note: the AuthName in the folder's
.htaccess is simply  "t")

2."File transferring" message briefly displayed

3. pw request for Resource http://MyDomain/t/jnk.xls, I enter correct pw
(do above a total of three times)

4. Read only copy of spread sheet opens & is ready to use.

Scenario 2 - Enter pw at 1st promot only:
1. pw request for Resource http://MyDomain/t/jnk.xls, I enter correct pw 
(One time only)

2. pw request for Resource http://MyDomain/t/jnk.xls, I click on "Cancel)
(One time only)

3. "File transferring" message briefly displayed

4. pw request for Resource http://MyDomain/t/jnk.xls, I click on "Cancel)
(One time only)

5. Read only copy of spread sheet opens & is ready to use.
(Note I was only challenged for the pw 3 times instead of 6 as in scenario
1)

Why all the additional prompts when it didn't "care" if I gave it or not?

Scenario 3 - Enter P/W on last prompt only:
1. pw request for Resource http://MyDomain/t/jnk.xls, I click on "Cancel"
(One time only)

2.  "File transferring" message briefly displayed — Strange?!!?

3. pw request for Resource http://MyDomain/t/jnk.xls, I click on "Cancel"

4. pw request for Resource t, I enter correct pw
(t is the AuthName in .htaccess)

5. Read only copy of spread sheet opens & is ready to use.
(Note I was only challenged for the pw 3 times instead of 6 as in scenario
1)

Scenario 4 - Never enter pw:
1-3.  Same as scenario 3

4. pw request for Resource t, I click on "Cancel"
(t is the AuthName in .htaccess)

5. Message box: "Microsoft Excel cannot access the file ..."

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by "Mark A. Marcello" <mm...@rhnet.org>.
SOLVED

it was a redirect issue.  Thanks for pointing that out, It never occured to me.

--mark


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by "Mark A. Marcello" <mm...@rhnet.org>.
users@httpd.apache.org writes:
>UseCanonicalName is used when Apache needs to create self-referential URIs,
>and that isn't necessary when you simply access the root, so something else
>is going on here. I'd look for suspicous explicit or implicit redirects in
>your config.
>
>It may also help if you did the trip with telnet, to see where things go
>wront. Start by doing an nslookup on the old host name, then telnet to that
>IP and GET the root and provide a host header with the "old" host name. Be
>sure to note that you're talking to the right server here. If you get the
>content, everything is fine. If you get a redirect response, there's
>something funny going on.


I did the nslookup.  Both the something1.rhnet.org and something2.rhnet.org are the same IP address as dev.instruct.rhnet.org.

I go to telnet to that address and it doesnt let me connect, its OSX 10.2, and  must not be set up for telnet.

Any other places I should look at on the machine to see whats up?  Anything in the DNS entry?

also, if i just type in the ip address, it too brings me to dev.instruct.rhnet.org/index.html, with dev.instruct.rhnet.org/index.html as the URL, not the IP address

--mark



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by Robert Andersson <ro...@profundis.nu>.
Mark A. Marcello
> UseCanonicalName off is still alowing something1.rhnet.org to be
> changed to dev.instruct.rhnet.org

UseCanonicalName is used when Apache needs to create self-referential URIs,
and that isn't necessary when you simply access the root, so something else
is going on here. I'd look for suspicous explicit or implicit redirects in
your config.

It may also help if you did the trip with telnet, to see where things go
wront. Start by doing an nslookup on the old host name, then telnet to that
IP and GET the root and provide a host header with the "old" host name. Be
sure to note that you're talking to the right server here. If you get the
content, everything is fine. If you get a redirect response, there's
something funny going on.

Regards,
Robert Andersson




---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by "Mark A. Marcello" <mm...@rhnet.org>.
users@httpd.apache.org writes:
>Likely, yes. This should not be such a hard thing; I have it working without
>even thinking about it. Could you describe better what you are seeing? Do
>you mean that when you type http://www.testone.com/, you will be redirected
>to http//www.finaldest.com/, or is when you enter something like
>http://www.testone.com/some_dir (without trailing slash) you get redirected?
>And, if you have any funny setup (SSL, rewrite rules, redirects) it is
>useful to know.


My exact use is like this.  We have a bunch of URL's that we are geting rid of, something1.rhnet.org, something2.rhnet.org, ect.....    and then we have our development site dev.instruct.rhnet.org.

We want something1.rhnet.org, something2.rhnet.org and any other ones to go to dev.instruct.rhnet.org/index.html.  This is working.  This is just a simple dns record pointing one URL to a particular
web server.

The second thing that I want to happen, and which is not working is I want the URL to be what they type in.  

For example.

The user types in something1.rhnet.org
	server loads up dev.instruct.rhnet.org/index.html
	I want the URL to be something1.rhnet.org, not dev.instruct.rhnet.org

The reason behind this is I am going to parse the URL the user types in, and with one simple lasso script on the index page, redirect it to the new page, that we decide.  I just dont know why the
UseCanonicalName off is still alowing something1.rhnet.org to be changed to dev.instruct.rhnet.org

--mark


p.s.   If it helps at all, it is also taking on /index.html to the end of dev.instruct.rhnet.org.  So if you type in something1.rhnet.org the actual URL that appears is
dev.instruct.rhnet.org/index.html


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by Robert Andersson <ro...@profundis.nu>.
Mark A. Marcello wrote:
> I figure that was the correct item to change in the config file.  I
> restarded the server, quit the browser,and tried again.  Is there
> just one spot in the config file that I have to change that to off

Likely, yes. This should not be such a hard thing; I have it working without
even thinking about it. Could you describe better what you are seeing? Do
you mean that when you type http://www.testone.com/, you will be redirected
to http//www.finaldest.com/, or is when you enter something like
http://www.testone.com/some_dir (without trailing slash) you get redirected?
And, if you have any funny setup (SSL, rewrite rules, redirects) it is
useful to know.

Regards,
Robert Andersson




---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] UseCanonicalName question

Posted by "Mark A. Marcello" <mm...@rhnet.org>.
users@httpd.apache.org writes:
>That is what UseCanonicalName Off is supposed to do; create self-referential
>URIs using the hostname provided by the client. Are you sure you restarted
>properly and made sure it isn't a caching issue?

I figure that was the correct item to change in the config file.  I restarded the server, quit the browser,and tried again.  Is there just one spot in the config file that I have to change that to
off?

Also, could there be any other options in the httpd.conf file that would be conflicting, and making it still go to the www.finaldest.com instead of www.testone.com or www.testtwo.com?

I'll try actually restarting the machine.

--mark


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org