Greenguy's Board

Greenguy's Board (http://www.greenguysboard.com/board/index.php)
-   General Business Knowledge (http://www.greenguysboard.com/board/forumdisplay.php?f=10)
-   -   Another download program to add to htaccess (http://www.greenguysboard.com/board/showthread.php?t=1134)

Tart 2003-09-28 08:45 PM

Another download program to add to htaccess
 
Express WebPictures (www.express-soft.com)

Just got this one in my logs... sigh.. First time I've seen it so I'm not sure if it's new or if it took this long to find me. My list keeps getting longer and longer :(

This might be a really good topic for some indepth tips.. or even for a chat. I know that even now I have a hard time protecting my sites without screwing other things up and Oh what a mess when I first started fooling with it!

JenC 2003-09-29 06:56 PM

I have asked about doing this before and I still haven't done it. I would really appreciate a tutorial or workshop on this because I am so .htaccess ignorant. :(

Surfn 2003-09-29 07:09 PM

Once you set it up (not difficult) you just add a line for each new domain you wish to block/redirect |rasta|

JenC 2003-09-29 08:23 PM

Quote:

Originally posted by Surfn
Once you set it up (not difficult) you just add a line for each new domain you wish to block/redirect |rasta|
Can you point me in the direction of how to set it up? |newbie|

Surfn 2003-09-29 08:28 PM

Here's what one of my servers has on it:

AddType text/x-server-parsed-html .html
AddType text/x-server-parsed-html .htm

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://cgcf.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.cgcf.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://co-edsgonewild.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.co-edsgonewild.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://coed-dorm-rooms.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.coed-dorm-rooms.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://exgo.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.exgo.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://girlsgonewildtgp.net.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.girlsgonewildtgp.net.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kltm.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kltm.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://ktej.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.ktej.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://pjfan.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.pjfan.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://pornoisseur.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.pornoisseur.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://pussylicking-lesbians.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.pussylicking-lesbians.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://sexpiate.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.sexpiate.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://sexponent.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.sexponent.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://smutbandit.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.smutbandit.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://wwedivass.com.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.wwedivass.com.*$ [NC]

RewriteRule .*[Jj][Pp][Gg]$|.*[Gg][Ii][Ff]$ http://smutbandit.com

Just change the domains to your own

HTH

dareutwo 2003-09-29 09:33 PM

1.) Create a text file - access.txt (save this to your desktop)
2.) Upload the access.txt file to your server in ASCII Mode (NOT BINARY)
Htaccess will cover Anything below where you put it. Meaning if you have Babes and put the file there, then ANYTHING in Babes will be protected ie


This one is very simple - copy this into your text file and save it as access.txt

< --- remove this part -->

RewriteEngine On
RewriteCond %{HTTP_REFERER} ^$ [OR]
RewriteCond %{HTTP_REFERER} !^http://([a-z0-9-]+\.)*yourdomain.com/ [NC]
RewriteCond %{HTTP_REFERER} !^http://66.154.11.181/ [NC]
RewriteRule .*\.(gif|jpg|jpeg) http://www.markslinks.com/babes.html [L,R,NC]

<-- I saved this as access.txt then removed this line too -->


Upload the access.txt file into the directory you wish to protect.
Then RENAME the file to DOT htaccess ".htaccess"
When you do this with CuteFTP anyway, you will see the icon of the text file change. (but test your work just to make sure - try typing in the exact url of a picture you want protected)

btw - edit the final URL "where I have my babes.html" to whatever URL you wish to send them to, google, nfl.com, wherever. (do not send them to a sponsor URL unless you are sure it's OK with their TOS - and even then, most browsers won't fill in a full sponsor code meaning you'll just be giving them very unproductive but not worthless traffic)

The above htaccess will NOT stop the actual html page from being loaded. What a hotlinker will see is a page with All the images blocked, But if you have any text links on the html page - they get those :)

dareutwo 2003-09-29 09:36 PM

Forgot - change those IP numbers to YOUR domain IP numbers.
IE
xxx.xx.xxx.xxx
If you don't know Your IP numbers, ask your host.

Cleo 2003-09-29 10:06 PM

Well since we are all doing HTacess examples mine is near the bottom of this page.
http://www.cleos-porn-links.com/adul...ster-help.html

Mine does use any wildcards so it is more secure but it does put more load on the sever since there is more lines of code to it.

Here is what one of mine looks like.
http://cleogoodstuff.com/htaccess.txt

spacemanspiff 2003-09-29 11:03 PM

I know absolutely nothing about this kind of stuff, but someone on this board posted this a while back

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://(www\.)?yourdomain.com(/)?.*$ [NC]
RewriteRule .*\.(gif|jpg|jpeg|bmp)$ http://fullpagead.com [R,NC]

I use it briefly for stuff like alltheweb.com's image search crap. I wasn't sure what the implications for google would be so I removed it, but I seem to recall that it just blocked everything instead of trying to catch each domain that's hotlinking.

Any of you code gurus care to comment?

SS

JenC 2003-09-30 01:18 PM

Awesome everyone! Thanks so much! I swear this board is the most helpful place on earth. |smooch|

Surfn 2003-09-30 01:22 PM

Quote:

Originally posted by topsmutlinks
Awesome everyone! Thanks so much! I swear this board is the most helpful place on earth. |smooch|
When you feel comfy with this level I have code for the advanced level that I can help you with too. Good luck! :)

JenC 2003-09-30 01:28 PM

A friend of mine is telling me that putting my domains in there will only prevent hotlinking and not block the software that downloads the entire site in one day. Is this true?

Sorry to keep asking stupid questions.

Surfn 2003-09-30 01:34 PM

Quote:

Originally posted by topsmutlinks
A friend of mine is telling me that putting my domains in there will only prevent hotlinking and not block the software that downloads the entire site in one day. Is this true?

Sorry to keep asking stupid questions.

That's usually done with spiders. Do you know how to write text to tell spiders to follow or not follow the page/site?

This will keep them out. BUT it will keep SE spiders out as well. Keep that in mind:







Cleo 2003-09-30 01:38 PM

More info…

Lets look at the first part of mine,

ErrorDocument 404 http://www.cleos-porn-links.com/

DirectoryIndex index.html index.php index.shtml index.htm

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com:80/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com:80/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com:80.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com:80.*$ [NC]

This part defines my custom 404 page
ErrorDocument 404 http://www.cleos-porn-links.com/


This line defines what is a valid index page in a folder
DirectoryIndex index.html index.php index.shtml index.htm


This line turns on the rewrite engine so that the rest of the code will work
RewriteEngine on

This line says allows a image to be served with no referral info like if they just typed the URL of a pic
RewriteCond %{HTTP_REFERER} !^$

These lines define what is a good referral URL. I have them there 8 times because I do not use wild cards in my htaccess so I have to type every combo that is valid. I do not use wild cards because if you do all someone has to do to get around your htaccess is put their site inside of a folder named after your domain.
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com:80/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com:80/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://kinkycleo.com:80.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.kinkycleo.com:80.*$ [NC]


This is what file extensions it should examine in the rewiteCond and where they should be sent if false.
RewriteRule [Ss][Ww][Ff]$|[Jj][Pp][Ee]*[Gg]|[Gg][Ii][Ff]$ http://cleo-says-fuck-you.com/ [R,L]

JenC 2003-09-30 02:56 PM

Quote:

Originally posted by Surfn
That's usually done with spiders. Do you know how to write text to tell spiders to follow or not follow the page/site?

This will keep them out. BUT it will keep SE spiders out as well. Keep that in mind:





If I put this on my members page though, will it keep out the download spiders and search engines couldn't get to them anyway due to the password protection right?

Cleo 2003-09-30 02:59 PM

htaccess will keep out the spiders if it is used to passoword protect a directory.

Spiders don't do password protected directories.

JenC 2003-09-30 02:59 PM

Okay I think what Cleo is saying is sinking in. I'm so code-illiterate. It's my biggest weakness in this business. :(

Surfn 2003-09-30 03:02 PM

Quote:

Originally posted by topsmutlinks
If I put this on my members page though, will it keep out the download spiders and search engines couldn't get to them anyway due to the password protection right?
Yeppers, you don't want anything in the members area other than the members. if you allow SE's to index them then you have surfers coming to that page without paying. In which case you want them to see your 404 (which,in my case, is the same as my join page) HTH


All times are GMT -4. The time now is 11:20 PM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
© Greenguy Marketing Inc