Expand my Community achievements bar.

July 31st AEM Gems Webinar: Elevate your AEM development to master the integration of private GitHub repositories within AEM Cloud Manager.
SOLVED

Digital Signature Issue

Avatar

Level 2

Jasmin or anyone who can help,

I created a PKCS#12 Digital ID file in Acrobat Pro 7 on my PC. When I sign a document in Workspace it places the signature just fine but when I submit the document the signature does not travel with the form like the rest of the inputted data.

Any help you can give with this issue would be much appreciated.

Thanks,

Brian

1 Accepted Solution

Avatar

Correct answer by
Former Community Member

You are right. I was typing too quickly. It should be the Export Data.

To fix the error message you are getting, and off the top of my head, achieve your desired result you will need to register the xfa namespace.  To that right click on an empty area of your process and click properties.  In the properties section you should be able to click the ADVANCED tab.  You will then notice an area for "Register namespace prefixes...".  Here you can click the + button to add the prefix of "xfa" and the namespace "http://www.xfa.org/schema/xfa-data/1.0/"

Try running the process again and it should work.

View solution in original post

10 Replies

Avatar

Former Community Member

Your form is most likely configured to submit xml/xdp whichi is why you are losing your signature. Be sure the form is configured to submit PDF

Avatar

Level 2

I changed the process to use a PDF instead of an XDP and it doesn't seem to matter as the signature still doesn't travel with the form.

Avatar

Former Community Member

A couple of things to look at...

1) Be sure the renderer in the process is set to render only once or else it will render again and you will lose your signature (in the form variable there will be a button for Advanced... that brings you to the rendere. There will be a checkbox so you can be sure to render only once)

2) Be sure that in the form itself in the properties of the button the submit as: parameter is set to PDF and not the default of XDP

That should work.

Avatar

Level 10

It's the submit button's property you need to change and not the form itself.

If you click on submit button (in Designer) make sure it submits PDF and not XDP data.

Jasmin

Avatar

Level 2

Jasmin, Maceo29, Jayan, or whoever can help,

Ok changing the submit button to submit a PDF instead of the default XDP works as far as keeping the signature with the document but it causes other problems in my process.

In order to keep the PDF from rerendering each time and thus removing the signature I had to change the initForm data type from XFAform to Document Form and check the call the rendering service only once checkbox as Maceo29 said.

Now I can't figure out how to access the data in the form so I can use it to set some process variables. With an XFAform I am able to access the data from the form using xpath /process_data/initForm/object/data/xdp/datasets/data and then add my XML path to the data and map that to a process variable in a Set Value activity.

Now my options after /process_data/initForm/object are document and formURL and I'm not sure what to do. If I add an exportData FormDataIntegration activity and input xpath /process_data/initForm/object/@document and output to a docData document type process variable I get something I can then use to set a FormXML XML type process variable in a Set Value activity. But I can't figure out how to access the individual nodes of XML data to set the process variables.

If I try to map a process variable to xpath /process_data/FormXML/Form/P1/fromName the process moves along but the variables aren't set.

If I try to map a process variable to xpath /process_data/FormXML/xfa:datasets/xfa:data/Form/P1/fromName I get a Cannot resolve namespace prefix 'xfa' error.

So what can I do to access those specific XML data nodes or is there a better way for me to do what I am trying to do now?

Thanks again for everyone's help.

Avatar

Former Community Member

There are a couple of things you can do now that this has come about. It will depend on your workflow so I'll give the two options I know of....

Option 1:

You can keep things how you have changed them and add another step into the process that will accept the PDF as input and output the XML data to a variable. This operation is the import Data operation from the FormDataIntegration service. You can then use the data in the variable to populate your process variables.  This is probably the best where you will have multiple signatures and multiple spots in your workflow.

Option 2:

You would change things back (that is submit XDP and have it arrive in an XFAForm variable). This way you would be able to navigate the xml to set your process varialbes. The one change in order to keep the signature is that in the form design you would have to check off the 'include PDF' option that becomes available for the submit button when the submit type is  set to XDP.  You could then add a step in your process that would extract the signed PDF from the xdp data.  In this case you would need to have the Output Solution Component because it has an operation convertXDPtoPDF.  This is probably the best where you are only gathering signature(s) at one point and simply want to be able to get the singed PDF for arhival but use the data through the rest of the process

Hope that helps

Avatar

Level 2

I need to add signatures throughout the workflow so I am trying to work with option 1. Are you sure it isn't the Export Data operation from the FormDataIntegration service not the Import Data operation?

With the Export Data operation I can Input xpath /process_data/initForm/object/@document where initForm is a Document Form data type and I can Output xpath /process_data/FormXML where FormXML is an XML data type. That XML looks good when I look at it in the playback. But I can't figure out how to access the data in that XML.

My XML looks like:

<xfa:datasets xmlns:xfa="http://www.xfa.org/schema/xfa-data/1.0/" xmlns:dd="http://ns.adobe.com/data-description/" xmlns:xfdf="http://ns.adobe.com/xfdf/">
    <xfa:data>
        <Form>
            <P1>
                <toName type="VARCHAR2">Name1</toName>
                <fromName>Name2</fromName>
            </P1>

        </Form>

    </xfa:data>
</xfa:datasets>

If in the next activity a SetValue activity I try to set Location /process_data/@processField1, where processField1 is a string data type  to Expression /process_data/FormXML/Form/P1/fromName the process doesn't bog down but I get nothing in /process_data/@processField1.

If in the SetValue activity I try to set Location /process_data/@processField1, where processField1 is a string data type  to Expression /process_data/FormXML/xfa:datasets/xfa:data/Form/P1/fromName I get a Cannot resolve namespace prefix 'xfa' error and the process stops.

If I use an Import Data operation it outputs a Data merged PDF and I'm not sure what good that does me and it also wants in addition to the Input PDF Input data and I don't have any data to add to the PDF because my data is already in the PDF that was submitted.

Thanks again for your help.

Avatar

Correct answer by
Former Community Member

You are right. I was typing too quickly. It should be the Export Data.

To fix the error message you are getting, and off the top of my head, achieve your desired result you will need to register the xfa namespace.  To that right click on an empty area of your process and click properties.  In the properties section you should be able to click the ADVANCED tab.  You will then notice an area for "Register namespace prefixes...".  Here you can click the + button to add the prefix of "xfa" and the namespace "http://www.xfa.org/schema/xfa-data/1.0/"

Try running the process again and it should work.

Avatar

Level 2

That worked, thanks so much.

Interestingly I also found that if I did this:

In the SetValue activity I set Location /process_data/@processField1 Expression /process_data/FormXML/datasets/data/Form/P1/fromName to

it worked also.

So if you register the namespace the Expression would be /process_data/FormXML/xfa:datasets/xfa:data/Form/P1/fromName but if you don't register the namespace using the Expression /process_data/FormXML/datasets/data/Form/P1/fromName works.

Avatar

Level 7

I have noticed a funny behavior. When I submit a signed form by email and open it Workspace, it retains the signature. However, if I sign the form in Workspace it doesn't carry over to the next step...

In both cases the form is submitted as XDP. How can I keep the signature?

Aditya

The following has evaluated to null or missing: ==> liqladmin("SELECT id, value FROM metrics WHERE id = 'net_accepted_solutions' and user.id = '${acceptedAnswer.author.id}'").data.items [in template "analytics-container" at line 83, column 41] ---- Tip: It's the step after the last dot that caused this error, not those before it. ---- Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign answerAuthorNetSolutions = li... [in template "analytics-container" at line 83, column 5] ----