Can only get image if it"s in a webpage

Can only get image if it"s in a webpage

am 27.05.2007 06:02:58 von chancegardinner

I use the URL's for images found within a webpage in order to display
the images alone on a tab in my browser.

Something I don't understand started happening with one of these image
files.

Til recently this URL: http://www.oceancitycam.com/images/board1.jpg
went to a webcam of a boardwalk in Maryland. The jpeg changed about
every 5 seconds.

Now when you go to that URL you get a a message:
"Visit Beach-net.com Web Cams."

However if you go to the page where the webcam image is embedded it
appears as usual:
http://www.oceancitycam.com/

Checking the current URL for the pic,it appears to be the same as it
has been:
http://www.oceancitycam.com/images/board1.jpg

Somehow, they have made the pic accessible only within the wepage.
Does anyone know how they do that?

Re: Can only get image if it"s in a webpage

am 27.05.2007 07:18:27 von dorayme

In article
<1180238578.363645.213260@q19g2000prn.googlegroups.com>,
chancegardinner@yahoo.com wrote:

> I use the URL's for images found within a webpage in order to display
> the images alone on a tab in my browser.
>
> Something I don't understand started happening with one of these image
> files.
>
> Til recently this URL: http://www.oceancitycam.com/images/board1.jpg
> went to a webcam of a boardwalk in Maryland. The jpeg changed about
> every 5 seconds.
>
> Now when you go to that URL you get a a message:
> "Visit Beach-net.com Web Cams."
>
> However if you go to the page where the webcam image is embedded it
> appears as usual:
> http://www.oceancitycam.com/
>
> Checking the current URL for the pic,it appears to be the same as it
> has been:
> http://www.oceancitycam.com/images/board1.jpg
>
> Somehow, they have made the pic accessible only within the wepage.
> Does anyone know how they do that?

Not quite. When I go to url where it is embedded and I control
click it in Safari and choose "open in new window", the picture
opens in new window fine. But if, instead, I choose "open in new
tab" it get what you are calling a message.

--
dorayme

Re: Can only get image if it"s in a webpage

am 27.05.2007 07:21:14 von shb*NO*SPAM*

On 26 May 2007 21:02:58 -0700, chancegardinner@yahoo.com wrote:

>I use the URL's for images found within a webpage in order to display
>the images alone on a tab in my browser.
>
>Something I don't understand started happening with one of these image
>files.
>
>Til recently this URL: http://www.oceancitycam.com/images/board1.jpg
>went to a webcam of a boardwalk in Maryland. The jpeg changed about
>every 5 seconds.
>
>Now when you go to that URL you get a a message:
>"Visit Beach-net.com Web Cams."
>
>However if you go to the page where the webcam image is embedded it
>appears as usual:
>http://www.oceancitycam.com/
>
>Checking the current URL for the pic,it appears to be the same as it
>has been:
>http://www.oceancitycam.com/images/board1.jpg
>
>Somehow, they have made the pic accessible only within the wepage.
>Does anyone know how they do that?

It is done in the web server setup to prevent people from
hijacking the web cam feed for their own web pages (and missing
all the advertising).

Re: Can only get image if it"s in a webpage

am 27.05.2007 08:09:17 von rf

wrote in message
news:1180238578.363645.213260@q19g2000prn.googlegroups.com.. .
>I use the URL's for images found within a webpage in order to display
> the images alone on a tab in my browser.

> Something I don't understand started happening with one of these image
> files.
>
> Til recently this URL: http://www.oceancitycam.com/images/board1.jpg
> went to a webcam of a boardwalk in Maryland. The jpeg changed about
> every 5 seconds.
>
> Now when you go to that URL you get a a message:
> "Visit Beach-net.com Web Cams."
>
> However if you go to the page where the webcam image is embedded it
> appears as usual:
> http://www.oceancitycam.com/
>
> Checking the current URL for the pic,it appears to be the same as it
> has been:
> http://www.oceancitycam.com/images/board1.jpg
>
> Somehow, they have made the pic accessible only within the wepage.
> Does anyone know how they do that?

