[jira] [Commented] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497618#comment-14497618
 ] 

Tilman Hausherr commented on PDFBOX-2756:
-

Thanks, the new hoster is OK. I was able to open the fille with PDFReader with 
both 1.8 and 2.0 versions. 
https://pdfbox.apache.org/1.8/commandline.html
However it is a huge file (24MB), which is why you couldn't attach it. So it 
takes a bit longer, I counted 9 seconds until the first image was displayed.

Displaying is slow, because the image contains type 7 shadings which are 
complex math calculations.

Questions to you:
- could you attach the text of the exception you get with 1.8 ?
- can you reproduce the effect with the command line tools?
- if not - could you attach the smallest possible servlet that reproduces the 
error on tomcat?


 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497626#comment-14497626
 ] 

Tilman Hausherr edited comment on PDFBOX-2756 at 4/16/15 6:42 AM:
--

I don't have Windows 2008/2012 at home.

Yes the command line utilities use PDDocument.load(). A possible difference is 
that your application opens the PDF from a stream, while the command utilities 
don't, they use files.

You should be able to output a stacktrace... if ex is your exception, 
ex.printStackTrace() outputs what we need.

Are you unable/forbidden to open a dos box on that server system to run the 
command line utility?


was (Author: tilman):
I don't have Windows 2008/2012 at home.

Yes the command line utilities use PDDocument.load(). A possible difference is 
that your application possibly opens the PDF from a stream, while the command 
utilities don't, they use files.

You should be able to output a stacktrace... if ex is your exception, 
ex.printStackTrace() outputs what we need.

Are you unable/forbidden to open a dos box on that server system to run the 
command line utility?

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497643#comment-14497643
 ] 

Tilman Hausherr commented on PDFBOX-2756:
-

https://pdfbox.apache.org/1.8/commandline.html

run this:

java -jar name of command line app jar PDFReader path of your PDF file

get the command line app here
https://repository.apache.org/content/groups/snapshots/org/apache/pdfbox/pdfbox-app/1.8.10-SNAPSHOT/
https://repository.apache.org/content/groups/snapshots/org/apache/pdfbox/pdfbox-app/2.0.0-SNAPSHOT/
 or build it yourself, it is in the app/target subdirectory.

Another / an additional strategy would be to build a minimal tomcat servlet 
that loads a file, and see what happens with that one.



 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread ido sarussy (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497636#comment-14497636
 ] 

ido sarussy commented on PDFBOX-2756:
-

i use a file not a stream,
i might be able to run a command line later on, since i have to get to a server 
first (my development OS is win 7)
same as for the stacktrace,
the thing is - i tried working around it so much since, so i'll have to roll 
back to get the same results,
hopefully i'll be able to do it today.

which command line would you like me to run?

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497626#comment-14497626
 ] 

Tilman Hausherr commented on PDFBOX-2756:
-

I don't have Windows 2008/2012 at home.

Yes the command line utilities use PDDocument.load(). A possible difference is 
that your application possibly opens the PDF from a stream, while the command 
utilities don't, they use files.

You should be able to output a stacktrace... if ex is your exception, 
ex.printStackTrace() outputs what we need.

Are you unable/forbidden to open a dos box on that server system to run the 
command line utility?

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread ido sarussy (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497620#comment-14497620
 ] 

ido sarussy commented on PDFBOX-2756:
-

i think think it has to do with the size of the file since i used the same load 
function on 1.5GB files..
i can't reproduce the issue on command line since it's a part of a large system 
and workflow.
and the exception the i catch is an IOException which prints nothing - blank.

did you use PDDocument.load() under pdmodel?
also - pay attention that the issue reproduces only under windows server 
2008/2012 (jre 7/8)
on win7 it works fine

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



TravisCI

2015-04-16 Thread Andreas Lehmkühler
Hi,

https://blogs.apache.org/infra/entry/apache_gains_additional_travis_ci

@John
Is there anything to move elsewehere so that we can participate?

BR
Andreas Lehmkühler

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Re: CryptoBox and ETSI PAdES Plugtest

2015-04-16 Thread Maruan Sahyoun
Hi,

 Am 16.04.2015 um 01:03 schrieb Thomas Chojecki i...@rayman2200.de:
 
 Hello,
 I've startet creating a crypto engine for pdfbox. The aim is to provide
 a highlevel api for signing and verifying pdf documents. 

great - this is a very important use case for PDFBox.

 
 The engine is called cryptobox and is splited into a 1.8.x and
 main branch. After the basic functions are ready in the 1.8.x, I will
 do a pdfbox 2.0.x port and clean up the signature interface. 
 
 The goal is to do a pdfbox reference implementation for PAdES [1] up to
 part 4 of the specification or I will go straight to the Europen Union
 Commision Decision [2]. I hope with the help of the community, we have a
 chance to reach the goal. 
 
 At the moment the code is hosted on github [3] but I will move it to the
 apache repository after the codebase reached a usable level. It is
 easier for me to prepare the code and play with it on github (less
 restrictions). 
 
 From 4 to 29 May 2015 ETSI is making a PAdES PlugTest [4], I'm already
 a participant and will try to test the cryptobox. So I first try to go
 through the specification and later port stuff like visual signatures.
 
 Maybe we can participant as Apache at such plugtests, so we can gain
 more publicity.

good idea - what would we need to participate as Apache PDFBox?

 
 
 
 I don't made much planing, but I think this roadmap could be a good
 start:
 
 - Implement pdf signatures and verification for the ISO 32000-1:2008
  specification.
 - Implement the ETSI signature specification PAdES
 (deadline is the PlugTest)
 
 - Basic signature service, maybe webservice or gui application.
 - Port the visual signature stuff that already exist and maybe start a
  table based visualisation (without the need to create pictures)
 - Port it to pdfbox 2.0.x with NonSeqParser
 - Cleanup the existing pdfbox signature code
 
 other parts that need to be done are:
 - refactor signature interface and coswriter
 - make pdf signature streamable without the dirty hooks that are needed now.
 - there where already plans to move the pdf encryption from pdfbox
  to a new module. Maybe we can move it into the cryptobox.   
 
 I don't want promise anything, so I try mainly get through the plugtest
 and show how the feedback is.
 
 If you have some ideas how the cryptobox can be improved or maybe how
 the architecture may look like to provide best usability, then
 please give me some suggestions.

I quickly scanned through the code - there are some features from Java 1.7 such 
as Objects.requireNonNull in CoreHelper.copy. As PDFBox is currently on 1.6 
this might be an issue when bringing it over.

Here are some of my initial thoughts

API wise maybe there could be a class SignatureService with sign(), certify() 
and verify() methods loading a PDDocument.

so the signing process would look something like

PDDocument doc = PDDocument.load
SignatureService sigservice = SignatureService.newInstance(doc);
sigservice.sign(SignatureOptions, OutputStream);

As for the packaging maybe it could live in org.apache.pdfbox.services.crypto 
as this would allow for additional services to be added at a later stage wo. 
having so many top level packages (services being a sample we'd need to decide 
on).

As for the general naming maybe this could be renamed to pdfbox-crypto to 
utilize the PDFBox name fully and not only the box part.  


BR
Maruan

 
 Best regards
 Thomas
 
 [1]
 http://www.etsi.org/news-events/news/324-news-release-14th-september-2009
 [2] http://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0130
 [3] https://github.com/Rayman2200/cryptobox/tree/1.8
 [4] http://xades-portal.etsi.org/pub/index.shtml
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
 For additional commands, e-mail: dev-h...@pdfbox.apache.org
 


-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



RE: api question

2015-04-16 Thread Simon Steiner
Hi,

PDStructureNode
PDObjectReference
PDMarkedContentReference

Thanks

-Original Message-
From: Tilman Hausherr [mailto:thaush...@t-online.de] 
Sent: 15 April 2015 20:33
To: dev@pdfbox.apache.org
Subject: Re: api question

Am 15.04.2015 um 13:47 schrieb Simon Steiner:
 Hi,

   

 Why do you  have classes where getCOSObject is public but 
 getCOSDictionary is not public?

Can you mention a few classes where this happens?

Tilman

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional
commands, e-mail: dev-h...@pdfbox.apache.org



-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2756) PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on version 2.0.0

2015-04-16 Thread JIRA

[ 
https://issues.apache.org/jira/browse/PDFBOX-2756?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497659#comment-14497659
 ] 

Andreas Lehmkühler commented on PDFBOX-2756:


I've couldn't reproduce the issue using win server 2008R2 + Java 1.7.0_45. I've 
checked PDFReader, PDFToImage and ExtractText and all of them are working fine. 
Yes, the rendering is slow (rendering of all pages approx. 8 minutes vs. text 
extraction 16 seconds, which doesn't render those complicated shadings).

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0
 

 Key: PDFBOX-2756
 URL: https://issues.apache.org/jira/browse/PDFBOX-2756
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 1.8.7, 1.8.9, 2.0.0
 Environment: windows server 2008/2012, running on apache tomcat 7.0
Reporter: ido sarussy
Priority: Blocker
  Labels: loadDocument, pdfbox, tomcat

 PDDocument.load() fails for some PDFs in versions 1.8.x, and stucks on 
 version 2.0.0 (probably an infinite loop or similar).
 in version 1.8.x throws IOExceoption while on 2.0.0 just hangs
 pdf can be found in:
 https://www.wetransfer.com/downloads/a15ab48687679ddedb04c93b70cfb5d220150415141903/d62dad81f00e57d2feba87d10ef81be420150415141903/75b647
 and:
 https://attachmore.com/721446060
 or the external issues URL



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497911#comment-14497911
 ] 

Frederik Bertling commented on PDFBOX-2757:
---

I'm using the following code:
Not at all means, the code after pdfRenderer.renderImageWithDPI(i, 200f, 
ImageType.RGB); is never executed, but I don't get an exception.
I'll try to use fontbox additionally. Thanks!

PDDocument pdf;
PDFRenderer pdfRenderer;

try {
// read pdf
pdf = PDDocument.load(file);
System.out.println(Loaded File);
pdfRenderer = new PDFRenderer(pdf);
System.out.println(Created Renderer);
for (int i = 0; i  pdf.getNumberOfPages(); i++) {
pdfRenderer.renderImageWithDPI(i, 200f, ImageType.RGB);
System.out.println(Rendered Image # + i);
}
pdf.close();
} catch (IOException e) {
e.printStackTrace();
}

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Frederik Bertling updated PDFBOX-2757:
--
Fix Version/s: 2.0.0

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Closed] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Frederik Bertling closed PDFBOX-2757.
-
Resolution: Fixed

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497890#comment-14497890
 ] 

Frederik Bertling edited comment on PDFBOX-2757 at 4/16/15 10:52 AM:
-

Attached an example pdf


was (Author: burtan):
Attached an example pdf and the old snapshot which works correctly

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14498023#comment-14498023
 ] 

Frederik Bertling commented on PDFBOX-2757:
---

I executed the code in the main thread to see if i get an exception then and 
yes, pdfbox was complaining about missing fontbox. After adding the most recent 
fontbox 2.0.0 snapshot, everything worked as expected. Thank you for leading me 
into the right direction!

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)
Frederik Bertling created PDFBOX-2757:
-

 Summary: PDF to image is not converted correctly (1.8.9) or not at 
all (pdfbox-2.0.0-20150414.202717-1243)
 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0


Hi,
I'm using pdfbox to convert pdf musical sheets to images. However, I have some 
problems converting some pdfs correctly.

When using 1.8.9. I get the following warning and the pdf is not rendered 
correctly:
org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
INFO: Using font SansSerif.plain instead

When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any warning, 
but pdfRenderer.renderImageWithDPI does not give any result.

I still have an older 2.0.0 snapshot, where the pdf is rendered correctly.





--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Frederik Bertling updated PDFBOX-2757:
--
Attachment: 000 Anheizer Laudato Si.pdf
pdfbox-2.0.0-SNAPSHOT.jar

An example pdf and the old snapshot which works correctly

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.
 I still have an older 2.0.0 snapshot, where the pdf is rendered correctly.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Frederik Bertling updated PDFBOX-2757:
--
Description: 
Hi,
I'm using pdfbox to convert pdf musical sheets to images. However, I have some 
problems converting some pdfs correctly.

When using 1.8.9. I get the following warning and the pdf is not rendered 
correctly:
org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
INFO: Using font SansSerif.plain instead

When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any warning, 
but pdfRenderer.renderImageWithDPI does not give any result.



  was:
Hi,
I'm using pdfbox to convert pdf musical sheets to images. However, I have some 
problems converting some pdfs correctly.

When using 1.8.9. I get the following warning and the pdf is not rendered 
correctly:
org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
INFO: Using font SansSerif.plain instead

When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any warning, 
but pdfRenderer.renderImageWithDPI does not give any result.

I still have an older 2.0.0 snapshot, where the pdf is rendered correctly.




 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Frederik Bertling updated PDFBOX-2757:
--
Fix Version/s: (was: 2.0.0)

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Re: CryptoBox and ETSI PAdES Plugtest

2015-04-16 Thread Thomas Chojecki


Zitat von Maruan Sahyoun sahy...@fileaffairs.de:


Hi,



Hi Maruan,


From 4 to 29 May 2015 ETSI is making a PAdES PlugTest [4], I'm already
a participant and will try to test the cryptobox. So I first try to go
through the specification and later port stuff like visual signatures.

Maybe we can participant as Apache at such plugtests, so we can gain
more publicity.


good idea - what would we need to participate as Apache PDFBox?



The first registration should be done by the apache office. There is  
also a NDA that need to be signed. This means that all data from the  
plugtest are not public and the test would run in a kind of blackbox.


Then the office need to register the participating members, so each  
member will get access to the plugtest and can use there infra. That's  
all.


This plugtest is free of charge, but this wasn't always the case.

The registration deadline is the end of april.





I don't made much planing, but I think this roadmap could be a good
start:

- Implement pdf signatures and verification for the ISO 32000-1:2008
 specification.
- Implement the ETSI signature specification PAdES
(deadline is the PlugTest)

- Basic signature service, maybe webservice or gui application.
- Port the visual signature stuff that already exist and maybe start a
 table based visualisation (without the need to create pictures)
- Port it to pdfbox 2.0.x with NonSeqParser
- Cleanup the existing pdfbox signature code

other parts that need to be done are:
- refactor signature interface and coswriter
- make pdf signature streamable without the dirty hooks that are needed now.
- there where already plans to move the pdf encryption from pdfbox
 to a new module. Maybe we can move it into the cryptobox.

I don't want promise anything, so I try mainly get through the plugtest
and show how the feedback is.

If you have some ideas how the cryptobox can be improved or maybe how
the architecture may look like to provide best usability, then
please give me some suggestions.


I quickly scanned through the code - there are some features from  
Java 1.7 such as Objects.requireNonNull in CoreHelper.copy. As  
PDFBox is currently on 1.6 this might be an issue when bringing it  
over.


Here are some of my initial thoughts

API wise maybe there could be a class SignatureService with sign(),  
certify() and verify() methods loading a PDDocument.


so the signing process would look something like

PDDocument doc = PDDocument.load
SignatureService sigservice = SignatureService.newInstance(doc);
sigservice.sign(SignatureOptions, OutputStream);


Yes such a service with PDDocument as base would be great, but we need  
to refactor first the signature part in the pdfbox. At the moment we  
are bound to files. So the 1.8.x and the first 2.0.x release will be  
file and stream-based. But I have this in mind.


So at the moment we need to live with the fact that the  
SignatureService creates the PDDocument itself.




