We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 72a0ce3 commit ad0a974Copy full SHA for ad0a974
apps/OpenSignServer/cloud/parsefunction/pdf/PDF.js
@@ -384,7 +384,7 @@ async function PDF(req) {
384
isCompleted = true;
385
}
386
const randomNumber = Math.floor(Math.random() * 5000);
387
- const docName = _resDoc?.Name?.replace(/\s+/g, '_')?.toLowerCase();
+ const docName = _resDoc?.Name?.replace(/[^a-zA-Z0-9._-]/g, '_')?.toLowerCase();
388
const name = `signed_${docName}_${randomNumber}.pdf`;
389
const filePath = `./exports/${name}`;
390
let pdfSize = PdfBuffer.length;
0 commit comments