Bookstack: Code Editor not working anymore

Created on 5 Mar 2020  Â·  9Comments  Â·  Source: BookStackApp/BookStack

Describe the bug
Using the Code Editor is not working anymore.
The links for the script language selection are doing nothing and saving code using the modal button does also nothing.

Steps To Reproduce
Steps to reproduce the behavior:

  1. create a new page
  2. Click on Format > Code Editor
  3. try to choose a script language
  4. add some code
  5. try to save

Your Configuration (please complete the following information):

  • Exact BookStack Version (Found in settings): v0.28.2
  • PHP Version: PHP 7.3.7-1+0~20190710.40+debian10~1.gbp032aec
  • Hosting Method (Nginx/Apache/Docker): Apache on Debian Buster

Additional context
Console Log Errors when opening an existing Page or adding a new page in Bookstack:
image

Most helpful comment

OOOH my god... i got'it, finally...

We have a Firewall (Sophos) which is also running virtual webservers (proxy) for DMZ Connections from the Web, and there an admin changed 2 options...

image

Deactivating these 2 options and everything works again as expected.

oooh man... sry ^^ and thanks for your help and tips.

All 9 comments

Hi @Wachert,
Thanks for reporting that error. Seems to appear when there are no templates in the system. Easily fixed.

In regards to the code editor issue, I'm unable to replicate this as of yet.

  1. Are you able to replicate this issue on the demo site?
  2. What browser are you using to access BookStack?
  3. Have you made any customisations to your BookStack instance?

1.) nope, on the demo site its working
2.) Chrome, Firefox, Vivaldi, Edge (we get this error on every browser, on different PCs)
3) nope not really, no plugins/mods, we tried updating to 0.28.2 which worked, but didn't fix the bug

We have updated using the release branch from git.

I installed bookstack yesterday and was using the code blocks with no issues.
Not complete but from my head:
PHP 7.2
Firefox
A looot of plugins for firefox.
Hosted on nginx.

Which language did you choose in the editor @Wachert ? I only used shell and nothing.

I have already problems clicking any language because nothing happens ;)

I also checked different browsers in case of maybe a browser plugin being the problem, but nope... even fresh browser dont work.

Maybe the installation has any problem but while the update, i got no errors.

I also deleted the cache once again using

php artisan cache:clear
php artisan view:clear

image

What i also did... rename the doc root Folder, create a blank one, reinstall bookstack, copy htaccess and env file into new installation and test again, but this also did not help.

Next thing i'll try: Backup the VM and update the VM and all packages.

OK i tried it but it also didn't help hm...

Darn, You definitely don't have any thing in the "Custom HTML Head Content" option in the settings area?

OOOH my god... i got'it, finally...

We have a Firewall (Sophos) which is also running virtual webservers (proxy) for DMZ Connections from the Web, and there an admin changed 2 options...

image

Deactivating these 2 options and everything works again as expected.

oooh man... sry ^^ and thanks for your help and tips.

@Wachert No problem, Happy to hear you found the cause!

I will further add that as soon as a Sophos UTM Firewall profile is loaded, it will stop working as well, as soon as static URL hardening is activated – even if there is an exceptions in place to skip the subnet the request is coming from.

@Wachert how do you use WAF for the internal interface only? Do you have some kind of special NAT rule in place & how does it work via VPN? I tried protecting my Bootstack using URL hardening and subnet exceptions.

Was this page helpful?
0 / 5 - 0 ratings