Matthew Wild
11ef94449f
mod_websocket: Refactor frame validity checking, also check partially-received frames against constraints
5 years ago
Matthew Wild
74f380f064
mod_websocket: Continue to process data already in the buffer after an error occurs
...
Previously any error, or even a normal websocket close frame, would return early,
leaving potentially entire frames in the buffer unprocessed and then discarded.
This change stops processing new data, but returns an existing processed data up
to the point of the error/close.
5 years ago
Matthew Wild
68208217af
mod_websocket: Enforce stanza size limit and close stream
5 years ago
Matthew Wild
01f881f500
mod_websocket: Add separate limit for frame buffer size
5 years ago
Matthew Wild
344958724e
mod_websocket: handle full frame buffer and raise stream error
5 years ago
Matthew Wild
a96430a843
mod_websocket: Switch partial frame buffering to util.dbuffer
...
This improves performance and enforces stanza size limits earlier
in the pipeline.
5 years ago
Matthew Wild
2546c272bc
mod_websocket: Refactor frame validity checking, also check partially-received frames against constraints
5 years ago
Matthew Wild
fb2a77467f
mod_websocket: Continue to process data already in the buffer after an error occurs
...
Previously any error, or even a normal websocket close frame, would return early,
leaving potentially entire frames in the buffer unprocessed and then discarded.
This change stops processing new data, but returns an existing processed data up
to the point of the error/close.
5 years ago
Matthew Wild
68898a0880
mod_websocket: Enforce stanza size limit and close stream
5 years ago
Matthew Wild
2eee29ff1e
mod_websocket: Add separate limit for frame buffer size
5 years ago
Matthew Wild
7f839ba449
mod_websocket: handle full frame buffer and raise stream error
5 years ago
Matthew Wild
d8be48981f
mod_websocket: Switch partial frame buffering to util.dbuffer
...
This improves performance and enforces stanza size limits earlier
in the pipeline.
5 years ago
Matthew Wild
bd51ccfbbc
mod_websocket: Fire event on session creation (thanks Aaron van Meerten)
6 years ago
Kim Alvefur
954b42849d
mod_websocket: Clear mask bit when reflecting ping frames ( fixes #1484 )
6 years ago
Matthew Wild
9185758048
mod_websocket: Fire event on session creation (thanks Aaron van Meerten)
6 years ago
Kim Alvefur
e84ead8c29
mod_websocket: Clear mask bit when reflecting ping frames ( fixes #1484 )
6 years ago
Matthew Wild
70e9ff3887
mod_websocket: Fire event on session creation (thanks Aaron van Meerten)
6 years ago
Matthew Wild
3258337532
mod_bosh, mod_websocket: Add config options to override GET responses
6 years ago
Matthew Wild
1b8229790e
mod_websocket: Fire event on session creation (thanks Aaron van Meerten)
6 years ago
Kim Alvefur
022198143d
mod_websocket: Clone stanza before mutating ( fixes #1398 )
...
Checking for `stanza.attr.xmlns == nil` to determine if the stanza
object is an actual stanza (`<message>`, `<presence>` or `<iq>` in the
`jabber:client` or `jabbber:server` namespace) or some other stream
element.
Since this mutation is not reverted, it may leak to other places and
cause them to mistreat stanzas as stream elements. Especially in cases
like MUC where a single stanza is broadcast to many recipients.
7 years ago
Kim Alvefur
165db3098d
mod_websocket: Guard against upgrading to websocket from a HEAD request
6 years ago
Kim Alvefur
d692102013
mod_websocket: Log an error if cross_domain_websocket = true is set in a VirtualHost section
7 years ago
Kim Alvefur
62082d5832
mod_websocket: Include the value of cross_domain_websocket in debug message
7 years ago
Kim Alvefur
0d6f101a49
mod_websocket: Clone stanza before mutating ( fixes #1398 )
...
Checking for `stanza.attr.xmlns == nil` to determine if the stanza
object is an actual stanza (`<message>`, `<presence>` or `<iq>` in the
`jabber:client` or `jabbber:server` namespace) or some other stream
element.
Since this mutation is not reverted, it may leak to other places and
cause them to mistreat stanzas as stream elements. Especially in cases
like MUC where a single stanza is broadcast to many recipients.
7 years ago
Kim Alvefur
2b8caf8dac
plugins: Remove tostring call from logging
...
Taken care of by loggingmanager now
Mass-rewrite using lua pattern like `tostring%b()`
7 years ago
Kim Alvefur
0cf46e37a7
mod_websocket: Silence the one warning instead of ignoring the entire file
7 years ago
Kim Alvefur
6e9777081f
mod_websocket: Serve HTTP in global context
7 years ago
Matthew Wild
9bd948919b
mod_websocket: Store the request object on the session for use by other modules
8 years ago
Kim Alvefur
8c3f6bd236
mod_websocket: Convert set to string (syslog sink needs a better fix)
9 years ago
Kim Alvefur
59fa0c1c44
mod_websocket: Log state of cross domain set after changing it
9 years ago
Kim Alvefur
e4a558af46
mod_websocket: Transfer IP address derived by mod_http
8 years ago
Kim Alvefur
5535c0fb48
mod_websocket: Make open_stream method behave like the one from util.xmppstream
9 years ago
Kim Alvefur
41ef96b42e
mod_websocket: Include xml:lang attribute on stream <open> ( fixes #840 )
9 years ago
Kim Alvefur
c99a49ae02
mod_websocket: Set connections starttls method to false to prevent mod_tls from offering starttls ( fixes #837 )
9 years ago
Kim Alvefur
cc617421b1
mod_websocket: Allow per-host cross_domain_websocket, defaulting to the base URL of the current host
9 years ago
Kim Alvefur
a6443e8ff3
mod_websocket: Add the base URL of each host module is enabled on to 'cross_domain_websocket'
9 years ago
Kim Alvefur
947faa1ccd
mod_websocket: Verify that the client-sent Origin header matches cross_domain_websocket ( fixes #652 )
9 years ago
Kim Alvefur
de2540b480
mod_websocket: Use contains_token from util.http for checking if the requested WebSocket sub-protocols include XMPP
9 years ago
Kim Alvefur
499ca748ea
mod_websocket: Add some debug messages
9 years ago
Kim Alvefur
500d7efbf4
mod_websocket: Set FIN flag on ping frames ( fixes #773 )
9 years ago
Kim Alvefur
86ece22c8c
mod_websocket: Fix read timeout handler (thanks mt)
10 years ago
Kim Alvefur
921c695338
mod_websocket: Send a ping on read timeout
10 years ago
Kim Alvefur
b69db0deff
mod_websocket: Remove warning about unsolicited pong frames "MAY be sent unsolicited" per RFC 6455 (thanks mt)
10 years ago
Kim Alvefur
6a52a3feac
mod_websocket: Make sure stanza xmlns filter runs late in the chain
10 years ago
Kim Alvefur
8a93612482
mod_websocket: Silence luacheck warnings
10 years ago
Kim Alvefur
7284b55cc0
mod_websocket: Import util.timer and session close timeout config option (thanks fairuz)
10 years ago
Kim Alvefur
ffb9f937a1
mod_websocket: Import sessionmanager (fixes traceback)
11 years ago
Florian Zeitz
25bb15fc74
mod_websocket: Initial commit (based on the prosody-modules version)
11 years ago
Kim Alvefur
814eebb672
mod_bosh, mod_websocket: Remove accidentally included dependency on non-existant module
7 years ago
Kim Alvefur
26542811ea
mod_websocket: Drop CORS code in favor of that in mod_http
...
Like for mod_bosh, deprecates consider_websocket_secure and depend on
mod_http_crossdomain if it is set.
7 years ago