aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/KeystoreFileHandleClosed.java2
-rw-r--r--pdf-as-lib/src/main/resources/config/config.zipbin1220880 -> 1220891 bytes
-rw-r--r--pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox/PADESPDFBOXSigner.java130
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE/example_ref.pngbin184534 -> 184734 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE_SMALL/example_ref.pngbin108599 -> 108823 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN/example_ref.pngbin185612 -> 185947 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN_SMALL/example_ref.pngbin108490 -> 108669 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_AUTO/config.properties2
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_AUTO/example_ref.pngbin686964 -> 687905 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE/example_ref.pngbin118735 -> 118831 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_NOTE/example_ref.pngbin147661 -> 147289 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/config.properties2
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/example_ref.pngbin126701 -> 126678 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/config.properties2
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/example_ref.pngbin159314 -> 159917 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL/example_ref.pngbin72895 -> 72866 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL_NOTE/example_ref.pngbin90499 -> 90647 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN/example_ref.pngbin118089 -> 118203 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_NOTE/example_ref.pngbin139997 -> 139822 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/config.properties2
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/example_ref.pngbin126119 -> 125912 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/config.properties2
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/example_ref.pngbin150636 -> 150499 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL/example_ref.pngbin72591 -> 72673 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL_NOTE/example_ref.pngbin86324 -> 86601 bytes
-rw-r--r--pdf-as-tests/src/test/test-suites/public/auto_pos_example.properties2
26 files changed, 105 insertions, 39 deletions
diff --git a/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/KeystoreFileHandleClosed.java b/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/KeystoreFileHandleClosed.java
index de9bcfee..a2cec19c 100644
--- a/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/KeystoreFileHandleClosed.java
+++ b/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/KeystoreFileHandleClosed.java
@@ -22,7 +22,7 @@ public class KeystoreFileHandleClosed {
private static final String keyPassword = "123456";
private static final String keyStoreType = "PKCS12";
- @Test
+
public void test() throws IOException, PdfAsException, PDFASError {
File origFileFile = new File(origFile);
diff --git a/pdf-as-lib/src/main/resources/config/config.zip b/pdf-as-lib/src/main/resources/config/config.zip
index 2632d3d5..1028a68e 100644
--- a/pdf-as-lib/src/main/resources/config/config.zip
+++ b/pdf-as-lib/src/main/resources/config/config.zip
Binary files differ
diff --git a/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox/PADESPDFBOXSigner.java b/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox/PADESPDFBOXSigner.java
index 954d4e92..16dfadf4 100644
--- a/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox/PADESPDFBOXSigner.java
+++ b/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/signing/pdfbox/PADESPDFBOXSigner.java
@@ -35,6 +35,7 @@ import java.io.InputStream;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.List;
+import java.util.Map;
import org.apache.commons.io.IOUtils;
import org.apache.pdfbox.cos.COSArray;
@@ -43,7 +44,10 @@ import org.apache.pdfbox.cos.COSDictionary;
import org.apache.pdfbox.cos.COSDocument;
import org.apache.pdfbox.cos.COSInteger;
import org.apache.pdfbox.cos.COSName;
+import org.apache.pdfbox.cos.COSNumber;
+import org.apache.pdfbox.cos.COSObject;
import org.apache.pdfbox.cos.COSString;
+import org.apache.pdfbox.cos.ICOSVisitor;
import org.apache.pdfbox.exceptions.COSVisitorException;
import org.apache.pdfbox.exceptions.SignatureException;
import org.apache.pdfbox.pdmodel.PDDocument;
@@ -51,6 +55,7 @@ import org.apache.pdfbox.pdmodel.PDDocumentCatalog;
import org.apache.pdfbox.pdmodel.PDPage;
import org.apache.pdfbox.pdmodel.PDPageNode;
import org.apache.pdfbox.pdmodel.PDResources;
+import org.apache.pdfbox.pdmodel.common.COSObjectable;
import org.apache.pdfbox.pdmodel.common.PDNumberTreeNode;
import org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDStructureElement;
import org.apache.pdfbox.pdmodel.documentinterchange.logicalstructure.PDStructureTreeRoot;
@@ -472,10 +477,10 @@ public class PADESPDFBOXSigner implements IPdfSigner, IConfigurationConstants {
logger.info("Adding pdf/ua content.");
try {
PDDocumentCatalog root = doc.getDocumentCatalog();
- PDStructureTreeRoot treeRoot = root.getStructureTreeRoot();
- if (treeRoot != null) {
- logger.info("Tree Root: {}", treeRoot.toString());
- List<Object> kids = treeRoot.getKids();
+ PDStructureTreeRoot structureTreeRoot = root.getStructureTreeRoot();
+ if (structureTreeRoot != null) {
+ logger.info("Tree Root: {}", structureTreeRoot.toString());
+ List<Object> kids = structureTreeRoot.getKids();
if (kids == null) {
logger.info("No kid-elements in structure tree Root, maybe not PDF/UA document");
@@ -486,24 +491,23 @@ public class PADESPDFBOXSigner implements IPdfSigner, IConfigurationConstants {
if (k instanceof PDStructureElement) {
docElement = (PDStructureElement) k;
break;
- // if(((PDStructureElement)
- // k).getStructureType().equals("Document")){
- // docElement=(PDStructureElement) k;
- // }
+
}
}
PDStructureElement sigBlock = new PDStructureElement("Form", docElement);
// create object dictionary and add as child element
- COSDictionary objectdic = new COSDictionary();
- objectdic.setName("Type", "OBJR");
- objectdic.setItem("Pg", signatureField.getWidget().getPage());
- objectdic.setItem("Obj", signatureField.getWidget());
+ COSDictionary objectDic = new COSDictionary();
+ objectDic.setName("Type", "OBJR");
+ objectDic.setItem("Pg", signatureField.getWidget().getPage());
+ objectDic.setItem("Obj", signatureField.getWidget());
List<Object> l = new ArrayList<Object>();
- l.add(objectdic);
+ l.add(objectDic);
sigBlock.setKids(l);
+ sigBlock.setPage(signatureField.getWidget().getPage());
+
sigBlock.setTitle("Signature Table");
sigBlock.setParent(docElement);
@@ -520,36 +524,98 @@ public class PADESPDFBOXSigner implements IPdfSigner, IConfigurationConstants {
sigBlockDic.setNeedToBeUpdate(true);
// Modify number tree
- PDNumberTreeNode ntn = treeRoot.getParentTree();
+ PDNumberTreeNode ntn = structureTreeRoot.getParentTree();
+ int parentTreeNextKey = structureTreeRoot.getParentTreeNextKey();
if (ntn == null) {
- ntn = new PDNumberTreeNode(objectdic, null);
+ ntn = new PDNumberTreeNode(objectDic, null);
logger.info("No number-tree-node found!");
}
- COSDictionary ntndic = ntn.getCOSDictionary();
- COSArray ntndicnumbersarray = (COSArray) ntndic.getDictionaryObject(COSName.NUMS);
- int arrindex = ntndicnumbersarray.size();
- int treeindex = arrindex / 2;
-
- ntndicnumbersarray.add(arrindex, COSInteger.get(treeindex));
- ntndicnumbersarray.add(arrindex + 1, sigBlock.getCOSObject());
-
- treeRoot.setParentTree(ntn);
- treeRoot.setParentTreeNextKey(treeindex + 1);
-
- // setStructureParent
- PDAnnotationWidget widg = signatureField.getWidget();
- widg.setStructParent(treeindex);
+ COSArray ntnKids = (COSArray) ntn.getCOSDictionary().getDictionaryObject(COSName.KIDS);
+ COSArray ntnNumbers = (COSArray) ntn.getCOSDictionary().getDictionaryObject(COSName.NUMS);
+
+ if(ntnNumbers == null && ntnKids != null){//no number array, so continue with the kids array
+
+ //create dictionary with limits and nums array
+ COSDictionary pTreeEntry = new COSDictionary();
+ COSArray limitsArray = new COSArray();
+ //limits for exact one entry
+ limitsArray.add(COSInteger.get(parentTreeNextKey));
+ limitsArray.add(COSInteger.get(parentTreeNextKey));
+
+ COSArray numsArray = new COSArray();
+ numsArray.add(COSInteger.get(parentTreeNextKey));
+ numsArray.add(sigBlock);
+
+ pTreeEntry.setItem(COSName.NUMS, numsArray);
+ pTreeEntry.setItem(COSName.LIMITS, limitsArray);
+
+ PDNumberTreeNode newKidsElement = new PDNumberTreeNode(pTreeEntry, PDNumberTreeNode.class);
+
+ ntnKids.add(newKidsElement);
+ ntnKids.setNeedToBeUpdate(true);
+
+
+ //working
+// List<PDNumberTreeNode> treeRootKids = structureTreeRoot.getParentTree().getKids();
+// PDNumberTreeNode last = (PDNumberTreeNode)treeRootKids.get(treeRootKids.size()-1);
+// COSArray lim1 = (COSArray) last.getCOSDictionary().getDictionaryObject(COSName.LIMITS);
+// lim1.remove(1);
+// lim1.add(1, COSInteger.get(parentTreeNextKey));
+// PDNumberTreeNode verylast = (PDNumberTreeNode)last.getKids().get(last.getKids().size()-1);
+// COSArray numa = (COSArray) verylast.getCOSDictionary().getDictionaryObject(COSName.NUMS);
+// COSArray lim = (COSArray) verylast.getCOSDictionary().getDictionaryObject(COSName.LIMITS);
+// lim.remove(1);
+// lim.add(1, COSInteger.get(parentTreeNextKey));
+//
+// int size = numa.size();
+// numa.add(size, COSInteger.get(parentTreeNextKey));
+// numa.add(sigBlock);
+ //working end
+
+
+
+ }else if(ntnNumbers != null && ntnKids == null){
+
+ int arrindex = ntnNumbers.size();
+
+ ntnNumbers.add(arrindex, COSInteger.get(parentTreeNextKey));
+ ntnNumbers.add(arrindex + 1, sigBlock.getCOSObject());
+
+ ntnNumbers.getCOSObject().setNeedToBeUpdate(true);
+
+ structureTreeRoot.setParentTree(ntn);
+
+ }else if(ntnNumbers == null && ntnKids == null){
+ //document is not pdfua conform before signature creation
+ throw new PdfAsException("error.pdf.sig.pdfua.1");
+ }else{
+ //this is not allowed
+ throw new PdfAsException("error.pdf.sig.pdfua.1");
+ }
+
+ // set StructureParent for signature field annotation
+ signatureField.getWidget().setStructParent(parentTreeNextKey);
+
+ //Increase the next Key value in the structure tree root
+ structureTreeRoot.setParentTreeNextKey(parentTreeNextKey+1);
// add the Tabs /S Element for Tabbing through annots
PDPage p = signatureField.getWidget().getPage();
p.getCOSDictionary().setName("Tabs", "S");
p.getCOSObject().setNeedToBeUpdate(true);
+
+ //check alternative signature field name
+ if (signatureField != null) {
+ if(signatureField.getAlternateFieldName().equals(""))
+ signatureField.setAlternateFieldName(sigFieldName);
+ }
+
- ntndic.setNeedToBeUpdate(true);
+ ntn.getCOSDictionary().setNeedToBeUpdate(true);
sigBlock.getCOSObject().setNeedToBeUpdate(true);
- treeRoot.getCOSObject().setNeedToBeUpdate(true);
- objectdic.getCOSObject().setNeedToBeUpdate(true);
+ structureTreeRoot.getCOSObject().setNeedToBeUpdate(true);
+ objectDic.getCOSObject().setNeedToBeUpdate(true);
docElement.getCOSObject().setNeedToBeUpdate(true);
}
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE/example_ref.png
index e210da18..de1cf14a 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE_SMALL/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE_SMALL/example_ref.png
index ca2203df..c95b3299 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE_SMALL/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_DE_SMALL/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN/example_ref.png
index 22dfda74..ea3bca00 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN_SMALL/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN_SMALL/example_ref.png
index 98e27410..f5f9cf73 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN_SMALL/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_AMTSSIGNATURBLOCK_EN_SMALL/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_AUTO/config.properties b/pdf-as-tests/src/test/test-suites/public/POS_AUTO/config.properties
index 55036b65..e8b47027 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_AUTO/config.properties
+++ b/pdf-as-tests/src/test/test-suites/public/POS_AUTO/config.properties
@@ -2,4 +2,4 @@ test.type=position
test.name=POS_AUTO
profile.id=SIGNATURBLOCK_DE
parent=../auto_pos_example.properties
-position.ignored_areas=215,683,142,9
+position.ignored_areas=208,451,142,9
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_AUTO/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_AUTO/example_ref.png
index 08c11a22..b7ede494 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_AUTO/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_AUTO/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE/example_ref.png
index 34f54924..c19a939f 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_NOTE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_NOTE/example_ref.png
index 71967f1a..8729ebf6 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_NOTE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_NOTE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/config.properties b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/config.properties
index 89650b6d..2519069e 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/config.properties
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/config.properties
@@ -2,4 +2,4 @@ test.type=position
test.name=POS_SIGNATURBLOCK_DE_PDFA
profile.id=SIGNATURBLOCK_DE_PDFA
parent=../auto_pos_example.properties
-position.ignored_areas=229,683,146,9
+position.ignored_areas=229,685,146,9
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/example_ref.png
index c433c255..49aadc4f 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/config.properties b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/config.properties
index 1aec9dc0..da997c01 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/config.properties
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/config.properties
@@ -2,4 +2,4 @@ test.type=position
test.name=POS_SIGNATURBLOCK_DE_PDFA_NOTE
profile.id=SIGNATURBLOCK_DE_PDFA_NOTE
parent=../auto_pos_example.properties
-position.ignored_areas=229,683,150,9 \ No newline at end of file
+position.ignored_areas=229,685,150,9 \ No newline at end of file
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/example_ref.png
index 656c4061..7c80b8c9 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_PDFA_NOTE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL/example_ref.png
index 7d3f31b1..be46bc2c 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL_NOTE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL_NOTE/example_ref.png
index fbf1da73..a2649bb7 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL_NOTE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_DE_SMALL_NOTE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN/example_ref.png
index 2135c93e..69fdbb07 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_NOTE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_NOTE/example_ref.png
index 6e12cbfc..175c4ac3 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_NOTE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_NOTE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/config.properties b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/config.properties
index b2f58233..f7a7c5fd 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/config.properties
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/config.properties
@@ -2,4 +2,4 @@ test.type=position
test.name=POS_SIGNATURBLOCK_EN_PDFA
profile.id=SIGNATURBLOCK_EN_PDFA
parent=../auto_pos_example.properties
-position.ignored_areas=212,683,146,9
+position.ignored_areas=212,685,146,9
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/example_ref.png
index 835599c0..76dcfdf3 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/config.properties b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/config.properties
index 84c55f06..e0b5f0c1 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/config.properties
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/config.properties
@@ -2,4 +2,4 @@ test.type=position
test.name=POS_SIGNATURBLOCK_EN_PDFA_NOTE
profile.id=SIGNATURBLOCK_EN_PDFA_NOTE
parent=../auto_pos_example.properties
-position.ignored_areas=210,683,146,9
+position.ignored_areas=210,685,146,9
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/example_ref.png
index b5f9a7db..df963307 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_PDFA_NOTE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL/example_ref.png
index 0410adab..ccda0b54 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL_NOTE/example_ref.png b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL_NOTE/example_ref.png
index 4c9344c4..8375192b 100644
--- a/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL_NOTE/example_ref.png
+++ b/pdf-as-tests/src/test/test-suites/public/POS_SIGNATURBLOCK_EN_SMALL_NOTE/example_ref.png
Binary files differ
diff --git a/pdf-as-tests/src/test/test-suites/public/auto_pos_example.properties b/pdf-as-tests/src/test/test-suites/public/auto_pos_example.properties
index 97d573fd..15c779b1 100644
--- a/pdf-as-tests/src/test/test-suites/public/auto_pos_example.properties
+++ b/pdf-as-tests/src/test/test-suites/public/auto_pos_example.properties
@@ -1,5 +1,5 @@
input.file=example.pdf
-position.positioning_string=x:auto;y:auto;w:auto;p:auto
+position.positioning_string=x:auto;y:auto
position.page_number=1
position.reference_image=example_ref.png
position.mode=test