Pierre Fersing
7df5c40004
Fix $SYS counters when message is sent over WS
...
Signed-off-by: Pierre Fersing <pierre.fersing@bleemeo.com>
2018-01-02 16:51:56 +01:00
Roger A. Light
7943072b1f
Fix use_identity_as_username not working on websockets clients.
...
Thanks to achest.
2017-07-26 23:27:04 +01:00
Roger A. Light
ba0122f9a9
Don't disable IPv6 support for websockets.
2017-07-18 22:12:51 +01:00
Roger A. Light
e74203de2c
Merge branch 'master' into develop
2017-07-16 22:52:01 +01:00
Pierre Fersing
408972ddc1
Fix two issues with Websocket ( #472 )
...
* Websocket were always marked as "want_write" (even if they only
want to read, or worse want nothing).
* Websocket FD was read twice in some case (when socket recv queue was
larger that size read by libwebsocket)
Signed-off-by: Pierre Fersing <pierre.fersing@bleemeo.com>
2017-06-23 22:30:57 +01:00
Roger A. Light
c78678607d
[427] Fix large retained messages over websockets.
...
Thanks to Brian Block.
Bug: https://github.com/eclipse/mosquitto/issues/427
2017-06-19 21:40:19 +01:00
Roger A. Light
c07ba2a3da
Experimental fix for poor websockets performance.
2017-06-18 12:52:59 +01:00
Roger A. Light
91b308a11d
Merge branch 'master' into develop
2017-03-06 21:19:53 +00:00
Roger A. Light
2c92d3b837
More file closing fixes.
2017-02-20 23:48:30 +00:00
Roger A. Light
e7c1507f88
Fix error message when websockets http_dir directory does not exist.
2017-02-20 23:48:30 +00:00
Roger A. Light
b01e32bd8b
[354] Close http files even on bad clients.
...
Thanks to jbwdevries.
Bug: https://github.com/eclipse/mosquitto/issues/354
2017-02-20 23:48:30 +00:00
tucic
9f743d5972
Maximum connections for websockets listener ( #271 )
...
Check current number of connections before accepting new websockets clients.
Signed-off-by: tucic <tucic.milan@gmail.com>
2017-02-20 23:48:30 +00:00
Karl Palsson
20197e2496
websockets: fix compatibility with older lws versions ( #260 )
...
In 1.3, 1.4 and 1.5, the function was "libwebsockets_get_protocol" not
"libwebsocket_get_protocol" While the #define name doesn't matter on
newer libwebsockets, where it redirects to lws_get_protocol, the naming
is critical for older versions.
Fixes: 477cd3e399
(Fix missing context->listener for websocket client)
Signed-off-by: Karl Palsson <karlp@etactica.com>
2017-02-20 23:48:30 +00:00
Pierre Fersing
477cd3e399
Fix missing context->listener for websocket client ( #239 )
...
The context associated with websocket client didn't had listener
filled, which caused use_username_as_clientid to be ignored.
Signed-off-by: Pierre Fersing <pierre.fersing@bleemeo.com>
2016-08-16 22:10:41 +01:00
Roger A. Light
b1c4171cdc
Merge branch 'develop' of github.com:eclipse/mosquitto into develop
2016-08-10 12:22:39 +01:00
Roger A. Light
017db6706f
Rename mosquitto_broker.h -> mosquitto_broker_internal.h
2016-07-08 10:10:04 +01:00
Roger A. Light
8378fe44cf
Update copyrights.
2016-07-08 09:42:24 +01:00
Karl Palsson
7cb8988192
websockets: fix compile fail after refactoring ( #207 )
...
A lot of function renaming was done in 663d50a016
,
and this websockets patch was merged afterwards. Autobuild testing
doesn't have websockets enabled, and missed this.
Fixes: d9142c3974
Signed-off-by: Karl Palsson <karlp@etactica.com>
2016-07-07 14:19:54 +01:00
Roger A. Light
1c3988a397
Merge branch 'master' into develop
2016-06-21 23:33:58 +01:00
Roger A. Light
63416e6547
;
2016-06-06 16:03:24 +01:00
Roger A. Light
5d96c3d7ba
[186] Fix TLS operation with websockets listeners and libwebsockts 2.x.
...
Bug: https://github.com/eclipse/mosquitto/issues/186
2016-06-06 15:53:05 +01:00
Roger A. Light
7761218d3c
[170] Fix WS listeners not being able to bind to an IP.
...
Closes #170 . Thanks to minghuadev.
Bug: https://github.com/eclipse/mosquitto/issues/170
2016-05-26 09:21:15 +01:00
Roger A. Light
a79412e3d8
Fix compile error from library keepalive handling.
2016-03-06 19:49:20 +00:00
Roger A. Light
d9142c3974
[476314] Deliver queued WS client msgs on reconnect.
...
Thanks to Joking Young and Christoph Krey.
Bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=476314
2016-03-05 22:31:52 +00:00
Roger A. Light
51f275bd02
Error messages for websockets init failure.
2016-01-07 21:56:16 +00:00
Roger A. Light
fca9ac84f7
Merge fixes into develop.
2016-01-06 21:10:34 +00:00
Roger A. Light
2549919413
Fix support for libwebsockets 1.22.
2015-12-21 11:32:02 +00:00
Roger A. Light
7aa653c42f
Add support for libwebsockets 1.6.
2015-12-19 01:21:17 +00:00
Roger Light
e2324ff9bb
Merge remote-tracking branch 'remotes/origin/master' into develop
...
Conflicts:
CMakeLists.txt
ChangeLog.txt
THANKS.txt
appveyor.yml
config.mk
installer/mosquitto-cygwin.nsi
installer/mosquitto.nsi
lib/messages_mosq.c
lib/messages_mosq.h
lib/mosquitto.c
lib/mosquitto.h
lib/net_mosq.c
lib/net_mosq.h
lib/send_client_mosq.c
lib/send_mosq.c
lib/socks_mosq.c
lib/will_mosq.c
src/bridge.c
src/conf.c
src/context.c
src/database.c
src/loop.c
src/mosquitto.c
src/mosquitto_broker.h
src/net.c
src/read_handle.c
src/read_handle_server.c
src/subs.c
2015-09-09 22:02:46 +01:00
Roger A. Light
201bb1a04a
Fix potential crash on libwebsockets error.
2015-08-18 23:33:55 +01:00
Roger A. Light
4c147309a4
Minimum supported libwebsockets version is now 1.3.
2015-07-08 09:07:48 +01:00
Roger A. Light
4195fde70b
Last raft of renames for the moment.
2015-05-18 09:29:22 +01:00
Roger A. Light
21946ace6c
mosquitto__log_printf -> log__printf
2015-05-18 08:53:21 +01:00
Roger A. Light
b67c90ec02
Rename internal datatypes.
2015-05-16 19:03:12 +01:00
Roger A. Light
3c703408f2
More function renaming.
2015-05-16 18:43:06 +01:00
Roger A. Light
94ef6ec7bb
Big set of function renames.
2015-05-16 15:24:24 +01:00
Roger A. Light
1744477cf8
Rename/reorganise packet functions.
2015-05-16 14:16:40 +01:00
Roger A. Light
8049c4b7f8
Simplify code around SYS statistics gathering.
2015-05-16 12:25:35 +01:00
Roger A. Light
6f2fe06f0b
[464811] Fix handling of payload lengths>4096 with websockets.
...
Thanks to Arjen van Elteren and Stephen Zeng.
Bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=464811
2015-05-06 16:40:10 -05:00
Roger A. Light
11756d24c8
Change internal funcs _foo_bar() to foo__bar().
2015-04-19 22:10:59 +01:00
Roger A. Light
35b729909c
[463241] Fix possible crash under heavy network load.
...
Thanks to Alexandre Zia.
Bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=463241
2015-03-27 01:07:48 +00:00
Roger A. Light
3a36ae843b
Fix lws 1.3 detection.
2015-02-23 15:20:23 +00:00
Roger A. Light
ff9c2087b1
Basic support for libwebsockets 1.2.x.
2015-02-16 22:02:34 +00:00
Roger A. Light
2098d6a392
Remove debug line.
2015-02-15 20:10:46 +00:00
Roger A. Light
db86809ee9
Add websockets logging options.
2015-02-13 22:57:49 +00:00
Roger A. Light
3ed5c94038
Struct optimisations.
2015-02-13 21:17:11 +00:00
Roger A. Light
e3bf10cd9a
Change the way that new clients with match client ids are dealt with.
...
This change means that the connection isn't swapped from new context to
old, which makes dealing with websockets lots easier. It does require
that clients storing a list of their subscriptons.
2014-10-12 11:38:21 +01:00
Roger A. Light
950c4ed9c6
Check return value of fseek for errors.
2014-09-23 00:45:12 +01:00
Roger A. Light
aa2e6a8d29
Fix possible NULL derefence.
2014-09-23 00:35:51 +01:00
Roger A. Light
e561b5ea08
Windows fix.
2014-09-19 10:43:14 +01:00
Roger A. Light
58a7565a2b
Check http request directories on Windows.
2014-09-17 23:14:22 +01:00
Roger A. Light
65526d2746
No need to call lws_partial_buffered() here. It is never set at the start of a callback.
2014-09-17 22:27:18 +01:00
Roger A. Light
f61a8cbf74
Get address for websockets clients.
2014-09-17 22:19:45 +01:00
Roger A. Light
91fa1c9625
Disable ipv6 websockets.
2014-09-17 21:55:02 +01:00
Roger A. Light
3d58f5ed82
Some minor memory leak fixes.
2014-09-17 21:50:08 +01:00
Roger A. Light
dd36c4b273
Don't attempt to find real path of NULL.
2014-09-15 21:43:44 +01:00
Roger A. Light
3c5ca95c81
File serving from http on *nix.
2014-09-08 23:25:02 +01:00
Roger A. Light
b84ca80052
Skeleton callback_http() function.
2014-09-08 18:39:51 +01:00
Roger A. Light
f500ff78b8
no_buffer_all_partial_tx not in latest LWS.
2014-09-08 18:24:12 +01:00
Roger A. Light
c4e7233159
Add http_dir option (not yet used).
2014-09-08 18:21:53 +01:00
Roger A. Light
6af0c236e8
Each listener requires its own copy of the protocols struct.
2014-07-28 14:14:36 +01:00
Roger A. Light
9bb336bbf3
Use do_disconnect() for websockets.
2014-07-08 23:18:11 +01:00
Roger A. Light
3fd1dc477f
Fix defects identified by Coverity.
2014-07-03 21:55:25 +01:00
Roger A. Light
5ac576f2ab
Request write callback if there is still more to send.
2014-07-03 18:48:40 +01:00
Roger A. Light
399453837d
Log websockets listeners being opened.
2014-07-03 11:32:29 +01:00
Roger A. Light
13f94f3511
More reconnect fixes.
2014-07-03 01:00:57 +01:00
Roger A. Light
d75903b0ae
Fix reconnect support for websockets.
2014-06-30 23:30:43 +01:00
Roger A. Light
bdb3e74100
More memory fixes.
2014-06-29 23:16:10 +01:00
Roger A. Light
7f18ced0b4
Close websockets connection if we are set to disconnecting.
2014-06-26 22:13:22 +01:00
Roger A. Light
3577dbf332
Add sock hash earlier to avoid crashes.
2014-06-23 23:47:48 +01:00
Roger A. Light
0fc0e13a8f
Can't access mosq after free.
2014-06-23 18:44:42 +01:00
Roger A. Light
749ea76678
Typo.
2014-06-23 18:20:32 +01:00
Roger A. Light
cc33a6e5af
Do proper cleanup, including websockets.
2014-06-23 18:18:29 +01:00
Roger A. Light
9a9dba6cd5
Support for mqttv3.1 subprotocol string.
2014-06-20 10:52:10 +01:00
Roger A. Light
c8a0786dea
TLS websockets support.
2014-06-03 02:10:55 +01:00
Roger A. Light
1984e2e37d
v3.1.1 requires websockets protocol to be mqtt.
2014-05-31 21:24:16 +01:00
Roger A. Light
7d197563bc
Fix for non-lws compilation.
2014-05-26 19:16:59 +01:00
Roger A. Light
58891769c1
Quicker to return here.
2014-05-18 22:45:09 +01:00
Roger A. Light
5ca13a82f9
No need for pthreads in broker code.
2014-05-18 22:44:02 +01:00
Roger A. Light
50f9b6bd7a
Enable partial writes for mqtt websockets.
2014-05-18 22:41:22 +01:00
Roger A. Light
9ea161f90e
Return success on libwebsocket_write==0.
2014-05-18 20:54:44 +01:00
Roger A. Light
4bb7a45b71
Crude, hard coded websockets support. No TLS.
2014-05-06 10:47:00 +01:00