URL rewriting module for Apache web servers

learn more… | top users | synonyms (1)

0
votes
0answers
132 views

URL Obfuscation: How to securely hide backend urls with nginx or apache?

Simply put: How can I obfuscate a url? Much like whats in this post but I need to have security also in mind. Lets say I have a url endpoint: ...
0
votes
0answers
45 views

.htpasswd allow one URL with RewriteEngine = on

I'm trying to get exception from auth (.htpasswd ) for one specific URL, but seems, that it does not work with my Rewriting rules. Disabling RewriteEngine solving auth problem. My .htaccess: SetEnv ...
0
votes
0answers
57 views

I got “Request exceeded the limit of 10 internal redirects”?

I have a rewrite RewriteEngine on RewriteBase / RewriteCond %{HTTP_HOST} ^(.*).club.domain.net$ RewriteRule ^(.*) %{HTTP_HOST}$1 [C] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond ...
0
votes
0answers
17 views

How should I configure my mod_rewrite rule for use in subdirectory?

I have a simple PHP site that uses the following .htaccess: RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^([^/]+)/([^/]+)/? ...
0
votes
0answers
77 views

WORKING URL with capital letters to lowercase rule for mod_rewrite

I tried both (mod_rewrite) rules from http://www.askapache.com/htaccess/rewrite-uppercase-lowercase.html But they ain't working. http://www.example.com/de/Accessoire -> 404, it doesn't rewrite to ...
0
votes
0answers
82 views

Mod-Rewrite - going from plain url to one with special characters

I am having a little issue with FreeBSD 10 RELEASE and Mod_Rewrite when it comes to special characters -- not in the source URL, but in the destination URL. The vast majority of Mod_Rewrites that I ...
0
votes
0answers
66 views

Dynamic vhosts www alias — symlink vs mod_rewrite

MI have hundreds of domains, each of them added dynamically. Now I want each domain to have www.* alias, as far as I know there are two ways to achieve this: 1) Using symlinks www.domain.com → ...
0
votes
0answers
91 views

Apache error log not showing full path of 404 failures

If I have a working path like /gallery/landscapes and I try to access this inexistent url: /gallery/landscapes/whatever I see the 404 error in my browser but the apache log says that I had an ...
0
votes
0answers
85 views

How to exclude a URL from mod-rewrite with nginx?

I'm moving my Joomla! 2.5 from Apache Ubuntu to Debian nginx and I need to exclude some URLs from the mod-rewrite. Now I'm rewrite all within this directive on the IspConfig panel: # mod_rewrite url ...
0
votes
0answers
118 views

redirection in Apache include current ServerPort

For long time I am using Apache instalation which doing automated redirect with mod_rewrite (mainly root redirected to specific app and from HTTP to HTTPS but also other). There are could be severeal ...
0
votes
0answers
39 views

Making changes in Loglevel httpd.conf of apache server?

I am working on windows-7 Visual studio 2008,According to Apache: Configure "LogLevel debug" for certain modules only? i am making changes in the loglevel of configuration file I am giving ...
0
votes
0answers
111 views

Conditional reverse proxy in apache

I'm using Apache 2.2.25 as a reverse proxy for two diferent servers, using two diferent URLs. So basically the URL http://www.mydomain.com/path1 will be reversed-proxied to server1 (weblogic) ...
0
votes
0answers
48 views

Third level domain and redirect

I have a domain like mydomain.com I have bought blog.mydomain.com I want that when people hit blog.mydomain.com, they get redirected to mydomain.com/blog. What I am trying is the following ...
0
votes
0answers
204 views

Rewrite URL and keep POST data

We recently setup SVN for our web development. We'd like to be able to browse different branches/tags/trunk based on the URL you input on our dev server. So, for example, ...
0
votes
0answers
165 views

access restriction using http_referer in nginx

access restriction in nginx URL: http://test.example.com/pentaho/reporting/reportviewer/report.html?solution=steel-wheels........... I will call the above URL from ...
0
votes
0answers
40 views

How can I make this SSL rewrite work?

We have two domains. Both have valid SSL certs. But we are moving towards a more "unified" domain scheme. For example, our domains are like: https://apps.example.com/webapp1 ...
0
votes
0answers
48 views

Apache Rewrite Rule that Updates Query String Case

I have been looking far and wide for help with this but am not able to get a Query String-based rewrite to work. I want saas.site.com/shop-accesories.html to redirect to ...
0
votes
0answers
25 views

htaccess go up a folder, above web root

I've been looking around on the internet, but i couldn't find a good answer to this question. Since i'm very new to htaccess, i would like to know how you would solve this problem. On my site, a user ...
0
votes
0answers
59 views

How do you exlcude a sub-directory from an Apache rewrite ruleset?

I have a multilingual site with the root being English and a sub-directory (/es/) being a human translation into Spanish. Instead of manually updating all URLs, I have a opted to use mod_rewrite to ...
0
votes
0answers
31 views

RewriteMap in Apache configuration

I have a question about implementing RewriteMap in doing a large number of rewrites. There are many static landing pages with a url path along the lines of ...
0
votes
0answers
18 views

Apache mod_rewrite no further rules after proxy

I have this config RewriteCond %{HTTP_HOST} ^([^.]+)\.domain.com RewriteRule ([a-zA-Z0-9]+)/([a-zA-Z0-9]+) http://%1.$2.domain.com/$1 [P,L] which should show me the content of ...
0
votes
0answers
50 views

Mod_Rewrite : Rules exist + work, but apache still calling stat + lstat before processing rule?

We have a strange issue... Perhaps this is how apache is designed, but I would think not: Even tho we have a rule that works 100%, when we do a strace on our apache processes, it appears that apache ...
0
votes
0answers
45 views

unidentified redirect based on the referer

My client has a problem with a redirect. When there's an external link pointing to his website, this link gets redirected by the server back to the referer. $ curl -i -H "Referer: ...
0
votes
0answers
30 views

Redirecting apache2 www/non-www domains to one webpage vhosts

<VirtualHost *:80> DocumentRoot /var/www ServerName kittest.pl ServerAlias www.kittest.pl www.kit-test.net kit-test.net kit-test.pl www.kit-test.pl <Directory "/var/www"> ...
0
votes
0answers
428 views

How to add a custom header despite a RewriteRule redirecting to 304?

I have an apache2 server set up to return 304 responses when appropriate. I implemented it with a rewrite rule, like so: <VirtualHost *:9290> (...) Header set Last-Modified "Tue, 01 Jan ...
0
votes
0answers
17 views

mod_rewrite more than one variable

I'm trying to mod rewrite my url into smth more friendly, but I'm experiencing problems with multiple variables.. i'd like to have my urls like www.gogostyle.it/tenda/boucle-ricamata (var design) ...
0
votes
0answers
133 views

Is there a way to get a password from HTTP authorization header in mod_rewrite (apache2)

I'd like to parse HTTP authorization header in mod_rewrite - to be able to use login and password for another redirect. I want to achieve something like this: user puts ...
0
votes
0answers
38 views

Script working from test to production server

I am running the following script: http://phprestsql.sourceforge.net/ My test environment is a WAMP server running Apache 2.2.17 and PHP 5.3.4 My production server is running Apache 2.2.14 and PHP ...
0
votes
0answers
21 views

mod_rewrite config works for any language except Chinese

Currently, I have this configuration in mod_rewrite in apache: RewriteCond %{REQUEST_URI} !-f RewriteCond %{REQUEST_URI} !-d RewriteRule ^([a-zA-Z]{2,3})/?$ /index.html?wtsLang=$1 [L] RewriteRule ...
0
votes
0answers
103 views

problems mod_rewrite for a root document

