Can GhostScript run in Medium Trust

Posted by SkippyFire on Stack Overflow See other posts from Stack Overflow or by SkippyFire
Published on 2010-04-23T14:12:12Z Indexed on 2010/04/23 14:13 UTC
Read the original article Hit count: 621

I am using GhostScript to generate some thumbnails of PDF pages in an ASP.NET application. I have it wrapped in this library called GhostScriptSharp that just uses DllImport to call methods in the GhostScript DLL.

It looks like this wont work on a medium trust hosting environment, either because of the fact that it is calling unmanaged code, or that it looks like the library is creating files all over the place (outside my virtual directory).

I ran Process Monitor and saw it trying to Read, QueryNameInformationFile, CreateFile and QueryStandardInformationFile in places like:

C:\WINDOWS\system32\Halftone\Default or C:\gs\gs8.63\lib\Halftone\Default or C:\gs\font\Halftone\Default

Any ideas about whether this is "fixable" to run in medium trust?

If I can't use GhostScript, is there another free/open source library that WILL work in Medium trust?

© Stack Overflow or respective owner

Related posts about ghostscript

Related posts about medium-trust