Quite simple. They serve a different image if the image is not being
included in *their* page. Look at *their* page you get the correct image.
Look directly at the image, or include the image on *your* page, you get
something else. This is to stop bandwidth stealing.

The image you get is only a gentle hint to use *their* page to look at the
image. There have been reports of people replacing images with something
that, shall we say, you would not display in mixed company.

--
Richard.

Re: Can only get image if it"s in a webpage

am 27.05.2007 09:21:29 von dorayme

In article ,
"rf" wrote:

> wrote in message
> news:1180238578.363645.213260@q19g2000prn.googlegroups.com.. .
> >I use the URL's for images found within a webpage in order to display
> > the images alone on a tab in my browser.
>
> > Something I don't understand started happening with one of these image

> > http://www.oceancitycam.com/
> >
> > Checking the current URL for the pic,it appears to be the same as it
> > has been:
> > http://www.oceancitycam.com/images/board1.jpg
> >
> > Somehow, they have made the pic accessible only within the wepage.
> > Does anyone know how they do that?
>
> Quite simple. They serve a different image if the image is not being
> included in *their* page.

It is not quite simple. See my post.

--
dorayme

Re: Can only get image if it"s in a webpage

am 27.05.2007 12:00:51 von rf

"dorayme" wrote in message
news:doraymeRidThis-91C27A.17212927052007@news-vip.optusnet. com.au...
> In article ,
> "rf" wrote:
>
>> wrote in message
>> news:1180238578.363645.213260@q19g2000prn.googlegroups.com.. .
>> >I use the URL's for images found within a webpage in order to display
>> > the images alone on a tab in my browser.
>>
>> > Something I don't understand started happening with one of these image
>
>> > http://www.oceancitycam.com/
>> >
>> > Checking the current URL for the pic,it appears to be the same as it
>> > has been:
>> > http://www.oceancitycam.com/images/board1.jpg
>> >
>> > Somehow, they have made the pic accessible only within the wepage.
>> > Does anyone know how they do that?
>>
>> Quite simple. They serve a different image if the image is not being
>> included in *their* page.
>
> It is not quite simple. See my post.

Very simple to do. Simply check referrer. What you found is that it is hard
to ensure that it works. A simple referrer spoof is a workaround.

I suspect (not checked, I don't currently have a Safari attached to the
internet*) that Safari includes referrer in the headers sometimes. Possibly
this is because you referenced the image via control-click on *their* page.
You could check the headers sent to confirm this.

What happens when you access the image via the image URL in the OP's post?

* FWIW I abhore Safari. I develop to Camino or Firefox. Safari is simply not
complete for the stuff I do (CMS etc).

--
Richard.

Re: Can only get image if it"s in a webpage

am 27.05.2007 12:22:52 von Shion

rf wrote:
> "dorayme" wrote in message
> news:doraymeRidThis-91C27A.17212927052007@news-vip.optusnet. com.au...
>> In article ,
>> "rf" wrote:
>>
>>> wrote in message
>>> news:1180238578.363645.213260@q19g2000prn.googlegroups.com.. .
>>>> I use the URL's for images found within a webpage in order to display
>>>> the images alone on a tab in my browser.
>>>> Something I don't understand started happening with one of these image
>>>> http://www.oceancitycam.com/
>>>>
>>>> Checking the current URL for the pic,it appears to be the same as it
>>>> has been:
>>>> http://www.oceancitycam.com/images/board1.jpg
>>>>
>>>> Somehow, they have made the pic accessible only within the wepage.
>>>> Does anyone know how they do that?
>>> Quite simple. They serve a different image if the image is not being
>>> included in *their* page.
>> It is not quite simple. See my post.
>
> Very simple to do. Simply check referrer. What you found is that it is hard
> to ensure that it works. A simple referrer spoof is a workaround.

Yes, the board1.jpg php-script does check the HTTP referer and will serve the
message image to those requests that don't have the right referer.

For those with wget, you can try

wget http://www.oceancitycam.com/images/board1.jpg

wget --referer=http://www.oceancitycam.com/
http://www.oceancitycam.com/images/board1.jpg

and you will end with two different images.


--

//Aho

Re: Can only get image if it"s in a webpage

am 27.05.2007 12:25:30 von John Hosking

chancegardinner@yahoo.com wrote:
>
> Til recently this URL: http://www.oceancitycam.com/images/board1.jpg
> went to a webcam of a boardwalk in Maryland. The jpeg changed about
> every 5 seconds.
>
> Now when you go to that URL you get a a message:
> "Visit Beach-net.com Web Cams."
>
> However if you go to the page where the webcam image is embedded it
> appears as usual: http://www.oceancitycam.com/
>
> Checking the current URL for the pic,it appears to be the same as it
> has been: http://www.oceancitycam.com/images/board1.jpg
>
> Somehow, they have made the pic accessible only within the wepage.
> Does anyone know how they do that?

The site checks for the referrer. When I turn off referrers in my
Firefox, I only ever see the ersatz image
http://www.oceancitycam.com/images/hotlink.jpeg, even within their main
page. I must have referrers enabled, and I must be accessing the
board1.jpg image via their site. They're doubtless enforcing this with
..htaccess files.

See, for example, http://en.wikipedia.org/wiki/Hotlink and
http://altlab.com/htaccess_tutorial.html.

--
John

Re: Can only get image if it"s in a webpage

am 27.05.2007 22:40:25 von chancegardinner

Thanks for the replies. It is the referrer.

I use a local proxy server called Proxomitron that alllows you to
strip or replace anything in the html of the webpage or anything in
the header. I use it mainly to remove the no cache tags.

There is a prewritten rule in Proxomitron that will strip the
referer or there is an option to substitute a URL of your own as the
referring address. I don't know what a referrer tag should look like.
What is the format for a referrer tag in the header?

In reading up on referrers, I found this site:
http://www.garthgillespie.com/tools/iterator.php

It seems to act as a proxy server referrer spoofer. If you plug in the
address of the .jpg, it returns this URL which will then retrieve the
"real" pic from the server:

http://www.garthgillespie.com/tools/refspoof.php?ref=&url=ht tp://www.oceancitycam.com/images/board1.jpg

This is only for my own web browsing and enlightenment. I have
bookmarked an assortment of pics (like Piccadilly Circus and Times
Square) that I like to open in full screen views in my browser. I am
not trying to steal bandwidth by putting others' pics on a webpage.




> The site checks for the referrer. When I turn off referrers in my
> Firefox, I only ever see the ersatz imagehttp://www.oceancitycam.com/images/hotlink.jpeg, even within their main
> page. I must have referrers enabled, and I must be accessing the
> board1.jpg image via their site. They're doubtless enforcing this with
> .htaccess files.
>
> See, for example,http://en.wikipedia.org/wiki/Hotlinkandhttp://altlab .com/htaccess_tutorial.html.
>
> --
> John- Hide quoted text -
>
> - Show quoted text -

Re: Can only get image if it"s in a webpage

am 27.05.2007 23:56:48 von dorayme

In article ,
"rf" wrote:

> "dorayme" wrote
> > "rf" wrote:
> >
> >>

> >> > http://www.oceancitycam.com/
> >> >
> >> > Checking the current URL for the pic,it appears to be the same as it
> >> > has been:
> >> > http://www.oceancitycam.com/images/board1.jpg
> >> >
> >> > Somehow, they have made the pic accessible only within the wepage.
> >> > Does anyone know how they do that?
> >>
> >> Quite simple. They serve a different image if the image is not being
> >> included in *their* page.
> >
> > It is not quite simple. See my post.
>
> Very simple to do. Simply check referrer. What you found is that it is hard
> to ensure that it works. A simple referrer spoof is a workaround.
>

In iCab I can control-click the image and choose open in new tab
and the image loads fine. In Mac IE, there is no webcam image to
begin with, in Opera, I see no options in context menu to open
(not a browser I know well though).

Whatever, it is a horrible looking flashing site.

>
> What happens when you access the image via the image URL in the OP's post?
>

As he says.

--
dorayme