Questions tagged [apache]

The Apache HTTP Server is an Open Source Web server, which originated from a series of patches to the NCSA HTTPd. Apache is the world's most popular Web server, which is run on 54.90% of all Web servers according to the Netcraft survey conducted July 2010.

Filter by
Sorted by
Tagged with
6 votes
2 answers
17k views

What is SymLinksIfOwnerMatch?

What is SymLinksIfOwnerMatch in .htaccess, in layman's terms? I have this option active. Do I need it? I have a plain HTML web site (though might go for Joomla one day). Some sites specify that it ...
0 votes
1 answer
12 views

How may I do a redirect where the page it {redirected to} shows the URL it {redirected from} to the user? [closed]

I'm doing some special error pages but because of things, they're one hop away though, meaning all that's left in the address bar is a cleaned up address with a 3-character-long path. I want to, ...
2 votes
1 answer
827 views

Apache Logs: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/69.0.3497.81 Safari/537.36

Amid increasing complaints of excessive resource usage from a shared webhost, a detailed check on the Raw Access Log files reveals repeat instances of the following from various IP addresses: 18.232....
5 votes
4 answers
5k views

Apache - Force https by default on custom port

I am hosting a control panel for web management on a second Apache instance that runs on port 2083. It has port 2082 for the HTTP version of the site because it needed something to run the HTTP ...
3 votes
1 answer
154 views

Flush cached selector in Adobe Experience Manager without flushing entire directory

How can I use selector based cache flushing in Adobe Experience Manager? http://example.com/content/myapp/us/en.child1.xml http://example.com/content/myapp/us/en.child2.xml Lets say,we have xml's ...
15 votes
3 answers
41k views

How can I use robots.txt to disallow subdomain only?

