Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(headers): only add Cross-Origin-Opener-Policy and Cross-Origin-Embedder-Policy on richdocuments #4207

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tcitworld
Copy link
Member

Summary

Otherwise it's being added to absolutely all requests, creating issues in other apps.

However, since I don't know how to test this and why these headers are required, I'm not sure if this still works for public sharing pages for instance.

Ref. #3258 (comment)

TODO

Checklist

  • Code is properly formatted
  • Sign-off message is added to all commits
  • Documentation (manuals or wiki) has been updated or is not required

…bedder-Policy on richdocuments

Otherwise it's being added to absolutely all requests, creating issues in other apps

Closes #4103

Signed-off-by: Thomas Citharel <[email protected]>
@tcitworld tcitworld added bug Something isn't working 3. to review Ready to be reviewed labels Nov 7, 2024
@tcitworld tcitworld requested review from juliusknorr, a team and grnd-alt and removed request for a team November 7, 2024 10:20
@@ -24,7 +25,7 @@ public function handle(Event $event): void {
return;
}

if ($this->capabilitiesService->hasWASMSupport()) {
if ($this->capabilitiesService->hasWASMSupport() && $event->getResponse()->getApp() === Application::APPNAME) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As far as I remember this will not work as we require the headers to be set e.g. on the files app as it is the one that iframes Collabora directly.

@caolanm Since you worked on that, can you provide some steps how to test and verify that the wasm support still fully works with that change?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If not, would it be acceptable to hardcode 'files' (and probably 'files_sharing') as well here?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Depends, in theory collabora could be loaded by any app, e.g. talk when using the viewer to show a file shared to a conversation.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though it is arguable what benefit the wasm experimental feature has there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Ready to be reviewed bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Nextcloud Office: Cross-Origin-Opener-Policy breaks other nextcloud apps
2 participants