Chapter 04


Published on


Published in: Education, Technology
  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Chapter 04

  1. 1. Linux Networking and Security Chapter 4
  2. 2. Configuring Client Services <ul><li>Configure “superservers” to handle multiple network services </li></ul><ul><li>Set up administrative services like logging and printing </li></ul><ul><li>Use simple network information services like finger and talk </li></ul><ul><li>Understand basic mailing list and news server configurations </li></ul>
  3. 3. The Superservers <ul><li>Superservers listen on multiple network ports and start the appropriate service when a client connection arrives for that port. </li></ul><ul><li>xinetd is a superserver gaining popularity </li></ul><ul><ul><li>It is a revised version of inetd that creates a more secure environment </li></ul></ul><ul><ul><li>Shipped with Red Hat Linux </li></ul></ul><ul><li>xinetd is the most widely used superserver </li></ul><ul><ul><li>Application level security is provided via TCP Wrappers - the tcpd program </li></ul></ul>
  4. 4. TCP Wrappers
  5. 5. TCP Wrappers <ul><li>TCP Wrappers - tcpd - is an application-level access control program </li></ul><ul><ul><li>TCP Wrappers is not a firewall and should be used with one if Linux security issues exist </li></ul></ul><ul><ul><li>Configuration is done by two files: /etc/hosts.allow and /etc/hosts.deny </li></ul></ul><ul><ul><li>Ensure proper and expected configuration by testing carefully before relying on it </li></ul></ul>
  6. 6. TCP Wrappers
  7. 7. Services Beyond the Superserver <ul><li>Many services do not rely on superservers, they are designed to run standalone </li></ul><ul><ul><li>Apache Web server is the best example of this </li></ul></ul><ul><ul><li>Servers such as SMTP and FTP can be used in standalone mode, or with inetd or xinetd </li></ul></ul><ul><ul><li>FTP runs more efficiently in standalone mode if much FTP traffic is expected </li></ul></ul>
  8. 8. Exploring Network Testing Services <ul><li>There are 5 common testing services and they are used via Telnet </li></ul><ul><ul><li>The echo service repeats back whatever you type showing that a remote host is receiving typed data </li></ul></ul><ul><ul><li>The chargen service returns a character stream and continues to until the session is ended </li></ul></ul><ul><ul><li>The discard service is like /dev/null </li></ul></ul><ul><ul><li>The time service returns a number corresponding to the current time and closes the connection </li></ul></ul><ul><ul><li>The daytime service returns the current date/time in human-readable form, then ends the session </li></ul></ul>
  9. 9. Using Administrative Services <ul><li>Logging with logd </li></ul><ul><ul><li>System logging can be done remotely using syslogd by enabling another host to receive syslog messages across the network and specifying a host in /etc/syslog.conf </li></ul></ul><ul><li>Printing with lpd </li></ul><ul><ul><li>Linux can print across the network using lpd when printer definitions that specify remote hosts cause a local copy of lpd to contact lpd running on a remote host and forward the print job to that host </li></ul></ul>
  10. 10. Using Administrative Services
  11. 11. Using Administrative Services
  12. 12. Using Administrative Services <ul><li>Time Management with NTP </li></ul><ul><ul><li>Time in Linux is managed using the Network Time Protocol (NTP) , which is implemented by the ntpd daemon </li></ul></ul><ul><ul><li>On a LAN, NTP is designed to maintain correct time to within a few milliseconds, the NTP protocol is designed for precision of 232 picoseconds </li></ul></ul><ul><ul><li>The ntpd program is installed on most Linux systems by default and it is controlled by a script in /etc/rc.d/init.d </li></ul></ul>
  13. 13. Using Administrative Services
  14. 14. Understanding SNMP on Linux <ul><li>The Simple Network management Protocol (SNMP) is designed to give feedback about how the components of the network are functioning </li></ul><ul><ul><li>Use SNMP to determine if routers are overloaded or whether remote programs have crashed </li></ul></ul><ul><ul><li>An SNMP-aware program running on a host is called an agent and it is configured to watch for specific events on the host </li></ul></ul><ul><ul><li>An SNMP console gathers data from agents on the network for system administrator’s review </li></ul></ul>
  15. 15. Benchmarking with NetPerf <ul><li>NetPerf provides benchmarking service to help determine how the throughput of the networking hardware compares with others </li></ul><ul><ul><li>Benchmarking is the process of comparing items by evaluating their performance on a fixed task </li></ul></ul><ul><ul><li>Throughput tells how much data a connection can handle </li></ul></ul><ul><ul><li>NetPerf easily tests network speeds using the UDP and TCP transport protocols </li></ul></ul>
  16. 16. Allowing Dial-in Access with a PPP Server <ul><li>The same program, pppd, is used for both the client and server sides of a PPP connection; the only difference is who calls whom and how pppd is configured </li></ul><ul><ul><li>To set up a PPP dial-in server, you must have a getty-type program that watches a modem </li></ul></ul><ul><ul><li>mgetty is typically used since it was designed with modems in mind </li></ul></ul><ul><ul><li>mgetty starts pppd, however, mgetty must be configured to use the AutoPPP command </li></ul></ul>
  17. 17. Using Basic Information Services <ul><li>Communicating with talk </li></ul><ul><ul><li>The talk program uses the talkd daemon to allow a real-time conversation with another user who is logged in on a remote host and also using talkd </li></ul></ul><ul><ul><li>Talkd service must be enabled in /etc/inetd.conf or in /etc/xinetd.d/talkd </li></ul></ul><ul><ul><li>To work in a graphical display mode rather than a character-mode, access talkd functionality using a graphical tool such as Ktalk </li></ul></ul>
  18. 18. Using Basic Information Services
  19. 19. Using Basic Information Services <ul><li>Using finger to Collect User Information </li></ul><ul><ul><li>The finger program uses the finger protocol via the in.fingerd.daemon.finger </li></ul></ul><ul><ul><li>finger provides a user with information as to whether another user is logged in and for how long, as well as the user’s full name </li></ul></ul><ul><ul><li>finger is enabled in /etc/inetd.conf or /etc/xinetd.d/finger </li></ul></ul><ul><ul><li>To use a graphical finger client, use kfinger </li></ul></ul>
  20. 20. Using Basic Information Services
  21. 21. Using Basic Information Services <ul><li>Collecting Server Information with whois </li></ul><ul><ul><li>In order to learn more about a domain, access domain information in the database maintained by the domain registrar </li></ul></ul><ul><ul><li>The whois utility queries that database to learn about a specific domain </li></ul></ul><ul><ul><li>whois queries the main whois server, called </li></ul></ul><ul><ul><li>Use whois with the help parameter to learn about extended queries you can make </li></ul></ul>
  22. 22. Using Basic Information Services <ul><li>Linux Telephony </li></ul><ul><ul><li>The term telephony typically refers to having a computer interact with a telephone in such a way that it can be an answering machine, it can route and track calls, and act as a voice recorder </li></ul></ul><ul><ul><li>Linux has support for special hardware cards that allow you to connect phone lines to the system </li></ul></ul><ul><ul><li>Using Linux as a fax server is a simple but useful form of telephony </li></ul></ul>
  23. 23. Using Basic Information Services
  24. 24. Using Basic Information Services
  25. 25. Understanding Mailing Lists and News Servers <ul><li>A mailing list enables a group of users to share information on an ongoing basis via email </li></ul><ul><ul><li>The concept behind mailing lists is that when an email message is sent (posted) to the email list, the mailing list manager (MLM) sends the message to all users on the list </li></ul></ul><ul><ul><li>To become a member of a mailing list, users subscribe, where unsubscribing removes user </li></ul></ul>
  26. 26. Understanding Mailing Lists and News Servers <ul><li>The advantage of mailing list software is that it automates subscribing, unsubscribing, and sending all the messages so individuals don’t have to spend time managing user lists </li></ul><ul><ul><li>One of the most widely used MLM packages is majordomo </li></ul></ul><ul><ul><li>Other mailing list managers include: LISTSERV; ListProc; SmartList; Mailman </li></ul></ul>
  27. 27. Understanding Mailing Lists and News Servers
  28. 28. Understanding Mailing Lists and News Servers <ul><li>Understanding Linux News Servers </li></ul><ul><ul><li>Newsgroup postings are passed around the Internet using NNTP </li></ul></ul><ul><ul><li>The most widely used Linux news server software is INN, with the news server daemon innd </li></ul></ul><ul><ul><li>For most networks, setting up a dedicated news server is not worth the effort </li></ul></ul><ul><ul><li>A better solution is to gain access to an ISP’s news server </li></ul></ul>
  29. 29. Understanding Mailing Lists and News Servers <ul><li>Linux News Clients </li></ul><ul><ul><li>Linux provides several good news clients that allow the reading of newsgroup postings, either graphically or in text mode </li></ul></ul><ul><ul><li>Most full-featured Web browsers now include newsgroup browsing capabilities </li></ul></ul><ul><ul><li>Netscape browser is a popular browser option </li></ul></ul><ul><ul><li>Gnome and KDE are graphical options </li></ul></ul><ul><ul><li>The most widely used text-mode news reader is trn </li></ul></ul>
  30. 30. Understanding Mailing Lists and News Servers
  31. 31. Chapter Summary <ul><li>The superservers, inetd and xinetd, listen to numerous ports and start network services when needed to respond to an incoming client request </li></ul><ul><li>Application-level security is provided for inetd via TCP Wrappers - the tcpd program </li></ul><ul><li>Ports are mapped to service names by the /etc/services file </li></ul><ul><li>Some network services such as Apache Web server and the innd news server are not designed to be run by the superserver but standalone </li></ul><ul><li>Network testing services such as chargen and echo are provided by inetd </li></ul>
  32. 32. Chapter Summary <ul><li>System logging can be done remotely using syslogd by enabling another host to receive syslog messages across the network and specifying a host in /etc/syslog.conf </li></ul><ul><li>Linux can print across the network using lpd </li></ul><ul><li>Time management in Linux is provided via NTP and the ntpd daemon </li></ul><ul><li>SNMP provides detailed information about what is happening on hosts on a network </li></ul><ul><li>NetPerf provides benchmarking service to help you determine how the throughput of your networking hardware compare with that of other systems </li></ul>
  33. 33. Chapter Summary <ul><li>To configure Linux as a PPP server, use mgetty or a similar program to watch for incoming modem calls </li></ul><ul><li>The talk system lets users communicate in real-time between hosts </li></ul><ul><li>Linux supports a number of chat-style messaging services such as Yahoo! Chat, America Online instant messager (AIM), and Microsoft Network </li></ul><ul><li>The finger program provides a small user account summary </li></ul><ul><li>The whois command lets you query information about a domain name through the network information databases maintained by name registers </li></ul>
  34. 34. Chapter Summary <ul><li>Linux telephony is a growing field that allows your computer to interact with voice telephone systems </li></ul><ul><li>Voice-over-IP (VoIP) is a technology that allows you to make long-distance telephone calls </li></ul><ul><li>Mailing List Management (MLM) software provides automated management of message delivery between a potentially large number of users </li></ul><ul><li>Setting up a news server on Linux is possible, but maintaining such a server can entail much work </li></ul><ul><li>Many Web browsers include news-reading capability </li></ul>