Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > HOWTO-Related Questions

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 18th January 2007, 01:24
Webspot Webspot is offline
Junior Member
 
Join Date: Jan 2007
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default Ftp file permisions chown ftpuser:ftpgroup

Hi
i have tried to solve this by myself searhing through a few forum posts but no luck.
I did come across a reply from falko about changing permisions form apache to ftpuser:ftp group by using the following command

chown ftpuser:ftpgroup /var/www/web1/
chown -R ftpuser:ftpgroup /var/www/web1/
but i get for both commands

chown: `ftpuser:ftpgroup': invalid user

previously i aplyed
chown -R -v -f www-data:www-data web/*

which i got from the joomla_ispconfig tutorial making it writable for apache
but i think that needs to be changed.

my /etc/proftpd.conf is as follows
Code:
# /etc/proftpd.conf -- This is a basic ProFTPD configuration file.
# To really apply changes reload proftpd after modifications.
#

ServerName                      "Debian"
ServerType                      standalone
DeferWelcome                    off

MultilineRFC2228                on
DefaultServer                   on
ShowSymlinks                    on

TimeoutNoTransfer               600
TimeoutStalled                  600
TimeoutIdle                     1200

DisplayLogin                    welcome.msg
DisplayFirstChdir               .message
ListOptions                     "-l"

DenyFilter                      \*.*/

# Uncomment this if you are using NIS or LDAP to retrieve passwords:
#PersistentPasswd               off

# Uncomment this if you would use TLS module:
#TLSEngine                      on

# Uncomment this if you would use quota module:
#Quotas                         on

# Uncomment this if you would use ratio module:
#Ratios                         on

# Port 21 is the standard FTP port.
Port                            21

# To prevent DoS attacks, set the maximum number of child processes
# to 30.  If you need to allow more than 30 concurrent connections
# at once, simply increase this value.  Note that this ONLY works
# in standalone mode, in inetd mode you should use an inetd server
# that allows you to limit maximum number of processes per service
# (such as xinetd)
MaxInstances                    30

# Set the user and group that the server normally runs at.
User                            nobody
Group                           nogroup

# Umask 022 is a good standard umask to prevent new files and dirs
# (second parm) from being group and world writable.
Umask                           022  022
# Normally, we want files to be overwriteable.
AllowOverwrite                  on

# Delay engine reduces impact of the so-called Timing Attack described in
# http://security.lss.hr/index.php?page=details&ID=LSS-2004-10-02
# It is on by default.
#DelayEngine                    off

# A basic anonymous configuration, no upload directories.

# <Anonymous ~ftp>
#   User                                ftp
#   Group                               nogroup
#   # We want clients to be able to login with "anonymous" as well as "ftp"
#   UserAlias                   anonymous ftp
#   # Cosmetic changes, all files belongs to ftp user
#   DirFakeUser on ftp
#   DirFakeGroup on ftp
#
#   RequireValidShell           off
#
#   # Limit the maximum number of anonymous logins
#   MaxClients                  10
#
#   # We want 'welcome.msg' displayed at login, and '.message' displayed
#   # in each newly chdired directory.
#   DisplayLogin                        welcome.msg
#   DisplayFirstChdir           .message
#
#   # Limit WRITE everywhere in the anonymous chroot
#   <Directory *>
#     <Limit WRITE>
#       DenyAll
#     </Limit>
#   </Directory>
#
#   # Uncomment this if you're brave.
#   # <Directory incoming>
#   #   # Umask 022 is a good standard umask to prevent new files and dirs
#   #   # (second parm) from being group and world writable.
#   #   Umask                           022  022
#   #            <Limit READ WRITE>
#   #            DenyAll
#   #            </Limit>
#   #            <Limit STOR>
#   #            AllowAll
#   #            </Limit>
#   # </Directory>
#
DefaultRoot ~
IdentLookups off
ServerIdent on "FTP Server ready."
# </Anonymous>


Include /etc/proftpd_ispconfig.conf
could some one please give me the steps id need to take to change this?

thx
Reply With Quote
Sponsored Links
  #2  
Old 18th January 2007, 10:13
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,044
Thanks: 841
Thanked 5,661 Times in 4,468 Posts
Default

You must replace ftpuser with the admin username of this website and ftpgroup with the name of the group of the website.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 18th January 2007, 10:38
Webspot Webspot is offline
Junior Member
 
Join Date: Jan 2007
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Site runs under admin group

would i be changing the /etc/proftpd.conf file in the following section

# Set the user and group that the server normally runs at.
User nobody
Group nogroup

to

# Set the user and group that the server normally runs at.
User admin-user-name
Group admin

or is there a set of commands i should run ?
this my 4th day on linux so not sure how to do command type changes.

Thx
Reply With Quote
  #4  
Old 18th January 2007, 10:45
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,044
Thanks: 841
Thanked 5,661 Times in 4,468 Posts
Default

Do you use ISPConfig?
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #5  
Old 18th January 2007, 10:51
Webspot Webspot is offline
Junior Member
 
Join Date: Jan 2007
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default

yes
and everythign is working fine apart from the file permisions for users FTP
they are all set to www-data making it hard for me to chnage any files in a websites directory when im accesing it via ftp.

In ISPConfig i only have made 1 client which is me
added 1 websites which is working fine
and added 1 administative user

should i have perhaps set myself up as a ressler first ?
Reply With Quote
  #6  
Old 18th January 2007, 22:09
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,752 Times in 2,582 Posts
Default

Quote:
Originally Posted by Webspot
Site runs under admin group

would i be changing the /etc/proftpd.conf file in the following section

# Set the user and group that the server normally runs at.
User nobody
Group nogroup

to

# Set the user and group that the server normally runs at.
User admin-user-name
Group admin

or is there a set of commands i should run ?
this my 4th day on linux so not sure how to do command type changes.

Thx
No, don't change your Proftpd configuration.

What's the username of that web site's admin user?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #7  
Old 19th January 2007, 02:34
Webspot Webspot is offline
Junior Member
 
Join Date: Jan 2007
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default

user name is webregister
Reply With Quote
  #8  
Old 19th January 2007, 17:12
Webspot Webspot is offline
Junior Member
 
Join Date: Jan 2007
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I corrected permissions for ftp so the admin of the website has ownership for all files by running

chown -R -v -f (admin_account_username):www-data web/*

that made all existing files to be have administrator control
but anytime i upload any form of component or module for joomla within joomla

the ftp client shows those files having owner www-data

now i can simply run the above mentioned chown command for any of the sites
but there has to be a better way around this.
Reply With Quote
  #9  
Old 20th January 2007, 00:11
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,752 Times in 2,582 Posts
Default

You could do a chmod 777 on all files, but if your server is used by other users, too, they get write access to your files.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #10  
Old 20th January 2007, 03:42
Webspot Webspot is offline
Junior Member
 
Join Date: Jan 2007
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
 
Default

Quote:
Originally Posted by falko
You could do a chmod 777 on all files, but if your server is used by other users, too, they get write access to your files.
Problem is ownership of files anytime anything is done from within joomla they have www-data ownership. Their should be a directive for the ownership to be the administrator of that web. Commercial linux systems running clients hosting account always show a 5 digit number for ownership for all the files that do not change when installing items with joomla.

For now the command i mentioned on top does do the trick but ill have to find a way to tell the system that even joomla installs are owned by administrator.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Dspam planet_fox General 6 20th January 2007 19:42
Systemimager (rsync) doesn't copy all comedit HOWTO-Related Questions 11 19th January 2007 18:17
HotSaNIC domino Tips/Tricks/Mods 23 6th November 2006 06:19
jamed up my table borders?? Boon-Dog-Danny Installation/Configuration 5 23rd September 2006 17:12
Howto suggestion suse PhP ver 4 + Ver 5 wwparrish Suggest HOWTO 11 7th August 2006 14:29


All times are GMT +2. The time now is 18:35.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.