Commit graph

221 commits

Author SHA1 Message Date
Henry Castro
79bd9e42cb wsd: proxy: add ProxyRequestHandler files
Change-Id: Ic61f70316e921ba3cb988a3b0f8f8d2c7df89cc6
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-06-27 16:04:32 +01:00
Michael Meeks
47275c6f9e This should do something cooler.
Change-Id: I90d6028c91e88034b48ab91de7429ebde5ba5c25
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2022-05-10 11:48:33 +01:00
Ashod Nakashian
96adaa15d1 wsd: kill coolwsd_fuzzer
coolwsd_fuzzer predates actual fuzzing
with libfuzzer and is currently unsused.

Change-Id: Id095b165943ba14dbf525ddc607ad329f5d952d4
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-04-20 07:12:03 -04:00
Ashod Nakashian
827d9518c0 wsd: make: build the fuzzer binaries only configured with fuzzing
This reduces the build time significantly while also
minimizing the disk-space requirements for builds.

When configured with --enable-fuzzers the fuzzing
target binaries are built.

Change-Id: Ia8560d876f548d04ac085503e55a3a5dca90f590
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-04-20 07:12:03 -04:00
Ashod Nakashian
b34de7fad1 wsd: move STATE_ENUM to common/StateEnum.hpp
With some minor modifications.

Change-Id: I5bc06bd96bbf201ccaee87170d052b4ad2a6c778
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-04-06 18:33:45 -04:00
Rash419
31d8822758 wsd: cleanup: moved all parsing related static methods and containers to HostUtil.cpp
Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: I8555522c6216f893b90ba4c27747314830f7abd2
2022-03-29 12:18:31 +02:00
Ashod Nakashian
1022a7e78e Revert "wsd: exclude deprecated openssl API"
Apparently this breaks the build on at least
CentOS. Reverting for now.

This reverts commit 23f02b8929.

Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
Change-Id: Ie8f00bbc53a63098b473d625846c0b6fd4e074bd
2022-03-22 08:41:59 +01:00
Ashod Nakashian
23f02b8929 wsd: exclude deprecated openssl API
There are no deprecated API currently in use,
but that is a moving target as we upgrade openssl.
This prevents any accidental use of deprecated API
and will reveal any deprecated API used in any
particular build.

Change-Id: I969f7f7c4efe163d4704dea9aab45c09550baa40
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-03-21 08:57:41 +00:00
Michael Meeks
42f565faf7 add $ make stress
Change-Id: I7da764b711f1a143ee67ef7a2f48fc34e3d17487
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2022-03-04 10:06:33 +00:00
Michael Meeks
96b15bd704 Count and report on various internal exceptions.
An initial set of seven of these, easy to add more as/when needed.

Change-Id: I6c65e052d00f9eaa10adee3c9464043e4c594848
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2022-02-18 13:51:41 +00:00
Ashod Nakashian
4fcd07b172 make: silence chmod failure on missing path
Change-Id: I38d302377a26f2ebe4a734b5f16286613e762891
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-17 18:52:48 -05:00
Ashod Nakashian
3d04a857bd wsd: test: improved and simplify test logging
Build-time unit-test output is now only
displayed when the test fails. This is to
reduce noise while building when not helpful.

Change-Id: I273d97dae192a24e9a1ae9f662b0fcd7ff555b75
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-17 18:52:48 -05:00
Ashod Nakashian
203a58f6d8 wsd: test: add SaveOnExit test
Refactor UnitWOPIDocumentConflict.cpp into
WOPIUploadConflictCommon.hpp and reuse for both
DocumentConflict and SaveOnExit tests.

