CodeOfficer / rack-options-request
- Source
- Commits
- Network (0)
- Issues (0)
- Downloads (3)
- Wiki (1)
- Graphs
-
Branch:
master
| name | age | message | |
|---|---|---|---|
| |
.gitignore | Wed Mar 11 08:26:46 -0700 2009 | |
| |
LICENSE | Wed Mar 11 08:26:46 -0700 2009 | |
| |
README.rdoc | Wed Mar 11 11:55:05 -0700 2009 | |
| |
Rakefile | Wed Mar 11 08:26:46 -0700 2009 | |
| |
VERSION.yml | Sat Apr 11 23:14:00 -0700 2009 | |
| |
lib/ | Sat Apr 11 23:12:50 -0700 2009 | |
| |
rack-options-request.gemspec | Sat Apr 11 23:15:02 -0700 2009 | |
| |
spec/ | Wed Mar 11 08:26:46 -0700 2009 |
README.rdoc
rack-options-request
- Web: www.codeofficer.com/
- Email: spam*@*codeofficer*dot*com
- Github: github.com/CodeOfficer/rack-options-request/
Have you seen exceptions like this before?
"ActionController::NotImplemented: Only requests are allowed."
This is usually the result of a Microsoft product sending an OPTIONS request to your app with a user_agent of "Microsoft Office Protocol Discovery". This middleware will stop those requests in their tracks, and keep them from hitting your rails stack.
TO USE with Rails 2.3:
gem install CodeOfficer-rack-options-request
in your environment.rb
require 'rack/options/request'
then do a
config.gem "CodeOfficer-rack-options-request" # (optional)
config.middleware.use Rack::Options::Request
For more information, please read: rails.learnhub.com/lesson/2318-dealing-with-microsoft-office-protocol-discovery-in-rails
Until I learn TDD, you can test your local app with …
curl -X GET http://localhost:3000/
Should return your normal content.
While …
curl -X OPTIONS http://localhost:3000/
Should return a 200 status and "Microsoft Office Protocol Discovery".
Copyright
Copyright © 2009 Russell Jones. See LICENSE for details.