My code base is shared between several environments (live, staging, dev) & sub-domains (staging.example, dev.example, etc.) and only two should be allowed to be crawled (ie. www.example and ...
0 votes
0 answers
17 views

How to proxypass every contexts from public domain to a virtual host domain with Apache?

I have one server and two domains, a public domain 'apple.com' for service, and a private domain 'grape.com' for internal network. I tried to ProxyPass every contexts after apple.com to grape.com. For ...
2 votes
1 answer
61 views

Pagespeed Virtual Host Configuration

I installed pagespeed on CentOS 7 with plesk (apache 2.4). I have 2 vhosts with different SSL certificates on the server. Pagespeed is running server-wide. Filters such as collapse_whitespace and ...
1 vote
1 answer
113 views

Use their own SSL certificate for domains when DNS routing is applied

On my VPS server with cPanel/WHM, I have 2 accounts: domain1 and domain2. Each of these domains are the main domains for their accounts. Meaning that domain1 has other alias domains as well, and ...
2 votes
2 answers
137 views

How to remove the wildcard subdomain on Apache to prevent Google from indexing Subdomains that do not exist

I am experiencing the issue explained at https://stackoverflow.com/questions/53065450/subdomains-that-dont-exist-are-indexed-by-google-zombie-subdomain-removal-via. Notice how the the search engine ...
6 votes
3 answers
2k views

Functional difference between proxypass and proxypassreverse in Apache

The official document states that: The ProxyPass configures the server to fetch the appropriate documents, while the ProxyPassReverse directive rewrites redirects originating at internal.example.com ...
0 votes
0 answers
197 views

How to block unwanted bot in Apache 2.4?

These rules work good in my .htaccess: #https://workinnet.ru/de/wie-man-amazonbot-blockiert/#German language# SetEnvIfNoCase User-Agent "Amazonbot" blocked_bot <Limit GET POST HEAD> ...
2 votes
1 answer
76 views

Identifying virtual hosts on server

Is there some mechanism for remotely determining what virtual hosts are configured on a server? For example, I have a domain, say example.com, and I'm running an Apache server. Let me then create a ...
0 votes
0 answers
26 views

Connection refused when accessing my website with a url and a port number but its fine if accessing it with IP

I have a cpanel apache website. When i try to access it with url and a port number like mysite.com:3000 it returns connection refused but if I access it with ip like 147.100.xx.xxx:3000 it's working ...
0 votes
1 answer
53 views

Apache URL rewrite does not mask subdirectories

The admin setup a subdirectory /sites/default/files/resources and updated the docroot .htaccess to point to this subdirectory so that the domain www.example.com points to it. I do not have access to ...
1 vote
0 answers
31 views

Snipe-IT / Cpanel / WHM auto SSL issue

Maybe some of you have done it and could help me. I use Cpanel and WHM. Basically I installed snipe-it and had to create a custom VirtualHost in WHM via include file. The site is a subdomain.(( # To ...
4 votes
2 answers
3k views

Apache redirect all requests for file type to 404

I have some .inc files that I want blocked from being accessible via web pages. I want to simply redirect them to another page or throw a 404 when those files are accessed. I have tried this so far ...
2 votes
1 answer
187 views

Best practice for suEXEC on complex sites?

What is best practice for using suEXEC on complex sites? We've got a site running under a single vhost, and we want to be able to run different PHP web apps eg /forum /wiki /crm as their own UIDs, to ...
0 votes
0 answers
160 views

How can I test the PHP module in .htaccess

I have installed XAMPP on my Mac for testing and teaching purposes. One thing I need to do is set up some settings, but I can’t guarantee whether PHP will be running as a module, so I can’t guarantee ...
1 vote
1 answer
67 views

Prevent access to parent URL but not its children

On a Debian VPS I run an Apache 2.4.56 web server and I want to prevent any access to a parent URL, for instance https://example.com/participants while allowing access to any of its children, for ...
0 votes
1 answer
36 views

In an apache reverse proxy config, for the max attempts, do balancers count as workers?

Within the ProxyPass directive is a table titled Balancer parameters and it has a row called maxattempts. The default is as follows: One less than the number of workers, or 1 with a single worker. ...
3 votes
3 answers
20k views

NginX redirect to PHP file if image does not exist on file server

This is what I am trying to do. I am not familiar with Nginx enough to create custom rewrite rules like you can with Apache. It would be greatly appreciated if someone could help me with the Nginx ...
1 vote
0 answers
47 views

Apache Server Side Includes Won't Expand Variables in Regular Expressions

I am trying to use an SSI variable in an SSI regular expression like the 3rd line ( I will paste the full test code further down) <!--#set var="referrer" value="https://edcint.co.nz/...
1 vote
0 answers
22 views

Apache Server Side Includes Won't Parse CGI Output [closed]

I am trying to parse the output of a CGI script for SSI code. The simple CGI code is as follows and simply prints one line of SSI code #!/usr/bin/perlml -w use strict; use CGI qw( :standard ); my $q=...
1 vote
1 answer
47 views

Apache2 Only Showing Default Page/Unlimited Redirects

I am using a reverse proxy to show my bitwarden site. Here is the .conf in my sites enabled: <VirtualHost *:80> ServerName bitwarden.example.com Redirect "/" "...
15 votes
4 answers
18k views

Interpretation of empty User-agent

How should I interpret an empty User-agent? I have some custom analytics code and that code has to analyze only human traffic. I have got a working list of User-agents denoting human traffic and bot ...
0 votes
1 answer
138 views

Help with HTACCESS 301 Redirect to different site with URL parameters

I have two websites, elijahstreams.com (OLDSITE) and projectjustcause.com (NEWSITE). I need ID-based URLS to forward from OLDSITE to SEO-friendly URLS on NEWSITE via .htaccess directives. This is what ...
1 vote
2 answers
83 views

HTTPS site on Chrome with paid SSL showing as Dangerous

I built a WordPress STAGING site on projectjustcause.com domain. I have installed and tested paid SSL cert and it worked fine. When I added directives to APACHE 2.4 .htaccess file to forward all http ...
4 votes
2 answers
2k views

Why can't I access an Apache web server on a local network with my phone?

I have a website that needs to work only on my local network, I am hosting it on Apache, I have already done all the steps to make it accessible from any PC and laptop, but for some reasons if I try ...
2 votes
1 answer
52 views

Odd slash added at start of file folder in Apache rewrite

I'm working with an Apache rewrite statement that reads: RewriteRule ^((?!%{HTTP_HOST}).*)$ ${US_ROOTF_WWW}/www.%{HTTP_HOST}%{REQUEST_URI} [L,E=PROJECT_PREPENDED:1] The value of {US_ROOTF_WWW} is C:/...
0 votes
0 answers
126 views

Redirecting old domain to two new domains

The issue at hand is redirecting selected pages from the olddomain to the newdomain1 and newdomain2. Doing one domain is fairly straightforward, but it's different when handling two domains. Any ...
2 votes
1 answer
209 views

Bing site scan: Avoid Error 403 if index.html is missing the root domain name

I have a website with the following domain name: https://example.com (there is no index.html in the root domain name) I have the following redirect based on language detection in .htaccess: https://...
0 votes
0 answers
11 views

How to solve problem of the appearance website IP in Google search results [duplicate]

I published my website on the Internet a year ago, and it has been working normally since then and Google indexed it, but I had an error in my server and Some SSL certificate files were deleted by ...
0 votes
1 answer
37 views

301 Redirect a domain to new domain and add extra subdirectory to the existing path

i want to redirect my old domain to new domain x.com - y.com and also, my old domain x.com currently doesn't have sub directory in url ex: x.com/news-today for my new domain y.com having sub ...
1 vote
1 answer
267 views

htaccess redirect with negated conditions

Simple redirect in .htaccess works: #Redirect 302 / https://domain.toberedirected.com But the conditional one doesn't. I want that if the remote user IP address is in the list then ignore the ...
2 votes
1 answer
3k views

How can I make a specific series of URLS have "410" Gone status?

Server was hacked and my .htaccess file was changed to wildcard redirect (spam). I am seeing a lot of requests like those below even after I've cleaned up my server: example.com/cobwebbing-...
0 votes
0 answers
13 views

My Apache is logging even an IPV6 Address as an IPV4 address. How to fix this? [duplicate]

My phone has an IPV6 address. When I hit my apache server, I see an IPV4 address being logged there. I did that with multiple IPV6 address devices and same thing happened. Kindly help what I can do.
1 vote
0 answers
139 views

Installing PHP extensions in Plesk Obsidian - idiots guide required

I'm trying to upload files from my server to an another server via SFTP. I'm running Plesk Obsidian 18.0.31 Update #3 - ‪CentOS 6.10 (Final)‬ From what I understand I need to install some extensions ...
2 votes
2 answers
5k views

Can I redirect a subdomain to an IP address with a port? [duplicate]

I've got two addresses: ipaddress and ipaddress:100. The first one uses the default port of 80, but the second server (running GitLab) uses port 100. I have multiple IP addresses, but I am wondering ...
1 vote
0 answers
22 views

Block specific C range of IP addresses [duplicate]

I can't find a good reference though my understanding is that ranges in an IPv4 address are: a.b.c.d I wish to block only the C ranges starting with 51.15.51.0 and ending with 51.15.142.255. I have ...
2 votes
1 answer
94 views

I got a Google indexing warning because I am using HTTP forwarding

Today I received a mail from Google. There is a problem with indexing my website because I am using HTTP forwarding. I disabled HTTP a week ago now only allowing HTTPS. I am using this code in my ...
2 votes
1 answer
53 views

Change server structure to be able to view files/folders in browser (Dedictaed server)

I'm trying to deploy Wordpress on a red hat Linux server (dedicated server). I'm trying to access it using the normal URL structure [IP]/[rootfoldername]/[nameofthefile] but it's not working. Note ...
1 vote
0 answers
87 views

I need some help modifying a url going through an apache Reverse Proxy [closed]

I inherited this system from my retired coworker who inherited it from the person who set it up, so my knowledge of reverse proxies is pretty bad. Here is the situation... We are upgrading a system ...
2 votes
1 answer
81 views

Redirect 301 a URL already created by a rewrite rule in .htaccess

I'm creating SEO friendly URLs with rewrites in .htaccess. Now I need to redirect (301) a couple of these rewrites, and have no idea how to do that. These lines: Options +FollowSymLinks RewriteEngine ...
1 vote
0 answers
14 views

Is RewriteMod for WordPress site: site.ro -> site.com/?lang=ro possible?

I'm not much of a WordPress specialist - is it possible to redirect new domain to the same site, but with ?lang=ro query parameter so it shows the old site with selected language? Result I want: site....
1 vote
1 answer
78 views

Pointing domain to my IP an port [duplicate]

I have a server with ip 55.335.32.56:4000 but want to use my domain user.example.com I am trying to do this with apache via httpd:vhost.conf Listen 4000 <VirtualHost 55.335.32.56:4000> ...
7 votes
2 answers
3k views

Mysterious ico files appearing on webserver

Files are unexpectedly appearing on one of my shared web servers. They can appear in pretty much hundreds of directories and they are always called something like favicon_1166f9.ico. The first 6 ...
1 vote
0 answers
308 views

Plesk Obsidian (18.0.48) - 413 Request Entity Too Large (nginx)

Hello recently I set up a server using Ubuntu 22.04.1 LTS and Plesk Obsidian 18.0.48. However I encountered a problem when uploading files around 1GB of size. The website I am running is a docker-...
9 votes
2 answers
38k views

How can I use .htaccess to respond with 403 forbidden status for URLs that contain a query string?

Some bots have been crawling my site for every link that ends with: ?utm_source=dlvr.it&utm_medium=twitter I haven't checked out its IP. Then other bots (10+) follow the link rules ?utm_source=...
2 votes
0 answers
98 views

While setting up http to https redirect on Apache (with Drupal and certbot) it broke http access and fails to redirect

I am trying to set up a Drupal site on a VPS. It was working. I used certbot to set up https, which worked when going to https://example.com . Going to example.com was in http. I vaguely followed ...

1
2 3 4 5
24