logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: proxy server and virtual hosts
Author
turncol



Joined: 17 Sep 2007
Posts: 6

PostPosted: Thu 01 Nov '07 17:58    Post subject: proxy server and virtual hosts Reply with quote

Hi All,

Another Apache Beginner here!!

I am putting together an Apache proxy server to test updating a windows application via a proxy that require authentication. I would like 3 proxy servers on one machine if possible
1) Basic Auth
2) Digest Auth
3) No authentication

I am trying to do this using virtual hosts and currently have the code shown below, these all work individually however when I put all three together, I'm always being asked for the basic credentials. Any ideas how I can solve this?

<VirtualHost *:80>
DocumentRoot "c:/basic"
ServerName basic.s210er2.210er2
ProxyRequests On
ProxyVia On

<Proxy *>
AuthType Basic
AuthName "basic"
AuthUserFile c:/basic/basic
Require valid-user
</Proxy>
</VirtualHost>

<VirtualHost *:80>
DocumentRoot "c:/digest"
ServerName digest.s210er2.210er2
ProxyRequests On
ProxyVia On

<Proxy *>
AuthType Digest
AuthName "s210"
AuthDigestDomain *
AuthDigestFile c:/digest/digest
Require valid-user
</Proxy>
</VirtualHost>

<VirtualHost *:80>
DocumentRoot "c:/proxy"
ServerName proxy.s210er2.210er2
ProxyRequests On
ProxyVia On

<Proxy *>
Order deny,allow
Allow from all
</Proxy>
</VirtualHost>

Thanks in advance!!
C
Back to top
turncol



Joined: 17 Sep 2007
Posts: 6

PostPosted: Thu 01 Nov '07 18:58    Post subject: Reply with quote

Problem solved, I've used different ports for each of the proxy servers:

1) 80
2)8080
3)8008

Unless any one has any better ideas?

Cheers
C
Back to top
KuraKai



Joined: 09 Nov 2007
Posts: 12

PostPosted: Fri 09 Nov '07 23:36    Post subject: Reply with quote

Yay I find the answer to my question right here, anyways I have a question for anyone related to this subject. What is the difference in the authentication and how do i create the files for them?
Back to top
turncol



Joined: 17 Sep 2007
Posts: 6

PostPosted: Sat 10 Nov '07 19:36    Post subject: Reply with quote

Hi,

The main difference in authentication methods is:

Basic - User Name and Password send in plain text (i.e. Unencrypted)
Digest - the credentials are encrypted went sent.

For details on how to set up Authentication the Apache documentation is a good place to start: http://httpd.apache.org/docs/2.0/howto/auth.html
Back to top
KuraKai



Joined: 09 Nov 2007
Posts: 12

PostPosted: Sun 11 Nov '07 4:53    Post subject: Reply with quote

Thank you! Also do all virtual hosts have to run on different ports? Or is it with just Proxys? I haven't tried it yet but I don't want to mess with it yet.
Back to top
turncol



Joined: 17 Sep 2007
Posts: 6

PostPosted: Sun 11 Nov '07 15:17    Post subject: Reply with quote

Normal Virtual hosts can have the same port, but for some reason it was the only way I could get the proxy servers to work using virtual hosts!
Back to top
KuraKai



Joined: 09 Nov 2007
Posts: 12

PostPosted: Sun 11 Nov '07 18:58    Post subject: Reply with quote

Thank you so much for you help!
Back to top


Reply to topic   Topic: proxy server and virtual hosts View previous topic :: View next topic
Post new topic   Forum Index -> Apache