Commit Graph

16 Commits (master)

Author SHA1 Message Date
Ashod Nakashian 708e4a7746 wsd: uninitialized member
Change-Id: I2eefc58eb0105999277114c70c2b17bf3a615ccd
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-04-03 14:26:28 +01:00
Ashod Nakashian ed753e16d2 wsd: use new CheckFileInfo class in RequestVettingStation
Change-Id: Iafcf965c98027fa2b5ffe4db5bd1fd5820c47f23
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-03-05 07:10:34 -05:00
Ashod Nakashian f4707aac13 wsd: split createDocBroker into createClientSession
We only need the client WebSocket when creating
a new ClientSession. As such, we can spawn the Kit,
create a new thread, and even download the document
before the said WebSocket is connected.

At this point we only refactor the createDocBroker
helper.

Change-Id: I1bb57f6f0f2e89d49266cb87f152970a47e1eecf
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-24 14:09:22 -05:00
Ashod Nakashian 84aa1a44e8 wsd: parallel load with cool.html
Support parallel CheckFileInfo upon serving
cool.html. This makes loading documents faster
from the user's perspective by parallelizing
CheckFileInfo and, later, DocBroker creation
and document downloading.

Change-Id: I838a19022517196ee2b459991a542ed9ef323e48
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-24 14:09:22 -05:00
Ashod Nakashian 789eb6fa52 wsd: make wopiInfo a member of RequestVettingStation
Change-Id: I74eaaee3a5afc30ee89d16a83f89d3f471bd1f09
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-24 14:09:22 -05:00
Ashod Nakashian 32ba3e34b5 wsd: restructure RequestVettingStation interface
This makes it easier to support even earlier use
of RequestVettingStation, when cool.html is served.

Change-Id: I206f5f593a33806c24c6ed1e126d4cae5500f405
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-24 14:09:22 -05:00
Ashod Nakashian 7570dd299c wsd: use RequestVettingStation for async loading
This replaces the synchronous loading logic
with the new asynchronous one.

Change-Id: I20fd7903cffbbd7c524d8051295113439ef75d5b
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-24 14:09:22 -05:00
Ashod Nakashian 92e52e663c wsd: support sendMessage with string literals
Change-Id: I1caaf408c424c1cb11fec6aaf9d894dac7f99f93
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-09 15:50:50 +00:00
Ashod Nakashian a449b8d229 wsd: simplify WebSocketHandler::sendErrorAndShutdown
Socket::shutdown() already does ignoreInput().

Change-Id: I75004ae881c481440d3e3cd31a96ba75ddbad22d
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-09 15:50:50 +00:00
Ashod Nakashian 3a109537ee wsd: exclude WopiStorage in mobile builds
This excludes Wopi handling (as much as possible)
from mobile builds.

Change-Id: I4abb00f02e77b5d89d56ced49ce19a37ae93c13e
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-02-09 15:50:50 +00:00
Ashod Nakashian 8358fc2293 wsd: rvs: refactor send error and shutdown socket
Change-Id: I0a32dec86e3e9b9b5989da40a25af90ba9b82095
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-01-18 18:59:18 +00:00
Ashod Nakashian 6fe96901c9 wsd: rvs: support redirection of CheckFileInfo
CheckFileInfo requests can now redirect
to a new URL.

Change-Id: I7579ac37235b1a2ac1d7091366f0046cf889ce15
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-01-18 18:59:18 +00:00
Ashod Nakashian 1f3441cc42 wsd: rvs: refactor CheckFileInfo
This breaks the CheckFileInfo fetching
code in RVS into its own function to
allow for redirection.

Change-Id: I8bfa3a71705c77af8f6e75ed1af75e710767cf19
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-01-18 18:59:18 +00:00
Ashod Nakashian 1164cb90fa wsd: rvs: pass wopiFileInfo around
Change-Id: I52ef794d758a06d66cb91cc7bdb272bd2167b05c
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-01-18 18:59:18 +00:00
Ashod Nakashian 91029b0efd wsd: rvs: refactor createDocBroker
Change-Id: Iaff50d505aa054a1f13c71a60a247feaede54172
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-01-18 18:59:18 +00:00
Ashod Nakashian 5c5c4559f9 wsd: rvs: add RequestVettingStation
RequestVettingStation is designed to
vet requests before allocating further
resources. Specifically, it is to be
used to verify whether the resource
requested exists and whether or not
the request is allowed and authenticated.

All of this is designed to be done
asynchronously, for performance reasons.

Change-Id: I399fa7bc91741ffee065a6d41acca0756eedc939
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2024-01-18 18:59:18 +00:00