As for the packaging maybe it could live in  
org.apache.pdfbox.services.crypto as this would allow for additional  
services to be added at a later stage wo. having so many top level  
packages (services being a sample we'd need to decide on).


What services are planed? I thought putting all stuff in crypto and do  
there the additional packages like sign, encrypt, verify would be ok.  
But if we plan more services that aren't covert by crypto, I would  
understand this step.


As for the general naming maybe this could be renamed to  
pdfbox-crypto to utilize the PDFBox name fully and not only the box  
part.


Are you sure? As it will be a submodule of the pdfbox, I thought it  
should match the other module names such fontbox, jempbox, xmpbox and  
so on. Naming the github project pdfbox-crypto will be indeed ok, but  
I think later we does not need the additional pdfbox- in the name.





BR
Maruan



Best regards
Thomas



[1]
http://www.etsi.org/news-events/news/324-news-release-14th-september-2009
[2] http://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0130
[3] https://github.com/Rayman2200/cryptobox/tree/1.8
[4] http://xades-portal.etsi.org/pub/index.shtml







-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Re: CryptoBox and ETSI PAdES Plugtest

2015-04-16 Thread Maruan Sahyoun
Hi,

 Am 16.04.2015 um 12:59 schrieb Thomas Chojecki i...@rayman2200.de:
 
 
 Zitat von Maruan Sahyoun sahy...@fileaffairs.de:
 
 Hi,
 
 
 Hi Maruan,
 
 From 4 to 29 May 2015 ETSI is making a PAdES PlugTest [4], I'm already
 a participant and will try to test the cryptobox. So I first try to go
 through the specification and later port stuff like visual signatures.
 
 Maybe we can participant as Apache at such plugtests, so we can gain
 more publicity.
 
 good idea - what would we need to participate as Apache PDFBox?
 
 
 The first registration should be done by the apache office. There is also a 
 NDA that need to be signed. This means that all data from the plugtest are 
 not public and the test would run in a kind of blackbox.
 
 Then the office need to register the participating members, so each member 
 will get access to the plugtest and can use there infra. That's all.
 
 This plugtest is free of charge, but this wasn't always the case.
 
 The registration deadline is the end of april.
 
 
 
 
 I don't made much planing, but I think this roadmap could be a good
 start:
 
 - Implement pdf signatures and verification for the ISO 32000-1:2008
 specification.
 - Implement the ETSI signature specification PAdES
 (deadline is the PlugTest)
 
 - Basic signature service, maybe webservice or gui application.
 - Port the visual signature stuff that already exist and maybe start a
 table based visualisation (without the need to create pictures)
 - Port it to pdfbox 2.0.x with NonSeqParser
 - Cleanup the existing pdfbox signature code
 
 other parts that need to be done are:
 - refactor signature interface and coswriter
 - make pdf signature streamable without the dirty hooks that are needed now.
 - there where already plans to move the pdf encryption from pdfbox
 to a new module. Maybe we can move it into the cryptobox.
 
 I don't want promise anything, so I try mainly get through the plugtest
 and show how the feedback is.
 
 If you have some ideas how the cryptobox can be improved or maybe how
 the architecture may look like to provide best usability, then
 please give me some suggestions.
 
 I quickly scanned through the code - there are some features from Java 1.7 
 such as Objects.requireNonNull in CoreHelper.copy. As PDFBox is currently on 
 1.6 this might be an issue when bringing it over.
 
 Here are some of my initial thoughts
 
 API wise maybe there could be a class SignatureService with sign(), 
 certify() and verify() methods loading a PDDocument.
 
 so the signing process would look something like
 
 PDDocument doc = PDDocument.load
 SignatureService sigservice = SignatureService.newInstance(doc);
 sigservice.sign(SignatureOptions, OutputStream);
 
 Yes such a service with PDDocument as base would be great, but we need to 
 refactor first the signature part in the pdfbox. At the moment we are bound 
 to files. So the 1.8.x and the first 2.0.x release will be file and 
 stream-based. But I have this in mind.
 
 So at the moment we need to live with the fact that the SignatureService 
 creates the PDDocument itself.

OK

 
 
 As for the packaging maybe it could live in 
 org.apache.pdfbox.services.crypto as this would allow for additional 
 services to be added at a later stage wo. having so many top level packages 
 (services being a sample we'd need to decide on).
 
 What services are planed? I thought putting all stuff in crypto and do there 
 the additional packages like sign, encrypt, verify would be ok. But if we 
 plan more services that aren't covert by crypto, I would understand this step.

Don't know yet - but I'm also looking at doing form flattening - of course that 
could live inside interactive.forms - so that was only an initial thought.

 
 As for the general naming maybe this could be renamed to pdfbox-crypto to 
 utilize the PDFBox name fully and not only the box part.
 
 Are you sure? As it will be a submodule of the pdfbox, I thought it should 
 match the other module names such fontbox, jempbox, xmpbox and so on. Naming 
 the github project pdfbox-crypto will be indeed ok, but I think later we does 
 not need the additional pdfbox- in the name.

Again something worth discussing. If there are more subproject IMHO the current 
naming won't scale.

 
 
 
 BR
 Maruan
 
 
 Best regards
 Thomas
 
 
 [1]
 http://www.etsi.org/news-events/news/324-news-release-14th-september-2009
 [2] http://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:32011D0130
 [3] https://github.com/Rayman2200/cryptobox/tree/1.8
 [4] http://xades-portal.etsi.org/pub/index.shtml
 
 
 
 
 
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
 For additional commands, e-mail: dev-h...@pdfbox.apache.org
 


-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-2758) Support additional annotation types when importing XFDF files

2015-04-16 Thread Maruan Sahyoun (JIRA)
Maruan Sahyoun created PDFBOX-2758:
--

 Summary: Support additional annotation types when importing XFDF 
files
 Key: PDFBOX-2758
 URL: https://issues.apache.org/jira/browse/PDFBOX-2758
 Project: PDFBox
  Issue Type: Improvement
  Components: PDModel
Affects Versions: 1.8.9, 2.0.0
Reporter: Maruan Sahyoun


When importing an XFDF file an IOException is generated if the annotation type 
is not {{text}}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Reopened] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr reopened PDFBOX-2757:
-

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Closed] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr closed PDFBOX-2757.
---
   Resolution: Not A Problem
Fix Version/s: (was: 2.0.0)

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Tilman Hausherr (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497898#comment-14497898
 ] 

Tilman Hausherr commented on PDFBOX-2757:
-

You'll also need fontbox. Alternatively, use pdfbox-app.

not at all means what? A blank page, an exception, a null return, a JVM 
crash, a system freeze?

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Comment Edited] (PDFBOX-2757) PDF to image is not converted correctly (1.8.9) or not at all (pdfbox-2.0.0-20150414.202717-1243)

2015-04-16 Thread Frederik Bertling (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2757?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14497890#comment-14497890
 ] 

Frederik Bertling edited comment on PDFBOX-2757 at 4/16/15 10:46 AM:
-

Attached an example pdf and the old snapshot which works correctly


was (Author: burtan):
An example pdf and the old snapshot which works correctly

 PDF to image is not converted correctly (1.8.9) or not at all 
 (pdfbox-2.0.0-20150414.202717-1243)
 -

 Key: PDFBOX-2757
 URL: https://issues.apache.org/jira/browse/PDFBOX-2757
 Project: PDFBox
  Issue Type: Bug
  Components: Rendering
Affects Versions: 1.8.9, 2.0.0
 Environment: Debian Jessie, IntelliJ IDEA 14.1
Reporter: Frederik Bertling
 Fix For: 2.0.0

 Attachments: 000 Anheizer Laudato Si.pdf, pdfbox-2.0.0-SNAPSHOT.jar


 Hi,
 I'm using pdfbox to convert pdf musical sheets to images. However, I have 
 some problems converting some pdfs correctly.
 When using 1.8.9. I get the following warning and the pdf is not rendered 
 correctly:
 org.apache.pdfbox.pdmodel.font.PDTrueTypeFont getawtFont
 INFO: Using font SansSerif.plain instead
 When using pdfbox-2.0.0-20150414.202717-1243 snapshot, I don't get any 
 warning, but pdfRenderer.renderImageWithDPI does not give any result.
 I still have an older 2.0.0 snapshot, where the pdf is rendered correctly.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Jenkins build is unstable: PDFBox-trunk » Apache PDFBox #1994

2015-04-16 Thread Apache Jenkins Server
See 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$pdfbox/1994/changes


