How to setup Useresponse behind a HTTPS proxy

Completed Guest 10 years ago

Is there a way to set up Useresponse correctly through a reverse https-to-http proxy?

Eg: http://piwik.org/faq/how-to-install/faq_98/

We seem to be getting _almost_ there, but when we set up the site with https in $config['resources']['frontController']['baseUrl'] - the front page is shown correctly, but we're not able to log in or use any functionality. When we set up the site with http, the functionality works, but the CSS and Javascript are pointing to the wrong URL.

We're using Apache mod_proxy/ProxyPass both on the front https server and on the server behind hosting Useresponse.

Is there a way to tell Useresponse to respect the X-Forwarded-For Headers, like Piwik does it? http://en.wikipedia.org/wiki/X-Forwarded-For

Best Answer
photo

We've made allowing proxy in self-hosted version. You just need to add following parameter in your config if you use 3.1.1 release:


  1. followProxy = true

This is the example how should it be added to the config:


  1. 'frontController' => array(
  2. 'baseUrl' => 'http://useresponse/',
  3. 'followProxy' => true,
  4. 'plugins' => array(

Replies (5)

photo
1

Solbjørg,

So, what the void of the problem at all?

Please, describe us what UseResponse must confirm or accept and what should it do with passed data?

In other words, what implementation you want to do using X-Forwarded-For?

photo
1

This is the problem: Our proxy server accepts a request to useresponse at https://ourdomain.com/useresponse. It then makes a proxy request to a server where useresponse is actually installed at http://ourlocaldomain.com:8080/useresponse including X-Forwareded-For with the value https://ourdomain.com/useresponse

However, Useresponse doesn't use this value to serve script and css stylesheets. Useresponse ALWAYS uses $config['resources']['frontController']['baseUrl']. As I explained in my previous post, with Piwik for instance, there is a config setting to tell the system to use X-Forwarded-For INSTEAD of $config['resources']['frontController']['baseUrl']. That would solve the problem in our case as well I think.


I've noticed that Useresponse is using Zend Framework, and this might be a solution

http://www.dasprids.de/blog/2013/10/11/zend-framework-2-routing-and-reverse-proxies

but I haven't tested it. What do you think?

photo
1

Solbjørg,

Now it's clear for me.

Currently UseResponse does not provide this capability. We have put this feature in our roadmap up to the stable 3.* release.

photo
1

We've made allowing proxy in self-hosted version. You just need to add following parameter in your config if you use 3.1.1 release:


  1. followProxy = true

This is the example how should it be added to the config:


  1. 'frontController' => array(
  2. 'baseUrl' => 'http://useresponse/',
  3. 'followProxy' => true,
  4. 'plugins' => array(

photo
1

Hello.

How should I configure nginx as a proxy for cloud useresponse?

Now I have created location


  1. location /help/ {
  2. proxy_pass http://uzap.useresponse.com/;
  3. proxy_set_header Host $host;
  4. proxy_set_header X-Real-IP $remote_addr;
  5. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  6. proxy_set_header X-Forwarded-Proto $scheme;
  7. }

but getting useresponse.com/404 response

photo
1

Hello Enver,

If you are using Cloud version, please use following instructions https://help.useresponse.com/knowledge-base/article/using-a-custom-domain-for-your-support-center

You don't need to do anything in the settings of your Web server.

photo
1

Thx for quick reply.

But in this case I'll get it on subdomain but I would like to have it located at my domanin URI (https://uzap.com.ua/help)

photo
1

I doubt that it's possible to locate it in the folder. For cloud users, you can create subdomain like http://help.uzap.com.ua and add cname record to DNS. More details could be found here.


Only self-hosted version could be installed in the folder of domain.

photo
Leave a Comment
 
Attach a file