-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Invalid PDF structure on shared files #207
Comments
This problem also affects shared files that are .zip. The error appears when trying to download the file:
The file has also been re-shared and was also re-uploaded but still the same problem. |
This problem also affect images shared through the shared link. It produces the same error as well when trying to download or access the file. Is there any news regarding this? This problem is affecting multiple users at the same time... |
Can someone please help here? This issue is getting critical, because suddenly it is now happening on our other 18.0.6 installation that worked before. Our last upgrade was still on June, which is why Its weird because we not did not do changes here and have tried to reproduce the problem here before and everything seems to be fine and now suddenly this problem appears.... Opening some PDF files that are shared by link are getting the same "Invalid PDF structure" error and on the server errors regarding the encryption appears.
|
Can you open it properly from regular files? Not from a share? |
@skjnldsv Yes, accessing the files normally as the user is working fine. The problem only occurs if the files are opened through a shared link. |
Have you disabled federated sharing? |
If you can also screenshot the preview tab after you clicked the request, it would be nice :) |
Can you click the last one? |
Also, might be fixed in latest nc20, since we moved the pdfviewer 🤔 |
Also, please take note that this does not only happen for PDF files but also for .zip and photos that are shared through link
|
@skjnldsv could you please confirm that this issue is fixed with Nextcloud 20? Your sentence above only states "might", which is not quite clear... Could you also please backport this fix to Nextcloud 18/19 as I also have this issue and it is affecting a lot of users on my installation too. |
I cannot as this is a super edge case and I haven't the time to set this up :) |
@skjnldsv So are there any updates regarding this or any workaround for this issue or do we have to wait until Nextcloud 20 has been released? Will this also solve the problems with the .zip files and images files? Is it possible that this has to do something with our server side encryption with user keys? |
I cannot tell. This is out of my league for the encryption part. What zip and images issue are you referring to? |
The issue with the zip and images are the same with the PDF files. The user can open/download it if opened normally but if it is through the shared link it gives the same error as the PDFs.
|
@rullzer @blizzz @MorrisJobke is it a known issue for encryption? |
This comment has been minimized.
This comment has been minimized.
Hello everyone, are there any updates regarding the issue with shared files? |
We have now upgraded our installation to version 18.0.9 and still the same problem with the shared files... Are there any updates regarding this problem? |
Hello, any news regarding this problem? We have noticed that this mainly affects our installation with server-side encryption with user-keys. Were there any changes regarding the sharing function for this kind of encryption? |
Sorry, this is unfortunately not in our current priorities :( |
@skjnldsv I have now sent an email with the shared links. Thanks in advance for the help. |
Yeah, turns out this is not possible 🤔 |
I'd argue against that. Nextcloud allows to publicly share SSE encrypted files by means of the pubShare keypair. The link you provided relates to user key encryption in cases where not all user keypairs have been generated. However, the pubShare keypair should be generated as soon as the SSE is enabled. |
I have no clue to be honest, but it seems that it is disabled. |
@CamZie Could have a look into your data directory whether you have files called |
@yahesh As requested, I confirm that the files are existing and the random identifier of the keys are the same, which i replaced here with
|
Then Nextcloud should be able to decrypt the file when it is accessed through the share link. |
I'm out of ideas, does it work for you @yahesh ? |
So I noticed I get this error if I try to open a pdf file in a folder with '#' prepended (e.g. /#testfolder). I can view the pdf without issues if it is placed in a folder like /testfolder. So special characters in the link / folder structure are causing this??? |
Generally, folder and file names containing hash signs ( I also checked ampersand ( |
We are also aware of the problems with folder/file names containing special characters. But this is not cause of our issue because we are not using any special characters in the names. |
Hello, Regards! |
Hello, When I share the same PDF-File directly (not inside a shared folder) it works as expected - I get the correct view of the PDF-File inside the browser! I hope this helps to isolate the problem. Best regards |
Hello, Same problem here, I have a folder with a PDF inside , and if I'm connected to my account and click the PDF : no problem, the PDF is previewed. Using Nextcloud 20.0.7 on Debian 10 / Apache / Mariadb up to date. |
Steps to reproduce
Expected behaviour
Actual behaviour The same files can be opened without problems inside non shared folders. This is reproducable. Server configuration |
Same here after Update to Nextcloud 20.0.7.> Message: Invalid PDF structure. In the meantime I will set Onlyoffice as the default PDF viewer. |
This is peculiar. For me, the view works in a shared folder with OnlyOffice |
Same problem here in Nextcloud 20.0.7. It only occoures in shared folder via links. |
I seems @wankdanker has a patch for this, Kudos to him : #309 |
Patch has been made, adapting original one, and seems to be delivered soon in stable release, see #319 |
I HAD the same problem. Resolved with the help of this discussion ... We ran server side encryption and ran into some issues with accessing shared files. Given we're running encryption on the filesystem, we decided to abandon NC encryption and I ran thru the process: Unfortunately, not all files got decrypted. I had to learn that a lot of data remained encrypted. But status of encryption was 'enabled: false'. I.e. I could not simply rerun the decryption. After I have to say that I ssh'ed into the server and experienced some disconnections, i.e. the process could not be completed within a single step. With every reconnect, encryption had got disabled, and I had to start the above procedure. But when it came back with the system prompt, everything is now working well. Whether we'll decide on leveraging server side encryption again in the future, remains to be seen. So far, for us it did not work reliably. |
I noticed this issue is closed but this bug is still happening for some reason, so here is my temporary approach to have sharing links to work, without embeds. I have tried some of the advices listed in this thread but none of them could help me get at the same time, sharing to work, PDF to embed and files to be downloadable. The issue is clearly the PDFjs viewer because the moment this app is disabled, files can be downloaded just fine and sharing link works perfectly. So this is my temporary fix for this bug, disable PDF Viewer Version : |
Steps to reproduce
Expected behaviour
shows and can download PDF file through the shared link without any problems
Actual behaviour
receives error when opening and downloading the PDF file:
![image](https://user-images.githubusercontent.com/16030886/89629631-6b02cf00-d89e-11ea-9994-d9f2378d6e92.png)
The owner of the shared link can access the PDFs so it does not seem to be corrupted. Also re-shared the PDF and still same problem occurs.
Server configuration
Operating system: Debian 9.13 (stretch)
Web server: nginx 1.10.3
Database: MariaDB 10.1.45
PHP version: 7.2
Nextcloud version: NC 18.0.6
Updated from an older Nextcloud/ownCloud or fresh install: updated from an older version
Where did you install Nextcloud from: Nextcloud website
Signing status:
Signing status
List of activated apps:
App list
Nextcloud configuration:
Config report
Are you using encryption: yes
Client configuration
Browser: Chrome, Firefox
Operating system: Linux / Windows
Logs
Web server error log
Web server error log
Nextcloud log (data/nextcloud.log)
Nextcloud log
Browser log
Browser log
The text was updated successfully, but these errors were encountered: