-
Notifications
You must be signed in to change notification settings - Fork 464
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
[PATCH] dvipdf doesnot pass -R flag to dvips #2027
Comments
CUPS.org User: htl10 Security not be by-passed at the system level for user-convenience. On a per-user set-up, you can achieve the same effect without ln -s ../fig/GaspardY.eps and modify your latex file to read from current directory instead of |
CUPS.org User: pieleric Yes, I agree with you, probably the correct way is to create symlinks and modify the latex documents. (in my case it's just a bit more complex because there are hundreds of documents written by different people which suddently don't compile anymore ;-) ) Still, I do beleive that if dvips has a "-R0" option, dvipdf should also be able to support the same option. From a user point of view, dvipdf is exactly like dvips but generates PDF files instead of PS files. It's very strange that some DVI files can be compiled with dvips (using -R0) while cannot be compiled with dvipdf at all. If the user knows that he can trust the DVI, then there is no need of forcing the security options. |
CUPS.org User: htl10 There are two other ways of achieving what you want: dvips options I just really do not see why a change that you want at the sacrifice Can you explain why this change is a good idea for every cups user worldwide? |
CUPS.org User: pieleric In this patch I'm not proposing to reduce security: by default the behaviour of dvipdf is unchanged. What I propose is to extend the "security model" to the same one as dvips, that is: if the user trusts the document, then he might be able to reduce the security (= have the same behaviour as older versions) by explicitely adding the flag "-R0". This allows backward compatibility while keeping the new security model by default. At least, this is the dvips behavior, if you do not beleive it is secure enough, I'd suggest to modify dvips accordingly :-) |
CUPS.org User: mike Fixed in Subversion repository. |
"dvipdf-pass-secure-option.patch": --- /usr/bin/dvipdf.bak 2006-10-15 11:38:25.000000000 +0200 Based on ps2pdfOPTIONS=""
We have to include the options twice because -I only takes effect if itappears before other options.-exec dvips -q -f "$infile" | gs $OPTIONS -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile="$outfile" $OPTIONS -c .setpdfwrite - |
Version: 8.15.3
CUPS.org User: pieleric
Hello,
dvipdf doesnot pass any flag to dvips (they are all passed to gs). However, for some documents I really need to disable the (default) secure option of dvips, aka "-R0". For instnace, some documents which I need compile use figures from directories like "../fig", with the latest dvips it's forbiden by default, so I get this kind of error:
$ dvipdf Distribute-Polyedre.dvi
dvips: Could not find figure file ../fig/GaspardY.eps; continuing
dvips: Could not find figure file ../fig/multiArchi.eps; continuing
dvips: Could not find figure file ../fig/multiplicationMatrice.eps; continuing
dvips: Could not find figure file ../fig/multiplicationMatrice.eps; continuing
In such case it's necessary to be able to pass -R flag to dvips. gs doesn't have -R option so there is no problem. Attached is a patch to dvipdf which allows passing the secure option to dvips.
The text was updated successfully, but these errors were encountered: