Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 04-22-2004, 04:21 PM
DenzoForums DenzoForums is offline
 
Join Date: Apr 2004
Posts: 73
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Protect avatars and attachments using mod_rewrite

I posted this over at vbulletin.com also, but i got pointed to an old thread that didn't have a working answer.

http://www.vbulletin.com/forum/showthread.php?t=19021

Anybody here know how to do this with htaccess?

Thanks
Dave
Reply With Quote
  #2  
Old 04-26-2004, 11:53 PM
DenzoForums DenzoForums is offline
 
Join Date: Apr 2004
Posts: 73
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Anybody??? I need some help with this..

Thanks
Dave
Reply With Quote
  #3  
Old 04-28-2004, 03:22 AM
Liquid1ce's Avatar
Liquid1ce Liquid1ce is offline
 
Join Date: Feb 2004
Location: /root
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

make a file called .htaccess & add the following then upload to your root dir

Code:
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://ServerIP/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://ServerIP$      [NC]
RewriteCond %{HTTP_REFERER} !^http://YourSite.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://YourSite.org$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.YourSite.org/.*$      [NC]
RewriteCond %{HTTP_REFERER} !^http://www.YourSite.org$      [NC]
RewriteRule .*\.(jpg|jpeg|gif|png|bmp|zip|rar|mpg|mp3)$ http://www.SomeOtherSite.org/Theif.gif [R,NC]
The RewriteRule Are the extensions you want protected
Reply With Quote
  #4  
Old 04-28-2004, 01:28 PM
DenzoForums DenzoForums is offline
 
Join Date: Apr 2004
Posts: 73
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK.. I will give it a whirl.. but how do i findmy ip address? My host seems to be sleeping at the wheel, and never answers my requests for help..

note to self: Must look into new hosting company.

Thanks Dave
Reply With Quote
  #5  
Old 04-28-2004, 01:44 PM
Sketch Sketch is offline
 
Join Date: Apr 2002
Location: Baltimore, Maryland
Posts: 135
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Windows > Start > Run > cmd

ping www.yourdomain.com
Reply With Quote
  #6  
Old 04-28-2004, 02:52 PM
DenzoForums DenzoForums is offline
 
Join Date: Apr 2004
Posts: 73
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Sketch
Windows > Start > Run > cmd

ping www.yourdomain.com
Thanks for the ip..
.. now how do i test this to see if it works.

i tried [img] place my url for image here? [/img] .. but this doens;t seem to work. I still see the picture..

EDIT - Also where am i putting this? I put it oin the root for my domain..
Thanks
Dave
Reply With Quote
  #7  
Old 04-28-2004, 02:54 PM
DenzoForums DenzoForums is offline
 
Join Date: Apr 2004
Posts: 73
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default



this is using the img tag.. it show as a link, instead of showing the image.. any reason?

1 more try..



OK.. this is not working either then..
Reply With Quote
  #8  
Old 04-28-2004, 04:23 PM
Liquid1ce's Avatar
Liquid1ce Liquid1ce is offline
 
Join Date: Feb 2004
Location: /root
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

have you set in admincp to allow the [ img ] tag ?

also http://www.bytenix.net Have VERY Cheap hosting if your after new hosting
Reply With Quote
  #9  
Old 04-28-2004, 04:32 PM
DenzoForums DenzoForums is offline
 
Join Date: Apr 2004
Posts: 73
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Liquid1ce
have you set in admincp to allow the [ img ] tag ?
Why would this matter? I am trying to protect my images from hotlinking to someone elses websites. as you can see in the post above, i was able to display an image hosted on my site directly in the post above. The .htaccess mod doesn;t seem to be protecting my image.

Thanks
Dave
P.S. I will look at the host. Do you host there? Are they in the U.S? how's the support?
Reply With Quote
  #10  
Old 04-28-2004, 04:42 PM
Liquid1ce's Avatar
Liquid1ce Liquid1ce is offline
 
Join Date: Feb 2004
Location: /root
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

RewriteEngine needs to be on

& you'll see the image as you have the cookie from your site-

As for the hosting yes im hosting there & support is very good
the servers are in the us yea
Reply With Quote
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. The time now is 10:01 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04889 seconds
  • Memory Usage 2,252KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete