Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

PDFjs Security

205 views
Skip to first unread message

web

unread,
Dec 2, 2014, 7:57:54 PM12/2/14
to dev-p...@lists.mozilla.org
I've just started trying to work with PDFJS and I noticed that it can work
with password protected PDF files. Would it be possible to use code to enter
a password from a database instead of entering the password into the
password entry dialog box. In fact I would prefer not to have the password
dialog box appear at all - and just enter a password in the background.



I'm just not sure where I could "paste" in the password - so that the pdfjs
system would recognize it.



Any help or guidance would be greatly appreciated....



Thanks for your attention..



Ron Lemire

rle...@telus.net

zdenko....@gmail.com

unread,
Jan 6, 2015, 6:37:59 PM1/6/15
to mozilla-d...@lists.mozilla.org
I add to viewer.html rewritten to viewer.php new line echo 'var DEFAULT_PASSWORD = "password"; '; before use script viewer.js and in viewer.js to function open: function pdfViewOpen rewrite line var parameters = {password: password}; rewrite to var parameters = {password: DEFAULT_PASSWORD}; and it works, but i have problem with security i must find a way to decrypt used password.
0 new messages