Raised This Month: $ Target: $400
 0% 

[SNIPPET] Multiple Fast Download URLs


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
KawMAN
SourceMod Donor
Join Date: Sep 2007
Location: Cracov
Old 04-28-2010 , 06:38   Re: [SNIPPET] Multiple Fast Download URLs
Reply With Quote #1

i published mirror script so i must publish this too
PHP Code:
RewriteEngine on
#Only HL2/Valve servers
RewriteCond %{HTTP_REFERER} ^hl2://(.*) [NC]
#Allowed servers
RewriteCond %{HTTP_REFERER} !^hl2://91\.91\.91\.91:27015 [NC]
RewriteCond %{HTTP_REFERER} !^hl2://91\.204\.162\.240:(.*) [NC]
#if not allowed, send 403 Forbidden
RewriteRule .* - [F
this is example of .htaccess mod_rewrite rule that block requests from servers not defined in this file. This blocks only another servers. Browser or other things will stil be able to download files.

This example allow donwload files for clients on servers: 91.91.91.91 port 27015 and 91.204.162.240 on any port

You can test this with FireFox and RefControl Addon. Exactly same file is on http://fastdownload.strefa-source.pl try to reach this site using referer hl2://91.91.91.91:27015 and some other hl2://
__________________

Last edited by KawMAN; 04-28-2010 at 07:03.
KawMAN is offline
Send a message via ICQ to KawMAN Send a message via Skype™ to KawMAN
Darkthrone
Senior Member
Join Date: Jun 2009
Old 07-01-2010 , 16:15   Re: [SNIPPET] Multiple Fast Download URLs
Reply With Quote #2

Quote:
Originally Posted by KawMAN View Post
This blocks only another servers. Browser or other things will stil be able to download files.
how to block browser?
__________________
all the best for your Zombie:Reloaded server
Auto !zspawn | ZProp | Infinite Ammo | Anti-Doorblock

Darkthrone is offline
KawMAN
SourceMod Donor
Join Date: Sep 2007
Location: Cracov
Old 07-01-2010 , 16:30   Re: [SNIPPET] Multiple Fast Download URLs
Reply With Quote #3

remove
PHP Code:
RewriteCond %{HTTP_REFERER} ^hl2://(.*) [NC] 
__________________
KawMAN is offline
Send a message via ICQ to KawMAN Send a message via Skype™ to KawMAN
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:26.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode