Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using pdfkit with CSP not allowing eval() #757

Open
ehaubold opened this issue Dec 13, 2017 · 7 comments
Open

using pdfkit with CSP not allowing eval() #757

ehaubold opened this issue Dec 13, 2017 · 7 comments

Comments

@ehaubold
Copy link

Would it be possible, to make pdfkit usable with a CSP not allowing eval()? As our site handles personal data, all eval() is not allowed to be executed, rendering pdfkit unusable.

@mrudelle
Copy link

We run into the same problem here.

The unsafe evaluation comes from the devongovett/restructure package:
https://github.com/devongovett/restructure/blob/master/src/Pointer.coffee#L11.
The coffee script builds a function from a parametric variable name.

It renders PDFkit unusable with decent CSP settings that do not include 'unsafe-eval'.

@firien
Copy link

firien commented Mar 30, 2018

see foliojs/restructure#22

@sangm
Copy link

sangm commented Mar 6, 2019

Any updates on this?

@ramosbugs
Copy link

Now that foliojs/restructure#28 has been fixed and released in 2.0.0, would it be possible to update pdfkit/fontkit to use the new version without the CSP issue?

@ghost
Copy link

ghost commented Apr 24, 2020

We'd also be really keen on having this. It's preventing us from having a CSP without unsafe-eval on our sites that use AMCharts (which depends on pdfkit, which in turn depends on this)

@twistedpair
Copy link

Any update? This library cannot be used securely with modern applications.

@philipp-durrer-jarowa
Copy link

+1 this is breaking our Web application security. Do others have alternatives to pdfkit that are secure CSP header friendly?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants