Title:
[ANeff] Bug for: cfpdf(action="import" incorrectly overwrites some metadata
| View in TrackerStatus/Resolution/Reason: Closed/Won't Fix/
Reporter/Name(from Bugbase): / Aaron Neff (External User)
Created: 03/09/2016
Components: Document Management
Versions: 2016
Failure Type: Unspecified
Found In Build/Fixed In Build: Alpha_v12 /
Priority/Frequency: Normal / Unknown
Locale/System: English / Win All
Vote Count: 0
cfpdf's action="import" incorrectly overwrites some metadata
Steps to reproduce:
1) Run below code
2) Compare CFDocumentMetadataBefore.xmp and CFDocumentMetadataAfter.xmp
2a) See pdf:Producer changed from "iText 2.1.0 (by lowagie.com)" to "Acrobat Web Capture 9.0" (bug b/c pdf:Producer is the PDF's producer and never to be overwritten)
2b) See xmp:CreateDate changed (bug b/c xmp:CreateDate is the date the resource was created and never to be overwritten)
2c) See xmpMM:DocumentID changed from undefined to defined (bug b/c xmpMM:DocumentID is only created once per resource and never to be overwritten)
3) Compare CFHTMLToPDFMetadataBefore.xmp and CFHTMLToPDFMetadataAfter.xmp
3a) See pdf:Producer changed from "Acrobat Web Capture 9.0" to "iText 2.1.0 (by lowagie.com)" (bug b/c pdf:Producer is the PDF's producer and never to be overwritten)
3b) See xmp:CreateDate changed (bug b/c xmp:CreateDate is the date the resource was created and never to be overwritten)
3c) See xmpMM:DocumentID changed (bug b/c xmpMM:DocumentID is only created once per resource and never to be overwritten)
<cfscript>
//export metadata from cfdocument PDF
cfdocument(format="pdf", filename=expandPath('./CFDocumentBefore.pdf'), overwrite="true") {writeOutput("my PDF");};
cfpdf(action="export", type="metadata", source=expandPath('./CFDocumentBefore.pdf'), exportto=expandPath('./CFDocumentMetadataBefore.xmp'), overwrite="true");
sleep(2000);//ensure timestamps change
//export metadata from cfhtmltopdf PDF
cfhtmltopdf(destination=expandPath('./CFHTMLToPDFBefore.pdf'), overwrite="true") {writeOutput("my PDF");};
cfpdf(action="export", type="metadata", source=expandPath('./CFHTMLToPDFBefore.pdf'), exportto=expandPath('./CFHTMLToPDFMetadataBefore.xmp'), overwrite="true");
sleep(2000);//ensure timestamps change
//import cfhtmltopdf metadata into cfdocument PDF
cfpdf(action="import", type="metadata", source=expandPath('./CFDocumentBefore.pdf'), destination=expandPath('./CFDocumentAfter.pdf'), importfrom=expandPath('./CFHTMLToPDFMetadataBefore.xmp'), overwrite=true);
sleep(2000);//ensure timestamps change
//import cfdocument metadata into cfhtmltopdf PDF
cfpdf(action="import", type="metadata", source=expandPath('./CFHTMLToPDFBefore.pdf'), destination=expandPath('./CFHTMLToPDFAfter.pdf'), importfrom=expandPath('./CFDocumentMetadataBefore.xmp'), overwrite=true);
//export metadata from updated cfdocument PDF
cfpdf(action="export", type="metadata", source=expandPath('./CFDocumentAfter.pdf'), exportto=expandPath('./CFDocumentMetadataAfter.xmp'), overwrite="true");
sleep(2000);//ensure timestamps change
//export metadata from updated cfhtmltopdf PDF
cfpdf(action="export", type="metadata", source=expandPath('./CFHTMLToPDFAfter.pdf'), exportto=expandPath('./CFHTMLToPDFMetadataAfter.xmp'), overwrite="true");
</cfscript>
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 4126619
Bug Grouping Info:
Bug Group ID: BG175083
Bug ID: CF-4126619
Bug relationship: Awaiting Fix
Product: ColdFusion
Bug Group ID: BG175083
Bug ID: 4125381
Bug relationship: Pending Fix
Product: CT Gibson
External Customer Info:
External Company:
External Customer Name: Aaron Neff
External Customer Email: adobelabs@itisdesign.com
External Test Config:
Attachments:
Comments: