FTP server z AZboxu
Moderátoři: monkus, gorick, schmegea
-
- Pokročilý
- Příspěvky: 513
- Registrován: 29 čer 2009, 12:32
Re: FTP server z AZboxu
ok jdu se na to napred vyspat, diky - je mi jasny, ze te unavuje zodpovidat stupidni dotazy, jestli se mi to podari vygooglit a rozjet, pisnu sem reseni
AB IPBox 9900HD+ 640GB (AB E2 26/05/2011 + oscam 5231) | AzBox HD Premium 200GB (0.9.5308 nebo RTi Core v1.6 Enigma 2) | Stab HH90, Emme Esse 90cm, 28.2E-1W, 0D96 & 0D0F | Samsung PS50B550 | Samsung BD-P1580
-
- Nováček
- Příspěvky: 96
- Registrován: 02 říj 2009, 18:22
- Bydliště: Bratislava
- Kontaktovat uživatele:
Re: FTP server z AZboxu
ani som netusil aky tam je ftp server, ale ani som po tom nepatral, o to to ma j3nda lahsiemonkus píše:naco chces instalovat vsftp, ked tam nainstalovany je?
....
monkus: (jedna rada za den)/(jeden clovek) postacuje, inac nie je ziadna vlastna iniciativa

AzBox HD Premium, fw 0.9.4466, int.HDD WD SCORPIO BLUE 500GB, Maximum E-85 + 4x LNB - GT-LST40, DPD TX-P42V10E, receiver Yamaha RX 757 + repro 5.1
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
Re: FTP server z AZboxu
nie, skor je to o tom, ze niekomu step-by-step nieco napisat, znamena otestovat to. a kedze nemam momentalne cas, treba pouzit google. treba verit, ze rovnaky problem malo uz desiatka inych ludi...
dreambox dm-800 hd se, dm-525 hd
-
- Pokročilý
- Příspěvky: 513
- Registrován: 29 čer 2009, 12:32
Re: FTP server z AZboxu
chapu a obema Vam dekuju za rady
nasel jsem okomentovanej konfigurak vsftpd a ten mi lecos ozrejmil, co se tyce toho chrootovani, tak uz je mi celkem jasno a skutecne staci pridat tech par radku jak mi radil jj_SK, ten problem s prihlasovanim jsem hledal a podle vseho by to melo byt pravy k adresari, to budu muset doma jeste otestovat. navodu jak na to jsem nasel nekolik a kazdej je jinej
jeste jsem se chtel zeptat jj_SK jak si to myslel s tim zakazanim shellu? predpokladam, ze je to z duvodu, aby nemohli obchazet ten chroot, ale jak ho vypnout jsem nenasel
jinak prikladam ten okomentovanej configurak, treba to nekomu pomuze:
# Example config file /etc/vsftpd.conf
#
# The default compiled in settings are fairly paranoid. This sample file
# loosens things up a bit, to make the ftp daemon more usable.
# Please see vsftpd.conf.5 for all compiled in defaults.
#
# READ THIS: This example file is NOT an exhaustive list of vsftpd options.
# Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd's
# capabilities.
#
# Allow anonymous FTP? (Beware - allowed by default if you comment this out).
anonymous_enable=YES
#
# Uncomment this to allow local users to log in.
local_enable=YES
#
# Uncomment this to enable any form of FTP write command.
write_enable=YES
#
# Default umask for local users is 077. You may wish to change this to 022,
# if your users expect that (022 is used by most other ftpd's)
local_umask=022
#
# Uncomment this to allow the anonymous FTP user to upload files. This only
# has an effect if the above global write enable is activated. Also, you will
# obviously need to create a directory writable by the FTP user.
anon_upload_enable=YES
#
# Uncomment this if you want the anonymous FTP user to be able to create
# new directories.
#anon_mkdir_write_enable=YES
#
# Activate directory messages - messages given to remote users when they
# go into a certain directory.
dirmessage_enable=YES
#
# Activate logging of uploads/downloads.
xferlog_enable=YES
#
# Make sure PORT transfer connections originate from port 20 (ftp-data).
connect_from_port_20=YES
#
# If you want, you can arrange for uploaded anonymous files to be owned by
# a different user. Note! Using "root" for uploaded files is not
# recommended!
#chown_uploads=YES
#chown_username=whoever
#
# You may override where the log file goes if you like. The default is shown
# below.
#xferlog_file=/var/log/vsftpd.log
#
# If you want, you can have your log file in standard ftpd xferlog format
xferlog_std_format=YES
#
# You may change the default value for timing out an idle session.
#idle_session_timeout=600
#
# You may change the default value for timing out a data connection.
#data_connection_timeout=120
#
# It is recommended that you define on your system a unique user which the
# ftp server can use as a totally isolated and unprivileged user.
#nopriv_user=ftpsecure
#
# Enable this and the server will recognise asynchronous ABOR requests. Not
# recommended for security (the code is non-trivial). Not enabling it,
# however, may confuse older FTP clients.
#async_abor_enable=YES
#
# By default the server will pretend to allow ASCII mode but in fact ignore
# the request. Turn on the below options to have the server actually do ASCII
# mangling on files when in ASCII mode.
# Beware that turning on ascii_download_enable enables malicious remote parties
# to consume your I/O resources, by issuing the command "SIZE /big/file" in
# ASCII mode.
# These ASCII options are split into upload and download because you may wish
# to enable ASCII uploads (to prevent uploaded scripts etc. from breaking),
# without the DoS risk of SIZE and ASCII downloads. ASCII mangling should be
# on the client anyway..
#ascii_upload_enable=YES
#ascii_download_enable=YES
#
# You may fully customise the login banner string:
#ftpd_banner=Welcome to blah FTP service.
#
# You may specify a file of disallowed anonymous e-mail addresses. Apparently
# useful for combatting certain DoS attacks.
#deny_email_enable=YES
# (default follows)
#banned_email_file=/etc/vsftpd.banned_emails
#
# You may specify an explicit list of local users to chroot() to their home
# directory. If chroot_local_user is YES, then this list becomes a list of
# users to NOT chroot().
#chroot_list_enable=YES
# (default follows)
#chroot_list_file=/etc/vsftpd.chroot_list
#
# You may activate the "-R" option to the builtin ls. This is disabled by
# default to avoid remote users being able to cause excessive I/O on large
# sites. However, some broken FTP clients such as "ncftp" and "mirror" assume
# the presence of the "-R" option, so there is a strong case for enabling it.
#ls_recurse_enable=YES
pam_service_name=vsftpd
userlist_enable=YES
#enable for standalone mode
listen=YES
tcp_wrappers=YES
nasel jsem okomentovanej konfigurak vsftpd a ten mi lecos ozrejmil, co se tyce toho chrootovani, tak uz je mi celkem jasno a skutecne staci pridat tech par radku jak mi radil jj_SK, ten problem s prihlasovanim jsem hledal a podle vseho by to melo byt pravy k adresari, to budu muset doma jeste otestovat. navodu jak na to jsem nasel nekolik a kazdej je jinej

jeste jsem se chtel zeptat jj_SK jak si to myslel s tim zakazanim shellu? predpokladam, ze je to z duvodu, aby nemohli obchazet ten chroot, ale jak ho vypnout jsem nenasel
jinak prikladam ten okomentovanej configurak, treba to nekomu pomuze:
# Example config file /etc/vsftpd.conf
#
# The default compiled in settings are fairly paranoid. This sample file
# loosens things up a bit, to make the ftp daemon more usable.
# Please see vsftpd.conf.5 for all compiled in defaults.
#
# READ THIS: This example file is NOT an exhaustive list of vsftpd options.
# Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd's
# capabilities.
#
# Allow anonymous FTP? (Beware - allowed by default if you comment this out).
anonymous_enable=YES
#
# Uncomment this to allow local users to log in.
local_enable=YES
#
# Uncomment this to enable any form of FTP write command.
write_enable=YES
#
# Default umask for local users is 077. You may wish to change this to 022,
# if your users expect that (022 is used by most other ftpd's)
local_umask=022
#
# Uncomment this to allow the anonymous FTP user to upload files. This only
# has an effect if the above global write enable is activated. Also, you will
# obviously need to create a directory writable by the FTP user.
anon_upload_enable=YES
#
# Uncomment this if you want the anonymous FTP user to be able to create
# new directories.
#anon_mkdir_write_enable=YES
#
# Activate directory messages - messages given to remote users when they
# go into a certain directory.
dirmessage_enable=YES
#
# Activate logging of uploads/downloads.
xferlog_enable=YES
#
# Make sure PORT transfer connections originate from port 20 (ftp-data).
connect_from_port_20=YES
#
# If you want, you can arrange for uploaded anonymous files to be owned by
# a different user. Note! Using "root" for uploaded files is not
# recommended!
#chown_uploads=YES
#chown_username=whoever
#
# You may override where the log file goes if you like. The default is shown
# below.
#xferlog_file=/var/log/vsftpd.log
#
# If you want, you can have your log file in standard ftpd xferlog format
xferlog_std_format=YES
#
# You may change the default value for timing out an idle session.
#idle_session_timeout=600
#
# You may change the default value for timing out a data connection.
#data_connection_timeout=120
#
# It is recommended that you define on your system a unique user which the
# ftp server can use as a totally isolated and unprivileged user.
#nopriv_user=ftpsecure
#
# Enable this and the server will recognise asynchronous ABOR requests. Not
# recommended for security (the code is non-trivial). Not enabling it,
# however, may confuse older FTP clients.
#async_abor_enable=YES
#
# By default the server will pretend to allow ASCII mode but in fact ignore
# the request. Turn on the below options to have the server actually do ASCII
# mangling on files when in ASCII mode.
# Beware that turning on ascii_download_enable enables malicious remote parties
# to consume your I/O resources, by issuing the command "SIZE /big/file" in
# ASCII mode.
# These ASCII options are split into upload and download because you may wish
# to enable ASCII uploads (to prevent uploaded scripts etc. from breaking),
# without the DoS risk of SIZE and ASCII downloads. ASCII mangling should be
# on the client anyway..
#ascii_upload_enable=YES
#ascii_download_enable=YES
#
# You may fully customise the login banner string:
#ftpd_banner=Welcome to blah FTP service.
#
# You may specify a file of disallowed anonymous e-mail addresses. Apparently
# useful for combatting certain DoS attacks.
#deny_email_enable=YES
# (default follows)
#banned_email_file=/etc/vsftpd.banned_emails
#
# You may specify an explicit list of local users to chroot() to their home
# directory. If chroot_local_user is YES, then this list becomes a list of
# users to NOT chroot().
#chroot_list_enable=YES
# (default follows)
#chroot_list_file=/etc/vsftpd.chroot_list
#
# You may activate the "-R" option to the builtin ls. This is disabled by
# default to avoid remote users being able to cause excessive I/O on large
# sites. However, some broken FTP clients such as "ncftp" and "mirror" assume
# the presence of the "-R" option, so there is a strong case for enabling it.
#ls_recurse_enable=YES
pam_service_name=vsftpd
userlist_enable=YES
#enable for standalone mode
listen=YES
tcp_wrappers=YES
AB IPBox 9900HD+ 640GB (AB E2 26/05/2011 + oscam 5231) | AzBox HD Premium 200GB (0.9.5308 nebo RTi Core v1.6 Enigma 2) | Stab HH90, Emme Esse 90cm, 28.2E-1W, 0D96 & 0D0F | Samsung PS50B550 | Samsung BD-P1580
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
Re: FTP server z AZboxu
vypnutie shellu je koli tomu, aby sa mohol ftpckovat, ale aby sa nemohol telnetnut / sshcknut. zvykne sa zmenit shell na /bin/nologin /bin/noshell ...
dreambox dm-800 hd se, dm-525 hd
-
- Mírně pokročilý
- Příspěvky: 294
- Registrován: 06 kvě 2009, 22:18
- Bydliště: Doma
- Dal poděkování: 2 poděkování
- Kontaktovat uživatele:
Re: FTP server z AZboxu
Výsledky 1 - 10 z asi 2 640 na dotaz "500 OOPS : vsftpd: refusing to run with writable anonymous root".monkus píše:detto zadaj do vyhladavaca "500 OOPS : vsftpd: refusing to run with writable anonymous root" a uvidis, kolko ludi zrazu malo rovnaky problem :-)
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
Re: FTP server z AZboxu
vies mi dat connect na tvoj azbox? do 5 minut to bude opravene :-)
dreambox dm-800 hd se, dm-525 hd
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
Re: FTP server z AZboxu
postup je nasledovny
1. editovat vsftpd.conf, pridal som tam len toto
chroot_local_user=YES
2. restart ftp (najlepsie cez OSD)
3. vytvorenie uzivatela
MMP[etc]$ adduser -h /PLUGINS/home/monkus -s /bin/sh monkus
Changing password for monkus
Enter the new password (minimum of 5, maximum of 8 characters)
Please use a combination of upper and lower case letters and numbers.
Enter new password:
Re-enter new password:
Password changed.
4. vytvorenie suboru v homeadresari, aby sme vedeli, ze kde sme
MMP[etc]$ touch /PLUGINS/home/monkus/TOTO_JE_MOJ_HOMEDIR
5. test pripojenia a kontorla, kde ma to vobec pusti
monkus@notbug:~$ ftp azbox
Connected to azbox.
220 (vsFTPd 2.0.7)
Name (azbox:monkus): monkus
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ls
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
TOTO_JE_MOJ_HOMEDIR
226 Directory send OK.
21 bytes received in 0.0017 seconds (11.83 Kbytes/s)
ftp> cd /
250 Directory successfully changed.
ftp> pwd
257 "/"
ftp> quit
221 Goodbye.
vsetko funguje ako ma.
ty mas imho problem v pravach homediru uzivatela, skus si to skontrolovat.
1. editovat vsftpd.conf, pridal som tam len toto
chroot_local_user=YES
2. restart ftp (najlepsie cez OSD)
3. vytvorenie uzivatela
MMP[etc]$ adduser -h /PLUGINS/home/monkus -s /bin/sh monkus
Changing password for monkus
Enter the new password (minimum of 5, maximum of 8 characters)
Please use a combination of upper and lower case letters and numbers.
Enter new password:
Re-enter new password:
Password changed.
4. vytvorenie suboru v homeadresari, aby sme vedeli, ze kde sme
MMP[etc]$ touch /PLUGINS/home/monkus/TOTO_JE_MOJ_HOMEDIR
5. test pripojenia a kontorla, kde ma to vobec pusti
monkus@notbug:~$ ftp azbox
Connected to azbox.
220 (vsFTPd 2.0.7)
Name (azbox:monkus): monkus
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ls
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
TOTO_JE_MOJ_HOMEDIR
226 Directory send OK.
21 bytes received in 0.0017 seconds (11.83 Kbytes/s)
ftp> cd /
250 Directory successfully changed.
ftp> pwd
257 "/"
ftp> quit
221 Goodbye.
vsetko funguje ako ma.
ty mas imho problem v pravach homediru uzivatela, skus si to skontrolovat.
dreambox dm-800 hd se, dm-525 hd
-
- Pokročilý
- Příspěvky: 513
- Registrován: 29 čer 2009, 12:32
Re: FTP server z AZboxu
super dik za navod, ja se s tim tu uz nakou dobu morim, problem bude asi v tom, ze vsftp je chrootovany do adresare plugins, zatimco me se vytvorila homedir uzivatele v home adresari v korenovem adresari
zacal jsem podle tveho navodu, zeditoval vsftpd.conf, ale nejde mi tam prehrat, read only file system, ani zmenit atributy mi nejdou
zatim nade mnou linux vyhrava
zacal jsem podle tveho navodu, zeditoval vsftpd.conf, ale nejde mi tam prehrat, read only file system, ani zmenit atributy mi nejdou
zatim nade mnou linux vyhrava