-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Jenkins build is back to normal : PDFBox-trunk » PDFBox parent #1994

2015-04-16 Thread Apache Jenkins Server
See 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$pdfbox-parent/1994/


-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Jenkins build is unstable: PDFBox-trunk #1994

2015-04-16 Thread Apache Jenkins Server
See https://builds.apache.org/job/PDFBox-trunk/1994/changes


-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Re: api question

2015-04-16 Thread Tilman Hausherr

Done.

Tilman

Am 16.04.2015 um 10:25 schrieb Simon Steiner:

Hi,

PDStructureNode
PDObjectReference
PDMarkedContentReference

Thanks

-Original Message-
From: Tilman Hausherr [mailto:thaush...@t-online.de]
Sent: 15 April 2015 20:33
To: dev@pdfbox.apache.org
Subject: Re: api question

Am 15.04.2015 um 13:47 schrieb Simon Steiner:

Hi,

   


Why do you  have classes where getCOSObject is public but
getCOSDictionary is not public?

Can you mention a few classes where this happens?

Tilman

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional
commands, e-mail: dev-h...@pdfbox.apache.org



-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org




-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2576) Improve code quality

2015-04-16 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2576?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14498262#comment-14498262
 ] 

ASF subversion and git services commented on PDFBOX-2576:
-

Commit 1674110 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1674110 ]

PDFBOX-2576: make getCOSDictionary() public as in the rest of the project for 
Simon Steiner; make fields final; make methods final that are called in 
constructor

 Improve code quality
 

 Key: PDFBOX-2576
 URL: https://issues.apache.org/jira/browse/PDFBOX-2576
 Project: PDFBox
  Issue Type: Task
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
 Attachments: ExtractText.2.patch, ExtractText.patch, 
 GraphicsOperatorProcessor.patch, SecuryHandlerFactory.patch, 
 Type5ShadingContext.patch, examples.arrayclone.patch, 
 fontbox.arrayclone.patch, org.apache.fontbox.afm.patch, 
 org.apache.fontbox.cff.cffparser.patch, org.apache.fontbox.cff.patch, 
 org.apache.fontbox.cmap.patch, 
 org.apache.pdfbox.contentstream.operator.state.patch, 
 org.apache.pdfbox.cos.patch, org.apache.pdfbox.filter-2.patch, 
 org.apache.pdfbox.filter.patch, org.apache.pdfbox.pdfwriter.COSWriter.patch, 
 org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.patch, 
 org.apache.pdfbox.pdmodel.documentinterchange.patch, 
 org.apache.pdfbox.preflight.graphic.patch, org.apache.pdfbox.resource.patch, 
 org.apache.pdfbox.text.testtextstripper.patch, pdfbox-override-patch.txt, 
 pdfbox-raw-type-patch.txt, pdfbox.arrayclone.patch, 
 pdfcloneutility-patch.txt, pdftextstripperbyarea-patch.txt, 
 ttfsubsetter-2.patch, ttfsubsetter-3.patch, ttfsubsetter-patch.txt


 This is a longterm issue for the task to improve code quality, by using the 
 [SonarQube 
 report|https://analysis.apache.org/dashboard/index/org.apache.pdfbox:pdfbox-reactor],
  hints in different IDEs, the FindBugs tool and other code quality tools.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-2759) NPE in BaseParser.parseCOSDictionaryValue() due to object reference in content stream

2015-04-16 Thread Tilman Hausherr (JIRA)
Tilman Hausherr created PDFBOX-2759:
---

 Summary: NPE in BaseParser.parseCOSDictionaryValue() due to object 
reference in content stream
 Key: PDFBOX-2759
 URL: https://issues.apache.org/jira/browse/PDFBOX-2759
 Project: PDFBox
  Issue Type: Bug
  Components: Parsing
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0


{code}
java.lang.NullPointerException
at 
org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionaryValue(BaseParser.java:235)
at 
org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionary(BaseParser.java:311)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser.parseNextToken(PDFStreamParser.java:217)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser.access$000(PDFStreamParser.java:47)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser$1.tryNext(PDFStreamParser.java:144)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser$1.hasNext(PDFStreamParser.java:157)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:477)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
at 
org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
at 
org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
at 
org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
at 
org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
at 
com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
{code}
The cause is a malformed content stream:
{code}
(186) Tj
-132.88 -0.24 TD
/F1 10.00 Tf
(TOTAL RESOURCES:) Tj
162.08 0.00 TD
(\(DAYS\)) Tj
155.92 16.48 TD
(February  15, 2001) Tj
ET
Q 0 g 0 G
endstream
endobj
649 0 obj
4096
endobj
647 0 obj

/Type /Page
/MediaBox [0 0 612 792]
/Parent 3 0 R
/Resources /ProcSet [ /PDF /Text ] /Font  /F0 12 0 R /F1 13 0 R  
/Contents 648 0 R
/CropBox [0 0 612 792]

endobj
{code}

BaseParser.parseCOSDictionaryValue() is used both by PDFParser and by 
PDFStreamParser because these have a few things in common, e.g. dictionaries. 

However the spec tells us: Indirect objects and object references shall not be 
permitted at all in content streams. I will throw an exception instead.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-2759) NPE in BaseParser.parseCOSDictionaryValue() due to object reference in content stream

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2759?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-2759:

Description: 
{code}
java.lang.NullPointerException
at 
org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionaryValue(BaseParser.java:235)
at 
org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionary(BaseParser.java:311)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser.parseNextToken(PDFStreamParser.java:217)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser.access$000(PDFStreamParser.java:47)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser$1.tryNext(PDFStreamParser.java:144)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser$1.hasNext(PDFStreamParser.java:157)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:477)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
at 
org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
at 
org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
at 
org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
at 
org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
at 
com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
{code}
The cause is a malformed content stream:
{code}
(186) Tj
-132.88 -0.24 TD
/F1 10.00 Tf
(TOTAL RESOURCES:) Tj
162.08 0.00 TD
(\(DAYS\)) Tj
155.92 16.48 TD
(February  15, 2001) Tj
ET
Q 0 g 0 G
endstream
endobj
649 0 obj
4096
endobj
647 0 obj

/Type /Page
/MediaBox [0 0 612 792]
/Parent 3 0 R
/Resources /ProcSet [ /PDF /Text ] /Font  /F0 12 0 R /F1 13 0 R  
/Contents 648 0 R
/CropBox [0 0 612 792]

endobj
{code}

BaseParser.parseCOSDictionaryValue() is used both by PDFParser and by 
PDFStreamParser because these have a few things in common, e.g. dictionaries. 
The difference is that document is null for a content stream, so 
document.getObjectFromPool() fails.

However the spec tells us: Indirect objects and object references shall not be 
permitted at all in content streams. I will throw an exception instead.

  was:
{code}
java.lang.NullPointerException
at 
org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionaryValue(BaseParser.java:235)
at 
org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionary(BaseParser.java:311)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser.parseNextToken(PDFStreamParser.java:217)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser.access$000(PDFStreamParser.java:47)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser$1.tryNext(PDFStreamParser.java:144)
at 
org.apache.pdfbox.pdfparser.PDFStreamParser$1.hasNext(PDFStreamParser.java:157)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:477)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
at 
org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
at 

Build failed in Jenkins: PDFBox-trunk » Apache XmpBox #1995

2015-04-16 Thread Apache Jenkins Server
See https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/1995/

--
[INFO] 
[INFO] 
[INFO] Building Apache XmpBox 2.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ xmpbox ---
[TASKS] Scanning folder 
'https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/ws/' for 
files matching the pattern '**/*.java' - excludes: 
[TASKS] Found 106 files to scan for tasks
Found 6 open tasks.
[TASKS] Computing warning deltas based on reference build #1994
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (default) @ xmpbox ---
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ xmpbox ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/ws/src/main/resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ xmpbox ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 72 source files to 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/ws/target/classes
[INFO] 
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ 
xmpbox ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 26 resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ xmpbox 
---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 34 source files to 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/ws/target/test-classes
[WARNING] Note: 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/ws/src/test/java/org/apache/xmpbox/schema/AbstractXMPSchemaTest.java
 uses unchecked or unsafe operations.
