LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 01-10-2005, 08:02 PM   #1
kau2
LQ Newbie
 
Registered: Jan 2004
Posts: 14

Rep: Reputation: 0
How do you setup FTP and SSH in Fedora?


I want to be able to FTP and SSH into my Fedora box. Is there a website tutorial on how to set this up?
 
Old 01-10-2005, 08:22 PM   #2
dr_zayus69
Member
 
Registered: Sep 2004
Location: western massachusetts
Distribution: fedora core 3, Suse 10
Posts: 877

Rep: Reputation: 35
check out www.tldp.org (the linux documentation project.) They have a wide array of HOWTOs and FAQs and guides.
 
Old 01-10-2005, 08:27 PM   #3
kau2
LQ Newbie
 
Registered: Jan 2004
Posts: 14

Original Poster
Rep: Reputation: 0
http://www.tldp.org/HOWTO/HOWTO-INDEX/index.html

Don't seem to see how to setup a telnet server. I see FTP and got that working.
 
Old 01-10-2005, 08:30 PM   #4
dr_zayus69
Member
 
Registered: Sep 2004
Location: western massachusetts
Distribution: fedora core 3, Suse 10
Posts: 877

Rep: Reputation: 35
from what i gather from reading post on here telnet is less secure then SSH. So maybe it is not a bad thing you can't find a HOWTO on telnet. lol. If you can't find it there there is always googling for it.

Last edited by dr_zayus69; 01-10-2005 at 08:32 PM.
 
Old 01-10-2005, 08:48 PM   #5
kau2
LQ Newbie
 
Registered: Jan 2004
Posts: 14

Original Poster
Rep: Reputation: 0
SSH would be fine. I can't find Google info on either

I've tried lots of combos on Google and can't find it either.
 
Old 01-10-2005, 09:04 PM   #6
dr_zayus69
Member
 
Registered: Sep 2004
Location: western massachusetts
Distribution: fedora core 3, Suse 10
Posts: 877

Rep: Reputation: 35
http://www.google.com/search?hl=en&q...=Google+Search
 
Old 01-13-2005, 01:55 AM   #7
zparihar
Member
 
Registered: Sep 2004
Distribution: Fedora, Debian
Posts: 59

Rep: Reputation: 15
SSH and FTP

Hey Kau2,

If you've got your Fedora OS up and running you should already be able to SSH into your Fedora Box

Just make sure that you have port 22 open on your firewall(s).

All you need is get the IP of your Fedora Box and then type in ' ssh 24.24.24.24 '
(where 24.24.24.24 is your ip address)

It will ask you to type in your user name and password.

It is recommended that you not log in as root. You should actually disable root logins. If you need help with that, just let me know.
You should always use the 'su' command to become root.


A good ftp program is ' proftpd ' . Real easy to use and very easy to setup... Since you have a fedora box. there are many places to get the rpm's of proftpd. Try googling ' proftpd rpm fedora' there should be packages all over the place.

Install the package and you should be ready to go...

To ftp into your machine you will need to type in ' ftp 24.24.24.24'
And it will ask you to enter a username and password.

(if it doesn't work right off the bat, you'll need to change on small setting in your /etc/proftpd.conf, really simple - let me know)

BECAREFUL! Ftp (and telnet) sends your user name and password in clear text! anyone can read it using a small program which is on almost every linux box called 'tcpdump' . Once you log in to your computer using ftp... anyone will be able to log in to your computer, if you are running ftp/ssh/telnet.

In my opinion you should use 'sftp' which is a part of ssh. It works exactly like ftp, except that it is encrypted.

For ftp you'll need port 20 and 21 open.

let me know if you need help.

Zubin Parihar
 
Old 01-13-2005, 01:57 AM   #8
zparihar
Member
 
Registered: Sep 2004
Distribution: Fedora, Debian
Posts: 59

Rep: Reputation: 15
yum and apt-get for fedora

just a little note...

you may want to do a little research for ' yum ' and ' apt-get ' for fedora.

very handy tools if you ever need a program!


Zubin Parihar
 
Old 01-13-2005, 08:44 AM   #9
hywaydave
Member
 
Registered: Dec 2004
Location: Omaha, NE
Distribution: RH9
Posts: 31

Rep: Reputation: 15
vsftp should be included in the fedora distro. I would search the CDs for the rpm and install it, or you may have it already installed.
 
Old 01-13-2005, 09:01 AM   #10
dr_zayus69
Member
 
Registered: Sep 2004
Location: western massachusetts
Distribution: fedora core 3, Suse 10
Posts: 877

Rep: Reputation: 35
or do
rpm -qa | grep vsftp
 
Old 01-13-2005, 12:31 PM   #11
goldentrout
LQ Newbie
 
Registered: Jan 2005
Location: Denver, Colorado
Distribution: Fedora Core 3
Posts: 3

Rep: Reputation: 0
I have a question along these lines too.........

I am a Linux newbie so be gentle, but I am familiar with networking

I have just recently set-up a Fedora core 3 dedicated box to play around with

All seems to be working fine and I can ping out and browse the web

However, I cannot ssh or ftp to the box from the LAN or WAN

I have disabled the firewall completely for testing to make sure that is not and issue

I have ports 21 and 22 forwarded to the Linux box at 192.168.1.27, gw is 192.168.1.1

ssh is started along with vsftpd

Ports 21 and 22 are not being blocked by my ISP

I get a timed out error on ssh and I do get a prompt for username and password for ftp, but a timeout after that

Any suggestions?
 
