Adding a private protocol to Twisted SSL Web server...
Hello fellow twisters: I'm writing an ActionScript application with it's corresponding server built upon twisted. first off, I'd like to thank you all for the awesome software you've all put into my hands. Since I'm taking your time I'll get right to the point. What is required - secure serving of web pages (works via twisted web/SSL) - proprietary socket protocol (works with TCPServer and pyAMF). - client access server only via port 443 <--- here I have the questions What I think I need to do is to capture an SSL CONNECT command, steal the the connection and use it as my proprietary communication socket. I've gotten access to the connection using the render_CONNECT() method, and having the client issue a corresponding command. What I cant figure out is how best to remove the connection from the HTTP protocol and setup a pass-thru to my application. (This is prefered to be able to run multiple servers on different machines) I would hate to 'fudged' code into the system all the way down in basic.py, and your code is well modularized that I feel there should be a way to accomplish this, but it seams to be above my current pay grade ;-) Thank You all for your time, and hope the problem is interesting enough to evoke responses Jerry
Found setRaw() method, maybe can use an override of the rawDataRecieved(...) to forward data to another tcp connection... now need to look for some kind plugin glue that connects 2 TCP sockets... (one SSL and one not)... This stuff is so big I feel, I'm spending more time looking for the "correct way", than it would be to re-invent the wheel... Sorry about answering my own post, but hoping someone will jump in and tell where I'm going wrong... Jerry On 11/17/2011 12:19 PM, Jerry Westrick wrote:
Hello fellow twisters:
I'm writing an ActionScript application with it's corresponding server built upon twisted. first off, I'd like to thank you all for the awesome software you've all put into my hands.
Since I'm taking your time I'll get right to the point.
What is required - secure serving of web pages (works via twisted web/SSL) - proprietary socket protocol (works with TCPServer and pyAMF). - client access server only via port 443<--- here I have the questions
What I think I need to do is to capture an SSL CONNECT command, steal the the connection and use it as my proprietary communication socket.
I've gotten access to the connection using the render_CONNECT() method, and having the client issue a corresponding command.
What I cant figure out is how best to remove the connection from the HTTP protocol and setup a pass-thru to my application. (This is prefered to be able to run multiple servers on different machines)
I would hate to 'fudged' code into the system all the way down in basic.py, and your code is well modularized that I feel there should be a way to accomplish this, but it seams to be above my current pay grade ;-)
Thank You all for your time, and hope the problem is interesting enough to evoke responses
Jerry
_______________________________________________ Twisted-web mailing list Twisted-web@twistedmatrix.com http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web
participants (1)
-
Jerry Westrick