I thought I had a minimum of understanding about how mod_rewrite works but, it's like sendmail, I'm always a step beyond (or even further!) :-( I have summarized what I want to do in the following ...
0
votes
0answers
180 views

mod_rewrite in .htaccess w/ wildcard virtual hosts - preserving subdomain while funneling requests through index.php

I have a project which utilizes wildcard subdomains to allow requests for www.foo.com, api.foo.com, & admin.foo.com to utilize the same document root. Routing for this project is based initially ...
0
votes
0answers
189 views

How to redirect public URL request to private internal URL?

I've got a staging environment in my local network, all websites or apps are accessed by prefixing the final domain, this happens because we've got a DNS resolver running locally. For example, ...
0
votes
0answers
474 views

Apache 2.2 Proxy pass 503 errors - redirect/rewrite/proxy local path to another URL

I've been struggling with this for a while, but please forgive my ignorance, I'm fairly new to Apache 2.2 configuration.... Basically I am trying to somehow get a local path to forward/rewrite/proxy ...
0
votes
0answers
66 views

mod_rewrite issue | Request exceeded the limit of 10 internal redirects

ok what Im doing normally works but since my rule "includes" itself is giving me issues and can't find a solution after hours working on different options. I have a .htaccess with: RewriteEngine On ...
0
votes
0answers
356 views

Pages load in brower fine, but 404 not found reported for the page during the GET on all pages except index

I believe this question is more suited to serverfault (please correct me if not). Even though pages do load the fact 404s are returned without a browser prevents other services (google adwords and ...
0
votes
0answers
66 views

Removing index.php redirects to file path

I have this code to redirect index.php to root domain: #RewriteCond %{QUERY_STRING} ^$ #RewriteRule ^index\.php?$ http:/www.domain.com/ [R=301,L] It works on my shared host however it doesn't work ...
0
votes
0answers
244 views

Password protect all requests except a certain directory

All requests on my domain go through a central PHP file (CMS) and I want to add a simple htaccess password to the site to all requests except those that match a certain sub directory. WOULD NOT ASK ...
0
votes
0answers
84 views

How can I get apache to stop logging header errors?

I may have this set up in a weird/bad way, but the idea I'm going for is to take wildcard subdomains and seamlessly convert them to a different URL behind the scenes that my app understands. My ...
0
votes
0answers
106 views

RewriteMap and RewriteRule troubleshooting on Apache2

First off, I'm trying to get the following rule working: RewriteMap legacyredirect txt:/var/www/path/to/legacyredirect.txt RewriteRule ...
0
votes
0answers
768 views

Apply SetEnvIf after Apache RewriteRule

I have a working apache rewrite rule: RewriteCond %{HTTP_HOST} ^.*foo.com RewriteRule (.*) http://bar.com$1 [R=301,QSA,L] and some working dontlog SetEnvIfs: SetEnvIf Host "allrecallsapp.com" ...
0
votes
0answers
486 views

Ubuntu Apache2.2.20 - Mod Rewrite - pass through

I am trying to test a simple rewrite on my local apache server (ubuntu 11.10 Desktop) Here is the virtual directory settings: <VirtualHost magic.al:83> ServerAdmin webmaster@localhost ...
0
votes
0answers
683 views

CentOS 6.2 and mod_rewrite - WP migration & permalinks

I recently migrated my WP site to a VirtualBox CentOS 6.2, using an IP address as the hostname (192.168.56.101 goes to my home page). I've edited the httpd.conf file of the DocumentRoot directory: ...
0
votes
0answers
57 views

apache rewrite_rule for a directory

I've add the following to a <Directory> tag in my /etc/apache2/sites-available/siteName file: RewriteEngine on RewriteOptions Inherit RewriteRule ^blog/ /blog.cfm [R] And I just get a 404, ...
0
votes
0answers
96 views

Old rewrite rule persisting

I have the following .htaccess file ErrorDocument 404 /missing.php Options +FollowSymLinks RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)/$ ...
0
votes
0answers
297 views

How can i test for an environment variable in a RewriteCond

Is there a way to put an environment variable in the condPattern part of a RewriteCond? Here is what i tried: RewriteCond %{REQUEST_URI} /%{ENV:ALIAS}/(js|css|img).* RewriteRule (.*) - [L,NS] But ...
0
votes
0answers
215 views

Virtual Hosts all Messed Up

I'm on OS X 10.6.8. I had two virtual hosts set up on my machine, http://site1.local and http://site2.local. Here's the Virtual Hosts file: <VirtualHost *:80> DocumentRoot ...
0
votes
0answers
233 views

apache mod_rewrite subdomain, domain and url arguments

I am trying to use mod_rewrite to capture a subdomain, domain, and the arguments passed with the url. I have multiple domains pointing to a single ip address, with both @ and * wildcard a-records, so ...
0
votes
0answers
560 views

mod_rewrite not working with serveralias

TL;DR: Apache is not processing urls for server aliases. Details: I am trying to set up a wordpress multisite (a feature of wordpress 3.+ which allows to host multiple blogs at once). The main ...
0
votes
0answers
149 views

How to remove the cgi script name from the URI (apache, mod_rewrite)?

There are a lot of apache / mod_rewrite questions here, and I looked at them but didn't find a duplicate. I have a web site properly running with apache, mod_rewrite and fast cgi. .htaccess: ...
0
votes
0answers
234 views

Automatic subdomains on local dev machine

I have working localhost on my Fedora 15. Directory tree look like this /var/www/html/default /var/www/html/projects /projects/foo /projects/bar /var/www/html/devel ...