Bug 416058 - Permission denied saving into "bin" folder
Summary: Permission denied saving into "bin" folder
Status: REPORTED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 1.7.2
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-01-09 17:18 UTC by Jon
Modified: 2020-01-11 17:30 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jon 2020-01-09 17:18:00 UTC
Ocular cannot save PDF's inside a folder that's called "bin" which lies in the home directory. Does not apply to folders with that name somewhere else in the system tree.


STEPS TO REPRODUCE
1. cd ~
2. mkdir ./bin
3. Open any PDF, edit it and save it to "~/bin" or any subfolder thereof

Error message:
File could not be saved in 'file:///home/USERNAME/bin/test.pdf'. Error: 'Access denied.
Could not write to /home/USERNAME/bin/test.pdf.part.'. Try to save it to another location.


EXPECTED RESULT
This restriction seems to be put in artificially and should not be there. (Or at most there should be a warning, "Cautious bin-folders are important")


SOFTWARE/OS VERSIONS
Linux (x86_64) release 5.0.0-37-generic
Comment 1 Yuri Chornoivan 2020-01-09 17:25:09 UTC
Cannot reproduce it here.

Can you check the permissions (0755) and the owner (your user) once more:

stat ~/bin

?

Thanks in advance for your answer.
Comment 2 Albert Astals Cid 2020-01-09 22:23:14 UTC
waiting on stat info
Comment 3 Jon 2020-01-10 15:32:16 UTC
Permissions are 755:
ME@COMPUTER:~$ ls -l |grep bin
drwxr-xr-x   2 ME ME   4096 Jan 10 09:41 bin

Then I set the permissions to 777 and the error still persisted:
ME@COMPUTER:~$ chmod -R a+w bin/
ME@COMPUTER:~$ ls -l |grep bin
drwxrwxrwx   2 ME ME   4096 Jan 10 09:41 bin

And finally the stats:
ME@COMPUTER:~$ stat ~/bin
  File: /home/ME/bin
  Size: 4096      	Blocks: 8          IO Block: 4096   directory
Device: fd01h/64769d	Inode: 5642408     Links: 2
Access: (0777/drwxrwxrwx)  Uid: ( 1000/s1964740)   Gid: ( 1000/ME)
Access: 2020-01-10 15:28:27.033651233 +0000
Modify: 2020-01-10 09:41:15.266793179 +0000
Change: 2020-01-10 15:28:27.033651233 +0000
 Birth: -
Comment 4 Jon 2020-01-10 15:34:05 UTC
(In reply to Jon from comment #3)
> Permissions are 755:
> ME@COMPUTER:~$ ls -l |grep bin
> drwxr-xr-x   2 ME ME   4096 Jan 10 09:41 bin
> 
> Then I set the permissions to 777 and the error still persisted:
> ME@COMPUTER:~$ chmod -R a+w bin/
> ME@COMPUTER:~$ ls -l |grep bin
> drwxrwxrwx   2 ME ME   4096 Jan 10 09:41 bin
> 
> And finally the stats:
> ME@COMPUTER:~$ stat ~/bin
>   File: /home/ME/bin
>   Size: 4096      	Blocks: 8          IO Block: 4096   directory
> Device: fd01h/64769d	Inode: 5642408     Links: 2
> Access: (0777/drwxrwxrwx)  Uid: ( 1000/s1964740)   Gid: ( 1000/ME)
> Access: 2020-01-10 15:28:27.033651233 +0000
> Modify: 2020-01-10 09:41:15.266793179 +0000
> Change: 2020-01-10 15:28:27.033651233 +0000
>  Birth: -
Comment 5 Albert Astals Cid 2020-01-11 17:30:52 UTC
user answered