Privatebin over plain HTTP, missing WebAssembly MIME-Types or missing SELinux write permissions not working #1805
-
Describe the problem/questionCould this be an issue? I see zlib library being loaded in Browser, but I still get the infamous message:
I searched that string project-wide and could not find it. Did you use the FAQ section?
What you did?
What happensInfobox with non-supported WebAssembly What should happenPrivatebin should load as usual Additional informationNo response Server addressNo response Server OSRHEL WebserverNginx with PHP-FPM PrivateBin version2.0.3 Browser and versionFirefox Local operating system and versionWin11 Issue reproducibilityNo, I cannot reproduce it on https://privatebin.net. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 6 replies
-
|
Check the browsers network tab in the developer utilities ([F12]) what gets blocked. More likely is that your webserver isn't delivering the WASM file with the correct mime type. The other issue that may arise in such scenarios is that your connection is not considered "secure" by the browser, if it's http-only and not using a localhost host name or an IP on a local loopback interface and therefore the webcrypt API gets disabled. |
Beta Was this translation helpful? Give feedback.
-
|
Seeing this is
|
Beta Was this translation helpful? Give feedback.
-
Solution: Fix SELinux PermissionsChange context — Set the SELinux security context on files/directorieschcon -Rv -t httpd_sys_rw_content_t /var/www/privatebinBreaking down the flags: SELinux contexts have four parts (user:role:type:level), and type is the one that matters most for access control. The common httpd types:
Verify permissions
Make changes permanent
semanage fcontext -a -t httpd_sys_rw_content_t "/var/www/privatebin(/.*)?"
restorecon -R /var/www/privatebin |
Beta Was this translation helpful? Give feedback.
Solution: Fix SELinux Permissions
Change context — Set the SELinux security context on files/directories
Breaking down the flags:
-R= Recursive-t= Type of SELinux contextSELinux contexts have four parts (user:role:type:level), and type is the one that matters most for access control.
httpd_sys_rw_content_tspecifically tells SELinux that web server processes are allowed to read and write this content.The common httpd types:
httpd_sys_content_t— web server can read onlyhttpd_sys_rw_content_t— web server can read and writehttpd_sys_script_exec_t— web server can execute these as scriptsVerify permissions
ls -Zd /var/www/priva…