On Apr 23, 7:03 am, Matt Harrison <[email protected]>
wrote:
> I got an email the other day from someone who has apparently built a
> vulnerability
> analysis tool for rails apps.
>
> He claims (and I have no idea whether this is true, I present this purely as a
> question) that a very old project of mine still hosted on github, allows
> malicious
> execution because controllers do not "return" at the end of each action.
>
> According to him, a redirect_to does not halt processing and can somehow lead
> to
> people "executing" code.
>
> Has anyone else heard of this or received a smiliar message? I'm mainly just
> curious
> because if it's true, it would mean revising how I personally write apps, and
> also how
> 99% of tutorials/guides are written I would think.
>
Well it's certainly true that redirect_to isn't a magic method in that
it doesn't affect flow of what happens afterwards ie
def some_action
if bad_guy
redirect_to '/'
end
do_something
end
would still end up running do something. I don't think this is a new
discovery though, I consider this a well know fact.
Also a lot of the time people do this sort of checking in a
before_filter, and rendering or redirecting from there will halt the
filter chain.
Fred
> application_pgp-signature_part
> < 1KViewDownload
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.