|
View:
New views
3 Messages
—
Rating Filter:
Alert me
|
|
|
How to edit the appearance of an existing digital signature?Hello all,
first of all, many thanks again to Paulo, who helped me a lot in my previous question. My next question is: How to edit the appearance of an existing digital signature? Is this possible? One thing that I want to do is to sign a pdf and display the digital signature in base64 in the n2 layer. The way I thought to do was: 1) Sign the pdf as shown in the tutorial 2) Read the signed pdf file and retrieve the signature bytes (thanks to Paulo who showed me how to do it!) 3) Get the n2 layer of the signature and change it. But when I try to do PdfReader reader2 = new PdfReader(baos.toByteArray()); // baos is the byte array where the signed pdf is stored PdfStamper stp2 = new PdfStamper(reader2, fout, '\0', true); PdfSignatureAppearance sap2 = stp2.getSignatureAppearance(); I get a java.lang.NullPointerException whenever I try doing anything with sap2, like sap2.getLayer(2) or sap2.setLayer2Text(). So, I was wondering what would be the right way to do, if there is one. Any help would be greatly appreciated. Thanks in advance, Luiz Kobayashi Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ iText-questions mailing list iText-questions@... https://lists.sourceforge.net/lists/listinfo/itext-questions |
|
|
Re: How to edit the appearance of an existing digitalsignature?You're not the first to ask that and it's not possible without invalidating
the signature. In effect, for that to work you would need to sign the signature itself a bit like an endless loop. Paulo ----- Original Message ----- From: "Luiz Kobayashi" <luiz.kobayashi@...> To: <itext-questions@...> Sent: Thursday, July 06, 2006 10:38 PM Subject: [iText-questions] How to edit the appearance of an existing digitalsignature? > Hello all, > > first of all, many thanks again to Paulo, who helped me a lot in my > previous question. > > My next question is: How to edit the appearance of an existing digital > signature? Is this possible? > > One thing that I want to do is to sign a pdf and display the digital > signature in base64 in the n2 layer. > > The way I thought to do was: > 1) Sign the pdf as shown in the tutorial > 2) Read the signed pdf file and retrieve the signature bytes (thanks to > Paulo who showed me how to do it!) > 3) Get the n2 layer of the signature and change it. > > But when I try to do > > PdfReader reader2 = new PdfReader(baos.toByteArray()); // baos is the > byte array where the signed pdf is stored > PdfStamper stp2 = new PdfStamper(reader2, fout, '\0', true); > PdfSignatureAppearance sap2 = stp2.getSignatureAppearance(); > > I get a java.lang.NullPointerException whenever I try doing anything > with sap2, like sap2.getLayer(2) or sap2.setLayer2Text(). > > So, I was wondering what would be the right way to do, if there is one. > > Any help would be greatly appreciated. > > Thanks in advance, > > Luiz Kobayashi > > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > iText-questions mailing list > iText-questions@... > https://lists.sourceforge.net/lists/listinfo/itext-questions Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ iText-questions mailing list iText-questions@... https://lists.sourceforge.net/lists/listinfo/itext-questions |
|
|
Re: How to edit the appearance of an existing digitalsignature?I would like to thank Paulo, Mark and Leonard for their valuable input.
Many thanks! I'll have to find another way then... Thanks again, Luiz Kobayashi <itext-questions-bounces@...> Paulo Soares escreveu: > You're not the first to ask that and it's not possible without invalidating > the signature. In effect, for that to work you would need to sign the > signature itself a bit like an endless loop. > > Paulo > ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ iText-questions mailing list iText-questions@... https://lists.sourceforge.net/lists/listinfo/itext-questions |
| Free embeddable forum powered by Nabble | Forum Help |