LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 09-04-2013, 09:30 PM   #1
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Rep: Reputation: 2
Want To Give User Permission To Download Files From The Internet


I have installed Slackware 13.37 32-bit with the KDE desktop environment. I am not very experienced with Linux...

How do I give a user permission to download files from the Internet? Can it be done with KDE? (I thought that as root I would find something like "User Management" in the "System Administration" section of "System Settings" but it is not there.)
 
Old 09-04-2013, 10:15 PM   #2
STDOUBT
Member
 
Registered: May 2010
Location: Stumptown
Distribution: Slackware 14.0/32bit + a T60p (2007-YS3) = YES
Posts: 260

Rep: Reputation: 60
tb75252,
Can you login as the user in question and issue the command
Code:
groups
in a terminal and tell us the output?
 
Old 09-04-2013, 10:28 PM   #3
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by STDOUBT View Post
tb75252,
Can you login as the user in question and issue the command
Code:
groups
in a terminal and tell us the output?
Here we go:
Quote:
$ groups
users lp floppy audio video cdrom games plugdev power netdev scanner
 
Old 09-04-2013, 10:37 PM   #4
STDOUBT
Member
 
Registered: May 2010
Location: Stumptown
Distribution: Slackware 14.0/32bit + a T60p (2007-YS3) = YES
Posts: 260

Rep: Reputation: 60
It appears there is no reason your user couldn't download files from the internet.
I don't use KDE, but what happens when you connect to the internet and attempt to
download a file? Are you using a web browser?
 
Old 09-04-2013, 10:58 PM   #5
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by STDOUBT View Post
It appears there is no reason your user couldn't download files from the internet.
I don't use KDE, but what happens when you connect to the internet and attempt to
download a file? Are you using a web browser?
I am using Firefox 17.0.8 and I am attempting to download a couple of files for my Thunderbird calendar (Lightning). The files that I am trying to download are available at: http://www.mozilla.org/projects/calendar/holidays.html (I am supposed to right-click the link of the holiday calendar I want to install and select Save Link As...)

I can do the file download without problems if I log in as root. But if I log in as user (I have created only one user account), nothing happens when I do the Save Link As... action, so I figured it was a matter of assigning the user a permission to download.
 
Old 09-04-2013, 11:53 PM   #6
STDOUBT
Member
 
Registered: May 2010
Location: Stumptown
Distribution: Slackware 14.0/32bit + a T60p (2007-YS3) = YES
Posts: 260

Rep: Reputation: 60
Firstly, it's not a good idea to use the GUI as root.
Secondly, your problem is certainly unusual. I'm running Firefox 21.0 because I chose
not to go along with the "upgrade" to the ESR channel. But that's beside the point.
FWIW, I have looked in about:config, and there are two references to "savelinkas" and my
values for those settings are 4000 (for the timeout) and "true" for shift.

