LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-30-2006, 01:07 PM   #1
hkillen
Member
 
Registered: Jun 2006
Posts: 41

Rep: Reputation: 15
Network Services


Running Linux Enterprise 4
How do you disable FTP and enable SFTP?
How do you disable telnet?
 
Old 09-30-2006, 01:47 PM   #2
ctkroeker
Senior Member
 
Registered: May 2005
Location: Paraguay
Posts: 1,565
Blog Entries: 1

Rep: Reputation: 50
Quote:
Running Linux Enterprise 4
Is that Red Hat?
Quote:
How do you disable FTP and enable SFTP?
in a terminal
man ftp
&
man sftp
Quote:
How do you disable telnet?
1. Type sudo nano /etc/xinetd.d/telnet
2. Look for the line: disable = no and replace with disable = yes
3. Save it.
4. Now restart the inetd service: /etc/rc.d/init.d/xinetd restart
5. Turn it off through chkconfig as well because it can still start through that.
/sbin/chkconfig telnet off
6. Scan your server to ensure port 23 is closed. nmap -sT -O localhost
Also run ps -aux | grep telnet and if you find anything other than "grep telnet" as result kill the process.
 
Old 09-30-2006, 05:16 PM   #3
JimBass
Senior Member
 
Registered: Oct 2003
Location: New York City
Distribution: Debian Sid 2.6.32
Posts: 2,100

Rep: Reputation: 49
Also, most distros have not had telnet enabled for some time now, at least several years. You can use the telnet client to check ports, like "telnet localhost 25" to see if the server is accepting SMTP communications, but straight "telnet localhost" won't work, unless you enabled it.

Code:
jim@jimsworktop:~$ telnet localhost
Trying 127.0.0.1...
telnet: Unable to connect to remote host: Connection refused
As for ftp and sftp, sftp is actually built into ssh, and most of the time it "just works", meaning the default operation of ssh allows sftp. In my /etc/ssh/sshd_config I see this line:

Code:
Subsystem sftp /usr/lib/openssh/sftp-server
If you have the same sftp-server file, and sftp isn't working, adding that line to your sshd_config file and restarting the ssh service should allow it.

Regular ftp can probably be disabled using the scripts in /etc/rc.d/init.d/, or I believe all the Red Hat distros still use a utility with the name chkconfig? If so, some command like chkconfig ftp off will probably do the trick.

Peace,
JimBass
 
  


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
zenwalk network services ajburch Zenwalk 1 09-09-2006 03:43 AM
Restarting network services Bull Terrier Slackware 2 12-15-2003 10:19 AM
Shutting down network services durden2.0 Linux - Newbie 1 06-10-2003 02:32 AM
Can 3 network services use the same umask? greenhornet Linux - Networking 2 04-23-2002 11:16 PM
Network services going down frequently Passive Linux - Networking 2 03-08-2002 05:05 PM


All times are GMT -5. The time now is 11:12 AM.

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration