You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@pdfbox.apache.org by Isaias Barroso <is...@gmail.com> on 2015/02/27 05:44:29 UTC

[PDFBOX-2.0] PDF Size after Signature

Hi all,

I'm using PDFBOX 2.0 to sign some documents and I found that the size of
signed file is too big if compared with 1.8 version, sometimes those files
get their sizes  increased in 100% or more. When the same file is signed
using 1.8 the file is increased in a expected way.

Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0

Signed With 1.8:
https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0

Signed With 2.0:
https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0

There is some option to reduce the signed file size on 2.0?

Best regards
-- 
Isaías Barroso
Belo Horizonte - MG

Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Andreas Lehmkühler <an...@lehmi.de>.
Hi,

> Maruan Sahyoun <sa...@fileaffairs.de> hat am 27. Februar 2015 um 09:19
> geschrieben:
> 
> 
> Hi Andreas,
> 
> the changes you made were these before or after the ones I did to COSBase wrt
> to immutable objects (PDFBOX-2685)?
My changes (PDFBOX-1822, PDFBOX-2515) where made prior to PDFBOX-2685. Saying
that, r1659998 could introduce a regression. I had a quick look and maybe the
changes made to COSWriter are the root cause. But we have to debug that first to
be sure.

BR
Andreas Lehmkühler

> BR
> Maruan
> 
> Am 27.02.2015 um 08:45 schrieb Andreas Lehmkühler <an...@lehmi.de>:
> 
> > Hi,
> > 
> >> Tilman Hausherr <TH...@t-online.de> hat am 27. Februar 2015 um 07:35
> >> geschrieben:
> >> 
> >> 
> >> Did you just start with signing or is this a recent phenomenon, i.e. 
> >> didn't happen a month ago?
> >> 
> >> I looked at both files - in the 1.8 one, only the changed objects appear 
> >> after EOF. In the 2.0 one, all objects are there ?!
> > Correct, something went wrong when appending the changed objects only. It
> > work
> > for 
> > me when I fixed the encryption stuff. I seems as if some recent change
> > introduced
> > this regression.
> > 
> > @Isaias
> > Which exact version/revision of the trunk are you using?
> > 
> > BR
> > Andreas Lehmkühler
> >> 
> >> Tilman
> >> 
> >> Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
> >>> Hi all,
> >>> 
> >>> I'm using PDFBOX 2.0 to sign some documents and I found that the size of
> >>> signed file is too big if compared with 1.8 version, sometimes those files
> >>> get their sizes  increased in 100% or more. When the same file is signed
> >>> using 1.8 the file is increased in a expected way.
> >>> 
> >>> Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
> >>> 
> >>> Signed With 1.8:
> >>> https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
> >>> 
> >>> Signed With 2.0:
> >>> https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
> >>> 
> >>> There is some option to reduce the signed file size on 2.0?
> >>> 
> >>> Best regards
> >> 
> >> 
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> >> For additional commands, e-mail: users-help@pdfbox.apache.org
> >> 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> > For additional commands, e-mail: users-help@pdfbox.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Maruan Sahyoun <sa...@fileaffairs.de>.
Hi Andreas,

the changes you made were these before or after the ones I did to COSBase wrt to immutable objects (PDFBOX-2685)?

BR
Maruan

Am 27.02.2015 um 08:45 schrieb Andreas Lehmkühler <an...@lehmi.de>:

> Hi,
> 
>> Tilman Hausherr <TH...@t-online.de> hat am 27. Februar 2015 um 07:35
>> geschrieben:
>> 
>> 
>> Did you just start with signing or is this a recent phenomenon, i.e. 
>> didn't happen a month ago?
>> 
>> I looked at both files - in the 1.8 one, only the changed objects appear 
>> after EOF. In the 2.0 one, all objects are there ?!
> Correct, something went wrong when appending the changed objects only. It work
> for 
> me when I fixed the encryption stuff. I seems as if some recent change
> introduced
> this regression.
> 
> @Isaias
> Which exact version/revision of the trunk are you using?
> 
> BR
> Andreas Lehmkühler
>> 
>> Tilman
>> 
>> Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
>>> Hi all,
>>> 
>>> I'm using PDFBOX 2.0 to sign some documents and I found that the size of
>>> signed file is too big if compared with 1.8 version, sometimes those files
>>> get their sizes  increased in 100% or more. When the same file is signed
>>> using 1.8 the file is increased in a expected way.
>>> 
>>> Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
>>> 
>>> Signed With 1.8:
>>> https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
>>> 
>>> Signed With 2.0:
>>> https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
>>> 
>>> There is some option to reduce the signed file size on 2.0?
>>> 
>>> Best regards
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
>> For additional commands, e-mail: users-help@pdfbox.apache.org
>> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org


Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Isaias Barroso <is...@gmail.com>.
Hi Andreas,

