'PDFBox doesn't show correct validating PDF digital signature after it was modified

Currently I'm working on PDFBox library to provide digital signature solution. My problem is detecting the pdf that has been modified. On Adobe Reader can detect this modification but on PDFBox it doesn't detect the document has been modified (I've using CoverWholeDocument method to detect the signature). The same case on DSS Europe doesn't give the give correct validation (https://ec.europa.eu/cefdigital/DSS/webapp-demo/validation) link modified pdf

Does anyone can help this problem using PDFBox how to detect this signature is invalid?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source