[WARNING] Note: Recompile with -Xlint:unchecked for details.
[INFO] 
[INFO] --- maven-surefire-plugin:2.17:test (default-test) @ xmpbox ---
[INFO] Surefire report directory: 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$xmpbox/ws/target/surefire-reports

---
 T E S T S
---
Running org.apache.xmpbox.TestXMPWithDefinedSchemas
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.343 sec - in 
org.apache.xmpbox.TestXMPWithDefinedSchemas
Running org.apache.xmpbox.DoubleSameTypeSchemaTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.021 sec - in 
org.apache.xmpbox.DoubleSameTypeSchemaTest
Running org.apache.xmpbox.type.TestLayerType
Tests run: 14, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.376 sec - in 
org.apache.xmpbox.type.TestLayerType
Running org.apache.xmpbox.type.TestSimpleMetadataProperties
Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.107 sec - in 
org.apache.xmpbox.type.TestSimpleMetadataProperties
Running org.apache.xmpbox.type.TestResourceRefType
Tests run: 105, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.708 sec - 
in org.apache.xmpbox.type.TestResourceRefType
Running org.apache.xmpbox.type.TestJobType
Tests run: 21, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.13 sec - in 
org.apache.xmpbox.type.TestJobType
Running org.apache.xmpbox.type.TestVersionType
Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.049 sec - in 
org.apache.xmpbox.type.TestVersionType
Running org.apache.xmpbox.type.TestAbstractStructuredType
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.021 sec - in 
org.apache.xmpbox.type.TestAbstractStructuredType
Running org.apache.xmpbox.type.TestResourceEventType
Tests run: 42, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.351 sec - in 
org.apache.xmpbox.type.TestResourceEventType
Running org.apache.xmpbox.type.AttributeTest
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0 sec - in 
org.apache.xmpbox.type.AttributeTest
Running org.apache.xmpbox.type.TestDerivedType
Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.041 sec - in 
org.apache.xmpbox.type.TestDerivedType
Running org.apache.xmpbox.type.TestThumbnailType
Tests run: 28, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.19 sec - in 
org.apache.xmpbox.type.TestThumbnailType
Running org.apache.xmpbox.SaveMetadataHelperTest
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.008 sec - in 
org.apache.xmpbox.SaveMetadataHelperTest
Running org.apache.xmpbox.parser.DeserializationTest
Tests run: 18, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.278 sec - in 
org.apache.xmpbox.parser.DeserializationTest
Running org.apache.xmpbox.schema.PDFAIdentificationTest
Tests run: 6, Failures: 0, Errors: 0, 

Build failed in Jenkins: PDFBox-trunk #1995

2015-04-16 Thread Apache Jenkins Server
See https://builds.apache.org/job/PDFBox-trunk/1995/changes

Changes:

[tilman] PDFBOX-2759: avoid NPE when indirect object appears in content stream

--
[...truncated 157 lines...]
[INFO] Writing OBR metadata
[INFO] 
[INFO] --- maven-deploy-plugin:2.8.2:deploy (default-deploy) @ fontbox ---
Downloading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/maven-metadata.xml
Downloaded: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/maven-metadata.xml
 (783 B at 5.0 KB/sec)
Uploading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/fontbox-2.0.0-20150416.175850-1290.jar
Uploaded: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/fontbox-2.0.0-20150416.175850-1290.jar
 (1428 KB at 4888.7 KB/sec)
Uploading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/fontbox-2.0.0-20150416.175850-1290.pom
Uploaded: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/fontbox-2.0.0-20150416.175850-1290.pom
 (3 KB at 16.0 KB/sec)
Downloading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/maven-metadata.xml
Downloaded: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/maven-metadata.xml
 (385 B at 4.4 KB/sec)
Uploading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/maven-metadata.xml
Uploaded: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/2.0.0-SNAPSHOT/maven-metadata.xml
 (783 B at 5.4 KB/sec)
Uploading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/maven-metadata.xml
Uploaded: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/fontbox/maven-metadata.xml
 (385 B at 2.7 KB/sec)
[INFO] 
[INFO] --- maven-bundle-plugin:2.5.3:deploy (default-deploy) @ fontbox ---
[INFO] Remote OBR update disabled (enable with -DremoteOBR)
[INFO] 
[INFO] 
[INFO] Building Apache XmpBox 2.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ xmpbox ---
[TASKS] Scanning folder 
'https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox' for files 
matching the pattern '**/*.java' - excludes: 
[TASKS] Found 106 files to scan for tasks
Found 6 open tasks.
[TASKS] Computing warning deltas based on reference build #1994
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (default) @ xmpbox ---
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ xmpbox ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox/src/main/resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ xmpbox ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 72 source files to 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox/target/classes
[INFO] 
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ 
xmpbox ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 26 resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ xmpbox 
---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 34 source files to 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox/target/test-classes
[WARNING] Note: 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox/src/test/java/org/apache/xmpbox/schema/AbstractXMPSchemaTest.java
 uses unchecked or unsafe operations.
[WARNING] Note: Recompile with -Xlint:unchecked for details.
[INFO] 
[INFO] --- maven-surefire-plugin:2.17:test (default-test) @ xmpbox ---
[INFO] Surefire report directory: 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox/target/surefire-reports

---
 T E S T S
---
Running org.apache.xmpbox.TestXMPWithDefinedSchemas
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.343 sec - in 
org.apache.xmpbox.TestXMPWithDefinedSchemas
Running org.apache.xmpbox.DoubleSameTypeSchemaTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.021 sec - in 
org.apache.xmpbox.DoubleSameTypeSchemaTest
Running org.apache.xmpbox.type.TestLayerType
Tests run: 14, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.376 sec - 

[jira] [Updated] (PDFBOX-2759) NPE in BaseParser.parseCOSDictionaryValue() due to object reference in content stream

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2759?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-2759:

Attachment: PDFBOX-2759-317669-p213.pdf

 NPE in BaseParser.parseCOSDictionaryValue() due to object reference in 
 content stream
 -

 Key: PDFBOX-2759
 URL: https://issues.apache.org/jira/browse/PDFBOX-2759
 Project: PDFBox
  Issue Type: Bug
  Components: Parsing
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: PDFBOX-2759-317669-p213.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionaryValue(BaseParser.java:235)
   at 
 org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionary(BaseParser.java:311)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser.parseNextToken(PDFStreamParser.java:217)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser.access$000(PDFStreamParser.java:47)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser$1.tryNext(PDFStreamParser.java:144)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser$1.hasNext(PDFStreamParser.java:157)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:477)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is a malformed content stream:
 {code}
 (186) Tj
 -132.88 -0.24 TD
 /F1 10.00 Tf
 (TOTAL RESOURCES:) Tj
 162.08 0.00 TD
 (\(DAYS\)) Tj
 155.92 16.48 TD
 (February  15, 2001) Tj
 ET
 Q 0 g 0 G
 endstream
 endobj
 649 0 obj
 4096
 endobj
 647 0 obj
 
 /Type /Page
 /MediaBox [0 0 612 792]
 /Parent 3 0 R
 /Resources /ProcSet [ /PDF /Text ] /Font  /F0 12 0 R /F1 13 0 R  
 /Contents 648 0 R
 /CropBox [0 0 612 792]
 
 endobj
 {code}
 BaseParser.parseCOSDictionaryValue() is used both by PDFParser and by 
 PDFStreamParser because these have a few things in common, e.g. dictionaries. 
 However the spec tells us: Indirect objects and object references shall not 
 be permitted at all in content streams. I will throw an exception instead.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2759) NPE in BaseParser.parseCOSDictionaryValue() due to object reference in content stream

2015-04-16 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2759?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14498388#comment-14498388
 ] 

ASF subversion and git services commented on PDFBOX-2759:
-

Commit 1674118 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1674118 ]

