CariDotMy

 Forgot password?
 Register

ADVERTISEMENT

View: 5695|Reply: 14

SFTP only account on freebsd ...

[Copy link]
Post time 19-6-2004 12:35 AM | Show all posts |Read mode
Tompang tanya kepada pakar BSD nih

uname -a =  FreeBSD mybox 5.1-RELEASE FreeBSD 5.1-RELEASE

i nak migrate ftp server dan guna SFTP ..
server adalah production server .. jadi minimum manipulation je bleh dibuat ..

masalahnye ade di sini

sblm ni .. user X, Y, Z takde shell .. (/etc/passwd set kepada /sbin/nologin).. tapi diorang bleh buat FTP ..  and ade ftpchroot

skarang ni .. nak migrate kepada SFTP ..
masalahnye ..
1) tamau kasi shell kat diorang
2) kalau boleh nak ade chroot gak  .. supaya tak melilau ke tempat lain .. especially /etc/

buat masa ni .. users tu nye shell dalam etc/passwd = /usr/libexec/sftp-server
and utk tambah paranoid , dalam login.conf.. utk user class X,Y tu ..

usermangkuk: \
:umask=027:\
:times.allow=MoTuWeThFr0830-1800:\
:host.allow=10.10.10.*:



since i tak cukup pakar ngan semua parameter yang wujud ngan command ssh ..

soalan soalannya adalah seperti berikut

1) adakah user sheel tu mencukupi ? ade work around possible tak ?
2) apsal times.allow tu tak menjadi ?
3) camne nak chroot ?

trima kasih

[ Last edited by Sarah_Radzi on 24-6-2004 at 06:51 PM ]
Reply

Use magic Report


ADVERTISEMENT


MaUi^ This user has been deleted
Post time 23-6-2004 09:42 AM | Show all posts
tak berape faham lah.... apa sayang nak buat ni... :hug:
Reply

Use magic Report

 Author| Post time 24-6-2004 01:57 AM | Show all posts
main problem ..

nak kasi buat sftp tapi taknak kasi bleh login guna SSH ..
dan tak mo kasi diorang (org sftp tu) bleh work around utk dapat gak shell

problem #2 .. tanak kasi org sftp tu access /etc/passwd
Reply

Use magic Report

MaUi^ This user has been deleted
Post time 24-6-2004 09:44 AM | Show all posts
ooo cakap lah itu macam ... ada banyak cara, cara susah ada cara sarkis monyet ada, cara lemat lembut ada, cara lagi kejam serta hina pun ada, pendek kata macam-macam lah... (chroot,jail dan lain-lain)

nak mudah boleh try guna scponly

cd /usr/ports/shells/scponly/

make WITH_SCPONLY_CHROOT=yes install
( atau kalau ada masalah make WITH_SCPONLY_CHROOT=yes FORCE_PKG_REGISTER=yes install )

lepas siap semua, kene/mesti add new user tu gune command lagu ni ye sayang....

cd /usr/local/share/examples/scponly && /bin/sh setup_chroot.sh
(ni add new user yg limit untuk sftp tu je ye, taruk je apa-apa yg dia mintak)

nak mudah kerja campak file setup_chroot.sh tu ke memana contoh kat /etc ke senang kerja ( /bin/sh /etc/setup_chroot.sh ).

ok sepatutnya dah selesai masalah ni, kalau nak cuba cara lain pun boleh, try guna rssh (freebsd 5.x ke atas sahaja - linux pon sodap).

lepas ni bolehlah kita gi dating lagi ok sayang.... rindu lah... muahhssss...
:love: :hug:
Reply

Use magic Report

MaUi^ This user has been deleted
Post time 24-6-2004 09:47 AM | Show all posts


sekadar joke
Reply

Use magic Report

 Author| Post time 24-6-2004 01:52 PM | Show all posts
okeh tq .. will try:love::love::love:
Reply

Use magic Report

Follow Us
MaUi^ This user has been deleted
Post time 24-6-2004 02:07 PM | Show all posts
ok 28/jun ni... kite kawin ye sayang... :love:
Reply

Use magic Report

 Author| Post time 24-6-2004 02:46 PM | Show all posts
erkk u lambat lah .. i dah kawin .. hik hik hik
Reply

Use magic Report


ADVERTISEMENT


MaUi^ This user has been deleted
Post time 24-6-2004 03:32 PM | Show all posts
alamak!!!! frust frust!!!

takpe lah kite geli-geli je dah lah ye..... hehehehe
Reply

Use magic Report

naruto This user has been deleted
Post time 29-6-2004 03:36 PM | Show all posts
her her her... lambat la maui ngurat... oit maui bila mau balik trg?
Reply

Use magic Report

Post time 29-6-2004 09:52 PM | Show all posts
budak trg ke? kekekeke
Reply

Use magic Report

MaUi^ This user has been deleted
Post time 1-7-2004 05:05 PM | Show all posts
tak tak, aku dibesarkan di queensland, mak bapak aku orang sana, lepas tu pindah kat malaysia dan jadi hantu komputer kat malaysia pasal barang komputer kat malaysia tersangat murah, lepas tu pindah sekejap ke ghoungzhou, china then pegi uk sebulan lepas tu baru pindah balik kl, tapi semua tu hanya rekaan semata-mata, yg sebetulnya aku seorang rakyat terengganu mencari sesuap nasi di kotaraya (bukan pusat menbeli-belah ye) kuala lumpur, dan juga disebabkan cik sarah ni dah kawin, memana awek-awek yang rasa dia tu paling cun antara yang cun-cun melecun-lecun tu, sila lah PM saya kasi no. telefon.

p.s; single lagi hensem ni, layanan penuh kasih sayang, jangan lepaskan peluang (her her her).
Reply

Use magic Report

naruto This user has been deleted
Post time 7-7-2004 01:25 PM | Show all posts
layan penun kasih sayang? : Dambaan Pilu sungguh bunyi tuh...
Reply

Use magic Report

 Author| Post time 9-7-2004 09:10 PM | Show all posts
maui^ sayang

dalam man scponly dia cakap ade logging ...
kat mana log dia (yang macam xferlog utk ftp)?


ke kena install sftp-logging ?
Reply

Use magic Report

MaUi^ This user has been deleted
Post time 13-7-2004 09:00 AM | Show all posts
default dia cume log kat syslog je, basic logging, kalau nak detail saya tak tahu ye cik sarah cayanggg....
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

 

ADVERTISEMENT


Forum Hot Topic

 

ADVERTISEMENT


 


ADVERTISEMENT
Follow Us

ADVERTISEMENT


Mobile|Archiver|Mobile*default|About Us|CariDotMy

28-12-2024 10:33 PM GMT+8 , Processed in 0.409389 second(s), 32 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

Quick Reply To Top Return to the list