[GH-ISSUE #222] WebAssembly: "Invalid" content-type for Firefox #123

Closed
opened 2026-02-26 09:36:39 +03:00 by kerem · 3 comments
Owner

Originally created by @aleho on GitHub (Feb 5, 2020).
Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/222

Do you want to request a feature or report a bug?
Bug.

What is the current behavior?
Head content-type is set to application/octet-stream. Firefox expects application/wasm and refuses to load the .wasm file. Code does fallback.

curl -I 'https://onlyoffice/5.4.2-46//sdkjs/common/libfont/wasm/fonts.wasm'
HTTP/2 200 
server: nginx
date: Tue, 04 Feb 2020 21:51:39 GMT
content-type: application/octet-stream
content-length: 641920
last-modified: Fri, 22 Nov 2019 16:46:51 GMT
vary: Accept-Encoding
etag: "5dd810fb-9cb80"
expires: Wed, 03 Feb 2021 21:51:39 GMT
cache-control: max-age=31536000
accept-ranges: bytes

Firefox reports:

wasm streaming compile failed: TypeError: Response has unsupported MIME type
falling back to ArrayBuffer instantiation

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.
Just fire up the Firefox console and look at its output. Or use the curl command above.

What is the expected behavior?
Set content-type: application/wasm.

Did this work in previous versions of DocumentServer?
Unkown.

DocumentServer Docker tag:
5.4.2.46 (docker latest).

Host Operating System:
Linux.

Browser version:
Firefox 72.0.2.

Originally created by @aleho on GitHub (Feb 5, 2020). Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/222 **Do you want to request a *feature* or report a *bug*?** Bug. **What is the current behavior?** Head `content-type` is set to `application/octet-stream`. Firefox expects `application/wasm` and refuses to load the `.wasm` file. Code does fallback. ``` curl -I 'https://onlyoffice/5.4.2-46//sdkjs/common/libfont/wasm/fonts.wasm' HTTP/2 200 server: nginx date: Tue, 04 Feb 2020 21:51:39 GMT content-type: application/octet-stream content-length: 641920 last-modified: Fri, 22 Nov 2019 16:46:51 GMT vary: Accept-Encoding etag: "5dd810fb-9cb80" expires: Wed, 03 Feb 2021 21:51:39 GMT cache-control: max-age=31536000 accept-ranges: bytes ``` Firefox reports: ``` wasm streaming compile failed: TypeError: Response has unsupported MIME type falling back to ArrayBuffer instantiation ``` **If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.** Just fire up the Firefox console and look at its output. Or use the curl command above. **What is the expected behavior?** Set `content-type: application/wasm`. **Did this work in previous versions of DocumentServer?** Unkown. **DocumentServer Docker tag:** 5.4.2.46 (docker latest). **Host Operating System:** Linux. **Browser version:** Firefox 72.0.2.
kerem 2026-02-26 09:36:39 +03:00
Author
Owner

@rugk commented on GitHub (Jun 20, 2021):

So sad, this issue is well-lnown, also in our PrivateBin project: https://github.com/PrivateBin/PrivateBin/issues/814 (more links and blockers there)

<!-- gh-comment-id:864525094 --> @rugk commented on GitHub (Jun 20, 2021): So sad, [this issue is well-lnown](https://stackoverflow.com/a/52732080/5008962), also in our PrivateBin project: https://github.com/PrivateBin/PrivateBin/issues/814 (more links and blockers there)
Author
Owner

@rugk commented on GitHub (Jun 20, 2021):

https://github.com/ONLYOFFICE/Docker-DocumentServer/pull/223#issuecomment-593347704 says this is already fixed? So close this issue here?

<!-- gh-comment-id:864525148 --> @rugk commented on GitHub (Jun 20, 2021): https://github.com/ONLYOFFICE/Docker-DocumentServer/pull/223#issuecomment-593347704 says this is already fixed? So close this issue here?
Author
Owner

@ShockwaveNN commented on GitHub (Jun 21, 2021):

Yeah, thanks for noticing, seems we forgot to close it

<!-- gh-comment-id:864816906 --> @ShockwaveNN commented on GitHub (Jun 21, 2021): Yeah, thanks for noticing, seems we forgot to close it
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Docker-DocumentServer-ONLYOFFICE#123
No description provided.