Change-Id: I54ec1e37e5e9c6298b12a2b2e596363683fb2e34
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-08 20:46:01 -05:00
Aron Budea
c6155a3513 coolconfig: Add config migration tool
Usage:
coolconfig migrateconfig [--old-config-file=<path>]
  [--config-file=<path>] [--write]

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: I44e16bd07588887e01732b430e4c6e368a034cd1
2022-01-10 20:11:26 +01:00
Jan Holesovsky
dbe05b2d48 Cleanup the old binaries
Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Change-Id: I16375c3d1c55cf7bda690a3c71dd5c996cd8be5a
2021-11-19 21:16:32 +01:00
Andras Timar
f07ff8c7e0 rename: remaining lool->cool changes
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ib7d4e804bebe52dead8d53b0e0bbaed0f08bf3d0
2021-11-18 14:14:11 +01:00
Andras Timar
504c05df3b rename: loolwsd-systemplate-setup -> coolwsd-systemplate-setup
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I699db87f94f9080909c2ca783e04ad8b4dd98025
2021-11-17 22:10:58 +01:00
Andras Timar
bf5bce7669 rename: loolwsd-generate-proof-key -> coolwsd-generate-proof-key
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I3aa30ce4e5f6df2068fa2e0788034e83cb0ae26b
2021-11-17 22:06:34 +01:00
Andras Timar
26d71a293a rename: remove old man files, add coolwsd man file, and create compat loolwsd symlink
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I4171e2d2825924cf73da692e743f2041a546b1a9
2021-11-17 22:02:46 +01:00
Mert Tumer
f32715a7bb rename: loolconvert -> coolconvert
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I3283cb0d222fbdf1edb09b549ae7945d6370c289
2021-11-17 21:51:05 +01:00
Mert Tumer
b59fbe8d4c rename: loolmap -> coolmap
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I3136305d5733c5c7a886baa230fd4c1e1401b734
2021-11-17 21:51:05 +01:00
Mert Tumer
c9a4d2f6f3 rename: loolmount -> coolmount
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ic025c5a76c6f27cdf1a6267f24cf8052733f1f24
2021-11-17 21:51:05 +01:00
Mert Tumer
5ebabf9f58 rename: loolwsd -> coolwsd only binary
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ia44f7f96bcad7200031ad87f6a6fdd3e361f2808
2021-11-17 18:08:19 +03:00
Andras Timar
9a88a95097 --disable-lool-user-checking was renamed to --disable-cool-user-checking at some places, now replace it everywhere
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I881f8b7adfbb396da8beb07c4d0300a153ecd304
2021-11-17 09:56:09 +01:00
Mert Tumer
81f61c8073 rename: loolforkit -> coolforkit
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I1de688dce4b068bff35451604486b72ecc8c91d4
2021-11-16 21:02:24 +01:00
Andras Timar
cde4d9322e add compatibility symlink 'loolconfig' for 'coolconfig'
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I4715b4469d5f11f63eff4b76651eee549000c1c2
2021-11-15 22:07:53 +01:00
Mert Tumer
78ccaa845e rename: loolconfig -> coolconfig
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ied23cb46a668f754931fc125745b674b546a0195
2021-11-15 22:07:53 +01:00
Jan Holesovsky
74d601920e Remove even the loleaflet/ dir if it is around
Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Change-Id: Ib264307672ea3fa351a1540fd3f4a6fafdd87d5a
2021-11-10 17:18:56 +01:00
Henry Castro
e3ebcb8f09 makefile: rename loleaflet -> browser
Change-Id: Iaaa33e3da68995e3d20ade69e7c70eaf27b32500
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-11-10 17:18:56 +01:00
Henry Castro
e0fe47be5f rename loleaflet.html -> cool.html
Change-Id: Iaa28f1269f8192755ec323396ae4ff054529f412
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-11-10 17:18:56 +01:00
Pranam Lashkari
f84df1161c quarantine: create hard links for quarantining when file is saved
number of versions to maintain per file can be specified in loolwsd.xml
on exceeding specified quarantine size oldest file(s) is deleted

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I3ca55b9ab29a82988f19fe0acd43e0fae2c2a423
2021-11-01 17:21:51 +02:00
Pranam Lashkari
f02a0a1447 freemium: renamed Freemium namespace to CommandControl
also renamed freemium files accordingly

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Id33b8a1d1a2a8725bfa6e7b7c562430ea126993c
2021-10-21 12:28:13 +03:00
Michael Meeks
b043b6213d Move LOOLWebSocket into test/ - where it can be slowly removed.
Change-Id: I388690261d323377648a1502b927e73f862ad802
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-10-11 13:40:20 +01:00
Andras Timar
ab2af84665 Fix Lintian warnings related to man pages
W: loolwsd: bad-whatis-entry usr/share/man/man1/loolforkit.1.gz
W: loolwsd: bad-whatis-entry usr/share/man/man1/loolwsd-generate-proof-key.1.gz
W: loolwsd: bad-whatis-entry usr/share/man/man1/loolwsd-systemplate-setup.1.gz
W: loolwsd: no-manual-page usr/bin/loolmount
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ieb7d2f92076d4d4b6b13bfc3ceb990ff3d8db78e
2021-09-29 21:34:41 +02:00
Andras Timar
30ef4a62d5 fix Lintian errors: binary-or-shlib-defines-rpath
E: loolwsd: binary-or-shlib-defines-rpath usr/bin/loolconvert /snap/loolwsd/current/usr/lib
E: loolwsd: binary-or-shlib-defines-rpath usr/bin/loolconvert /opt/poco/lib

