2

I work with application which comunicate with server over HTTP, but this server runs on HTTPS in my case and there is also basic authentication. There is no way to change this settings.

My idea is configure proxy on Apache server and then website wil be accessible at http://localhost/ and apache will be something like intermediator. I don't want redirect, rather something like mapping.

I tried configuration like below but it didn't work.

<VirtualHost *:80>
  ServerName foo.com
  SSLProxyEngine On
  ProxyPass / https://login:passwd@secured.web.com
  ProxyPassReverse / https://login:passwd@secured.web.com
</VirtualHost>

I will be glad for every idea.

1 Answers1

0

A quick search reveals that something like this:

https://superuser.com/questions/704781/apache-mod-proxy-with-automatic-authentication

Should allow you to perform the authentication and add it into the header.

Community
  • 1
  • 1
Welsh
  • 5,138
  • 3
  • 29
  • 43
  • Authentication probably works now. Thanks for that. But now I got error 'This webpage has a redirect loop (ERR_TOO_MANY_REDIRECTS)'. When I remove ProxyPassReverse line, error disappeared but I am redirected instead mapping. – Jan Slováček May 20 '15 at 08:57
  • It was probably some cached configuration. After cleaning everything works good. Thanks. – Jan Slováček May 20 '15 at 10:30