PDFBOX-2759: avoid NPE when indirect object appears in content stream

 NPE in BaseParser.parseCOSDictionaryValue() due to object reference in 
 content stream
 -

 Key: PDFBOX-2759
 URL: https://issues.apache.org/jira/browse/PDFBOX-2759
 Project: PDFBox
  Issue Type: Bug
  Components: Parsing
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: PDFBOX-2759-317669-p213.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionaryValue(BaseParser.java:235)
   at 
 org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionary(BaseParser.java:311)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser.parseNextToken(PDFStreamParser.java:217)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser.access$000(PDFStreamParser.java:47)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser$1.tryNext(PDFStreamParser.java:144)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser$1.hasNext(PDFStreamParser.java:157)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:477)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is a malformed content stream:
 {code}
 (186) Tj
 -132.88 -0.24 TD
 /F1 10.00 Tf
 (TOTAL RESOURCES:) Tj
 162.08 0.00 TD
 (\(DAYS\)) Tj
 155.92 16.48 TD
 (February  15, 2001) Tj
 ET
 Q 0 g 0 G
 endstream
 endobj
 649 0 obj
 4096
 endobj
 647 0 obj
 
 /Type /Page
 /MediaBox [0 0 612 792]
 /Parent 3 0 R
 /Resources /ProcSet [ /PDF /Text ] /Font  /F0 12 0 R /F1 13 0 R  
 /Contents 648 0 R
 /CropBox [0 0 612 792]
 
 endobj
 {code}
 BaseParser.parseCOSDictionaryValue() is used both by PDFParser and by 
 PDFStreamParser because these have a few things in common, e.g. dictionaries. 
 The difference is that document is null for a content stream, so 
 document.getObjectFromPool() fails.
 However the spec tells us: Indirect objects and object references shall not 
 be permitted at all in content streams. I will throw an exception instead.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-2760) NPE in MoveText.process()

2015-04-16 Thread Tilman Hausherr (JIRA)
Tilman Hausherr created PDFBOX-2760:
---

 Summary: NPE in MoveText.process()
 Key: PDFBOX-2760
 URL: https://issues.apache.org/jira/browse/PDFBOX-2760
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0


{code}
java.lang.NullPointerException
at 
org.apache.pdfbox.contentstream.operator.text.MoveText.process(MoveText.java:41)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
at 
org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:810)
at 
org.apache.pdfbox.contentstream.operator.text.MoveTextSetLeading.process(MoveTextSetLeading.java:45)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
at 
org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:490)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
at 
org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
at 
org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
at 
org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
at 
org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
at 
org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
at 
org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
at 
org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
at 
com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
{code}
The cause is this:
{code}
ET
240.48 515.64 1.44 0.6 re
f
243.36 515.64 1.44 0.6 re
f
246.24 515.64 1.44 0.6 re
f
249.12 515.64 1.44 0.6 re
f
252 515.64 1.44 0.6 re
f
254.88 515.64 1.44 0.6 re
f
257.76 515.64 1.44 0.6 re
f
260.64 515.64 1.44 0.6 re
f
263.52 515.64 1.44 0.6 re
f
266.4 515.64 1.44 0.6 re
f
269.28 515.64 1.44 0.6 re
f
23.93.96 1.44 0.6 re
f
1 .0.44--32 -1.18 TD
{code}
i.e. the operator is called outsitde of BT...ET.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-2760) NPE in MoveText.process()

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2760?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-2760:

Attachment: 455746.pdf

 NPE in MoveText.process()
 -

 Key: PDFBOX-2760
 URL: https://issues.apache.org/jira/browse/PDFBOX-2760
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: 455746.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveText.process(MoveText.java:41)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:810)
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveTextSetLeading.process(MoveTextSetLeading.java:45)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:490)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is this:
 {code}
 ET
 240.48 515.64 1.44 0.6 re
 f
 243.36 515.64 1.44 0.6 re
 f
 246.24 515.64 1.44 0.6 re
 f
 249.12 515.64 1.44 0.6 re
 f
 252 515.64 1.44 0.6 re
 f
 254.88 515.64 1.44 0.6 re
 f
 257.76 515.64 1.44 0.6 re
 f
 260.64 515.64 1.44 0.6 re
 f
 263.52 515.64 1.44 0.6 re
 f
 266.4 515.64 1.44 0.6 re
 f
 269.28 515.64 1.44 0.6 re
 f
 23.93.96 1.44 0.6 re
 f
 1 .0.44--32 -1.18 TD
 {code}
 i.e. the operator is called outsitde of BT...ET.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2760) NPE in MoveText.process()

2015-04-16 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2760?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14498653#comment-14498653
 ] 

ASF subversion and git services commented on PDFBOX-2760:
-

Commit 1674145 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1674145 ]

PDFBOX-2760: avoid NPE by checking that textLineMatrix exists

 NPE in MoveText.process()
 -

 Key: PDFBOX-2760
 URL: https://issues.apache.org/jira/browse/PDFBOX-2760
 Project: PDFBox
  Issue Type: Bug
  Components: PDModel
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: 455746.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveText.process(MoveText.java:41)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:810)
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveTextSetLeading.process(MoveTextSetLeading.java:45)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:490)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is this:
 {code}
 ET
 240.48 515.64 1.44 0.6 re
 f
 243.36 515.64 1.44 0.6 re
 f
 246.24 515.64 1.44 0.6 re
 f
 249.12 515.64 1.44 0.6 re
 f
 252 515.64 1.44 0.6 re
 f
 254.88 515.64 1.44 0.6 re
 f
 257.76 515.64 1.44 0.6 re
 f
 260.64 515.64 1.44 0.6 re
 f
 263.52 515.64 1.44 0.6 re
 f
 266.4 515.64 1.44 0.6 re
 f
 269.28 515.64 1.44 0.6 re
 f
 23.93.96 1.44 0.6 re
 f
 1 .0.44--32 -1.18 TD
 {code}
 i.e. the operator is called outsitde of BT...ET.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Commented] (PDFBOX-2566) Remove logging from operator classes

2015-04-16 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PDFBOX-2566?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14498611#comment-14498611
 ] 

ASF subversion and git services commented on PDFBOX-2566:
-

