Forum Moderators: phranque
The source computer is at the same IP at "office-gw.centreweb.com" just in case anybody else is seeing this behavior recently.
I have just written a short disconnected notice and am redirecting the IP to it, successfully. Does anybody know of a method I can use to actually disconnect this computer from my website, rather than redirecting them to the notice?
This is probably a student or office worker who inadvertantly left their browser open on my webpage. I don't really want to ban him/her, but don't know what else to do. Is there a way I establish a timeout for any connection, so that future excessive connections, say 24 continuous hours, can be automatically terminated?
My OSs: Apache and Linux on a Raq4.
Thnx, Wiz
[edited by: DaveAtIFG at 7:53 pm (utc) on Oct. 19, 2003]
[edit reason] Started new thread, deleted "May be OT" comment [/edit]
This thread points out a distinction that needs to be made in order to understand the problem: In an HTTP sense, a "connection" starts with a user-agent request, and ends with the server response. The server has no knowledge that a "session" is active - you can add a layer of code above the server to track sessions, but the server itself does not maintain information from one request/response to the next.
What this means is that each request for an html page, an image, a script, or CSS file, etc., exists on its own - You can often see the different users' browsers will load page elements in a different order, which hints at the behaviour.
So, this user is "connected" only because the page his browser has rendered contains a script, and that script issues a page reload every 60 seconds. But this reload is a new "connection" and the server won't know that it is related to the previous page load. The page, once reloaded, will call for new banners, and each of those is a new and separate request as well.
As far as solutions, you have two avenues open: server-side and client-side. On the server side, you can use various techniques to track sessions and redirect the user to a static page after a fixed time, just as one example. This could involve a session ID, a tracking cookie, and for the simplest cases, tracking the user by IP number - although this last won't work with many ISPs which use proxy caches and may assign a different IP to each user request - A recent post about AOL users' IP addresses described this.
Client-side, you can modify the script to stop rotating and/or reloading after 10 minutes or so. I think that would be the easiest way to do it, myself.
Jim
I will modify the banner script as suggested. I am already redirecting this client to a special page consisting of only 240 bytes (at this moment). At least this won't break the bandwidth bank as fast as whole page reloads. I sent a message to their hosting supplier, but haven't received any reply yet. I am also looking into getting a temporary IP block at my host's server level, and will find out about that later today. I hope that eventually somebody closes that browser and lets my server idle for a while.
Wiz
I based that assumption on this statement, interpreting it to mean that the entire page was reloaded. If the banner script is in an external .js file, however, it will be cached, and what you say will be true.
> sucking up my bandwidth by reloading ad banners and html code on a one minute basis.
Nasty problem, this one... :(
Jim
RewriteCond %{REMOTE_ADDR} ^12\.XXX\.22\.235$
RewriteRule .* http://12.XXX.22.235 [L]
Can anybody show me the syntax to include 301 permanent in the [L] switch? I think it goes [L=301] but I'm not sure and don't want to cause server errors with a bad command.
I'm trying things to fool the browser into thinking the scripts have moved permanently elsewhere. I even tried redirecting him/it to a phoney set of pages and scripts, hoping that the new scripts would overwrite the old ones, to no avail. Also, the webmaster at their hosting company did not respond to my requests for assistance with this. This all revolves around www.centreweb.com and a host calling itself "Centre Of The Web." The computer that is harrassing me is pinned to "office-gw.centreweb.com" with an IP of 12.XXX.22.235, both of which give a generic page not found when queried with my browser.
Any other suggestions would be welcomed.
Wiz
[edited by: DaveAtIFG at 3:41 pm (utc) on Oct. 22, 2003]
[edit reason] Neutered IPs [/edit]
I received a reply from the company whose computer has been connected to my website for 8 days and they have closed the browser that was open to my webpage which contains a rotating banner script. It was inadvertant on their part and they apologized for the inconvenience.
Now I have to fix the script to run thru once then halt on the last banner...
Wiz