Tag Info

New answers tagged

0

The Barracuda Web Application Firewall provides a good browser based management/configuration UI which can be setup by most admins which are comfortable setting up IIS or Apache, with just reading their documentation. I know it works with IIS and Apache servers as I've used it with both, and it should work with any server which follows the HTTP/HTTPS ...


1

Here my working config for your case. <VirtualHost *:80> ServerName proxy.example.net ProxyRequests off ProxyPass /some/prefix/ http://backend.example.net/ ProxyPassReverse /some/prefix/ http://backend.example.net/ <Location /some/prefix/> ProxyHTMLEnable On ProxyHTMLExtended On ...


1

The final working configuration is location / { proxy_pass {{ remote_server }}; proxy_set_header Authorization "Basic {{ base64_token }}"; } We shouldn't pass neither $host (we want our middleware to be host) nor $scheme (I don't use SSL on the middleware, while upstream uses).


1

My first thought would be to use a map. map $arg_param $cache_valid_404 { "" 2d; 1 15m; } Then you set: proxy_cache_valid 404 $cache_valid_404;


0

1) Did you try to clear the cookies in the browser when using SBP? SBP cookies are encrypted and HMACed. If you have cookies from a session before you start using SBP, these cookies are not valid for the SBP module. If a cookie is invalid, it is sent to the application server without modification. The application server should log out the session and start a ...


1

I found this by chance - because Serverfault showed to me all the reverse proxy questions in the sidebar: http://serverfault.com/a/142961/129177 The solution seems to be: ProxyPass /site http://10.1.1.8/backend retry=0 ProxyPassReverse /site http://10.1.1.8/backend


1

You can use seperate Location containers for the images. I am not testing this but this should be more or less it. For /c: <Location /c/images_v3> ProxyPass http://1.1.1.3/images_v3 ProxyPassReverse http://1.1.1.3/images_v3 </Location> <Location /c> ProxyPass ...


0

The [NE] flag in your rewrite rule is setting it to No Escape. Try changing it to [B] to escape back references.


0

< bot >convert self-answerer question to CW< /bot > I was finally able to get it working thanks to Pothi. Here is my final config nginx.conf: server { listen 80; server_name _; proxy_set_header Authorization ""; #$http_authorization; proxy_pass_header Authorization; auth_basic "Restricted"; ...


1

In some website, if you switch from HTTP to HTTPS version, you should inform the the website configuration like 'Hey, we are served through HTTPS now'. Well, the reason is some website has hard-coded configuration to their static file URL generator. So, even they are served through HTTPS, the static-resources-URL generator still thinks that we are talking ...


0

If example1 and username1 are not dependent, this is impossible, nginx will not guess it! Here a piece of configuration I often use to link sub domains to different roots: server { listen 80; server_name ~^(?P<my_root>[^\.]+)\.dev\.ebuildy\.com; root /home/dev/$my_root/app/www; error_log /var/log/nginx/dev-$my_root.log; ...


3

To start, I would set up Nginx as a reverse proxy to the third-party server. You can read about how that works here: http://nginx.com/resources/admin-guide/reverse-proxy/, an example setup might look like: server { listen 80; server_name example-proxy-domain.com; location /some/path/ { proxy_pass ...


-2

i use apache 2.4.9 and adding to the httpd-ssl.conf the following code SSLProxyProtocol +SSLv3 +TLSv1 +TLSv1.1 i have solved the problems


0

You want to use the default_server directive. What this does is set a default server to handle the incoming request for a given port. Example listen 80 default_server; would make that particular "server" block the default server for port 80. server { server_name ""; listen 80 default_server; location / { proxy_pass ...


1

Fixed Apache directive. Wrong directive: RequestHeader set X_FORWARDED_PROTO 'https' Correct directive: RequestHeader set X-FORWARDED-PROTO 'https' I originally took it from the http://www.redmine.org/projects/redmine/wiki/FAQ#Why-does-Redmine-use-http-links-when-I-want-it-to-use-https-links-in-Apache-SSL and then copied in my Apache config file. I ...


1

Right now any and all requests are going to hit this server block: server { listen 80 default_server; listen [::]:80 default_server ipv6only=on; server_name _; # This doesn't do anything rewrite ^ $scheme://www.example.com$request_uri permanent; # Rest of file irrelevant } Because: no server block has a valid server_name ...


0

My bad, I didnt test it as I should. It's working well right now with: ssh -N -f -R 9000:localhost:80 root@server Then on any machine when I try to access on the browser to http://server:9000 it shows the content stored on my local machine. I guess I dont need a reverse proxy for that.


3

You don't need rewrite for this. server { ... location ^~ /api/ { proxy_pass http://localhost:7379/; } location ^~ /api/mypath/ { proxy_pass http://localhost:3936/v1/; } }


1

OK figured it out, I thought the "not found" error was coming from nginx, but actually it was coming from my API. This is my solution if anyone is interested: server { listen 80; server_name localhost; server_name 192.168.3.90; server_name 127.0.0.1; location / { root /home/me/src/phoenix/ui; index index.html; } # automatically go to ...


0

apache proxypassreverse ServerName not working I gave up on this method as it doesn't work as it should. Simply manually substituting URL pieces works just fine as shown in this post. <Location /9999pcap/> ProxyPass http://localhost:22003/ ProxyPassReverse http://localhost:22003/ Substitute s>href='/>href='/9999pcap/> ...


0

You could take a stab at reverse rewriting the output but it is much, much easier to let the back-end app think it lives in /public as you will be playing wack a mole with content rewrites for your forseeable future if you go the rewrite path.


0

Unless I am missing something from your description, you are basically just describing using virtual hosts. In that case, I would probably set up segments such as the following (I've included a sensible SSL configuration as you've mentioned your current setup is running on port 443) <VirtualHost _default_:443> ServerAlias my.domain1.com ...


1

Your proxy_pass directives should all have trailing slashes, for example, from your default configuration (amended); server { listen 80 default; server_name _; server_name_in_redirect off; server_tokens off; access_log /var/log/nginx/default.access.log; error_log /var/log/nginx/default.error.log; location / { ...


1

After a lot of research I found the solution. In "inner" nginx configuration: http { ... map $http_x_forwarded_proto $context { https on; default off; } ... server { ... location ~ \.php$ { ... fastcgi_param HTTPS $context; ... } } } References: this hint on the nginx mailing ...


0

I use the following nginx config code: # make cookie secure (case sensitive) proxy_cookie_domain ~(?P<secure_domain>([-0-9a-z]+\.)?[-0-9a-z]+\.[a-z]+)$ "$secure_domain; secure"; Instead of the regex to make this dynamical you can of course use the FQDN.



Top 50 recent answers are included