Commit 1674143 from [~tilman] in branch 'pdfbox/trunk'
[ https://svn.apache.org/r1674143 ]

PDFBOX-2566: delete wrong operand count on more operators

 Remove logging from operator classes
 

 Key: PDFBOX-2566
 URL: https://issues.apache.org/jira/browse/PDFBOX-2566
 Project: PDFBox
  Issue Type: Improvement
  Components: PDModel
Affects Versions: 2.0.0
Reporter: John Hewson
Assignee: John Hewson
Priority: Minor
 Fix For: 2.0.0


 I've been trying to get better control over the logging that occurs in the 
 operator classes, but it's not easy to do so. Ideally all logging could pass 
 through PDFStreamEngine so that subclasses can more easily filter what they 
 want. By using exceptions instead of logging for error cases, we allow more 
 fine-grained management of exceptions. For example, in my own code I wish for 
 a missing XObject to be a terminal failure, but it currently just results in 
 a log message, and I have to implement a custom DrawObject operator and copy 
  paste over most of the code in order to catch this exception rather than 
 logging it.
 I'm therefore going to move what little logging there is in the Operator 
 classes over to PDFStreamEngine, and to throw custom exceptions (e.g. 
 MissingResourceException) rather than writing silently to the log. The 
 default implementation of processOperator in PDFStreamEngine will then catch 
 these custom exceptions and simply write them to the log - keeping the 
 current PDFBox behaviour unchanged. Only now consumers of PDFStreamEngine can 
 override processOperator and do their own exception handling, e.g. I can 
 choose to propagate MissingResourceException exception instead of logging it.
 This might be useful for Preflight too, as it often wants to throw errors 
 where we would otherwise skip the offending object and just keep processing. 
 Also it probably means that there will no longer be a need for to Preflight 
 implement its own operators in those cases where it was done just to get 
 stricter error handing.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Build failed in Jenkins: PDFBox-trunk » PDFBox parent #1996

2015-04-16 Thread Apache Jenkins Server
See 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$pdfbox-parent/1996/

--
maven3-agent.jar already up to date
maven3-interceptor.jar already up to date
maven3-interceptor-commons.jar already up to date
===[JENKINS REMOTING CAPACITY]===   channel started
Executing Maven:  -B -f 
/home/jenkins/jenkins-slave/workspace/PDFBox-trunk/trunk/pom.xml 
-Dmaven.repo.local=/home/jenkins/jenkins-slave/maven-repositories/0 clean 
deploy -Ppedantic -Dskip-bavaria=false
[INFO] Scanning for projects...
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for 
org.apache.pdfbox:xmpbox:bundle:2.0.0-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for 
org.apache.maven.plugins:maven-checkstyle-plugin is missing. @ line 58, column 
12
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for 
org.apache.pdfbox:preflight:bundle:2.0.0-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for 
org.apache.maven.plugins:maven-checkstyle-plugin is missing. @ line 98, column 
12
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten 
the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support 
building such malformed projects.
[WARNING] 
[INFO] 
[INFO] Reactor Build Order:
[INFO] 
[INFO] PDFBox parent
[INFO] Apache FontBox
[INFO] Apache XmpBox
[INFO] Apache PDFBox
[INFO] Apache Preflight
[INFO] Apache Preflight application
[INFO] Apache PDFBox tools
[INFO] Apache PDFBox application
[INFO] Apache PDFBox examples
[INFO] PDFBox reactor
[INFO] 
[INFO] 
[INFO] Building PDFBox parent 2.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ pdfbox-parent ---
[TASKS] Scanning folder 
'https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$pdfbox-parent/ws/'
 for files matching the pattern '**/*.java' - excludes: 
[TASKS] Found 0 files to scan for tasks
Found 0 open tasks.
[TASKS] Computing warning deltas based on reference build #1995
log4j:WARN No appenders could be found for logger 
(org.apache.commons.beanutils.converters.BooleanConverter).
log4j:WARN Please initialize the log4j system properly.
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (default) @ pdfbox-parent 
---
[INFO] 
[INFO] --- maven-site-plugin:3.4:attach-descriptor (attach-descriptor) @ 
pdfbox-parent ---
[INFO] 
[INFO] --- apache-rat-plugin:0.11:check (default) @ pdfbox-parent ---
[INFO] 51 implicit excludes (use -debug for more details).
[INFO] Exclude: release.properties
[INFO] 1 resources included (use -debug for more details)
[INFO] Rat check: Summary of files. Unapproved: 0 unknown: 0 generated: 0 
approved: 1 licence.
[INFO] 
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ pdfbox-parent 
---
[INFO] Installing 
https://builds.apache.org/job/PDFBox-trunk/org.apache.pdfbox$pdfbox-parent/ws/pom.xml
 to 
/home/jenkins/jenkins-slave/maven-repositories/0/org/apache/pdfbox/pdfbox-parent/2.0.0-SNAPSHOT/pdfbox-parent-2.0.0-SNAPSHOT.pom
[INFO] 
[INFO] --- maven-deploy-plugin:2.8.2:deploy (default-deploy) @ pdfbox-parent ---
Downloading: 
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/pdfbox-parent/2.0.0-SNAPSHOT/maven-metadata.xml
[WARNING] Could not transfer metadata 
org.apache.pdfbox:pdfbox-parent:2.0.0-SNAPSHOT/maven-metadata.xml from/to 
apache.snapshots.https 
(https://repository.apache.org/content/repositories/snapshots): peer not 
authenticated

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



Build failed in Jenkins: PDFBox-trunk #1996

2015-04-16 Thread Apache Jenkins Server
See https://builds.apache.org/job/PDFBox-trunk/1996/changes

Changes:

[tilman] PDFBOX-2760: avoid NPE by checking that textLineMatrix exists

[tilman] PDFBOX-2566: detect wrong operand count on more operators

--
Started by an SCM change
Building remotely on ubuntu-4 (docker Ubuntu ubuntu4 ubuntu) in workspace 
https://builds.apache.org/job/PDFBox-trunk/ws/
Cleaning up https://builds.apache.org/job/PDFBox-trunk/ws/trunk
Deleting https://builds.apache.org/job/PDFBox-trunk/ws/trunk/parent/target
Deleting https://builds.apache.org/job/PDFBox-trunk/ws/trunk/xmpbox/target
Deleting https://builds.apache.org/job/PDFBox-trunk/ws/trunk/fontbox/target
Updating http://svn.apache.org/repos/asf/pdfbox/trunk at revision 
'2015-04-16T20:58:10.968 +'
U 
pdfbox/src/main/java/org/apache/pdfbox/contentstream/operator/state/SetMatrix.java
U 
pdfbox/src/main/java/org/apache/pdfbox/contentstream/operator/state/Concatenate.java
U 
pdfbox/src/main/java/org/apache/pdfbox/contentstream/operator/text/MoveText.java
U 
pdfbox/src/main/java/org/apache/pdfbox/contentstream/operator/text/MoveTextSetLeading.java
U 
pdfbox/src/main/java/org/apache/pdfbox/contentstream/operator/text/SetTextHorizontalScaling.java
At revision 1674149
Parsing POMs
maven3-agent.jar already up to date
maven3-interceptor.jar already up to date
maven3-interceptor-commons.jar already up to date
[trunk] $ /home/jenkins/tools/java/jdk1.6.0_20-32-unlimited-security/bin/java 
-Xmx1g -XX:MaxPermSize=300m -cp 
/home/jenkins/jenkins-slave/maven3-agent.jar:/home/jenkins/jenkins-slave/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.0.5/boot/plexus-classworlds-2.4.jar
 org.jvnet.hudson.maven3.agent.Maven3Main 
/home/jenkins/jenkins-slave/tools/hudson.tasks.Maven_MavenInstallation/Maven_3.0.5
 /home/jenkins/jenkins-slave/slave.jar 
/home/jenkins/jenkins-slave/maven3-interceptor.jar 
/home/jenkins/jenkins-slave/maven3-interceptor-commons.jar 48212
===[JENKINS REMOTING CAPACITY]===   channel started
Executing Maven:  -B -f 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/pom.xml 
-Dmaven.repo.local=/home/jenkins/jenkins-slave/maven-repositories/0 clean 
deploy -Ppedantic -Dskip-bavaria=false
[INFO] Scanning for projects...
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for 
org.apache.pdfbox:xmpbox:bundle:2.0.0-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for 
org.apache.maven.plugins:maven-checkstyle-plugin is missing. @ line 58, column 
12
[WARNING] 
[WARNING] Some problems were encountered while building the effective model for 
org.apache.pdfbox:preflight:bundle:2.0.0-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for 
org.apache.maven.plugins:maven-checkstyle-plugin is missing. @ line 98, column 
12
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten 
the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support 
building such malformed projects.
[WARNING] 
[INFO] 
[INFO] Reactor Build Order:
[INFO] 
[INFO] PDFBox parent
[INFO] Apache FontBox
[INFO] Apache XmpBox
[INFO] Apache PDFBox
[INFO] Apache Preflight
[INFO] Apache Preflight application
[INFO] Apache PDFBox tools
[INFO] Apache PDFBox application
[INFO] Apache PDFBox examples
[INFO] PDFBox reactor
[INFO] 
[INFO] 
[INFO] Building PDFBox parent 2.0.0-SNAPSHOT
[INFO] 
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ pdfbox-parent ---
[TASKS] Scanning folder 
'https://builds.apache.org/job/PDFBox-trunk/ws/trunk/parent' for files 
matching the pattern '**/*.java' - excludes: 
[TASKS] Found 0 files to scan for tasks
Found 0 open tasks.
[TASKS] Computing warning deltas based on reference build #1995
log4j:WARN No appenders could be found for logger 
(org.apache.commons.beanutils.converters.BooleanConverter).
log4j:WARN Please initialize the log4j system properly.
[INFO] 
[INFO] --- maven-remote-resources-plugin:1.5:process (default) @ pdfbox-parent 
---
[INFO] 
[INFO] --- maven-site-plugin:3.4:attach-descriptor (attach-descriptor) @ 
pdfbox-parent ---
[INFO] 
[INFO] --- apache-rat-plugin:0.11:check (default) @ pdfbox-parent ---
[INFO] 51 implicit excludes (use -debug for more details).
[INFO] Exclude: release.properties
[INFO] 1 resources included (use -debug for more details)
[INFO] Rat check: Summary of files. Unapproved: 0 unknown: 0 generated: 0 
approved: 1 licence.
[INFO] 
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ pdfbox-parent 
---
[INFO] Installing 
https://builds.apache.org/job/PDFBox-trunk/ws/trunk/parent/pom.xml to 

[jira] [Updated] (PDFBOX-2760) NPE in MoveText.process()

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2760?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-2760:

Component/s: (was: PDModel)
 Parsing

 NPE in MoveText.process()
 -

 Key: PDFBOX-2760
 URL: https://issues.apache.org/jira/browse/PDFBOX-2760
 Project: PDFBox
  Issue Type: Bug
  Components: Parsing
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: 455746.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveText.process(MoveText.java:41)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:810)
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveTextSetLeading.process(MoveTextSetLeading.java:45)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:490)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is this:
 {code}
 ET
 240.48 515.64 1.44 0.6 re
 f
 243.36 515.64 1.44 0.6 re
 f
 246.24 515.64 1.44 0.6 re
 f
 249.12 515.64 1.44 0.6 re
 f
 252 515.64 1.44 0.6 re
 f
 254.88 515.64 1.44 0.6 re
 f
 257.76 515.64 1.44 0.6 re
 f
 260.64 515.64 1.44 0.6 re
 f
 263.52 515.64 1.44 0.6 re
 f
 266.4 515.64 1.44 0.6 re
 f
 269.28 515.64 1.44 0.6 re
 f
 23.93.96 1.44 0.6 re
 f
 1 .0.44--32 -1.18 TD
 {code}
 i.e. the operator is called outsitde of BT...ET.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Resolved] (PDFBOX-2760) NPE in MoveText.process()

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2760?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr resolved PDFBOX-2760.
-
Resolution: Fixed

 NPE in MoveText.process()
 -

 Key: PDFBOX-2760
 URL: https://issues.apache.org/jira/browse/PDFBOX-2760
 Project: PDFBox
  Issue Type: Bug
  Components: Parsing
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: 455746.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveText.process(MoveText.java:41)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:810)
   at 
 org.apache.pdfbox.contentstream.operator.text.MoveTextSetLeading.process(MoveTextSetLeading.java:45)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processOperator(PDFStreamEngine.java:829)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.processOperator(PreflightContentStream.java:140)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:490)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is this:
 {code}
 ET
 240.48 515.64 1.44 0.6 re
 f
 243.36 515.64 1.44 0.6 re
 f
 246.24 515.64 1.44 0.6 re
 f
 249.12 515.64 1.44 0.6 re
 f
 252 515.64 1.44 0.6 re
 f
 254.88 515.64 1.44 0.6 re
 f
 257.76 515.64 1.44 0.6 re
 f
 260.64 515.64 1.44 0.6 re
 f
 263.52 515.64 1.44 0.6 re
 f
 266.4 515.64 1.44 0.6 re
 f
 269.28 515.64 1.44 0.6 re
 f
 23.93.96 1.44 0.6 re
 f
 1 .0.44--32 -1.18 TD
 {code}
 i.e. the operator is called outsitde of BT...ET.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Created] (PDFBOX-2761) Casting error for PDRadioButton when trying to exportFDF

