I successfully reach the PAdES level B-B, B-T, B-LT in the itext using the below code.
// st is PdfStamper
var adobeLtvEnabling = new AdobeLtvEnabling(st);
adobeLtvEnabling.enable(ocsp, crl);
Unable to get level B-LTA using itext.
The @mki original comment.
As mentioned, AdobeLtvEnabling ignores time stamps; signature time stamps to be more exact. To process them, too, you need to extend the loop in enable to not only walk the certificate path of pdfPKCS7.getSigningCertificate()
but also of the signing certificate of pdfPKCS7.getTimeStampToken()
if applicable. Of course, it is possible that in your case this is not necessary: if the TSA certificate immediately is on the Trusted Lists (and not merely an ancestor in its certificate path), then no extra validation information is required. This is the case for some but not for all TSAs.
The @mki suggested extending the loop and using Java pdfPKCS7.getTimeStampToken()
in the post https://stackoverflow.com/questions/71351592/itext-pades-baseline-lt-lta
I found pdfPKCS7.TimeStampToken()
in C# but no idea about how to use it and where to use it to get the B-LTA levels.
I am looking ready to use code which is works with the Itext 5.5.13.2 and C# and get the B-LTA levels.
Is anyone has already done it? Please share the code.
Thanks in advance.