rack/rack-contrib — pull request #59 by RafeKettler (2012-08-09 14:13:38+00:00)
Title: Rack::CORS middleware

Attached is some very simple middleware to allow Cross Origin Resource Sharing for a flexible list of domains. The list of domains that is passed as an argument to the middleware can contain the same kind of wildcards that shell globs can (underneath the hood, I use `File.fnmatch?` to check Origins against patterns).