I would like to know if AEM provides libraries for creating hash of pdf document and embedding digital certificate in pdf
Solved! Go to Solution.
Topics help categorize Community content and increase your ability to discover relevant content.
Views
Replies
Total Likes
Hi @RamaniBa ,
I checked further and it seems it is not OOB (atleast not anymore). You can still go to depfinder (localhost:4502/system/console/depfinder) and check if your version of AEM exports some version of pdfbox. If yes, then you can essentially just add the dependency in your pom files and then can use its APIs
Otherwise, you can embed it in your project in the configuration section of filevault-package-maven-plugin generally located in all/pom.xml as below.
<embedded>
<groupId>org.apache.pdfbox</groupId>
<artifactId>pdfbox</artifactId>
<target>/apps/your-application-vendor-packages/container/install</target>
</embedded>
and you will also have to add the dependency
<dependency>
<groupId>org.apache.pdfbox</groupId>
<artifactId>pdfbox</artifactId>
<version>2.0.24</version>
</dependency>
Adjust the version as per your requirement. And then you should be able to use pdfbox features.
You can do similar steps to embed some other jar if you are interested in some library other than pdfbox
Hope this helps.
Hi @RamaniBa , Have a look at https://experienceleague.adobe.com/en/docs/experience-manager-65/content/forms/developer-reference/p... and see if this helps.
You can checkout apache pdfbox to see if it fullfills your requirement.
You can embed and add the dependency and you should be able to use it. Below is the sample dependency for AEM cloud environment
<dependency>
<artifactId>pdfbox</artifactId>
<version>2.0.24</version>
<groupId>org.apache.pdfbox</groupId>
<scope>provided</scope>
</dependency>
An example on how to create visible signatures : https://eideasy.com/creating-visible-signatures-with-apache-pdfbox-v2-java-library/
Hope this helps.
Do you mean that I import Apache PDF box and can be used with AEM. If so can you elaborate the steps that import the Apache PDF Box libraries and how to use this library in the AEM SignatureService code
Hi @RamaniBa ,
I checked further and it seems it is not OOB (atleast not anymore). You can still go to depfinder (localhost:4502/system/console/depfinder) and check if your version of AEM exports some version of pdfbox. If yes, then you can essentially just add the dependency in your pom files and then can use its APIs
Otherwise, you can embed it in your project in the configuration section of filevault-package-maven-plugin generally located in all/pom.xml as below.
<embedded>
<groupId>org.apache.pdfbox</groupId>
<artifactId>pdfbox</artifactId>
<target>/apps/your-application-vendor-packages/container/install</target>
</embedded>
and you will also have to add the dependency
<dependency>
<groupId>org.apache.pdfbox</groupId>
<artifactId>pdfbox</artifactId>
<version>2.0.24</version>
</dependency>
Adjust the version as per your requirement. And then you should be able to use pdfbox features.
You can do similar steps to embed some other jar if you are interested in some library other than pdfbox
Hope this helps.
Views
Likes
Replies