FTP node uploads correct PDF but QNAP downloads wrong file name / MIME (example.com, unix executable) – PDF valid only in n8n

I am uploading PDF files from n8n to a QNAP TS-664 NAS using the FTP node.
The PDF looks correct everywhere inside n8n:
correct binary
correct MIME type (application/pdf)
correct file name
and downloading directly from n8n gives a fully valid PDF (opens fine)
QNAP FileStation also shows the uploaded file as a correct PDF with:
correct name
correct MIME
correct file size
BUT when I download the same file from QNAP FileStation OR Finder (SMB), the NAS returns a completely different file name and/or MIME type.
Examples of what happens:
The filename becomes example.com or download
Finder shows the file as Unix executable
The file cannot be opened
However the binary inside is STILL a valid PDF (header %PDF-1.7).
I verified this using Python and PyPDF2.
This ONLY happens with files uploaded via the n8n FTP node.
I tried:
different folders
deleting all files
new “clean” upload folder
renaming the file inside n8n
using a Function node to rebuild the binary object
restarting n8n
restarting the QNAP NAS completely
The issue persists even in completely new folders.
It looks like either:
FTP node does not set metadata the way QNAP expects
QNAP assigns wrong MIME/download headers to files uploaded by n8n
or some edge-case behaviour between n8n FTP and QNAP FileStation
Has anyone seen this before?
Why does QNAP serve wrong filename and MIME for a PDF that is stored correctly?
Happy to provide additional logs or test files.
What is the error message (if any)?
No error in n8n.
The corrupted behaviour happens only when downloading from QNAP FileStation or Finder over SMB.

The issue seems to be with how the FTP node interacts with your QNAP NAS. I’m not 100% certain, but it’s possible that the FTP node isn’t setting the correct metadata that QNAP expects, leading to the incorrect filename and MIME type.

You might want to verify the settings within the FTP node, specifically the “File Name” and “Remote Path” fields, to ensure they’re configured as expected. Also, double-check your QNAP NAS settings related to file handling and MIME type detection.

If that doesn’t work, sharing your workflow JSON could help pinpoint the problem.