Age | Commit message (Collapse) | Author |
|
Stray line, presumably a merge edit failure.
|
|
|
|
|
|
|
|
|
|
If Bitmap.lockPixels fails with an allocation error, scavenge in
the store.
|
|
If a call to Bitmap_lockPixels() fails, then previously we
would have continued on blindly and tried to use it anyway.
Now, spot failures and return so we get a java exception.
|
|
|
|
_WIN32 is always defined on windows (it means the WinAPI is available).
_WIN64 is also defined on 64-bit targets.
This means the test for defined(_WIN32) || defined(_WIN64) is redundant,
since if _WIN64 is defined, then _WIN32 is always also defined.
MSC_VER is only defined for MSVC, so split the ifdef sections in
include/fitz/system.h into separate MSVC and WIN32 parts so that
we can build with MinGW and other non-MSVC compilers on windows.
|
|
Always recurse for the native library, so that it will be rebuilt if
the sources change.
|
|
Filter out Link and Popup annotations.
Links are not comments, popup annotations are auxiliary information
for other annotations, so neither of these types should be present
in our list of annotations, but all other annotations should be there,
whether they have appearance streams or not.
Ensure has_new_ap is zero when first loaded, and changed if either
the active AP object is changed or the current AP content stream
is updated.
|
|
Use KOI8-U for Cyrillic, and ISO 8859-7 for Greek.
Use with 'mutool create' using an extra argument to the %%Font directive:
%%Font TmRmC Times-Roman Cyrillic
BT
/TmRmC 16 Tf 10 10 Td
<fa c4 d2 c1 d7 d3 d4 d7 d5 ca d4 c5 21> Tj
ET
The alternatives are "Latin", "Greek", and "Cyrillic".
|
|
Create a non-embedded CJK font using UTF-16 encoding. This can be used
in mutool create like so:
%%CJKFont Ming GB1
BT
/Ming 10 Tf
100 100 Td
<4F60 597D> Tj
ET
|
|
|
|
|
|
|
|
|
|
|
|
Just use the pdf_obj directly.
Revise ap_iteration and split annot->dirty into separate flags.
One flag for needs_new_ap, and one for has_new_ap (to be used by
clients who may have cached a rendered annotation).
|
|
|
|
|
|
|
|
Use the MUPDF_EXTRA_CFLAGS, CPPFLAGS, LDLIBS, and LDFLAGS variables.
|
|
Adds a requirement on the caller to free the returned strings.
|
|
|
|
|
|
|
|
Remove direct inclusion of pkcs7 source from the mupdf project and
create a separate libpkcs7 project with others as dependants
|
|
Add a version of pdf_check_signature function that reports no support,
for builds without openssl. This allows the removal of ifdefs from the
apps.
|
|
|
|
The mupdf build included an implimentation of the pkcs7 functions that
are needed for signing documents and verifying signatures, the
implementation being either an openssl-based one, or a stub that returned
errors. This commit removes the pkcs7 functions from the main mupdf
library.
For the sake of verification, there wasn't really a need for the pkcs7
functions to be part of mupdf. It was only the checking function that used
them. The checking function is now provided as a helper, outside of the
main build. The openssl-based pkcs7 functions area also supplied as a
helper. Users wishing to verify signatures can either use the checking
function directly, or use the source on which to base their own.
Document signing requires more integration between mupdf and pkcs7
because part of the process is performed at time of signing and part when
saving the document. Mupdf already had a pdf_pkcs7_signer object that
kept information between the two phases. That object has now been extended
to include the pkcs7 functions involved in signing, and the signing
function now requires such an object, rather than a file path to a
certificate. The openssl-based pkcs7 helper provides a function that, given
the path to a certificate, will return a pdf_pkcs7_signer object.
The intention is that different implementations can be produced for
different platforms, based on cryptographic routines built into the
operationg system. In each case, for the sake of document signing, the
routines would be wrapped up as a pdf_pkcs7_signer object.
|
|
Previously, pdf-pkcs7.c contained mishmash of functions required
for creating and checking signatures, with no separation between
the parts relating to pdf and those relating to pkcs7. This
commit introduces pdf_signature.c which contains the pdf
specifics, leaving pdf-pkcs7.c to be purely pkcs7 functions.
This should more easily allow the use of pkcs7 solutions other
than openssl. The pkcs7 api is declared in pdf-pkcs7.h. It is
entirely free of mupdf specifics, other than using an fz_stream
to specify the bytes to be hashed.
|
|
|
|
|
|
|
|
|
|
This will allow us to read and write documents using I/O written
in Java, exposed by SeekableInputStream and SeekableOutputStream.
We supply an example FileStream which implements seekable streams
backed by a RandomAccessFile.
|
|
Previously, signature verification worked only for file-based documents
and the file path had to be passed into the verification function.
|
|
Without deleteing it the local reference table may overflow.
|
|
|
|
|
|
|
|
This allows us to clean up memory so we can check for memory leaks.
Also fix one memory leak.
|
|
|
|
Also clarify that a copy of author/contents is returned, and that
the caller must free them.
|
|
This mirrors the existing PDFObject.asByteString().
|
|
|
|
|
|
|
|
When iterating through blocks, make sure to include
text blocks. After building the char array for a
given line, be sure to add it to the line object.
|