# Document referer

**URL:** <https://discuss.rubyonrails.org/t/document-referer/43517>\
**Category:** rubyonrails-talk\
**Created:** [June 16, 2009, 2:17pm UTC](https://discuss.rubyonrails.org/t/document-referer/43517 "2009-06-16T14:17:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![SteveCox](https://avatars.discourse-cdn.com/v4/letter/s/258eb7/32.png) [@SteveCox](https://discuss.rubyonrails.org/u/SteveCox)\
**Post date:** [June 16, 2009, 2:17pm UTC](https://discuss.rubyonrails.org/t/document-referer/43517/1 "2009-06-16T14:17:09Z")

</div>

Hi, I want to allow only a handful of refering sites to access parts of my application.

I understand that in rails I can use request.referer which does identify the refering site correctly however is it possible for the less desirable to "spoof" this in order to access the app.

If so is there any other way of protecting the app.

Thanks in advance. Steve