AB IPBox 9900HD+ 640GB (AB E2 26/05/2011 + oscam 5231) | AzBox HD Premium 200GB (0.9.5308 nebo RTi Core v1.6 Enigma 2) | Stab HH90, Emme Esse 90cm, 28.2E-1W, 0D96 & 0D0F | Samsung PS50B550 | Samsung BD-P1580
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
Re: FTP server z AZboxu
mount -o remount,rw /dev/hda1 /MMP
a znova a znova
a znova a znova
dreambox dm-800 hd se, dm-525 hd
-
- Pokročilý
- Příspěvky: 513
- Registrován: 29 čer 2009, 12:32
Re: FTP server z AZboxu

slava monkusovi

ted teda jeste zakazat ten shell
pri tvorbe uzivatele tam teda mam dat nakonec /bin/noshell ?
koukam, ze je ale zachrootovanej i root, takze bych tam mel dat spis toto, ze?
# You may specify an explicit list of local users to chroot() to their home
# directory. If chroot_local_user is YES, then this list becomes a list of
# users to NOT chroot().
chroot_list_enable=YES
# (default follows)
chroot_list_file=/etc/vsftpd.chroot_list
a do nej dat root
AB IPBox 9900HD+ 640GB (AB E2 26/05/2011 + oscam 5231) | AzBox HD Premium 200GB (0.9.5308 nebo RTi Core v1.6 Enigma 2) | Stab HH90, Emme Esse 90cm, 28.2E-1W, 0D96 & 0D0F | Samsung PS50B550 | Samsung BD-P1580
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
-
monkus
- V.I.P.
- Příspěvky: 1289
- Registrován: 05 kvě 2009, 14:41
- Dal poděkování: 4 poděkování
- Kontaktovat uživatele:
-
- Pokročilý
- Příspěvky: 513
- Registrován: 29 čer 2009, 12:32
Re: FTP server z AZboxu
jeste jednou diky 

AB IPBox 9900HD+ 640GB (AB E2 26/05/2011 + oscam 5231) | AzBox HD Premium 200GB (0.9.5308 nebo RTi Core v1.6 Enigma 2) | Stab HH90, Emme Esse 90cm, 28.2E-1W, 0D96 & 0D0F | Samsung PS50B550 | Samsung BD-P1580
-
- Pokročilý
- Příspěvky: 513
- Registrován: 29 čer 2009, 12:32
Re: FTP server z AZboxu
slozku s FTP jsem tedy nasmeroval do /DATA/hdb1/ftp aby se to nezapisovalo na flasku, vsftpd.conf jsem upravil takto:
anonymous_enable=YES
local_enable=YES
write_enable=YES
local_umask=022
dirmessage_enable=YES
xferlog_enable=NO
connect_from_port_20=YES
xferlog_std_format=YES
listen=YES
pam_service_name=vsftpd
#tcp_wrappers=YES
ftp_username=root
secure_chroot_dir=/DATA/hdb1/ftp
chroot_list_enable=YES
chroot_list_file=/MMP/etc/vsftpd.chroot_list
a do chroot_listu:
root
ale mam nadale zamcenyho do slozky i roota, jinak to beha pekne
anonymous_enable=YES
local_enable=YES
write_enable=YES
local_umask=022
dirmessage_enable=YES
xferlog_enable=NO
connect_from_port_20=YES
xferlog_std_format=YES
listen=YES
pam_service_name=vsftpd
#tcp_wrappers=YES
ftp_username=root
secure_chroot_dir=/DATA/hdb1/ftp
chroot_list_enable=YES
chroot_list_file=/MMP/etc/vsftpd.chroot_list
a do chroot_listu:
root
ale mam nadale zamcenyho do slozky i roota, jinak to beha pekne
AB IPBox 9900HD+ 640GB (AB E2 26/05/2011 + oscam 5231) | AzBox HD Premium 200GB (0.9.5308 nebo RTi Core v1.6 Enigma 2) | Stab HH90, Emme Esse 90cm, 28.2E-1W, 0D96 & 0D0F | Samsung PS50B550 | Samsung BD-P1580