Elemental-IRCd / elemental-ircd

Continuation of ShadowIRCD to meet people's needs
GNU General Public License v2.0
41 stars 19 forks source link

Websocket support #53

Open Xe opened 9 years ago

Xe commented 9 years ago

Old branch at websockets. Would be nice but not required for 7.0.

dequis commented 9 years ago

This is a thing? Do any other ircds support it?

Also http://websocketd.com/

Xe commented 9 years ago

It was a thing that was heavily indev and didn't really work based off this fork of ircd-ratbox.

Xe commented 9 years ago

@dequis found https://github.com/warmcat/libwebsockets which will help immensely.

Xe commented 9 years ago

Actually. I have a better idea. This is kind of terrible but it could be done in a way that would allow for extension to other things.

(Xena) i have a really bad idea on how to add websockets to elemental
(Xena) you know how HTTP headers are separated by \r\n?
(Xena) what if m_websocket.so adds commands for the http headers
(Xena) and then use weechat's relay websocket code
(Xena) but basically
(Xena) you'd have a pre-registration command GET
(Xena) and commands UPGRADE: and CONNECTION:
(Xena) the parv[0] of upgrade: needs to be websocket
(Xena) the parv[0] of connection: need to be upgrade
(Xena) however
(Xena) need to add a little more hooking and the like to the 
    core so that the websocket read/write semantics can replace 
    the standard socket ones
(Xena) but that is not hard