Old 01-13-2005, 01:00 PM   #12
denver1980
Member
 
Registered: Dec 2004
Location: Québec
Distribution: Gentoo, Kubuntu Karmic
Posts: 48

Rep: Reputation: 15
Hi Kau2,
like zparihar said, you should use ssh instead of telnet.
If SSH doesn't work properly and your sshd is running (/etc/init.d/sshd status), try the following :
# netstat -an | grep 22
tcp 0 0 :::22 :::* LISTEN


If you don't get any result, your daemon isin't listening on port 22(default for SSH).
To try to fix it :
a) stop the daemon
- - # /etc/init.d/sshd stop
b) edit the sshd config file (should be in /etc/ssh/sshd_config) and verify the following (the line numbers can be different, I'm looking at my own file now):
- - Line 13) Port 22 #this is the default port for ssh
- - Line 14) Protocol 2 #better than protocol 1 and you can use banners
- - Line 37) PermitRootLogin no # very important for security reasons
- - Line 78) X11Forwarding yes # if you wanna forward your display on your WinXP
- - Line 91) Banner /var/mypath/banner # If you wanna put a banner on the ssh login before the password entry
c) restart the daemon
- - # /etc/init.d/sshd start
d) verify that no error message was issued
- - # tail /var/log/messages
e) retry to look at port listening
- - # netstat -an | grep 22

now try accessing your linux from himself of from a WinDho! box (my favorite tool on Windows is PuTTY)

Do not use FTP server unless you need to permit Anonymous access ...
I agree again with zparihar for using ssh to do file transfer ... it's a bit slower but much much more secure
I use The Core but there is A LOT of freewares out there that can do it.

Last edited by denver1980; 01-13-2005 at 01:03 PM.
 
Old 01-13-2005, 01:06 PM   #13
hywaydave
Member
 
Registered: Dec 2004
Location: Omaha, NE
Distribution: RH9
Posts: 31

Rep: Reputation: 15
Quote:
Originally posted by goldentrout
I have disabled the firewall completely for testing to make sure that is not and issue
Is this the firewall on your Linux machine or a standalone router/firewall connected to your cable/dsl modem?
 
Old 01-13-2005, 02:22 PM   #14
goldentrout
LQ Newbie
 
Registered: Jan 2005
Location: Denver, Colorado
Distribution: Fedora Core 3
Posts: 3

Rep: Reputation: 0
The firewall (iptables) is disabled on the linux box, nothing being blocked

I don't have any other firewall, hardware or otherwise

To be sure I forwarded telnet to my WinXP box and it works, so I pretty sure my router is forwarding correctly


One other piece of info, I initially installed Fedora but forgot to add some packages so I re-installed it again over the top. I have heard that might be an issue as well?
 
Old 01-14-2005, 03:22 AM   #15
zparihar
Member
 
Registered: Sep 2004
Distribution: Fedora, Debian
Posts: 59

Rep: Reputation: 15
goldentrout - firewall

Hi goldentrout,

Just a couple of suggestions...give them a try...

(for the purpose of this experiment only...flush your IPtables rules by typing:

/sbin/iptables -F

)

1) First check the status of your SSH server by typing:

/etc/rc.d/init.d/sshd status

OR

/sbin/service sshd status

If its running, then great! If not you may want to start it up...

/etc/rc.d/init.d/sshd start

OR

/sbin/service sshd start


2) Once you know that your ssh server is running...try ssh'ing to your self.

ssh localhost

OR

ssh 192.168.1.27

You should be able to do this...

3) Once you've been able to log in to yourself on your own machine... try logging in to this linux box from another machine within your network... If you don't have another Linux box, either boot in with a Knoppix live CD or download 'putty.exe' ( google putty - its a pretty nice ftp client for windows)

Hopefully that works out...


4) Once you've got all the previous steps working... it should be too hard... You mentioned previously that you got port 23 (telnet) forwarded to your Windows box. Try forwarding port 22 to your linux box... Port 22 is the only port you need to forward...



Btw. You may want to disable logging into your windows box via telnet. When you Telnet into a box, the username and password is sent in clear text to the machine, which then makes that box accessable to anyone who sniffed your password.

If you want to do a quick experiment to see how easy it is to sniff your password, try doing this:

1) ON your linux box open up a terminal and type in :
/usr/sbin/tcpdump -Xnn

(this will record the traffic to the screen)
(if you would like to output it to a file just add a ' | tee OutputFileName '

2) Now on the same Linux box, open up another terminal and just login via telnet to your Windows Box and then switch back to your tcpdump screen and scroll through the output on the right hand side of the screen. You will notice both your username and password in clear text!

It is dead easy to sniff network traffic!


If you really want to access your windows box from the outside, a better solution would probably to ssh to your linux box from the outside and then telnet to your windows box from your linux box.


Just about everyone who has a linux box, has tcpdump on it. And anyone can also download 'windump' which is a tcpdump port to windows.

Just giving you a heads up... :)

Zubin Parihar
 
  


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
How to setup FTP users only users on LInux Fedora Soujiro Linux - Newbie 8 09-13-2010 07:34 AM
FTP/SSH setup questions Telexen Slackware 3 10-01-2004 04:43 AM
Setup SSH? zigmund555 Slackware 2 02-13-2004 01:06 PM
FTP Question. Setup from SSH command line Aen Linux - Newbie 5 08-22-2003 12:20 PM
SSH Setup Gramo Linux - General 3 07-15-2003 07:06 PM


All times are GMT -5. The time now is 05:36 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