shelf_proxy
shelf_proxy copied to clipboard
A shelf handler for proxying requests to another server.
This is a bare-minimum fix for [#26](https://github.com/dart-lang/shelf_proxy/issues/26)
Supporting HTTP proxy is very useful, like '127.0.0.1:7890'
Expected Behavior: Proxied requests should be enriched by setting one or more of the following standard headers: * `Forwarded` (preferred) * `X-Forwarded-For` * `X-Forwarded-Host` * `X-Forwarded-Proto` * `X-Forwarded-Protocol`
I have solved the cross-domain problem of common interface with this plugin, but when a cookie is required, the cookie cannot take effect due to localhost and interface cross-domain. How...
Error: Unsupported operation: ServerSocket.bind at Object.throw_ [as throw] (http://localhost:50675/dart_sdk.js:4339:11) at Function._bind (http://localhost:50675/dart_sdk.js:57307:17) at Function.bind (http://localhost:50675/dart_sdk.js:57295:32) at Function.bind (http://localhost:50675/dart_sdk.js:183998:30) at Function.bind (http://localhost:50675/dart_sdk.js:177277:32) at serve (http://localhost:50675/packages/shelf/src/io_server.dart.lib.js:130:70) at serve.next () at runBody (http://localhost:50675/dart_sdk.js:37699:34)...
If I use custom headers, I have a cross-domain problem.
Future testProxy(String proxyUrl) async { var server; try { server = await shelf_io.serve( proxyHandler(proxyUrl), '181.204.31.17', 89456, ); print('Proxying atttttttttttttttttttttttttttttttttttttt'); } catch (e) { print('Proxying at 失败://$e'); } print('Proxying at http://${server.address.host}:${server.port}');...
hi is it possible have multiple destination? maybe some kind of roundrobin for basic to start with. and also possible to support http2 (for grpc to work?)
How can i make my whole flutter app when runApp runs connect to this service ?