~/talk

Building modular, scalable web apps? of CORS!

Talkat RubyConf 2012 · 2012-11-01..11-03· [web-platform, security]
slides:none on file

CORS is trivial to add in Ruby with rack-cors as middleware, and this enables a browser-side service-oriented architecture: a static HTML frontend on a CDN makes normal jQuery XHRs, sends a Bearer token in the URL hash, and uses an Ajax prefilter to attach an Authorization header to requests. The demo shows a Sinatra auth service (OmniAuth + Redis tokens) and a Sinatra stream service that verifies tokens via HTTP and accepts posts/gets — it works and lets services scale, reuse, and become public APIs (examples: GitHub, S3).

AI-written summary · about

  1. 0:00Start
  2. 1:31Cross Origin Resource Sharing
  3. 5:01Access Control Headers
  4. 13:01Initial Complexity • Cross-Service Communication • Lack of Framework
  5. 17:30Let's Dig In!
  6. 32:41Famous Examples · GitHub: Entire API can be accessed via CORS • Amazon S3: Uploading now possible via 53
  7. 35:06Now you know what you can do with CORS today
~/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.