-
-
Notifications
You must be signed in to change notification settings - Fork 198
Open
Description
Describe the bug and the expected behaviour
pdflibAddPlaceholder.ts
If Japanese is used for signature information,
When the signature information screen is opened with PDF software or a browser,
- @Property {string} reason
- @Property {string} contactInfo
- @Property {string} name
- @Property {string} location
are garbled.
Is it a bug in signing or in the helpers?
placeholder-pdf-lib
pdflibAddPlaceholder.js
To Reproduce
How about modifying the following part?
const signatureDict = doc.context.obj({
Type: 'Sig',
Filter: 'Adobe.PPKLite',
SubFilter: subFilter,
ByteRange: byteRange,
Contents: placeholder,
Reason: _pdfLib.PDFString.of(reason), ---> Reason: _pdfLib.PDFHexString.fromText(reason),
M: _pdfLib.PDFString.fromDate(signingTime !== null && signingTime !== void 0 ? signingTime : new Date()),
ContactInfo: _pdfLib.PDFString.of(contactInfo), ---> ContactInfo: _pdfLib.PDFHexString.fromText(contactInfo),
Name: _pdfLib.PDFString.of(name), ---> Name: _pdfLib.PDFHexString.fromText(name),
Location: _pdfLib.PDFString.of(location), ---> Location: _pdfLib.PDFHexString.fromText(location),
Prop_Build: {
Filter: {
Name: 'Adobe.PPKLite'
},
...appBuild
}
});Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels