Forum Moderators: phranque
Anyway, my question is, is adding more scripts the merrier or if you add too many different scripts that sort of perform the same function (ie/ blocking bad robots), it'll cause it not to work?
I've also been thinking of adding [another] script [to block proxy servers,] but have no idea what proxy servers are. Is it malicious?
[edited by: jdMorgan at 11:11 pm (utc) on July 21, 2008]
[edit reason] No URLs, please. See Terms of Service. [/edit]
Welcome to WebmasterWorld!
Please review our terms of service and the Charter of any forum you may wish to post in -- Our posting policies are a bit different here at WebmasterWorld.
As for adding "scripts," you will be well advised to not add any code unless you fully understand it, and how it might interact with your site and other directives already present. Copy-and-paste is pretty much a recipe for disaster. Always remember that this code affects your server configuration; Getting it 100% right is not optional.
Do not think of .htaccess as a "script," though. One pitfall that many Webmasters encounter is, in large part, due to thinking of .htaccess code as a sequentially-executed script.
It is not: The .htaccess file is sequentially "scanned" by each loaded Apache module in turn, and each module executes only the directives that it recognizes and knows how to handle. The order in which the modules scan the file is determined by the reverse order of the LoadModule list in the main Apache server configuration file on Apache 1.x, and by an internal priority-resolution scheme in Apache 2.x.
So while all directives handled by a given module will be executed sequentially, mixing in directives handled by other modules does not make them execute in directive order -- Everything is executed in module order. Therefore, to the extent possible, dependencies on module execution order should be avoided in order to maintain maximum code portability between servers.
Now, to answer your question: A proxy server is what it sounds like -- A server that can be used as a "proxy" --a "stand-in" or a "go-between"-- by another computer. In less general terms, it might be a server that an internet user connects through. A couple of uses are to allow some degree of anonymity -- a user can send all his requests to a Web site through a proxy, and the proxy will pass the responses from the Web site on the other end back to the user. The Web site sees the request coming from the proxy, and sends its responses to the proxy; As far as the Web site is concerned the proxy *is* the user. But the user has only revealed his true IP address to the proxy.
See the possibilities here? A person (good or bad) can use a proxy to anonymously access Web sites. A person in a politically-restricted country can use a proxy to access otherwise-restricted Web sites. A bad proxy administrator might collect information on the proxy's users and use that information in a dishonest way.
Another main function of proxies is in network traffic reduction, a la AOL and EarthLink. All of their customers access the Web through caching proxies. Many large corporations use caching proxies as well.
These proxies cache Web pages, according (usually) to the cache-control headers specified by Webmasters. So, for example, if AOL user "Bob" accesses this page on WebmasterWorld, and another AOL user "Ted" then requests the exact same page a few seconds later, only Bob's page request will be sent out of the AOL network to the WebmasterWorld server. Ted's page request for the same page will be served by the caching proxy, using the cached copy of the page that Bob just got.
Again, this (normally) only happens if the WebmasterWorld server sends a Cache-control header that tells the AOL proxy whether and how the page may be cached. In this way, traffic into and out of AOL's network is significantly reduced, and the load on popular sites caused by these popular ISPs' users is dramatically reduced.
I have not covered everything-all-about-proxies here: This is just a sample of some of the things you can do by passing requests through a middleman computer between the client and the server. These are called "forward" proxies. There are also "reverse proxies" -- commonly used by a server to send some of its "workload" to another server sitting "behind it." For example, this setup is often used to split the work of serving Web pages and doing database lookups to construct those Web pages. In this scenario, the database server is called the "back-end server," and requests to it may be proxied through the Web server on the "front end."
One thing should be clear by now, though -- a proxy is not good or bad -- It is essentially just an additional computer in the the network path between a client and a server. In order to determine if a request from a proxy is good or bad, you have to know and specify something about how that proxy is being used by people, and how the proxy is intended and configured to be used by people.
Jim