-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
wip #1
Conversation
…ent origin. Pdfs will be rendered from attachments.dobt.co, and that iframe will be embedded in screendoor.dobt.co.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks awesome. No changes from me.
var FILE_ORIGIN_WHITELIST = [ | ||
'https://screendoor.dobt.dev', | ||
'https://dobt-screendoor-staging.s3.amazonaws.com', | ||
'https://dobt-screendoor.s3.amazonaws.com' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It'd be pretty cool to just include this in production and the previous line in dev/staging, but definitely not necessary. I'm not sure how we'd even do that well if this is sitting in a separate gem, though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I decided to avoid dealing with injecting configuration into this file. The less we change this file, the easier it will be to pull in upstream updates from the pdf.js repo.
Changes
HOSTED_VIEWER_ORIGINS
whitelist.PdfjsViewer::ApplicationController
toPdfjsViewer::PdfApplicationController
to prevent namespace collisions with our main app's ApplicationControllerX-Frame-Options
andContent-Security-Policy
headers