Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/singpolyma/http-over-btp
HTTP over Browser Transfer Protocol (broken HTTP subset)
https://github.com/singpolyma/http-over-btp
Last synced: about 1 month ago
JSON representation
HTTP over Browser Transfer Protocol (broken HTTP subset)
- Host: GitHub
- URL: https://github.com/singpolyma/http-over-btp
- Owner: singpolyma
- License: isc
- Created: 2010-10-18T18:13:39.000Z (about 14 years ago)
- Default Branch: master
- Last Pushed: 2010-10-18T18:13:44.000Z (about 14 years ago)
- Last Synced: 2024-10-15T11:34:34.267Z (3 months ago)
- Language: Ruby
- Homepage:
- Size: 89.8 KB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README
- License: COPYING
Awesome Lists containing this project
README
This is a piece of Rack middleware and example application.
The middleware assumes that the request body contains a fully-formed HTTP request (optionally only if a certain parameter was passed, just as ?ajax) and parses said request into the Rack environment, overriding anything that came from the actual HTTP request.
The example application takes the environment produced by the middleware, constructs an HTTP request from it, and sends that request on to the server specified by the Host header. A hard-coded or restricted host/port would allow this server to run in production as a proxy onto any HTTP-based API, so that broken HTTP-like clients that only support some HTTP features can proxy onto the real HTTP API.