These RPATHs are not needed when we statically link poco, as we do with production
packages.

Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I5050fe1f1925937388793d443020fdc6a14ec97d
2021-09-25 19:04:59 +02:00
Andras Timar
dad92dee25 remove EULA from source code
... in order to avoid confusion. Binaries that Collabora compile, and
distribute are under a EULA. Source code is not.

Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I34c7e089a100b43e6b9c69ee566736a9ae0cb93c
2021-09-23 18:35:52 +02:00
Michael Meeks
860290df2a trace: add make run-trace and clean some duplication.
Change-Id: I912be9aa603125e6fe3a6de234bc4647f0ae2893
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-09-10 22:45:29 +01:00
Michael Meeks
9f4ee5d450 stress: start to implement based on SocketPoll.
Change-Id: I6fba41c826ab70b1f653f6511dac32f10f998259
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-08-17 19:19:46 +01:00
Pranam Lashkari
e02e1df76d Introduce Freemium options
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ib6b68ff74839cf84f2d8c8cfb7d380be9209f923
2021-07-20 14:41:18 +05:30
Michael Meeks
1c2bbced33 systemplate: ensure we have write access to directories before cleaning.
Some of the folders we setup from the system are:

dr-xr-xr-x 1 michael users 2824 Jun  9 21:05 systemplate/usr/share/fonts/

before adjustment, and resist removal.

Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
Change-Id: I8e5a96264b98d8091b205f7469bc46c401f47ab1
2021-07-16 19:25:44 +01:00
Tor Lillqvist
64675d2926 Add ProfileZone to encodeSubBufferToPNG
Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I7363ea929ba703ce34a5c2411687f120ac5ba59e
2021-06-22 16:43:40 +03:00
Tor Lillqvist
d6569159b7 Output a Trace Event metadata event identifying each named thread
Move the generic dummy implementation of
TraceEvent::emitOneRecording() to a source file of its own. (That is
the one which is used in test and tool executables.)

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I81cab07e5a6852b42d278a5446c13c3825cf546e
2021-06-21 12:43:17 +03:00
Tor Lillqvist
8cef48a0fa Introduce a generic TraceEvent class and instant events here, too
Modelled on how it is done in core. ProfileZone is derived from
NamedEvent which is derived from TraceEvent. Here we don't keep any
separate ProfileZone.hpp, though.

This was needed to introduce generation of "instant" events here, too.

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I6583134e96001641c50339deb4197fca6ab7d5d5
2021-06-02 09:04:21 +03:00
Henry Castro
adbe58bded parallel npm installation
npm installation is taking too long,
it is preferable to process in parallel
while compiling some c++ source files.

Change-Id: Ie04726805723d94227806fb8b30c39909b84cb0f
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-05-27 16:27:14 -04:00
Tor Lillqvist
9c6b74ad08 Use a loolwsd.xml setting instead of --enable-trace-event-logging
That is our convention, and this also avoids a global variable in the
kit process.

Change-Id: I37d2d53aa7eb24f9848fa8ef98bc57d75db90d13
Signed-off-by: Tor Lillqvist <tml@collabora.com>
2021-05-19 13:33:26 +03:00
Michael Meeks
ded537eed5 make run should log to the console in product mode.
We don't have permission for /var/log/loolwsd.log typically.

Change-Id: I37c04bfba25c4c8241b2d92d77d93e5a3b662d82
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-05-15 17:40:09 +01:00
Tor Lillqvist
9da0145280 Add an --enable-trace-event-logging option to loolwsd
It enables turning Trace Event recording on (and off again). The
option is passed down to the client through loleaflet.html, and to the
KIT processes. If the option is not used, the new JS functions that
send trace events to the server turn into no-ops to avoid wasting
bandwidth.

It is always on in a "make run".

Change-Id: Iafe1919ccba7c376137d3e0568b857e20780bbc8
Signed-off-by: Tor Lillqvist <tml@collabora.com>
2021-05-10 12:39:07 +03:00
Ashod Nakashian
3e500107c4 wsd: make: add new files
Change-Id: If0ad0c841658c7ab035f267ab8f0b031c6b71da9
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2021-05-06 22:14:51 -04:00
Tor Lillqvist
e7ed4e11cf Add a ProfileZone implementation here, too
Compiled but not yet used.

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I3b85696ca6076e42d16e710b49bfd37bac342ec8
Signed-off-by: Tor Lillqvist <tml@collabora.com>
2021-05-03 16:09:35 +03:00
Miklos Vajna
c66f1d181c make dist: add missing test/HttpTestServer.hpp
Signed-off-by: Miklos Vajna <vmiklos@collabora.com>
Change-Id: Ib5bc2be18421e02e9c00bb1c61e41c4c93f2deb5
2021-04-30 10:38:09 +02:00