I'm getting the SNAPSHOT from Maven Snapshot Repository
https://repository.apache.org/content/groups/snapshots.

Thank yout


On Fri, Feb 27, 2015 at 4:45 AM, Andreas Lehmkühler <an...@lehmi.de>
wrote:

> Hi,
>
> > Tilman Hausherr <TH...@t-online.de> hat am 27. Februar 2015 um 07:35
> > geschrieben:
> >
> >
> > Did you just start with signing or is this a recent phenomenon, i.e.
> > didn't happen a month ago?
> >
> > I looked at both files - in the 1.8 one, only the changed objects appear
> > after EOF. In the 2.0 one, all objects are there ?!
> Correct, something went wrong when appending the changed objects only. It
> work
> for
> me when I fixed the encryption stuff. I seems as if some recent change
> introduced
> this regression.
>
> @Isaias
> Which exact version/revision of the trunk are you using?
>
> BR
> Andreas Lehmkühler
> >
> > Tilman
> >
> > Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
> > > Hi all,
> > >
> > > I'm using PDFBOX 2.0 to sign some documents and I found that the size
> of
> > > signed file is too big if compared with 1.8 version, sometimes those
> files
> > > get their sizes  increased in 100% or more. When the same file is
> signed
> > > using 1.8 the file is increased in a expected way.
> > >
> > > Original File:
> https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
> > >
> > > Signed With 1.8:
> > > https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
> > >
> > > Signed With 2.0:
> > > https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
> > >
> > > There is some option to reduce the signed file size on 2.0?
> > >
> > > Best regards
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> > For additional commands, e-mail: users-help@pdfbox.apache.org
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org
>
>


-- 
Isaías Barroso
Belo Horizonte - MG

Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Andreas Lehmkühler <an...@lehmi.de>.
Hi,

> Tilman Hausherr <TH...@t-online.de> hat am 27. Februar 2015 um 07:35
> geschrieben:
> 
> 
> Did you just start with signing or is this a recent phenomenon, i.e. 
> didn't happen a month ago?
> 
> I looked at both files - in the 1.8 one, only the changed objects appear 
> after EOF. In the 2.0 one, all objects are there ?!
Correct, something went wrong when appending the changed objects only. It work
for 
me when I fixed the encryption stuff. I seems as if some recent change
introduced
this regression.

@Isaias
Which exact version/revision of the trunk are you using?

BR
Andreas Lehmkühler
> 
> Tilman
> 
> Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
> > Hi all,
> >
> > I'm using PDFBOX 2.0 to sign some documents and I found that the size of
> > signed file is too big if compared with 1.8 version, sometimes those files
> > get their sizes  increased in 100% or more. When the same file is signed
> > using 1.8 the file is increased in a expected way.
> >
> > Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
> >
> > Signed With 1.8:
> > https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
> >
> > Signed With 2.0:
> > https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
> >
> > There is some option to reduce the signed file size on 2.0?
> >
> > Best regards
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Isaias Barroso <is...@gmail.com>.
Hi Andreas,

I've tested it now. The problem was fixed. Follow evidence to the same file
used on initial tests.

https://www.dropbox.com/s/e8epkdtue74g1w2/sign_me_signed_2.0-blow-fixed.pdf?dl=0


Thanks



On Sat, Feb 28, 2015 at 1:20 PM, Andreas Lehmkuehler <an...@lehmi.de>
wrote:

> Hi
>
> Am 27.02.2015 um 11:00 schrieb Isaias Barroso:
>
>> Hi Tilman,
>>
>> I've started testing the signing feature with 2.0 before migrate from 1.8
>> to 2.0, so my focus was to get the document signed, Andreas has solved
>> some
>> problems and I started to use, just now that I migrated the real code I've
>> noticed the size increase, in this way I can't say if it is recent or not.
>>
> I've fixed the regression. The recent trunk works as expected and no
> longer blow up the size of a signed pdf.
>
>  Thank you
>>
> Thanks for the report
>
> BR
> Andreas Lehmkühler
>
>
>
>> On Fri, Feb 27, 2015 at 3:35 AM, Tilman Hausherr <TH...@t-online.de>
>> wrote:
>>
>>  Did you just start with signing or is this a recent phenomenon, i.e.
>>> didn't happen a month ago?
>>>
>>> I looked at both files - in the 1.8 one, only the changed objects appear
>>> after EOF. In the 2.0 one, all objects are there ?!
>>>
>>> Tilman
>>>
>>> Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
>>>
>>>   Hi all,
>>>
>>>>
>>>> I'm using PDFBOX 2.0 to sign some documents and I found that the size of
>>>> signed file is too big if compared with 1.8 version, sometimes those
>>>> files
>>>> get their sizes  increased in 100% or more. When the same file is signed
>>>> using 1.8 the file is increased in a expected way.
>>>>
>>>> Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?
>>>> dl=0
>>>>
>>>> Signed With 1.8:
>>>> https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
>>>>
>>>> Signed With 2.0:
>>>> https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
>>>>
>>>> There is some option to reduce the signed file size on 2.0?
>>>>
>>>> Best regards
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
>>> For additional commands, e-mail: users-help@pdfbox.apache.org
>>>
>>>
>>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org
>
>


-- 
Isaías Barroso
Belo Horizonte - MG

Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Andreas Lehmkuehler <an...@lehmi.de>.
Hi

Am 27.02.2015 um 11:00 schrieb Isaias Barroso:
> Hi Tilman,
>
> I've started testing the signing feature with 2.0 before migrate from 1.8
> to 2.0, so my focus was to get the document signed, Andreas has solved some
> problems and I started to use, just now that I migrated the real code I've
> noticed the size increase, in this way I can't say if it is recent or not.
I've fixed the regression. The recent trunk works as expected and no longer blow 
up the size of a signed pdf.

> Thank you
Thanks for the report

BR
Andreas Lehmkühler

>
> On Fri, Feb 27, 2015 at 3:35 AM, Tilman Hausherr <TH...@t-online.de>
> wrote:
>
>> Did you just start with signing or is this a recent phenomenon, i.e.
>> didn't happen a month ago?
>>
>> I looked at both files - in the 1.8 one, only the changed objects appear
>> after EOF. In the 2.0 one, all objects are there ?!
>>
>> Tilman
>>
>> Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
>>
>>   Hi all,
>>>
>>> I'm using PDFBOX 2.0 to sign some documents and I found that the size of
>>> signed file is too big if compared with 1.8 version, sometimes those files
>>> get their sizes  increased in 100% or more. When the same file is signed
>>> using 1.8 the file is increased in a expected way.
>>>
>>> Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
>>>
>>> Signed With 1.8:
>>> https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
>>>
>>> Signed With 2.0:
>>> https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
>>>
>>> There is some option to reduce the signed file size on 2.0?
>>>
>>> Best regards
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
>> For additional commands, e-mail: users-help@pdfbox.apache.org
>>
>>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Isaias Barroso <is...@gmail.com>.
Hi Tilman,

I've started testing the signing feature with 2.0 before migrate from 1.8
to 2.0, so my focus was to get the document signed, Andreas has solved some
problems and I started to use, just now that I migrated the real code I've
noticed the size increase, in this way I can't say if it is recent or not.

Thank you

On Fri, Feb 27, 2015 at 3:35 AM, Tilman Hausherr <TH...@t-online.de>
wrote:

> Did you just start with signing or is this a recent phenomenon, i.e.
> didn't happen a month ago?
>
> I looked at both files - in the 1.8 one, only the changed objects appear
> after EOF. In the 2.0 one, all objects are there ?!
>
> Tilman
>
> Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
>
>  Hi all,
>>
>> I'm using PDFBOX 2.0 to sign some documents and I found that the size of
>> signed file is too big if compared with 1.8 version, sometimes those files
>> get their sizes  increased in 100% or more. When the same file is signed
>> using 1.8 the file is increased in a expected way.
>>
>> Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
>>
>> Signed With 1.8:
>> https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
>>
>> Signed With 2.0:
>> https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
>>
>> There is some option to reduce the signed file size on 2.0?
>>
>> Best regards
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
> For additional commands, e-mail: users-help@pdfbox.apache.org
>
>


-- 
Isaías Barroso
Belo Horizonte - MG

Re: [PDFBOX-2.0] PDF Size after Signature

Posted by Tilman Hausherr <TH...@t-online.de>.
Did you just start with signing or is this a recent phenomenon, i.e. 
didn't happen a month ago?

I looked at both files - in the 1.8 one, only the changed objects appear 
after EOF. In the 2.0 one, all objects are there ?!

Tilman

Am 27.02.2015 um 05:44 schrieb Isaias Barroso:
> Hi all,
>
> I'm using PDFBOX 2.0 to sign some documents and I found that the size of
> signed file is too big if compared with 1.8 version, sometimes those files
> get their sizes  increased in 100% or more. When the same file is signed
> using 1.8 the file is increased in a expected way.
>
> Original File: https://www.dropbox.com/s/s8p40ukorhchtcu/sign_me.pdf?dl=0
>
> Signed With 1.8:
> https://www.dropbox.com/s/ty8axylq8ol6204/sign_me_signed_1.8.pdf?dl=0
>
> Signed With 2.0:
> https://www.dropbox.com/s/ge1x3mdpqlalnvq/sign_me_signed_2.0.pdf?dl=0
>
> There is some option to reduce the signed file size on 2.0?
>
> Best regards


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org