ITworld.com
  Search  
 Home  Newsletter Archive  LINUX TIPS AND TRICKS
R-Services
Sign up for LINUX TIPS AND TRICKS
More Newsletters
 Printer Friendly Format
 Mail to a friend

LINUX TIPS AND TRICKS --- 01/04/2002

R-services provide a variety of methods for executing commands via a remote host, but they also generate serious security concerns.



Danny Kalev

This week, I will discuss the so-called R-services that provide various levels of interaction and command execution on a remote host. I will then show how to disable these services to eliminate their potential security risks.
Advertisement
 On this topic
 Newsletters
 Linux Tips and Tricks. Sign up Now!
 More news on this subject
Red Hat, HP ship Linux Itanium 2 workstations

UnitedLinux plans under-$1,000 release, US entity

Linux takes confidence says RS/6000 supporter

Gartner: Linux will be the savior of Unix

HP to work with US government on Linux clusters
 White Papers
 Unix
Search the Newsletter Archives
View the LINUX TIPS AND TRICKS Archive

A Note on Security
All the R-services ("R" stands for "remote") are solid, convenient, and reliable tools when used inside a closed local network, preferably secured by a firewall. However, they easily turn into a dangerous security loophole when used in a public, open network or a Web server. Therefore, you should usually disable them on public Web servers.

rlogin
The rlogin (remote login) utility enables a user to log automatically into a remote machine without having to supply a username and a password. Once you have logged in, rlogin provides a telnet-like interface. For example, if you have two machines called "mac1" and "mac2" that are connected to each other on the same network, you can log into mac1 from mac2 using the following command:

$rlogin mac2

The automatic login is enabled only for known usernames that have a matching .rhosts entry; otherwise, the user will still be prompted for a valid username and a password. To disable rlogin, remove or comment out the rlogind (the rlogin server) entry from inetd.conf. In addition, you should delete /etc/hosts.equiv and any .rhosts files from your system.

rsh
The rsh (remote shell) service allows execution of remote commands. The rsh program runs on a client that connects to a remote host. rsh opens a shell on the remote host in which the command executes. To disable rsh, comment out the rshd entry in the inetd.conf file.

rexec
The rexec (remote execution) service offers remote command execution, similar to rsh. The only difference is that the user must supply a username and a password to execute a command using rexec. To disable rexec, remove or comment out the rexecd entry from inetd.conf.

rwho
The rwho (remote who) service reports information on currently logged users on a remote host. The information gained this way can be quite dangerous if it reaches the hands of professional crackers. To disable this service, comment out the rwhod entry in the inetd.conf file.

 

Danny Kalev is a system analyst and software engineer with more than 10 years of experience, specializing in C++ and object-oriented analysis and design on various platforms including VMS, DOS, Windows, Unix, and Linux. His technical interests involve code optimization, networking, and distributed computing. He is also a member of the ANSI C++ standardization committee and the author of ANSI/ISO C++ Professional Programmer's Handbook (Que, 1999). Danny can be reached at Danny.Kalev@itworld.com.

Webcasts
ramco_graphic.gif
Ramco Systems - Can Architecture Change the Rules of Enterprise Solutions?

Sophos - Do You have a False Sense of Anti-virus Security?

Lucent - Data on the Move for Businesses on the Move

IBM - IT's Role in Protein Structure Analysis


White Papers
Dell - Wireless Security in 802.11 (Wi-Fi) Networks

Read this and other White Papers from ITworld.com.

 


Sponsored links
Bring harmony to your mix of UNIX-Linux-Windows computing environments
Locate Hidden Software on business PCs with this free tool
Top 5 Reasons to Combine App Performance and Security
KODAK i1400 Series Scanners stand up to the challenge
www.itworld.com    open.itworld.com     security.itworld.com     smallbusiness.itworld.com
storage.itworld.com     utilitycomputing.itworld.com     wireless.itworld.com

 
Contact Us   About Us   Privacy Policy    Terms of Service   Reprints  

CIO   Computerworld   CSO   GamePro   Games.net   IDG Connect   IDG World Expo   Industry Standard   Infoworld   ITworld   JavaWorld   LinuxWorld  MacUser   Macworld   Network World   PC World   Playlist  

Copyright © Computerworld, Inc. All rights reserved

Reproduction in whole or in part in any form or medium without express written permission of Computerworld Inc. is prohibited. Computerworld and Computerworld.com and the respective logos are trademarks of International Data Group Inc.