I'm afraid I don't have an answer for you. :-(
 
Old 09-05-2013, 12:31 AM   #7
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,750

Rep: Reputation: 462Reputation: 462Reputation: 462Reputation: 462Reputation: 462
Where are you trying to save the file as user? Sounds like you are trying to save it to some area of the file system where the users don't have write priviliges.
 
Old 09-05-2013, 06:01 AM   #8
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by gnashley View Post
Where are you trying to save the file as user? Sounds like you are trying to save it to some area of the file system where the users don't have write priviliges.
Firefox is set to save downloaded files in the default directory, i.e. /home/<username>/Downloads.

Last edited by tb75252; 09-05-2013 at 06:04 AM.
 
Old 09-05-2013, 06:35 AM   #9
tronayne
Senior Member
 
Registered: Oct 2003
Location: Northeastern Michigan, where Carhartt is a Designer Label
Distribution: Slackware 32- & 64-bit Stable
Posts: 3,008

Rep: Reputation: 742Reputation: 742Reputation: 742Reputation: 742Reputation: 742Reputation: 742Reputation: 742
Have you tried, logged in as the user, open Firefox, click Edit, Preferences. Select The General tab and click the box at Show the Downloads Window when downloading a file and click the circle Always as me where the save files (the default is save in Downloads)?

Too, does the Download directory exist? Open a terminal and do
Code:
ls -l
drwxr-xr-x  2 username users 4096 Dec 29  2012 Desktop/
drwxr-xr-x  2 username users 4096 May  2  2012 Documents/
drwxr-xr-x  2 username users 4096 Feb  9  2013 Downloads/
drwxr-xr-x  2 username users 4096 May  2  2012 Music/
drwxr-xr-x  2 username users 4096 May  2  2012 Pictures/
drwxr-xr-x  2 username users 4096 May  2  2012 Public/
drwxr-xr-x  2 username users 4096 May  2  2012 Templates/
drwxr-xr-x  2 username users 4096 May  2  2012 Videos/
If those directories are there (they may not all exist), they should look exactly like the above, particularly the Downloads directory. If one or more of those directories does not have the permissions as above (the drwxr-xr-x), do this
Code:
chmod 755 directory_name
Note that you do not have to save files in your home directory Downloads directory, if you chose the "Ask me" setting above, you can specify where to save a file, but, you must have permission to write to the directory where you're saving it; e.g., any user can write to /tmp but users cannot (by default) write to other user's home directories (and should not be doing that).

Hope this helps some.
 
Old 09-05-2013, 10:31 PM   #10
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by tronayne View Post
Have you tried, logged in as the user, open Firefox, click Edit, Preferences. Select The General tab and click the box at Show the Downloads Window when downloading a file and click the circle Always as me where the save files (the default is save in Downloads)?

Too, does the Download directory exist? Open a terminal and do
Code:
ls -l
drwxr-xr-x  2 username users 4096 Dec 29  2012 Desktop/
drwxr-xr-x  2 username users 4096 May  2  2012 Documents/
drwxr-xr-x  2 username users 4096 Feb  9  2013 Downloads/
drwxr-xr-x  2 username users 4096 May  2  2012 Music/
drwxr-xr-x  2 username users 4096 May  2  2012 Pictures/
drwxr-xr-x  2 username users 4096 May  2  2012 Public/
drwxr-xr-x  2 username users 4096 May  2  2012 Templates/
drwxr-xr-x  2 username users 4096 May  2  2012 Videos/
If those directories are there (they may not all exist), they should look exactly like the above, particularly the Downloads directory. If one or more of those directories does not have the permissions as above (the drwxr-xr-x), do this
Code:
chmod 755 directory_name
Note that you do not have to save files in your home directory Downloads directory, if you chose the "Ask me" setting above, you can specify where to save a file, but, you must have permission to write to the directory where you're saving it; e.g., any user can write to /tmp but users cannot (by default) write to other user's home directories (and should not be doing that).

Hope this helps some.
This is what I get ("tb" is the username):
Quote:
$ ls -l
total 12
-rw-r--r-- 1 tb users 1056 Aug 8 22:02 C:\\nppdf32Log\\debuglog.txt
drwxr-xr-x 2 tb users 4096 Oct 16 2012 Desktop/
drwxr-xr-x 2 root root 4096 Mar 13 21:57 Downloads/
So it appears to me that the /home/tb/Downloads directory belongs to the "root" group instead of the "tb" one. How do I fix this problem?
 
Old 09-05-2013, 11:16 PM   #11
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by tb75252 View Post
This is what I get ("tb" is the username):

So it appears to me that the /home/tb/Downloads directory belongs to the "root" group instead of the "tb" one. How do I fix this problem?
I did some research on the Internet. Here's what I did:
Quote:
# chown -R tb /home/tb/Downloads
And this is the result:
Quote:
$ ls -l
total 12
-rw-r--r-- 1 tb users 1056 Aug 8 22:02 C:\\nppdf32Log\\debuglog.txt
drwxr-xr-x 2 tb users 4096 Oct 16 2012 Desktop/
drwxr-xr-x 2 tb root 4096 Mar 13 21:57 Downloads/
I now am able to download files to /home/tb/Downloads. So, unless somebody sees a problem with what I have done or the results thereof I shall mark this thread as solved.
 
Old 09-06-2013, 05:11 AM   #12
tronayne
Senior Member
 
Registered: Oct 2003
Location: Northeastern Michigan, where Carhartt is a Designer Label
Distribution: Slackware 32- & 64-bit Stable
Posts: 3,008

Rep: Reputation: 742Reputation: 742Reputation: 742Reputation: 742Reputation: 742Reputation: 742Reputation: 742
You probably want to do this:
Code:
<log in as tb>              < log in as "you" >
su -                        < become root for a little while >
<root password>
cd /home                    < get into the /home directory >
chown -R tb.users tb        < change the owner and group of the tb directory >
<Ctrl-D or exit>            < exit from su - >
You want to avoid logging in as root as a general rule; you use su - to "become root" temporarily when necessary. Your user accounts should all be owned by the user with the group "users" unless there is some specific reason for them to be in another default group (and I can't think of any good reason for that offhand). Too, don't change the owner or group of the /home directory; it's owned by root and the group is root, be sure to leave that alone.

Looks like you got it going, though, so all is well that ends.

Hope this helps some.
 
Old 09-06-2013, 05:33 AM   #13
tb75252
Member
 
Registered: Oct 2010
Distribution: Slackware 14.1 (64-bit)
Posts: 91

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by tronayne View Post
You probably want to do this:
Code:
<log in as tb>              < log in as "you" >
su -                        < become root for a little while >
<root password>
cd /home                    < get into the /home directory >
chown -R tb.users tb        < change the owner and group of the tb directory >
<Ctrl-D or exit>            < exit from su - >
You want to avoid logging in as root as a general rule; you use su - to "become root" temporarily when necessary. Your user accounts should all be owned by the user with the group "users" unless there is some specific reason for them to be in another default group (and I can't think of any good reason for that offhand). Too, don't change the owner or group of the /home directory; it's owned by root and the group is root, be sure to leave that alone.

Looks like you got it going, though, so all is well that ends.

Hope this helps some.
Done! Thank you very much for the help.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with user permission level--give access to a user 2 use 500 servers svani Linux - Newbie 2 06-17-2010 08:57 PM
[SOLVED] How to give user audio permission? openSUSE 11.1 mag1strate Linux - Newbie 2 09-29-2009 09:09 PM
How do I give a user permission to save files to /var/www/html? rotnay6000 Linux - Newbie 10 07-14-2009 08:45 PM
how to give the permission to user to change his password ramesh14 Linux - Newbie 2 11-19-2008 01:40 AM
how give permission to user for using mounted devices alooma Linux - General 2 09-25-2006 08:46 PM


All times are GMT -5. The time now is 06:26 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration