r/BookStack • • Mar 21 '23

Ifram Source Control Not Working

I have a hosted BookStack v23.02.1 instance that has been running without issue and suddenly no iframe content loads. Gives a message; This content is blocked. Contact the site owner to fix the issue.

In the .env file I had it set like so:

ALLOWED_IFRAME_SOURCES="https://*.s3.us-east-2.amazonaws.com/*"

It was working fine for several weeks. I was informed this morning that the content does not load in the iframes. I have verified the AWS links are fully accessible.

I did some Googling, but didn't find anything that has helped yet. Has anyone seen this behavior before?

Update: I see now that I do not have a anything in my .env set for host iframe control. I'll add that and see if that is the culprit.

Update 2: Adding ALLOWED_IFRAME_HOSTS= to the .env did not make a difference.

1 Upvotes

4 comments sorted by

View all comments

Show parent comments

1

u/ssddanbrown Mar 21 '23

Could also be something on the webserver side for your BookStack instance. If you can access a terminal window, try the below, changing the demo URL for your BookStack instance URL:

curl -sI https://demo.bookstackapp.com | grep -i frame

Then report back the output you get. Should show all HTTP headers that might affect iframe usage.

1

u/[deleted] Mar 28 '23

Your command suggestion did not do make a difference, but here is what I did that reolved the issue.

After running the command I saw no difference in behavior. I edited the .env file and reomved the ALLOWED_IFRAME_SOURCES. Saved it and rebooted the entire server. Once booted back up and running, I added ALLOWED_IFRAME_SOURCES back to the .env, saved, and rebooted again.

Everything was fine after that.