2015-04-16 Thread Jason Mackin (JIRA)
Jason Mackin created PDFBOX-2761:


 Summary: Casting error for PDRadioButton when trying to exportFDF
 Key: PDFBOX-2761
 URL: https://issues.apache.org/jira/browse/PDFBOX-2761
 Project: PDFBox
  Issue Type: Bug
  Components: AcroForm
Affects Versions: 2.0.0
Reporter: Jason Mackin


When trying to exportFDF() in PDAcroForm.java, there is a ClassCastException 
thrown when addFieldAndChilden(PDFieldTreeNode docField, ListFDFField 
fdfFields) is called and the docField is a PDRadioButton that has kids and one 
is a PDWidget.

PDRadioButton.getKids() says:
This will get all the kids of this field. The values in the list will either 
be PDWidget or PDField. Normally they will be PDWidget objects unless this is a 
non-terminal field and they will be child PDField objects.

But when kids are returned in the addFieldAndChilden method and one is a 
PDWidget (PDAnnotationWidget in my case), it tries to cast it as a 
PDFieldTreeNode and throws the exception.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Resolved] (PDFBOX-2759) NPE in BaseParser.parseCOSDictionaryValue() due to object reference in content stream

2015-04-16 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-2759?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr resolved PDFBOX-2759.
-
Resolution: Fixed

 NPE in BaseParser.parseCOSDictionaryValue() due to object reference in 
 content stream
 -

 Key: PDFBOX-2759
 URL: https://issues.apache.org/jira/browse/PDFBOX-2759
 Project: PDFBox
  Issue Type: Bug
  Components: Parsing
Affects Versions: 2.0.0
Reporter: Tilman Hausherr
Assignee: Tilman Hausherr
 Fix For: 2.0.0

 Attachments: PDFBOX-2759-317669-p213.pdf


 {code}
 java.lang.NullPointerException
   at 
 org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionaryValue(BaseParser.java:235)
   at 
 org.apache.pdfbox.pdfparser.BaseParser.parseCOSDictionary(BaseParser.java:311)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser.parseNextToken(PDFStreamParser.java:217)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser.access$000(PDFStreamParser.java:47)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser$1.tryNext(PDFStreamParser.java:144)
   at 
 org.apache.pdfbox.pdfparser.PDFStreamParser$1.hasNext(PDFStreamParser.java:157)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStreamOperators(PDFStreamEngine.java:477)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processStream(PDFStreamEngine.java:456)
   at 
 org.apache.pdfbox.contentstream.PDFStreamEngine.processPage(PDFStreamEngine.java:167)
   at 
 org.apache.pdfbox.preflight.content.PreflightContentStream.validatePageContentStream(PreflightContentStream.java:72)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validateContent(SinglePageValidationProcess.java:186)
   at 
 org.apache.pdfbox.preflight.process.reflect.SinglePageValidationProcess.validate(SinglePageValidationProcess.java:89)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:55)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validatePage(PageTreeValidationProcess.java:60)
   at 
 org.apache.pdfbox.preflight.process.PageTreeValidationProcess.validate(PageTreeValidationProcess.java:48)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.callValidation(ContextHelper.java:83)
   at 
 org.apache.pdfbox.preflight.utils.ContextHelper.validateElement(ContextHelper.java:121)
   at 
 org.apache.pdfbox.preflight.PreflightDocument.validate(PreflightDocument.java:164)
   at 
 com.mycompany.preflightmasstest.PreflightChecker.run(PreflightChecker.java:49)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
 {code}
 The cause is a malformed content stream:
 {code}
 (186) Tj
 -132.88 -0.24 TD
 /F1 10.00 Tf
 (TOTAL RESOURCES:) Tj
 162.08 0.00 TD
 (\(DAYS\)) Tj
 155.92 16.48 TD
 (February  15, 2001) Tj
 ET
 Q 0 g 0 G
 endstream
 endobj
 649 0 obj
 4096
 endobj
 647 0 obj
 
 /Type /Page
 /MediaBox [0 0 612 792]
 /Parent 3 0 R
 /Resources /ProcSet [ /PDF /Text ] /Font  /F0 12 0 R /F1 13 0 R  
 /Contents 648 0 R
 /CropBox [0 0 612 792]
 
 endobj
 {code}
 BaseParser.parseCOSDictionaryValue() is used both by PDFParser and by 
 PDFStreamParser because these have a few things in common, e.g. dictionaries. 
 The difference is that document is null for a content stream, so 
 document.getObjectFromPool() fails.
 However the spec tells us: Indirect objects and object references shall not 
 be permitted at all in content streams. I will throw an exception instead.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org