~/talk

The World of Rails Security

Talkat RailsConf 2015 · 2015-04-21..04-23· [security, ruby-on-rails]

Overview of concrete Rails security issues and fixes: historical behavior of mass-assignment and strong parameters, real XSS and CSRF examples (including a TweetDeck-style XSS), demos of SQL injection via ActiveRecord and a public SQLi playground, how session cookies are structured so they can be decoded and why cookie session store (versus encrypted session cookies) is risky, surprising default choices (server‑side sessions not default, JSON not escaped), and practical tools and automation: rack‑attack, secure_headers, and Brakeman/Brakeman in CI. Practical, example‑driven, and focused on fixes.

AI-written summary · about

  1. 0:00Intro
  2. 0:24Announcement
  3. 2:11Cross Site Scripting Protection
  4. 2:53Rails 3/4 Examples
  5. 4:35Lots of Safe(ish) Helpers
  6. 5:07Cross Site Request Forgery (CSRF)
  7. 7:43Mass Assignment Protection
  8. 8:38Strong Parameters
  9. 10:23Security Headers
  10. 11:40Back to Cross Site Scripting
  11. 12:16JSON Encoding in Rails 3.2
  12. 12:50How About Contextual Encoding?
  13. 13:45Not Great CSRF Protection
  14. 14:43CSRF Token Failures
  15. 15:36Why Care?
  16. 16:54Server-Side Sessions Not Default
  17. 17:32So What?
  18. 18:31Decoding Cookies
  19. 19:15No Account/Session Management
  20. 19:48No Authorization Framework
  21. 20:38Not Enough SQL Injection Protection
  22. 23:01Manual SQL Escaping
  23. 23:12Sanitizing SQL?
  24. 25:48No Open Redirect Protection
  25. 26:12No Protocol Filtering for Links
  26. 27:03Even More Missing Security Features
  27. 27:57Learn About Security
  28. 28:16Use Security Libraries
  29. 28:53Use Static Analysis Tools
  30. 29:31Cost of Fixing Defects
  31. 31:06The Plan
  32. 31:44Some Options
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.