Posts: 1,386
Threads: 252
Joined: Nov 2024
Reputation:
0
this is not suggested, because any ftp user can see other files in your system.
Restored from old drupal forum, for user uid:1 username:ehcpdeveloper
You may reset your password to access your new account here.
Posts: 0
Threads: 18
Joined: Nov 2024
Reputation:
0
Oops, I hadn't noticed that nor tried it. I re-read the links I sent, and I'll see if reverting my changes and setting:
allow_writeable_chroot=YES
will work on my test server.
I'll check more closely to the way security is impacted on my test sever. Thankfully, I am not using this setting on my main web server. Thanks so much for pointing it out. I'll hopefully find another solution that you can incorporate so we can finally put this issue behind us. I'll be testing and playing with it tonight!
Restored from old drupal forum, for user uid:1 username:ehcpdeveloper
You may reset your password to access your new account here.
Posts: 0
Threads: 18
Joined: Nov 2024
Reputation:
0
This worked for me while maintaining security:
<code>
sudo add-apt-repository ppa:thefrontiergroup/vsftpd
sudo apt-get update
sudo apt-get install vsftpd
sudo sed -i 's/chroot_local_user=NO/chroot_local_user=YES/g' /etc/vsftpd.conf
sudo sh -c "echo 'allow_writeable_chroot=YES' >> /etc/vsftpd.conf"
sudo service vsftpd restart
</code>
Found information here: http://blog.thefrontiergroup.com.au/2012/10/
You could even use a bash script to check which version of Ubuntu is in use and install the fix for those running version 12.04 or greater. Here's an example:
<code>
#!/bin/bash
YEAR="12"
MONTH="04"
version=$(lsb_release -r | awk '{ print $2 }')
yrelease=$( echo "$version" | cut -d. -f1 )
mrelease=$( echo "$version" | cut -d. -f2 )
# for debug
echo "Year: $yrelease"
echo "Month: $mrelease"
if [ "$yrelease" -ge "$YEAR" ]; then
if [ "$mrelease" -ge "$MONTH" ]; then
echo "We're running Ubuntu 12.04 or greater!"
# Run VSFTPD 3.0 Fix
# Described here: http://blog.thefrontiergroup.com.au/2012/10/
sudo add-apt-repository ppa:thefrontiergroup/vsftpd
sudo apt-get update
sudo apt-get install vsftpd
sudo sed -i 's/chroot_local_user=NO/chroot_local_user=YES/g' /etc/vsftpd.conf
sudo sh -c "echo 'allow_writeable_chroot=YES' >> /etc/vsftpd.conf"
sudo service vsftpd restart
else
echo "We're running an Ubuntu version less than 12.04!"
# Do whatever old versions need to do for vsftpd
fi
else
echo "We're running an Ubuntu version older than 12.x"
# Do whatever old versions need to do for vsftpd
fi
</code>
Restored from old drupal forum, for user uid:2735 username:own3mall
You may reset your password to access your new account here.
Posts: 0
Threads: 1
Joined: Nov 2024
Reputation:
0
Place the ftp home directory in a directory which you have removed write permission for. Point to that directory in vsftpd.config
from:
http://www.benscobie.com/fixing-500-oops-vsftpd-refusing-to-run-with-writable-root-inside-chroot/
Restored from old drupal forum, for user uid:2735 username:own3mall
You may reset your password to access your new account here.