\documentclass[letterpaper]{article}
\nonstopmode
\akai
\usepackage{linuxdoc-sgml}
\usepackage{qwertz}
\usepackage{url}
\usepackage[latin1]{inputenc}
\usepackage{t1enc}
\usepackage[english]{babel}
\usepackage{epsfig}
\usepackage{null}
\def\addbibtoc{
\addcontentsline{toc}{section}{\numberline{\mbox{}}\relax\bibname}
}%end-preamble
\setcounter{page}{1}
\title{Linux IP Masquerade mini HOWTO ÖÐÒë°æ}
\author{×÷Õß: Ambrose Au, {\ttfamily \onlynameurl{ambrose@writeme.com}}; \\ 
David Ranch, {\ttfamily \onlynameurl{dranch@trinnet.net}} \\ 
ÒëÕß: \onlynameurl{»ÆÖ¾Î°} {\ttfamily \onlynameurl{cwhuang@linux.org.tw}}}
\date{v1.50, 7 February 1999
·­ÒëÈÕÆÚ: 17-31 March 1999}
\abstract{Õâ·ÝÎÄ¼þÃèÊöÈçºÎÔÚÒ»Ì¨ Linux Ö÷»úÉÏÆð¶¯ IP Masquerade ¹¦ÄÜ£¬ÔÊÐíÃ»ÓÐ×¢²áÍø¼ÊÍøÂ· IP Î»Ö·µÄÁ¬ÏßµçÄÔ¾­ÓÉÄãµÄ Linux »úÆ÷Á¬½ÓÍø¼ÊÍøÂ·¡£}


\begin{document}
\maketitle
\tableofcontents

\section{¼ò½é}




\subsection{¼ò½é}

Õâ·ÝÎÄ¼þÃèÊöÈçºÎÔÚÒ»Ì¨ Linux  Ö÷»úÉÏÆð¶¯ IP Masquerade ¹¦ÄÜ£¬ÔÊÐíÃ»ÓÐ×¢²áÍø¼ÊÍøÂ· IP Î»Ö·µÄÁ¬ÏßµçÄÔ¾­ÓÉÄãµÄ Linux »úÆ÷Á¬½ÓÍø¼ÊÍøÂ·¡£ÄãµÄ»úÆ÷¿ÉÄÜÊÇÒÔÒÒÌ«ÍøÂ·Á¬½Ó Linux, Ò²¿ÉÄÜÊÇÆäËüÖÖÀà£¬ÏñÊÇ²¦½ÓµÄµã¶Ôµã(ppp) Á¬Ïß¡£Õâ·ÝÎÄ¼þ½«»áÇ¿µ÷ÒÒÌ«ÍøÂ·Á¬ÏßµÄÇé¿ö£¬ÒòÎªÕâÓ¦¸ÃÊÇ×î³£¼ûµÄ°¸Àý¡£

\begin{quotation}
{\bfseries Õâ·ÝÎÄ¼þÄ¿µÄÊÇ¸ø 2.2.x ¼° 2.0.x ÎÈ¶¨°æºËÐÄµÄÊ¹ÓÃÕß²Î¿¼¡£¾É°æµÄºËÐÄÈç 1.2.x ²¢²»°üº¬ÔÚÄÚ¡£}
\end{quotation}





\subsection{Ç°ÑÔ£¬»ØÀ¡ \& ²Î¿¼×ÊÑ¶}

ÎÒ·¢ÏÖÐÂÊÖÔÚ½ÏÐÂµÄºËÐÄÉÏ£¬ÏñÊÇ 2.x  ºËÐÄ£¬Éè¶¨ IP Masquerade Ê±·Ç³£À§»ó¡£ËäÈ»ÓÐ·Ý³£¼ûÎÊ´ð¼¯(FAQ) ÓëÍ¨ÐÅÂÛÌ³(mailing list)£¬È»¶øÃ»ÓÐÒ»·ÝÕâ·½ÃæµÄ×¨ÃÅÎÄ¼þ£»¶øÇÒÔÚÍ¨ÐÅÂÛÌ³ÉÏÓÐÐ©¶Ôì¶ÕâÑùÒ»·ÝËµÃ÷ÎÄ¼þ(HOWTO) µÄÇëÇó¡£ËùÒÔ£¬ÎÒ¾ö¶¨×«Ð´Ëü¸øËùÓÐÐÂÊÖ×÷ÎªÒ»¸öÆðµã£¬²¢ÇÒÏ£ÍûÄÜÅ××©ÒýÓñ£¬×÷ÎªÄÇÐ©·Ç³£ÁË½âËüµÄÊ¹ÓÃÕß½¨Á¢ÎÄ¼þµÄ»ù´¡¡£Èç¹ûÄãÈÏÎªÎÒ×öµÄ²»ºÃ£¬²»ÒªÔÚÒâ¸æËßÎÒ£¬ÕâÑùÎÒÄÜ°ÑËü×öµÃ¸üºÃ¡£

Õâ·ÝÎÄ¼þºÜ¶àÊÇÒÔÔ­ÏÈ Ken Eves µÄ³£¼ûÎÊ´ð¼¯ÒÔ¼° IP Masquerade Í¨ÐÅÂÛÌ³ÀïÐí¶àÓÐ°ïÖúµÄÑ¶Ï¢×÷Îª»ù´¡¡£ÌØ±ð¸ÐÐ»  Mr. Matthew Driver ÔÚÍ¨ÐÅÂÛÌ³ÖÐµÄÑ¶Ï¢Òý·¢ÎÒÉèÁ¢ IP Masquerade µÄÁé¸ÐÒÔ¼°×îáá×«Ð´ÁËÕâ·ÝÎÄ¼þ¡£

Èç¹ûÎÒµÄÈÎºÎ×ÊÑ¶ÓÐÎó»òÒÅÂ©ÈÎºÎ×ÊÑ¶£¬Çë±ð½éÒâ°ÑÈÎºÎ»ØÀ¡»òÒâ¼û¼Äµ½ \onlynameurl{ambrose@writeme.com} ¼° \onlynameurl{dranch@trinnet.net} À´¡£ÄãµÄÎÞ¼Û»ØÀ¡½«Ó°ÏìÕâ·ÝËµÃ÷ÎÄ¼þµÄÎ´À´!

{\bfseries Õâ·ÝËµÃ÷ÎÄ¼þÊÇÏë×÷ÎªÈÃÄãµÄ IP Masquerade  ÄÜÔÚ×î¶ÌÊ±¼äÄÚÔË×÷µÄ¿ìËÙÖ¸Òý¡£
ÒòÎªÎÒ²»ÊÇÒ»Î»×¨ÃÅ×÷¼Ò£¬Äã¿ÉÄÜ»á·¢ÏÖ±¾ÎÄ¼þµÄ×ÊÑ¶²¢·ÇÈçÄãÏëµÄÄÇ÷áÒ»°ã¼°¿Í¹Û¡£
×îÐÂµÄÏûÏ¢ÒÔ¼°×ÊÑ¶¿ÉÒÔÔÚÎÒËùÎ¬»¤µÄ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource} ÍøÒ³ÉÏÕÒµ½¡£
Èç¹ûÄãÓÐÈÎºÎ¹Øì¶ IP Masquerade  µÄ¼¼ÊõÎÊÌâ£¬Çë¼ÓÈë IP Masquerade  Í¨ÐÅÂÛÌ³¶ø±ð¼Äµç×ÓÓÊ¼þ¸øÎÒ£¬ÒòÎªÎÒµÄÊ±¼äÓÐÏÞ£¬¶øÇÒ IP Masquerade µÄ·¢Õ¹ÕßÃÇ¸üÓÐÄÜÁ¦»Ø´ðÄãµÄÎÊÌâ¡£}

Õâ·ÝÎÄ¼þ×îÐÂµÄ°æ±¾¿ÉÒÔÔÚ \onlynameurl{IP Masquerade Resource} ÉÏÕÒµ½£¬ÀïÃæÒ²ÓÐ HTML ÒÔ¼° postscript µÄ°æ±¾:
\begin{itemize}
\item \onlynameurl{http://ipmasq.cjb.net/}
\item \onlynameurl{http://ipmasq2.cjb.net/}
\item Çë²Î¿¼ \nameurl{http://ipmasq.cjb.net/index.html#mirror}{IP Masquerade Resource Ó³ÉäÕ¾Ì¨ÁÐ±í} ÒÔÕÒµ½ÆäËüµÄÓ³ÉäÕ¾Ì¨¡£
\end{itemize}







\subsection{°æÈ¨ \& Ðû¸æ}

Õâ·ÝÎÄ¼þ°æÈ¨Êôì¶ {\ttfamily Ambrose Au 1999}, ¶øÇÒÊÇÃâ·ÑµÄÎÄ¼þ¡£Äã¿ÉÒÔÔÚ GNU µÄÍ¨ÓÃ¹«¿ªÊÚÈ¨·½Ê½ÏÂÉ¢²¥Ëü¡£

Õâ·ÝÎÄ¼þÖÐµÄ×ÊÑ¶¸úÆäËüÄÚÈÝ¶¼ÒÑ¾­¾¡ÁËÎÒ×î´óµÄÅ¬Á¦¡£ÎÞÂÛÈçºÎ£¬IP Masquerade ÊÇ{\itshape ÊµÑéÐÔ\/}µÄ£¬¶øÇÒÎÒÒ²¿ÉÄÜ»á·¸Ð©´íÎó£»ËùÒÔÄãÓ¦¸Ã×Ô¼º¾ö¶¨ÊÇ²»ÊÇÒªÕÕÖøÕâ·ÝÎÄ¼þÖÐµÄ×ÊÑ¶×ö¡£

Ã»ÓÐÈË»áÎªÊ¹ÓÃÕâ·ÝÎÄ¼þÖÐµÄ×ÊÑ¶ËùÔì³ÉµÄµçÄÔËð»µ»òÆäËüËðÊ§¸ºÔð¡£Ò²¾ÍÊÇËµ£¬

\begin{quotation}
{\bfseries ×÷Õß¼°Î¬»¤Õß²»¶ÔÒÀÕÕÕâ·ÝÎÄ¼þÄÚÈÝ¶¯×÷ËùÔì³ÉµÄËðº¦¸ºÔð¡£} 
\end{quotation}


{\bfseries Ô­ÎÄ}

This document is {\ttfamily copyright(c) 1996 Ambrose Au}, and it's a free document. You can redistribute it under the terms of the GNU General Public License. 

The information and other contents in this document are to the best of my knowledge. However, ip\_masq is {\itshape experimental\/}, and there is chance that I make mistakes as well; so you should determine if you want to follow the information in this document. 

Nobody is responsible for any damage on your computers and any other losses by using the information on this document. i.e. 

\begin{quotation}
{\bfseries THE AUTHOR AND MAINTAINERS ARE NOT RESPONSIBLE FOR ANY DAMAGES INCURRED DUE
TO ACTIONS TAKEN BASED ON THE INFORMATION IN THIS DOCUMENT.}
\end{quotation}







\section{±³¾°ÖªÊ¶}




\subsection{Ê²÷áÊÇ IP Masquerade?}

IP Masquerade ÊÇ Linux µÄÒ»ÏîÍøÂ·¹¦ÄÜ¡£Èç¹ûÒ»Ì¨ Linux Ö÷»úÊ¹ÓÃ IP Masquerade ¹¦ÄÜÁ¬Ïßµ½Íø¼ÊÍøÂ·ÉÏ£¬ÄÇ÷á½ÓÉÏËüµÄµçÄÔ£¨²»ÂÛÊÇÔÚÍ¬Ò»¸öÇøÓòÍøÂ·ÉÏ»ò½åÓÉÊý¾Ý»úÁ¬Ïß£©Ò²¿ÉÒÔ½Ó´¥Íø¼ÊÍøÂ·£¬¼´Ê¹ËüÃÇ{\itshape Ã»ÓÐ»ñµÃÕýÊ½Ö¸¶¨µÄ IP Î»Ö·\/}¡£

ÕâÊ¹µÃÒ»Ð©µçÄÔ¿ÉÒÔ{\itshape Òþ²Ø\/}ÔÚÕ¢µÀ(gateway) ÏµÍ³ááÃæ´æÈ¡Íø¼ÊÍøÂ·¶ø²»±»·¢ÏÖ£¬¿´ÆðÀ´¾ÍÏñÖ»ÓÐÕâ¸öÏµÍ³ÔÚÊ¹ÓÃÍø¼ÊÍøÂ·¡£Í»ÆÆÉè¶¨Á¼ºÃµÄÎ±×°(masquerade)ÏµÍ³Ö®°²È«·À»¤Ó¦¸Ã»á±ÈÍ»ÆÆÁ¼ºÃµÄ·â°ü¹ýÂËÊ½·À»ðÇ½(packet filter firewall)À´µÃ¸ü¼ÓÀ§ÄÑ£¨¼ÙÉèÁ½ÕßÖ®ÖÐ¶¼Ã»ÓÐ´íÎó£©¡£




\subsection{ÏÖ¿ö}

IP Masquerade ÒÑ¾­·¢Õ¹¶àÄê¶øÇ÷ì¶³ÉÊì£¬Òò´ËÒÑÕýÊ½²¢Èë Linux 2.2.x µÄºËÐÄÖÐ¡£
´Ó 1.3.x °æµÄºËÐÄ¿ªÊ¼ÒÑ¾­ÄÚ½¨ÕâÏîÖ§Ô®¡£Ðí¶à¸öÈËÉõÖÁ¹«Ë¾ÕýÔÚÊ¹ÓÃËü£¬¶øÓÐÂúÒâµÄ½á¹û¡£

ä¯ÀÀÍøÒ³ÒÔ¼°Ô¶¶ËÇ©Èë(telnet)ÒÑ¾­ÓÐ»Ø±¨±íÊ¾¿ÉÒÔÔÚ IP Masquerade ÉÏÔË×÷¡£µµ°¸´«Êä(FTP)£¬ÍøÂ·½»Ì¸(IRC) ÒÔ¼°ñöÌý Real Audio ÏÖÔÚ¿ÉÒÔÔØÈëÄ³Ð©Ä£×éÅäºÏ¡£ÆäËüµÄÍøÂ·×ÊÁÏÁ÷ÒôÑ¶ (streaming audio) ÏñÊÇ True Speech  ÒÔ¼° Internet Wave  Ò²ÄÜÔË×÷¡£Ò»Ð©Í¨ÐÅÂÛÌ³ÖÐµÄÊ¹ÓÃâ·°éÉõÖÁ»¹³¢ÊÔ¹ýÊÓÑ¶»áÒéÈíÌå¡£ {\ttfamily Ping} ÏÖÔÚÅäºÏÐÂ½ü¿ÉÒÔÈ¡µÃµÄÍø¼ÊÍøÂ·¿ØÖÆÑ¶Ï¢Ð­¶¨(ICMP)ÐÞ²¹µµÒ²ÄÜÔË×÷¡£

¸üÍêÕûµÄÖ§Ô®ÈíÌåÁÐ±íÇë²Î¿¼ 4.3 ½Ú¡£

IP Masquerade ÔÚÊýÖÖ²»Í¬µÄ×÷ÒµÏµÍ³¼°Æ½Ì¨ÉÏÓë '¿Í»§¶Ë»úÆ÷' ÅäºÏÁ¼ºÃ¡£
³É¹¦µÄ°¸ÀýÓÐÊ¹ÓÃ Unix, Windows95, Windows NT, Windows for Workgroup (with TCP/IP package), OS/2, Macintosh System's OS with Mac TCP, Mac Open Transport, DOS with NCSA Telnet package, VAX, Alpha with Linux, ÉõÖÁ Amiga with AmiTCP »ò AS225-stack µÄÏµÍ³¡£
ÕâÁÐ±í»¹ÔÚ²»¶ÏÔö¼Óµ±ÖÐ¡£ÖØµã¾ÍÊÇ£¬Ö»ÒªÄãµÄÏµÍ³Ê¹ÓÃ TCP/IP Ð­¶¨£¬Ëü¾ÍÓ¦¸ÃÄÜºÍ IP Masquerade Ò»Æð¹¤×÷¡£




\subsection{Ë­¿ÉÒÔ´Ó IP Masquerade ÖÐ»ñÒæ?}

\begin{itemize}
\item Èç¹ûÄãÓÐÌ¨Á¬½ÓÍø¼ÊÍøÂ·µÄ Linux Ö÷»ú£¬¶øÇÒ
\item Èç¹ûÄãÓÐÒ»Ð©Ö´ÐÐ TCP/IP Á¬½Óµ½ Linux »úÆ÷µÄµçÄÔÔÚÇøÓòÍøÂ·ÉÏ£¬ÒÔ¼°/»òÊÇ
\item Èç¹ûÄãµÄ Linux Ö÷»úÓÐÒ»¸öÒÔÉÏµÄÊý¾Ý»ú²¢ÇÒ×÷Îª PPP »ò SLIP ËÅ·þÆ÷Á¬½ÓÆäËüµçÄÔ£¬ËüÃÇ
\item ÕâÐ©{\bfseries ÆäËü}»úÆ÷Ã»ÓÐÕýÊ½Ö¸¶¨µÄ IP Î»Ö·¡££¨ÕâÐ©»úÆ÷´ÓÕâÀï¿ªÊ¼ÒÔáá¾Í³ÆÎª{\bfseries ÆäËü}»úÆ÷£©
\item ¶øÇÒµ±È»£¬Èç¹ûÄãÏ£ÍûÕâÐ©{\bfseries ÆäËü}»úÆ÷²»±Ø»¨¶îÍâµÄ·ÑÓÃ¾ÍÄÜÁ¬ÉÏÍø¼ÊÍøÂ· :)
\end{itemize}





\subsection{Ë­²»ÐèÒª IP Masquerade?}

\begin{itemize}
\item Èç¹ûÄãµÄ»úÆ÷ÊÇµ¥¶ÀÒ»Ì¨(stand-alone) Á¬½ÓÍø¼ÊÍøÂ·µÄ Linux Ö÷»ú£¬ÄÇ÷áÖ´ÐÐ IP Masquerade Ã»Ê²÷áÒâÒå£¬»òÕß
\item Èç¹ûÄãµÄ{\bfseries ÆäËü}»úÆ÷ÓµÓÐÕýÊ½Ö¸¶¨µÄ IP Î»Ö·£¬ÄÇ÷áÄã¾Í²»ÐèÒª IP Masquerade
\item ¶øÇÒµ±È»£¬Èç¹ûÄã²»Ï²»¶Ãâ·ÑÊ¹ÓÃ(free ride) Õâ¸öÖ÷ÒâµÄ»°¡£
\end{itemize}





\subsection{IP Masquerade ÊÇÈçºÎÔË×÷µÄ?}

½Ú×Ô Ken eves µÄ IP Masquerade FAQ:
\begin{verbatim}
  ÕâÊÇ´ó²¿·Ö¼òµ¥µÄÉè¶¨²ÝÍ¼:

     SLIP/PPP         +------------+                         +-------------+
     to provider      |  Linux     |       SLIP/PPP          | Anybox      |
    <---------- modem1|            |modem2 ----------- modem |             |
      111.222.333.444 |            |           192.168.1.100 |             |
                      +------------+                         +-------------+

          ÉÏÃæµÄ²ÝÍ¼ÖÐÒ»Ì¨°²×°²¢Ö´ÐÐ ip_masquerading  µÄ Linux
      »úÆ÷Ê¹ÓÃ modem1 ¾­ÓÉ SLIP/or/PPP  Á¬½ÓÍø¼ÊÍøÂ·¡£ËüÓÐÒ»¸ö
      Ö¸¶¨µÄ IP Î»Ö· 111.222.333.444¡£ËüÉè¶¨ modem2 ÔÊÐí²¦½ÓÕß
      Ç©Èë²¢ÆðÊ¼ SLIP/or/PPP  Á¬½á¡£

          µÚ¶þ¸öÏµÍ³£¨²»±ØÊÇÖ´ÐÐ Linux  µÄÏµÍ³£©²¦½Ó½øÈë Linux
      »úÆ÷²¢ÆðÊ¼ SLIP/or/PPP  Á¬½á¡£ËüÔÚÍø¼ÊÍøÂ·ÉÏ²¢Ã»ÓÐÖ¸¶¨µÄ
      IP  Î»Ö·ËùÒÔËüÊ¹ÓÃ 192.168.1.100¡££¨²ÎÔÄÏÂÊö£©

          ÅäºÏ ip_masquerade  ¼°ÊÊµ±µÝËÍÅäÖÃ(routing configured)
      Anybox  ÕâÌ¨»úÆ÷¿ÉÒÔ¸úÍø¼ÊÍøÂ·½»Á÷¾ÍÈçÍ¬ËüÕæµÄÁ¬ÔÚÉÏÃæ°ã
      £¨³ýÁËÉÙÊýÀýÍâ£©¡£

  ½ÚÂ¼ Pauline Middelink:
      ±ðÍü¼ÇÌáµ½ ANYBOX Ó¦¸Ã°Ñ Linux  »úÆ÷µ±×÷ËüµÄÕ¢µÀ£¨ÎÞÂÛÊÇ
      Ô¤ÉèµÝËÍÂ·¾¶»òÖ»ÊÇ¸ö×ÓÍøÂ·¶¼Ã»¹ØÏµ£©¡£Èç¹û ANYBOX ²»ÄÜ¹»
      ÕâÑùÉè£¬ Linux  »úÆ÷Ó¦¸ÃÎªËùÓÐÒªµÝËÍµÄÎ»Ö·×ö´úÀíÎ»Ö·½âÎö
      ÎöÐ­¶¨(proxy arp) ·þÎñ£¬µ«´úÀíÎ»Ö·½âÎöµÄÉè¶¨³¬¹ýÕâ·ÝÎÄ¼þ
      µÄ¡õÎ§¡£

  ÏÂÃæ½ÚÂ¼×Ô comp.os.linux.networking µÄÒ»Æª²¼¸æ²¢ÇÒÉÔ¼Ó±à¼­ÒÔ
  ·ûºÏÉÏÊö¡õÀýµÄÓÃ´Ê:

  ¡£ÎÒ¸æËß ANYBOX ÕâÌ¨»úÆ÷ÅÜ slip µÄ linux  »úÆ÷ÊÇËüµÄÕ¢µÀ¡£
  ¡£µ±Ò»¸ö·â°ü´Ó ANYBOX ½øÈë linux  »úÆ÷Ê±£¬Ëü»áÖ¸¶¨ÐÂµÄÀ´Ô´²º
    ºÅ(source port number)£¬°ÑËü×Ô¼ºµÄ ip Î»Ö·ÈûÈë·â°üµÄ±êÍ·²¢
    ´¢´æÔ­À´µÄ¡£È»ááËü½«»á½åÓÉ SLIP/or/PPP  ½çÃæ°ÑÐÞ¸Ä¹ýµÄ·â°ü
    ËÍÉÏÍø¼ÊÍøÂ·¡£
  ¡£µ±Ò»¸ö·â°ü´ÓÍø¼ÊÍøÂ·À´µ½ linux  »úÆ÷Ê±£¬Èç¹û²ººÅÊÇÉÏÃæÖ¸¶¨
    µÄÆäÖÐÒ»¸ö£¬Ëü½«»áÈ¡³öÔ­À´µÄ²ººÅÒÔ¼° ip Î»Ö·£¬°ÑËüÃÇ·Å»Ø·â
    °üµÄ±êÍ·£¬²¢ÇÒ°Ñ·â°üËÍÍù ANYBOX ¡£
  ¡£ËÍ³ö·â°üµÄÖ÷»ú½«ÓÀÔ¶²»ÖªµÀÆäÖÐµÄ²î±ð¡£
\end{verbatim}




{\bfseries Ò»¸ö IP Masquerading µÄÀý×Ó:}

ÏÂÃæµÄÍ¼Ê¾ÊÇµäÐÍµÄÀý×Ó:-
\begin{verbatim}

    +----------+
    |          |  Ethernet
    | abox     |::::::
    |          |2    :192.168.1.x
    +----------+     :
                     :   +----------+   PPP   
    +----------+     :  1|  Linux   |   link
    |          |     ::::| masq-gate|:::::::::// Internet
    | bbox     |::::::   |          |
    |          |3    :   +----------+
    +----------+     :
                     :
    +----------+     :
    |          |     :
    | cbox     |::::::
    |          |4    
    +----------+  
                

    <-Internal Network->
\end{verbatim}

ÔÚÕâ¸öÀý×ÓÖÐÎÒÃÇ¿¼ÂÇËÄÌ¨µçÄÔÏµÍ³£¨Ïë±ØÒ£Ô¶µÄÓÒ·½»¹ÓÐÐ©¶«Î÷ÈÃÄãµ½Íø¼ÊÍøÂ·µÄ IP Á¬ÏßÄÜ¹»Á¬½Ó£¬ÒÔ¼°Ò»Ð©£¨Ô¶³¬¹ýÕâÒ»Ò³£©ÔÚÍø¼ÊÍøÂ·ÉÏÄãÓÐÐËÈ¤½»»»×ÊÑ¶µÄ¶«Î÷£©¡£
Õâ¸ö Linux ÏµÍ³ {\ttfamily masq-gate} ÊÇ {\ttfamily abox}, {\ttfamily bbox}, {\ttfamily cbox} ÄÚ²¿ÍøÂ·»úÆ÷Á¬½ÓÍø¼ÊÍøÂ·µÄÎ±×°Õ¢µÀ¡£
ÄÚ²¿ÍøÂ·Ê¹ÓÃÖ¸¶¨µÄË½ÓÃ(private) ÍøÂ·Î»Ö·£¬ÔÚÕâ¸ö°¸ÀýÖÐÊÇ class C ÍøÂ· 192.168.1.0, Linux »úÆ÷ÓµÓÐÎ»Ö· 192.168.1.1  ¶øÆäËüÏµÍ³Ò²ÓµÓÐ´ËÍøÂ·ÉÏµÄÎ»Ö·¡£

ÕâÈýÌ¨»úÆ÷ {\ttfamily abox}, {\ttfamily bbox} ÒÔ¼° {\ttfamily cbox} (ËüÃÇ¿ÉÒÔÖ´ÐÐÈÎºÎ×÷ÒµÏµÍ³ £­ ÏñÊÇ {\bfseries Windows 95}, {\bfseries Macintosh MacTCP} »òÉõÖÁÊÇÁíÒ»Ì¨ Linux »úÆ÷£¬Ö»ÒªËüÃÇÄÜÁË½â IP)¿ÉÒÔÁ¬Ïßµ½Íø¼ÊÍøÂ·ÉÏµÄÆäËü»úÆ÷È¥£¬È»¶øÕâ¸öÎ±×°ÏµÍ³Õ¢µÀ {\ttfamily masq-gate} ×ª»»ËüÃÇËùÓÐµÄÁ¬ÏßËùÒÔÕâÐ©Á¬Ïß¿´ÆðÀ´ÏñÊÇÔ­±¾¼´´ÓÎ±×°Õ¢µÀ {\ttfamily masq-gate} ±¾Éí·¢³öµÄ£¬¶øÇÒ»¹°²ÅÅÎ±×°Á¬Ïß´«»ØµÄ×ÊÁÏ×ª»ØÔ­ÏÈµÄÏµÍ³ £­ ËùÒÔÔÚÄÚ²¿ÍøÂ·ÉÏµÄÏµÍ³¿´µ½µÄÊÇÖ±½ÓÍ¨ÍùÍø¼ÊÍøÂ·µÄµÝËÍÂ·¾¶¶øÇÒ²»ÖªµÀËûÃÇµÄ×ÊÁÏ±»Î±×°¹ý¡£




\subsection{ÔÚ Linux 2.2.x ÉÏÊ¹ÓÃ IP Masquerade  µÄÐèÇó}

\begin{quotation}
 {\bfseries ** Çë²Î¿¼ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource} ÒÔ»ñµÃ×îÐÂ×ÊÑ¶¡£**} 
\end{quotation}


\begin{itemize}
\item 2.2.x °æºËÐÄµÄÔ­Ê¼³ÌÊ½Âë¿É´Ó \onlynameurl{http://www.kernel.org/} È¡µÃ¡£\\ 
(´ó²¿·ÝÏÖ´úµÄ·¢ÐÐÌ×¼þÈç Red Hat 5.2 - Åä±¸ÁË 2.0.36 µÄºËÐÄ -
ÒÑÓÐÁËÄ£×é»¯µÄºËÐÄ£¬ÇÒËùÓÐ IP Masquerade ËùÐèµÄÑ¡Ïî¶¼ÒÑ´ò¿ª¡£
ÕâÖÖÇéÐÎÏÂ£¬ÒÑÃ»ÓÐ±ØÒªÔÙ×ÔÐÐ±àÒë¡£Èç¹ûÄã×Ô¼ºÉý¼¶ºËÐÄ£¬ÄãÓ¦×¢ÒâÄãÐèÒªÊ²÷á£¬ÔÚÎÄ¼þÉÔáá»áÌáµ½¡£)
\item ¿ÉÔØÈëµÄºËÐÄÄ£×é£¬×îºÃÊÇ 2.1.121 »òÒÔááµÄ°æ±¾\\ 
\item Éè¶¨Á¼ºÃµÄ TCP/IP ÍøÂ·\\ 
Ïà¹ØÎÄ¼þÔÚ \nameurl{http://metalab.unc.edu/mdw/HOWTO/NET-3-HOWTO.html}{Linux NET-3 HOWTO} ¼° \nameurl{http://metalab.unc.edu/mdw/LDP/nag/nag.html}{Network Administrator's Guide}\\ 
Ò²Çë²Î¿¼
\nameurl{http://www.ecst.csuchico.edu/~dranch/LINUX/TrinityOS.wri}{Trinity OS Doc}, ÊÇÒ»·Ý·Ç³£ÍêÕûµÄ Linux ÍøÂ·²Î¿¼Ö¸Òý¡£
\item ½«ÄãµÄ Linux Ö÷»úÁ¬ÉÏÍø¼ÊÍøÂ·\\ 
Ïà¹ØÎÄ¼þÓÐ
\nameurl{http://metalab.unc.edu/mdw/HOWTO/ISP-Hookup-HOWTO.html}{Linux ISP Hookup HOWTO},
\nameurl{http://metalab.unc.edu/mdw/HOWTO/PPP-HOWTO.html}{Linux PPP HOWTO},
\nameurl{http://metalab.unc.edu/mdw/HOWTO/mini/DHCP.html}{Linux DHCP mini-HOWTO} ¼°
\nameurl{http://metalab.unc.edu/mdw/HOWTO/mini/Cable-Modem.html}{Linux Cable Modem mini-HOWTO}
\item IP Chains 1.3.8 »ò¸üÐÂµÄ°æ±¾¡£¿É´Ó
\onlynameurl{http://www.rustcorp.com/linux/ipchains/} È¡µÃ¡£\\ 
°æ±¾ÐèÇóµÄ¸ü¶à×ÊÑ¶Ò²ÔÚ
\nameurl{http://www.rustcorp.com/linux/ipchains/}{Linux IP Firewalling Chains page}¡£
\item ÆäËüµÄ×ÊÑ¶£¬Çë¼û
\nameurl{http://ipmasq.cjb.net/}{Linux IP Masquerade Resource}
\end{itemize}





\subsection{ÔÚ Linux 2.0.x ÉÏÊ¹ÓÃ IP Masquerade  µÄÐèÇó}

\begin{quotation}
 {\bfseries ** Çë²Î¿¼ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource} ÒÔ»ñµÃ×îÐÂ×ÊÑ¶¡£**} 
\end{quotation}




\begin{itemize}
\item ºËÐÄ 2.0.x µÄÔ­Ê¼³ÌÊ½Âë¿ÉÒÔ´ÓÕâÀïÈ¡µÃ
\onlynameurl{http://www.kernel.org/}\\ 
(´ó²¿·ÝÏÖ´úµÄ·¢ÐÐÌ×¼þÈç Red Hat 5.2 - Åä±¸ÁË 2.0.36 µÄºËÐÄ -
ÒÑÓÐÁËÄ£×é»¯µÄºËÐÄ£¬ÇÒËùÓÐ IP Masquerade ËùÐèµÄÑ¡Ïî¶¼ÒÑ´ò¿ª¡£
ÕâÖÖÇéÐÎÏÂ£¬ÒÑÃ»ÓÐ±ØÒªÔÙ×ÔÐÐ±àÒë¡£Èç¹ûÄã×Ô¼ºÉý¼¶ºËÐÄ£¬ÄãÓ¦×¢ÒâÄãÐèÒªÊ²÷á£¬ÔÚÎÄ¼þÉÔáá»áÌáµ½¡£)
\item ¿ÉÔØÈëºËÐÄÄ£×é£¬×îºÃÊÇ 2.0.0 »ò¸üÐÂµÄ°æ±¾£¬¿ÉÒÔ´ÓÕâÀïÈ¡µÃ \onlynameurl{http://www.pi.se/blox/modules/modules-2.0.0.tar.gz}\\ 
(ÖÁÉÙÐèÒª modules-1.3.57)
\item Éè¶¨ºÃµÄ TCP/IP ÍøÂ·\\ 

Ïà¹ØÎÄ¼þÔÚ \nameurl{http://metalab.unc.edu/mdw/HOWTO/NET-3-HOWTO.html}{Linux NET-3 HOWTO} ¼° \nameurl{http://metalab.unc.edu/mdw/LDP/nag/nag.html}{Network Administrator's Guide}\\ 
Ò²Çë²Î¿¼
\nameurl{http://www.ecst.csuchico.edu/~dranch/LINUX/TrinityOS.wri}{Trinity OS Doc}, ÊÇÒ»·Ý·Ç³£ÍêÕûµÄ Linux ÍøÂ·²Î¿¼Ö¸Òý¡£
\item ½«ÄãµÄ Linux Ö÷»úÁ¬ÉÏÍø¼ÊÍøÂ·\\ 
Ïà¹ØÎÄ¼þ \nameurl{http://metalab.unc.edu/mdw/HOWTO/ISP-Hookup-HOWTO.html}{Linux ISP Hookup HOWTO},
\nameurl{http://metalab.unc.edu/mdw/HOWTO/PPP-HOWTO.html}{Linux PPP HOWTO},
\nameurl{http://metalab.unc.edu/mdw/HOWTO/mini/DHCP.html}{Linux DHCP mini-HOWTO} ¼°
\nameurl{http://metalab.unc.edu/mdw/HOWTO/mini/Cable-Modem.html}{Linux Cable Modem mini-HOWTO}
\item Ipfwadm 2.3 »ò¸üÐÂµÄ°æ±¾¿ÉÒÔ´ÓÕâÀïÈ¡µÃ\\ 
\onlynameurl{ftp://ftp.xos.nl/pub/linux/ipfwadm/ipfwadm-2.3.tar.gz} 
ÔÚ Linux Ipfwadm  ÍøÒ³ÉÏÓÐ¸ü¶à¹Øì¶°æ±¾µÄ×ÊÑ¶ \nameurl{http://www.xos.nl/linux/ipfwadm/}{Linux IPFWADM page}
\item Äã¿ÉÒÔÑ¡ÔñÐÔµØ¼ÓÉÏÒ»Ð© IP Masquerade ÐÞ²¹µµÒÔÔö¼ÓÆäËü¹¦ÄÜ¡£
´ÓÕâÀï¿ÉÒÔÈ¡µÄ¸ü¶à×ÊÑ¶£¬ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resources} (ÕâÐ©ÐÞ²¹µµÊÊÓÃì¶ËùÓÐµÄ 2.0.x  ºËÐÄ)
\end{itemize}







\section{IP Masquerade µÄÉè¶¨}

\begin{quotation}
{\bfseries Èç¹ûÄãµÄË½ÓÃÍøÂ·ÀïÓÐÈÎºÎÖØÒªµÄ×ÊÑ¶£¬ÔÚÊ¹ÓÃ IP Masquerade Ö®Ç°ÇëÈýË¼¡£Õâ¿ÉÄÜ³ÉÎªÄãÍ¨ÍùÍø¼ÊÍøÂ·µÄÕ¢µÀ£¬·´Ö®ÒàÈ»£¬Ò²¿ÉÄÜ³ÉÎªÁíÒ»±ßµÄÊÀ½ç½øÈëÄãË½ÓÃÍøÂ·µÄÍ¾¾¶¡£}
\end{quotation}





\subsection{±àÒëºËÐÄ¼ÓÈë IP Masquerade µÄÖ§Ô®}

\begin{quotation}
 {\bfseries Èç¹ûÄãµÄ Linux ·¢ÐÐÌ×¼þÒÑ¾­½«ÏÂÃæ½«Ìáµ½µÄËùÐèÌØÐÔ¼°Ä£×é±àÒë½øÈ¥µÄ»°(´ó²¿·ÝÄ£×é»¯µÄºËÐÄÓÐÄãËùÐèµÄ¶«Î÷)£¬ÄÇ÷áÄã²»ÐèÒªÖØÐÂ±àÒëºËÐÄ¡£
²»¹ýÈÔÊ®·Ö½¨ÒéÄã¶ÁÒ»¶Á´Ë½Ú£¬ÒòÎªËü°üº¬ÁËÆäËüÓÐÓÃµÄ×ÊÑ¶¡£} 
\end{quotation}





\subsubsection{Linux 2.2.x °æºËÐÄ}

\begin{itemize}
\item Ê×ÏÈ£¬ÄãÐèÒª 2.2.x °æºËÐÄµÄÔ­Ê¼³ÌÊ½Âë¡£
\item Èç¹ûÕâÊÇÄãµÚÒ»´Î±àÒëºËÐÄ£¬²»Òªº¦ÅÂ¡£
ÊÂÊµÉÏ£¬Õâ·Ç³£ÈÝÒ×¶øÇÒº­¸Çì¶ \onlynameurl{Linux Kernel HOWTO}¡£
\item ÒÔÕâ¸öÖ¸Áî: {\ttfamily tar xvzf linux-2.2.x.tar.gz -C /usr/src}
½«ºËÐÄÔ­Ê¼Âë½â¿ªÖÁ {\ttfamily /usr/src/},
ÆäÖÐ x ÊÇ 2.2 Ö®ááµÄÐÞ²¹²ã¼¶(È·¶¨ÓÐÒ»½Ð {\ttfamily linux} µÄÄ¿Â¼»ò·ûºÅÁ¬½á)¡£
\item ¼ÓÉÏÊÊµ±µÄÐÞ²¹¡£ÒòÎªÐÂµÄÐÞ²¹µµ²»¶Ï³öÀ´£¬ËùÒÔÏ¸½Ú²»»á°üº¬ÔÚÕâÀï¡£
×îÐÂµÄ×ÊÑ¶Çë²Î¿¼ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resources}¡£
\item ÓÐ¹Ø±àÒëºËÐÄ¸ü½øÒ»²½µÄ½éÉÜÇë²Î¿¼ Kernel HOWTO ÒÔ¼°ºËÐÄÔ­Ê¼³ÌÊ½ÂëÄ¿Â¼ÀïµÄ README µµ°¸¡£
\item ÕâÀïÊÇÄãÒª±àÒë½øÈ¥µÄÑ¡Ïî:
ÏÂÁÐÑ¡ÏîÒª»Ø´ð {\itshape YES\/}:

\begin{tscreen}
\begin{verbatim}
  * Prompt for development and/or incomplete code/drivers
    CONFIG_EXPERIMENTAL
    - Õâ½«ÈÃÄãÄÜÑ¡Ôñ°ÑÊµÑéÐÔµÄ IP Masquerade ³ÌÊ½Âë±àÒëµ½ºËÐÄÀïÈ¥

  * Enable loadable module support
    CONFIG_MODULES
    - ÈÃÄãÄÜ¹»ÔØÈë ipmasq Ïà¹ØÄ£×éÈç ip_masq_ftp.o

  * Networking support
    CONFIG_NET

  * Network firewalls
    CONFIG_FIREWALL

  * TCP/IP networking
    CONFIG_INET

  * IP: forwarding/gatewaying
    CONFIG_IP_FORWARD

  * IP: firewalling
    CONFIG_IP_FIREWALL

  * IP: masquerading
    CONFIG_IP_MASQUERADE

  * IP: ipportfw masq support
    CONFIG_IP_MASQUERADE_IPPORTFW
    - ½¨Òé¼ÓÈë

  * IP: ipautofw masquerade support
    CONFIG_IP_MASQUERADE_IPAUTOFW
    - ¿ÉÑ¡ÓÃ

  * IP: ICMP masquerading
    CONFIG_IP_MASQUERADE_ICMP
    - Ö§Ô®Î±×° ICMP ·â°ü£¬½¨Òé¼ÓÈë

  * IP: always defragment
    CONFIG_IP_ALWAYS_DEFRAG
    - ¸ß¶È½¨ÒéÊ¹ÓÃ

  * Dummy net driver support
    CONFIG_DUMMY
    - ½¨Òé¼ÓÈë

  * IP: ip fwmark masq-forwarding support
    CONFIG_IP_MASQUERADE_MFW
    - ¿ÉÑ¡ÓÃ
\end{verbatim}
\end{tscreen}


×¢Òâ: ÕâÖ»²»¹ýÊÇÄãÅÜ IP Masquerade ËùÐèµÄÏîÄ¿£¬ÆäËüµÄ°´ÕÕÄãËùÐèµÄÀ´Ñ¡Ôñ¡£



\item ÔÚ±àÒëÍêºËÐÄÖ®áá£¬ÄãÐèÒª±àÒë¼°°²×°Ä£×é:
\begin{tscreen}
\begin{verbatim}
make modules; make modules_install
\end{verbatim}
\end{tscreen}

\item È»áá°ÑÏÂÃæ¼¸ÐÐ¼Óµ½ÄãµÄ {\ttfamily /etc/rc.d/rc.local} µµ°¸
(»òÆäËüÄãÈÏÎªÊÊµ±µÄµµ°¸)ÖÐÒÔ±ãì¶Ã¿´ÎÖØ¿ª»úÊ±×Ô¶¯ÔØÈëÎ»ì¶ 
{\ttfamily /lib/modules/2.2.x/ipv4/} µÄÄ£×é:
\begin{tscreen}
\begin{verbatim}
        .
        .
        .
/sbin/depmod -a
/sbin/modprobe ip_masq_ftp
/sbin/modprobe ip_masq_raudio
/sbin/modprobe ip_masq_irc
(ÒÔ¼°ÆäËüµÄÄ£×éÈç ip_masq_cuseeme, ip_masq_vdolive,
Èç¹ûÄãÓÐ¼ÓÉÏÕâÐ©ÐÞ²¹µÄ»°)
        .
        .
        .
\end{verbatim}
\end{tscreen}


{\bfseries ÖØÒª: IP ×ªËÍ¹¦ÄÜÔÚ 2.2.x °æºËÐÄÖÐÔ¤ÉèÊÇ¹Ø±ÕµÄ£¬ÇëÈ·¶¨ÄãÒÔ´ËÖ¸Áî½«Æä´ò¿ª:}\\ 
\begin{tscreen}
\begin{verbatim}
echo "1" > /proc/sys/net/ipv4/ip_forwarding
\end{verbatim}
\end{tscreen}

¶Ôì¶ Red Hat µÄÊ¹ÓÃÕßÀ´Ëµ£¬Äã¿ÉÒÔ°Ñ {\ttfamily /etc/sysconfig/network} ÖÐµÄ
{\ttfamily FORWARD\_IPV4=false} ¸Ä³É {\ttfamily FORWARD\_IPV4=true}¡£
\item ÖØÐÂÆô¶¯ Linux Ö÷»ú¡£
\end{itemize}





\subsubsection{Linux 2.0.x Kernels}

\begin{itemize}
\item Ê×ÏÈ£¬ÄãÐèÒªºËÐÄµÄÔ­Ê¼³ÌÊ½Âë(×îºÃÊÇ×îÐÂµÄ 2.0.36 »òÒÔÉÏµÄ°æ±¾)¡£
\item Èç¹ûÕâÊÇÄãµÚÒ»´Î±àÒëºËÐÄ£¬²»Òªº¦ÅÂ¡£
ÊÂÊµÉÏ£¬Õâ·Ç³£ÈÝÒ×¶øÇÒº­¸Çì¶ \onlynameurl{Linux Kernel HOWTO}¡£
\item ÒÔÕâ¸öÖ¸Áî: {\ttfamily tar xvzf linux-2.0.x.tar.gz -C /usr/src}
½«ºËÐÄÔ­Ê¼Âë½â¿ªÖÁ {\ttfamily /usr/src/},
ÆäÖÐ x ÊÇ 2.0 Ö®ááµÄÐÞ²¹²ã¼¶(È·¶¨ÓÐÒ»½Ð {\ttfamily linux} µÄÄ¿Â¼»ò·ûºÅÁ¬½á)¡£
\item ¼ÓÉÏÊÊµ±µÄÐÞ²¹¡£ÒòÎªÐÂµÄÐÞ²¹µµ²»¶Ï³öÀ´£¬ËùÒÔÏ¸½Ú²»»á°üº¬ÔÚÕâÀï¡£
×îÐÂµÄ×ÊÑ¶Çë²Î¿¼ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resources}¡£
\item ÓÐ¹Ø±àÒëºËÐÄ¸ü½øÒ»²½µÄ½éÉÜÇë²Î¿¼ Kernel HOWTO ÒÔ¼°ºËÐÄÔ­Ê¼³ÌÊ½ÂëÄ¿Â¼ÀïµÄ README µµ°¸¡£
\item ÕâÀïÊÇÄãÒª±àÒë½øÈ¥µÄÑ¡Ïî:
ÏÂÁÐÑ¡ÏîÒª»Ø´ð {\itshape YES\/}:

\begin{tscreen}
\begin{verbatim}
  * Prompt for development and/or incomplete code/drivers
    CONFIG_EXPERIMENTAL
    - Õâ½«ÈÃÄãÄÜÑ¡Ôñ°ÑÊµÑéÐÔµÄ IP Masquerade ³ÌÊ½Âë±àÒëµ½ºËÐÄÀïÈ¥

  * Enable loadable module support
    CONFIG_MODULES
    - ÈÃÄãÄÜ¹»ÔØÈëÄ£×é

  * Networking support
    CONFIG_NET

  * Network firewalls
    CONFIG_FIREWALL

  * TCP/IP networking
    CONFIG_INET

  * IP: forwarding/gatewaying
    CONFIG_IP_FORWARD

  * IP: firewalling
    CONFIG_IP_FIREWALL

  * IP: masquerading (EXPERIMENTAL)
    CONFIG_IP_MASQUERADE
    - ÕâËäÈ»ÊÇÊµÑéÐÔµÄ£¬µ«È´ÊÇ *±ØÐë* µÄ

  * IP: ipautofw masquerade support (EXPERIMENTAL)
    CONFIG_IP_MASQUERADE_IPAUTOFW
    - ½¨Òé¼ÓÈë

  * IP: ICMP masquerading
    CONFIG_IP_MASQUERADE_ICMP
    - Ö§Ô®Î±×° ICMP ·â°ü£¬¿ÉÑ¡ÓÃ

  * IP: always defragment
    CONFIG_IP_ALWAYS_DEFRAG
    - ¸ß¶È½¨ÒéÊ¹ÓÃ

  * Dummy net driver support
    CONFIG_DUMMY
    - ½¨Òé¼ÓÈë
\end{verbatim}
\end{tscreen}


×¢Òâ: ÕâÖ»²»¹ýÊÇÄãÅÜ IP Masquerade ËùÐèµÄÏîÄ¿£¬ÆäËüµÄ°´ÕÕÄãËùÐèµÄÀ´Ñ¡Ôñ¡£



\item ÔÚ±àÒëÍêºËÐÄÖ®áá£¬ÄãÐèÒª±àÒë¼°°²×°Ä£×é:
\begin{tscreen}
\begin{verbatim}
make modules; make modules_install
\end{verbatim}
\end{tscreen}

\item È»áá°ÑÏÂÃæ¼¸ÐÐ¼Óµ½ÄãµÄ {\ttfamily /etc/rc.d/rc.local} µµ°¸
(»òÆäËüÄãÈÏÎªÊÊµ±µÄµµ°¸)ÖÐÒÔ±ãì¶Ã¿´ÎÖØ¿ª»úÊ±×Ô¶¯ÔØÈëÎ»ì¶ 
{\ttfamily /lib/modules/2.0.x/ipv4/} µÄÄ£×é:
\begin{tscreen}
\begin{verbatim}
        .
        .
        .
/sbin/depmod -a
/sbin/modprobe ip_masq_ftp
/sbin/modprobe ip_masq_raudio
/sbin/modprobe ip_masq_irc
(ÒÔ¼°ÆäËüµÄÄ£×éÈç ip_masq_cuseeme, ip_masq_vdolive,
Èç¹ûÄãÓÐ¼ÓÉÏÕâÐ©ÐÞ²¹µÄ»°)
        .
        .
        .
\end{verbatim}
\end{tscreen}


{\bfseries ÖØÒª: IP ×ªËÍ¹¦ÄÜÔÚ 2.0.34 Ö®ááµÄºËÐÄÖÐÔ¤ÉèÊÇ¹Ø±ÕµÄ£¬ÇëÈ·¶¨ÄãÒÔ´ËÖ¸Áî½«Æä´ò¿ª:}\\ 
\begin{tscreen}
\begin{verbatim}
echo "1" > /proc/sys/net/ipv4/ip_forwarding
\end{verbatim}
\end{tscreen}


¶Ôì¶ Red Hat µÄÊ¹ÓÃÕßÀ´Ëµ£¬Äã¿ÉÒÔ°Ñ {\ttfamily /etc/sysconfig/network} ÖÐµÄ
{\ttfamily FORWARD\_IPV4=false} ¸Ä³É {\ttfamily FORWARD\_IPV4=true}¡£
\item ÖØÐÂÆô¶¯ Linux Ö÷»ú¡£
\end{itemize}







\subsection{Ö¸¶¨Ë½ÓÃÍøÂ·µÄ IP Î»Ö·}

ÒòÎªËùÓÐ{\bfseries ÆäËü}»úÆ÷¶¼Ã»ÓÐÕýÊ½Ö¸¶¨µÄÎ»Ö·£¬±ØÐëÓÐ¸öÕýÈ·µÄ·½Ê½À´·ÖÅäÎ»Ö·¸øÕâÐ©»úÆ÷¡£

½Ú×Ô IP Masquerade FAQ:

ÓÐ·Ý RFC (\#1597, ÏÖÔÚ¿ÉÄÜÒÑ¹ýÊ±ÁË) ÊÇÓÐ¹ØÃ»ÓÐÓëÍâ½çÁ¬ÏßµÄÍøÂ·¸ÃÊ¹ÓÃÊ²÷á IP Î»Ö·¡£ÓÐÈý¸öÊý×ÖÇø¿éÊÇÌØ±ðÎªÕâ¸öÄ¿µÄ¶ø±£ÁôµÄ¡£ÆäÖÐÒ»¸öÎÒÊ¹ÓÃµÄÊÇ 192.168.1.n µ½ 192.168.255.n Ö®¼äµÄ 255 Class-C ×ÓÍøÂ·¡£

\begin{tscreen}
\begin{verbatim}
½Ú×Ô RFC 1597:

µÚÈý½Ú: Ë½ÓÃÎ»Ö·¿Õ¼ä

      Íø¼ÊÍøÂ·Î»Ö·Ö¸¶¨µ±¾Ö(IANA: Internet Assigned Numbers Authority)
      ÒÑ¾­±£ÁôÏÂÁÐÈý¸öÇø¿éµÄ IP Î»Ö·¿Õ¼ä¸øË½ÓÃÍøÂ·:

                     10.0.0.0        -   10.255.255.255
                     172.16.0.0      -   172.31.255.255
                     192.168.0.0     -   192.168.255.255

      ÎÒÃÇ½«³ÆµÚÒ»¸öÇø¿éÎª "24Î»ÔªÇø¿é"£¬µÚ¶þ¸öÎª "20Î»ÔªÇø¿é"£¬
      ¶øµÚÈý¸öÔò³ÆÎª "16Î»ÔªÇø¿é"¡£×¢Òâµ½µÚÒ»¸öÇø¿é¾ÍÖ»ÊÇ¸ö 
      class A  ÍøÂ·ºÅÂë£¬µÚ¶þ¸öÇø¿éÔòÊÇÁ¬ÐøµÄ 16 ¸ö class B ÍøÂ·
      ºÅÂë£¬¶øµÚÈý¸öÇø¿éÊÇÒ»×é 255  ¸öÁ¬ÐøµÄ class C ÍøÂ·ºÅÂë¡£
\end{verbatim}
\end{tscreen}

ËùÒÔ£¬Èç¹ûÄãÒªÊ¹ÓÃÒ»¸ö class C  ÍøÂ·µÄ»°£¬ÄÇ÷áÄãµÄ»úÆ÷Ó¦¸ÃÒÔ 192.168.1.1, 192.168.1.2, 192.168.1.3, ..., 192.168.1.x À´ÃûÖ®¡£

192.168.1.1 Í¨³£ÊÇÕ¢µÀÕâÌ¨»úÆ÷£¬ÔÚ´Ë¼´ÄãÁ¬ÉÏÍø¼ÊÍøÂ·µÄ Linux Ö÷»ú¡£×¢Òâ 192.168.1.0 ÒÔ¼° 192.168.1.255 ·Ö±ðÎªÍøÂ·ÒÔ¼°¹ã²¥Î»Ö·£¬ÊÇ±£ÁôµÄ¡£±ÜÃâÔÚÄãµÄ»úÆ÷ÉÏÊ¹ÓÃÕâÐ©Î»Ö·¡£




\subsection{ÅäÖÃÆäËü»úÆ÷}

³ýÁËÎªÃ¿Ì¨»úÆ÷Éè¶¨ÊÊµ±µÄ IP Î»Ö·Ö®Íâ£¬ÄãÒ²Ó¦¸ÃÉè¶¨ÊÊµ±µÄÕ¢µÀ¡£Ò»°ãËµÀ´£¬ÕâÊÇ·Ç³£Ö±½ÓÁËµ±µÄ¡£ÄãÖ»Ðè¼òµ¥µØÊäÈë Linux Ö÷»úµÄÎ»Ö·(Í¨³£ÊÇ 192.168.1.1)×÷ÎªÕ¢µÀÎ»Ö·¡£

¹Øì¶ÁìÓòÃû³Æ·þÎñ£¬Äã¿ÉÒÔ¼ÓÈëÈÎºÎ DNS  ÏµÍ³¡£×î¿ÉÄÜµÄÓ¦¸ÃÊÇÄã Linux Ê¹ÓÃµÄÄÇÒ»¸ö¡£ÄãÒ²¿ÉÒÔÑ¡ÔñÐÔµØ¼ÓÉÏÈÎºÎÍøÓò×ÖÎ²(domain suffix) ¡£

ÔÚÄãÖØÐÂÅäÖÃÕâÐ© IP Î»Ö·Ö®áá£¬¼ÇµÃÖØÐÂÆô¶¯ÊÊµ±µÄ·þÎñ»òÊÇÖØÐÂ¿ª»ú¡£

ÏÂÃæµÄÅäÖÃ¡õÀý¼ÙÉèÄãÊ¹ÓÃÒ»¸ö Class C  ÍøÂ·²¢ÇÒÒÔ 192.168.1.1 ×÷Îª Linux  Ö÷»úµÄÎ»Ö·¡£Çë×¢Òâ 192.168.1.0  ¼° 192.168.1.255 ÊÇ±£ÁôµÄ¡£






\subsubsection{ÅäÖÃ Windows 95}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÓÐ°²×°ÍøÂ·¿¨ÒÔ¼°½çÃæÇý¶¯³ÌÊ½£¬ÏÖÔÚ×ö¡£
\item µ½ {\itshape '¿ØÖÆÌ¨/ÍøÂ·'\/} ÀïÈ¥¡£
\item Èç¹ûÄãµÄÍøÂ·ÅäÖÃÀïÃ»ÓÐ {\itshape 'TCP/IP  Ð­¶¨'\/} Ôò¼Ó½øÈ¥¡£
\item ÔÚ{\itshape 'TCP/IP  ÄÚÈÝ'\/}ÖÐ£¬Ñ¡Ôñ{\itshape 'IP  Î»Ö·'\/}²¢ÇÒ°Ñ IP Î»Ö·Éè¶¨Îª 192.168.1.x,(1$<$x$<$255) £¬²¢ÇÒ°Ñ×ÓÍøÂ·ÕÚÕÖÉèÎª 255.255.255.0
\item ÔÚ{\itshape 'Í¨Ñ¶Õ¢'\/}ÖÐ¼ÓÈë 192.168.1.x  ×÷ÎªÄãµÄÕ¢µÀ¡£
\item ÔÚ{\itshape 'DNS ÅäÖÃ'/'DNS ËÅ·þÆ÷'\/}ÏÂ¼ÓÈëÄãµÄ Linux Ö÷»úÊ¹ÓÃµÄ DNS (Í¨³£¿ÉÒÔÔÚ /etc/resolv.conf ÀïÕÒµ½)¡£Äã¿ÉÒÔÑ¡ÔñÐÔµØ¼ÓÈëÊÊµ±µÄÍøÓò×ÖÎ²ËÑÑ°Ë³Ðò¡£
\item ²»Òª±ä¸üÔ­ÏÈµÄÆäËüÉè¶¨£¬³ý·ÇÄãÖªµÀ×Ô¼ºÔÚ×öÊ²÷á¡£
\item ÔÚËùÓÐµÄ¶Ô»°ºÐÖÐ°´ÏÂ{\itshape 'È·¶¨'\/}²¢ÇÒÖØÐÂÆô¶¯ÏµÍ³¡£
\item ²âÊÔÍøÂ·Á¬Ïß£¬{\ttfamily Ping} ÄãµÄ linux Ö÷»ú: ´Ó{\itshape '¿ªÊ¼/Ö´ÐÐ'\/}£¬ÊäÈë ping 192.168.1.1\\ 
(ÕâÖ»ÊÇÇøÓòÍøÂ·Á¬Ïß²âÊÔ£¬ÄãÏÖÔÚ»¹²»ÄÜ {\ttfamily ping} ÍâÃæµÄÊÀ½ç¡£)
\item Äã¿ÉÒÔÔÚ windows  Ä¿Â¼ÏÂÑ¡ÔñÐÔµØ½¨Á¢Ò»¸ö {\ttfamily HOSTS} µµ°¸£¬Èç´ËÄã¿ÉÒÔÊ¹ÓÃÇøÓòÍøÂ·ÀïµÄ»úÆ÷Ãû³Æ¡£ÔÚ windows  Ä¿Â¼ÀïÓÐ¸ö³ÆÎª {\ttfamily HOSTS.SAM} µÄ¡õÀý¡£
\end{enumerate}





\subsubsection{ÅäÖÃ Windos for Workgroup 3.11}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÓÐ°²×°ÍøÂ·¿¨ÒÔ¼°½çÃæÇý¶¯³ÌÊ½£¬ÏÖÔÚ×ö¡£
\item Èç¹ûÄã»¹Î´°²×° TCP/IP 32b Ì×¼þµÄ»°¾Í×°°É¡£
\item ÔÚ {\itshape 'Main'/'Windows Setup'/'Network Setup'\/}, °´ÏÂ {\itshape 'Drivers'\/}¡£
\item ½« {\itshape 'Network Drivers'\/} ÀïµÄ {\itshape 'Microsoft TCP/IP-32 3.11b'\/} ·´°×£¬°´ÏÂ {\itshape 'Setup'\/}¡£
\item Éè¶¨ IP Î»Ö·ì¶ 192.168.1.x (1 $<$ x $<$ 255), È»ááÉè¶¨ Subnet Mask Îª 255.255.255.0 ÒÔ¼° Default Gateway Îª 192.168.1.1¡£
\item ²»Òª¿ªÆô {\itshape 'Automatic DHCP Configuration'\/} ²¢ÔÚ {\itshape 'WINS Server'\/} ÖÐ·ÅÈëÈÎºÎ¶«Î÷£¬³ý·ÇÄãÔÚÒ» Windows NT ÍøÓòÖÐ¶øÇÒÄãÖªµÀÄãÔÚ×öÊ²÷á¡£
\item °´ÏÂ {\itshape 'DNS'\/}, ÌîÈëÔÚ 3.3.1 Ð¡½ÚÖÐ²½ÖèÁùÌáµ½µÄ×ÊÑ¶£¬È»ááÔÚÄãÍê³Éáá°´ÏÂ {\itshape 'OK'\/} Å¥¡£
\item °´ÏÂ {\itshape 'Advanced'\/}, Èç¹ûÄãÊ¹ÓÃÀàËÆ 3.3.1 Ð¡½Ú²½ÖèÊ®ÖÐÌáµ½Ö÷»úµµ°¸£¬¹´Ñ¡ {\itshape 'Enable DNS for Windows Name Resolution'\/} ¼° {\itshape 'Enable LMHOSTS lookup'\/}¡£
\item ÔÚËùÓÐ¶Ô»°ºÐÖÐ°´ {\itshape 'OK'\/} ²¢ÖØÐÂÆô¶¯ÏµÍ³¡£
\item {\ttfamily Ping} Ò»ÏÂÄãµÄ Linux Ö÷»úÒÔ²âÊÔÍøÂ·Á¬½Ó: ÔÚ {\itshape 'File/Run'\/} ÊäÈë: {\ttfamily ping 192.168.1.1} \\ 
(ÕâÖ»²»¹ýÊÇÇøÓòÍøÂ·µÄÁ¬½Ó²âÊÔ£¬Äã»¹²»ÄÜ {\ttfamily ping} µ½ÍâÃæµÄÊÀ½ç)¡£
\end{enumerate}





\subsubsection{Configuring Windows NT}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÓÐ°²×°ÍøÂ·¿¨ÒÔ¼°½çÃæÇý¶¯³ÌÊ½£¬ÏÖÔÚ×ö¡£
\item µ½ {\itshape 'Main'/'Control Panel'/'Network'\/}¡£
\item Èç¹ûÄã»¹Ã»×° TCP/IP ·þÎñµÄ»°´Ó {\itshape 'Add Software'\/} Ñ¡µ¥ÖÐ¼ÓÈë TCP/IP Ð­¶¨¼°Ïà¹ØµÄ²¿·Ý¡£
\item ÔÚ {\itshape 'Network Software and Adapter Cards'\/} Àï½« {\itshape 'Installed Network Software'\/} Ñ¡ÔñºÐÖÐµÄ {\itshape 'TCP/IP Ð­¶¨'\/} ·´°×¡£
\item ÔÚ {\itshape 'TCP/IP Configuration'\/}£¬Ñ¡ÔñÊÊµ±µÄ½çÃæÇý¶¯³ÌÊ½£¬ÀýÈç£¬{\ttfamily [1]Novell NE2000 Adapter}¡£È»ááÉè¶¨ IP Î»Ö·ì¶ 192.168.1.x (1 $<$ x $<$ 255)£¬È»ááÉè¶¨ Subnet Mask Îª 255.255.255.0 ÒÔ¼° Default Gateway Îª 192.168.1.1¡£
\item ²»Òª¿ªÆô {\itshape 'Automatic DHCP Configuration'\/} ²¢ÔÚ {\itshape 'WINS Server'\/} ÖÐ·ÅÈëÈÎºÎ¶«Î÷£¬³ý·ÇÄãÔÚÒ» Windows NT ÍøÓòÖÐ¶øÇÒÄãÖªµÀÄãÔÚ×öÊ²÷á¡£
\item °´ÏÂ {\itshape 'DNS'\/}, ÌîÈëÔÚ 3.3.1 Ð¡½ÚÖÐ²½ÖèÁùÌáµ½µÄ×ÊÑ¶£¬È»ááÔÚÄãÍê³Éáá°´ÏÂ {\itshape 'OK'\/} Å¥¡£
\item °´ÏÂ {\itshape 'Advanced'\/}, Èç¹ûÄãÊ¹ÓÃÀàËÆ 3.3.1 Ð¡½Ú²½ÖèÊ®ÖÐÌáµ½Ö÷»úµµ°¸£¬¹´Ñ¡ {\itshape 'Enable DNS for Windows Name Resolution'\/} ¼° {\itshape 'Enable LMHOSTS lookup'\/}¡£
\item ÔÚËùÓÐ¶Ô»°ºÐÖÐ°´ {\itshape 'OK'\/} ²¢ÖØÐÂÆô¶¯ÏµÍ³¡£
\item {\ttfamily Ping} Ò»ÏÂÄãµÄ Linux Ö÷»úÒÔ²âÊÔÍøÂ·Á¬½Ó: ÔÚ {\itshape 'File/Run'\/} ÊäÈë: {\ttfamily ping 192.168.1.1} \\ 
(ÕâÖ»²»¹ýÊÇÇøÓòÍøÂ·µÄÁ¬½Ó²âÊÔ£¬Äã»¹²»ÄÜ {\ttfamily ping} µ½ÍâÃæµÄÊÀ½ç)¡£
\end{enumerate}





\subsubsection{ÅäÖÃ UNIX ÏµÁÐµÄÏµÍ³}

\begin{enumerate}
\item Èç¹ûÄã»¹Î´°²×°ÄãµÄÍøÂ·¿¨²¢ÒÔÊÊµ±µÄ½çÃæÇý¶¯³ÌÊ½ÖØÐÂ±àÒëÄãµÄºËÐÄ£¬ÏÖÔÚ¾Í×ö°É¡£
\item °²×° TCP/IP ÍøÂ·£¬ÏñÊÇ nettools Ì×¼þ£¬Èç¹ûÄã»¹Ã»×°µÄ»°¡£
\item ½« {\itshape IPADDR\/} ÉèÎª 192.168.1.x (1 $<$ x $<$ 255), È»áá½« {\itshape NETMASK\/} ÉèÎª 255.255.255.0, {\itshape GATEWAY\/} ÉèÎª 192.168.1.1, ÒÔ¼° {\itshape BROADCAST\/} ÉèÎª 192.168.1.255¡£\\ 
ÀýÈç£¬ÔÚ Red Hat Linux ÏµÍ³ÉÏÄã¿ÉÒÔ±à¼­ {\ttfamily /etc/sysconfig/network-scripts/ifcfg-eth0}£¬»òÖ±½Ó´Ó Control Panel Àï×ö¡£\\ 
(ÔÚ SunOS, BSDi, Slackware Linux, µÈÖÐ¶¼²»ÏàÍ¬...)
\item ½«ÄãµÄÃû³ÆËÅ·þÆ÷¼°ÁìÓòËÑÑ°×ÖÎ²¼Óµ½ {\ttfamily /etc/resolv.conf}¡£
\item ÒÀ¾ÝÄãµÄÉè¶¨Äã¿ÉÄÜÒª¸üÐÂÄãµÄ {\ttfamily /etc/networks} µµ°¸¡£
\item ÖØÐÂÆô¶¯ÊÊµ±µÄ·þÎñ£¬»ò¼òµ¥µÄÖØÐÂ¿ª»ú¡£
\item ·¢³ö {\ttfamily ping} Ö¸Áî: {\ttfamily ping 192.168.1.1} ÒÔ²âÊÔµ½ÄãµÄ gateway »úÆ÷µÄÁ¬½ÓÐÔ¡£\\ 
(ÕâÖ»²»¹ýÊÇÇøÓòÍøÂ·µÄÁ¬½Ó²âÊÔ£¬Äã»¹²»ÄÜ {\ttfamily ping} µ½ÍâÃæµÄÊÀ½ç)¡£
\end{enumerate}





\subsubsection{ÅäÖÃÊ¹ÓÃ NCSA Telnet Ì×¼þµÄ DOS »úÆ÷}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÓÐ°²×°ÍøÂ·¿¨£¬ÏÖÔÚ×ö¡£
\item ÔØÈëÊÊµ±µÄ·â°üÇý¶¯³ÌÊ½¡£¶Ôì¶ NE2000 ¿¨À´Ëµ£¬Èç¹ûÄãµÄ¿¨Éè¶¨Îª IRQ 10 ¼°Ó²ÌåÎ»Ö·ì¶ 0x300£¬ÓÃ {\ttfamily nwpd 0x60 10 0x300}¡£
\item ½¨Á¢Ò»ÐÂÄ¿Â¼£¬È»áá½â¿ª NCSA Telnet Ì×¼þ: {\ttfamily pkunzip tel2308b.zip}
\item Ê¹ÓÃÎÄ×Ö±à¼­Æ÷´ò¿ª {\ttfamily config.tel} µµ°¸¡£
\item Éè¶¨ {\ttfamily myip=192.168.1.x} (1 $<$ x $<$ 255), ÒÔ¼° {\ttfamily netmask=255.255.255.0}¡£
\item ÔÚ±¾Àý×ÓÖÐ£¬ÄãÓ¦¸ÃÉè¶¨ {\ttfamily hardware=packet, interrupt=10, ioaddr=60}¡£
\item ÄãÖÁÉÙÒªÓÐÒ»µ¥¶ÀµÄ»úÆ÷Éè¶¨Îª gateway£¬Ò²¾ÍÊÇ Linux Ö÷»ú:
\begin{tscreen}
\begin{verbatim}
name=default
host=yourlinuxhostname
hostip=192.168.1.1
gateway=1
\end{verbatim}
\end{tscreen}

\item »¹ÒªÓÐÁíÍâÒ»¸öÖ¸¶¨ÁìÓòÃû³Æ·þÎñ:
\begin{tscreen}
\begin{verbatim}
name=dns.domain.com ; hostip=123.123.123.123; nameserver=1
\end{verbatim}
\end{tscreen}

×¢Òâ: ÓÃÄã Linux Ö÷»úÊ¹ÓÃµÄ DNS µÄÊÊµ±×ÊÑ¶À´È¡´ú¡£
\item ´¢´æÄãµÄ {\ttfamily config.tel} µµ°¸¡£
\item Telnet µ½ÄãµÄ Linux Ö÷»úÒÔ²âÊÔÍøÂ·Á¬½Ó: {\ttfamily telnet 192.168.1.1}
\end{enumerate}





\subsubsection{ÅäÖÃÖ´ÐÐ MacTCP µÄ MacOS »úÆ÷}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÎªÄãµÄÒÒÌ«ÍøÂ·×ª½ÓÆ÷°²×°ÊÊµ±µÄÇý¶¯³ÌÊ½£¬×îºÃÏÖÔÚ¾Í×÷¡£
     
\item ´ò¿ª {\itshape MacTCP control panel\/}£¬Ñ¡ÔñÊÊµ±µÄÍøÂ·Çý¶¯³ÌÊ½(Ethernet, ¶ø·Ç EtherTalk) ²¢°´ÏÂ {\itshape 'More...'\/} Å¥¡£
\item ÔÚ {\itshape 'Obtain Address:'\/}, °´ {\itshape 'Manually'\/}¡£
\item ÔÚ {\itshape 'IP Address:'\/} ÏÂ£¬´Óµ¯³öÑ¡µ¥ÖÐÑ¡Ôñ {\itshape class C\/}¡£ºöÂÔ¶Ô»°ºÐÖÐµÄÆäËü²¿·Ý¡£
\item ÔÚ {\itshape 'Domain Name Server Information:'\/} ÖÐÌîÈëÊÊµ±×ÊÑ¶¡£
\item ÔÚ {\itshape 'Gateway Address:'\/} ÖÐ£¬ÌîÈë 192.168.1.1¡£
\item °´ÏÂ {\itshape 'OK'\/} ÒÔ´¢´æÉè¶¨¡£ÔÚ {\itshape MacTCP control panel\/} µÄÖ÷ÊÓ´°ÖÐ£¬ÔÚ {\itshape 'IP Address:'\/} ºÐÖÐÌîÈëÄã Mac µÄ IP Î»Ö· (192.168.1.x, 1 $<$ x $<$ 255)¡£
\item ¹Ø±Õ {\itshape MacTCP control panel\/}¡£Èç¹ûÓÐµÄµ¯³öÊÓ´°ÌáÐÑÄãÖØÐÂ¿ª»ú£¬ÄÇ¾Í×ö°É¡£  
\item Äã¿ÉÒÔ {\ttfamily ping} Ò»ÏÂÄãµÄ Linux Ö÷À´À´²âÊÔÍøÂ·Á¬Ïß¡£Èç¹ûÄãÓÐ {\itshape MacTCP Watcher\/} Ãâ·Ñ³ÌÊ½£¬°´ÏÂ {\itshape 'Ping'\/} Å¥£¬È»ááÔÚµ¯³öµÄ¶Ô»°ºÐÖÐ¼üÈëÄãµÄ Linux Ö÷»úµÄµØÖ·(192.168.1.1)¡£(ÕâÖ»²»¹ýÊÇÇøÓòÍøÂ·µÄÁ¬½Ó²âÊÔ£¬Äã»¹²»ÄÜ {\ttfamily ping} µ½ÍâÃæµÄÊÀ½ç¡£)
\item Äã¿ÉÑ¡ÔñÐÔµØÔÚ System Folder ÖÐ½¨Á¢Ò» {\ttfamily Hosts} µµ°¸ÒÔ±ãÄã¿ÉÒÔÊ¹ÓÃÄãÇøÓòÍøÂ·Àï»úÆ÷µÄÖ÷»úÃû³Æ¡£
Õâ¸öµµ°¸¿ÉÄÜÒÑ¾­´æÔÚì¶ÄãµÄ System Folder Àï£¬¶øÇÒËüÓ¦¸Ã»á°üº¬Ò»Ð©(×¢½âµôµÄ)¡õÀýÏîÄ¿¶øÄã¿ÉÒÔ¸ù¾ÝÄãµÄÐèÒªÀ´ÐÞ¸Ä¡£
\end{enumerate}





\subsubsection{ÅäÖÃÖ´ÐÐ Open Transport µÄ MacOS ÏµÍ³}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÎªÄãµÄÒÒÌ«ÍøÂ·×ª½ÓÆ÷°²×°ÊÊµ±µÄÇý¶¯³ÌÊ½£¬×îºÃÏÖÔÚ¾Í×÷¡£
\item ´ò¿ª {\itshape TCP/IP Control Panel\/} È»áá´Ó {\itshape Edit\/} Ñ¡µ¥ÖÐÑ¡Ôñ {\itshape 'User Mode ...'\/}¡£È·¶¨Ê¹ÓÃÕßÄ£Ê½ÖÁÉÙÊÇ {\itshape 'Advanced'\/} È»áá°´ÏÂ {\itshape 'OK'\/} Å¥¡£
\item ´Ó {\itshape File\/} Ñ¡µ¥ÖÐÑ¡Ôñ {\itshape 'Configurations...'\/}¡£Ñ¡Ôñ {\itshape 'Default'\/} ÅäÖÃ²¢°´ÏÂ {\itshape 'Duplicate...'\/} Å¥¡£ÔÚ {\itshape 'Duplicate Configuration'\/} ¶Ô»°ºÐÖÐ¼üÈë 'IP Masq' (»òÊÇÆäËüÄÜÈÃÄãÖªµÀÕâÊÇ¸öÌØÊâÅäÖÃµÄ×ÖÑÛ)£¬Ëü¿ÉÄÜ»áËµÏñÊÇ {\itshape 'Deafault copy'\/} Ê²÷áµÄ¡£È»áá°´ÏÂ {\itshape 'OK'\/} Å¥£¬ÒÔ¼° {\itshape 'Make Active'\/} Å¥¡£
\item ´Ó {\itshape 'Connect via:'\/} µ¯³öÊ½Ñ¡µ¥ÖÐÑ¡Ôñ {\itshape 'Ethernet'\/}¡£
\item ´Ó {\itshape 'Configure:'\/} µ¯³öÊ½Ñ¡µ¥Ñ¡ÔñÊÊµ±µÄÏîÄ¿¡£Èç¹ûÄã²»ÖªµÀÓ¦¸ÃÑ¡Ê²÷á£¬Äã¿ÉÄÜÓ¦¸ÃÖØÐÂÑ¡ÔñÄãµÄ {\itshape 'Default'\/} ÅäÖÃÈ»ááÀë¿ª¡£ÎÒÓÃµÄÊÇ {\itshape 'Manually'\/}¡£
\item ÔÚ {\itshape 'IP Address:'\/} ºÐÖÐÊäÈëÄãµÄ Mac µÄ IP Î»Ö· (192.168.1.x, 1 $<$ x $<$ 255)¡£
\item ÔÚ {\itshape 'Subnet mask:'\/} ºÐÖÐÊäÈë 255.255.255.0¡£
\item ÔÚ {\itshape 'Router address:'\/} ºÐÖÐÊäÈë 192.168.1.1 ¡£
\item ÔÚ {\itshape 'Name server addr.:'\/} ºÐÖÐÊäÈëÄãµÄÁìÓòÃû³ÆËÅ·þÆ÷ IP Î»Ö·¡£
\item ÔÚ {\itshape 'Implicit Search Path:'\/} ÀïµÄ {\itshape 'Starting domain name'\/} ÊäÈëÄãµÄÍø¼ÊÍøÂ·ÁìÓòÃû³Æ(ÀýÈç 'microsoft.com')¡£
\item ½ÓÏÂÀ´µÄ²½ÖèÊÇÑ¡ÔñÐÔµÄ¡£²»ÕýÈ·µÄÖµ¿ÉÄÜµ¼ÖÂÑÏÖØµÄ´íÎóÐÐÎª¡£Èç¹ûÄã²»È·¶¨£¬×îºÃÁôÏÂ¿Õ°×£¬²»Òª¹´Ñ¡¡£Èç¹ûÐèÒªµÄ»°£¬³ýÈ¥ÄÇÐ©À¸Î»ÖÐµÄÈÎºÎ×ÊÑ¶¡£¾ÍÎÒÄ¿Ç°ËùÖªÃ»ÓÐ°ì·¨ÔÚ TCP/IP ¶Ô»°ÊÓ´°ÖÐ¸æËßÏµÍ³²»ÒªÊ¹ÓÃÒÔÇ°Ñ¡¹ýµÄÁíÒ» "Hosts"  µµ°¸¡£Èç¹ûÄãÖªµÀµÄ»°£¬ÎÒºÜÓÐÐËÈ¤ÁË½â¡£Èç¹ûÄãµÄÍøÂ·ÐèÒª 802.3 ¿ò¼ÜµÄ»°¾Í¹´Ñ¡ {\itshape '802.3'\/}¡£
\item °´ÏÂ {\itshape 'Options...'\/} ÒÔÈ·¶¨ TCP/IP ÓÐ×÷ÓÃ¡£ÎÒÊ¹ÓÃ {\itshape 'Load only when needed'\/} Ñ¡Ïî¡£Èç¹ûÄãÖ´ÐÐ²¢½áÊø TCP/IP  Ó¦ÓÃ³ÌÊ½Ðí¶à´Î¶øÎ´ÖØÐÂÆô¶¯ÄãµÄ»úÆ÷£¬Äã½«·¢ÏÖ²»Ñ¡ {\itshape 'Load only when needed'\/} »áÒÖÖÆ/½µµÍÄã»úÆ÷µÄ¼ÇÒäÌå¹ÜÀíÐ§ÄÜ¡£²»Ñ¡´ËÏîÄ¿½«Ê¹ TCP/IP  Ð­¶¨×ÜÊÇ±»ÔØÈë±ãì¶Ê¹ÓÃ¡£Èç¹û¹´Ñ¡ÁË£¬TCP/IP  Ð­¶¨»á×Ô¶¯ÔÚÐèÒªÊ±ÔØÈë²¢ÔÚ²»ÐèÒªÊ±ÊÍ·Å¡£ÔØÈëÓëÊÍ·ÅµÄ¹ý³Ì¿ÉÄÜÊ¹Äã»úÆ÷µÄ¼ÇÒäÌå±äµÄËéÁÑ¡£
\item Äã¿ÉÒÔ {\ttfamily ping} Ò»ÏÂÄãµÄ Linux Ö÷À´À´²âÊÔÍøÂ·Á¬Ïß¡£Èç¹ûÄãÓÐ {\itshape MacTCP Watcher\/} Ãâ·Ñ³ÌÊ½£¬°´ÏÂ {\itshape 'Ping'\/} Å¥£¬È»ááÔÚµ¯³öµÄ¶Ô»°ºÐÖÐ¼üÈëÄãµÄ Linux Ö÷»úµÄµØÖ·(192.168.1.1)¡£(ÕâÖ»²»¹ýÊÇÇøÓòÍøÂ·µÄÁ¬½Ó²âÊÔ£¬Äã»¹²»ÄÜ {\ttfamily ping} µ½ÍâÃæµÄÊÀ½ç¡£)
\item Äã¿ÉÒÔÔÚ System Folder ÖÐ½¨Á¢Ò» {\ttfamily Hosts} µµ°¸ÒÔ±ãÄã¿ÉÒÔÊ¹ÓÃÄãÇøÓòÍøÂ·Àï»úÆ÷µÄÖ÷»úÃû³Æ¡£Õâ¸öµµ°¸¿ÉÄÜÒÑ¾­»ò»¹Î´´æÔÚì¶ÄãµÄ System Folder Àï¡£Èç¹ûÓÐµÄ»°£¬ËüÓ¦¸Ã»á°üº¬Ò»Ð©(×¢½âµôµÄ)¡õÀýÏîÄ¿¶øÄã¿ÉÒÔ¸ù¾ÝÄãµÄÐèÒªÀ´ÐÞ¸Ä¡£Èç¹û»¹Ã»ÓÐµÄ»°£¬Äã¿ÉÒÔ´ÓÒ»²¿ÕýÔÚÔË×÷ MacTCP µÄÏµÍ³ÖÐÈ¡»Ø£¬»ò×Ô¼º½¨Ò»¸ö(Ëü×ñÑ­ Unix µÄ {\ttfamily /etc/hosts} µµ°¸¸ñÊ½£¬ÔÚ RFC 952 ÖÐÃèÊö)¡£Ò»µ©Äã½¨Á¢ÁËÕâ¸öµµ°¸£¬´ò¿ª {\itshape TCP/IP control panel\/}£¬°´ÏÂ {\itshape 'Select Hosts File...'\/} Å¥£¬È»áá´ò¿ª {\ttfamily Hosts} µµ°¸¡£
\item ¹Ø±Õ¶Ô»°ºÐ»ò´Ó {\itshape File\/} Ñ¡µ¥ÖÐÑ¡Ôñ {\itshape 'Close'\/} »ò {\itshape 'Quit'\/} È»áá°´ÏÂ {\itshape 'Save'\/} ÒÔ´¢´æÄãËù×öµÄ¸Ä±ä¡£
\item ÕâÐ©¸Ä±ä»áÁ¢¿ÌÉúÐ§£¬µ«ÖØÐÂ¿ª»úÒ²ÎÞº¦¡£
\end{enumerate}







\subsubsection{ÅäÖÃÊ¹ÓÃ DNS µÄ Novell ÍøÂ·}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÎªÄãµÄÒÒÌ«ÍøÂ·×ª½ÓÆ÷°²×°ÊÊµ±µÄÇý¶¯³ÌÊ½£¬×îºÃÏÖÔÚ¾Í×÷¡£
\item ´Ó \nameurl{ftp.novell.com/pub/updates/unixconn/lwp5}{} È¡»Ø tcpip16.exe¡£
\item 
\begin{verbatim}
±à¼­ c:\nwclient\startnet.bat
\end{verbatim}
: (here is a copy of mine)
\begin{verbatim}
SET NWLANGUAGE=ENGLISH
LH LSL.COM
LH KTC2000.COM
LH IPXODI.COM
LH tcpip
LH VLM.EXE
F:
\end{verbatim}

\item 
\begin{verbatim}
±à¼­ c:\nwclient\net.cfg
\end{verbatim}
: (½«Çý¶¯³ÌÊ½¸ÄÎªÄãµÄ£¬ i.e. NE2000)
\begin{verbatim}
Link Driver KTC2000
        Protocol IPX 0 ETHERNET_802.3    
        Frame ETHERNET_802.3     
        Frame Ethernet_II        
        FRAME Ethernet_802.2

NetWare DOS Requester
           FIRST NETWORK DRIVE = F
           USE DEFAULTS = OFF
           VLM = CONN.VLM
           VLM = IPXNCP.VLM
           VLM = TRAN.VLM
           VLM = SECURITY.VLM
           VLM = NDS.VLM
           VLM = BIND.VLM
           VLM = NWP.VLM
           VLM = FIO.VLM
           VLM = GENERAL.VLM
           VLM = REDIR.VLM
           VLM = PRINT.VLM
           VLM = NETX.VLM

Link Support
        Buffers 8 1500
        MemPool 4096

Protocol TCPIP
        PATH SCRIPT     C:\NET\SCRIPT
        PATH PROFILE    C:\NET\PROFILE
        PATH LWP_CFG    C:\NET\HSTACC
        PATH TCP_CFG    C:\NET\TCP
        ip_address      xxx.xxx.xxx.xxx
        ip_router       xxx.xxx.xxx.xxx
\end{verbatim}

\item ×îáá½¨Á¢ 
\begin{verbatim}
c:\bin\resolv.cfg
\end{verbatim}
:
\begin{verbatim}
SEARCH DNS HOSTS SEQUENTIAL
NAMESERVER 207.103.0.2
NAMESERVER 207.103.11.9
\end{verbatim}

\item ÎÒÏ£ÍûÕâÐ©Ä³Ð©Ê¹ÓÃ Novell ÍøÂ·µÄÈËÓÐ°ïÖú¡£»¹ÓÐ£¬Õâ¶Ô Netware 3.1x »ò 4.x ¶¼ÓÐÓÃ¡£
\end{enumerate}





\subsubsection{ÅäÖÃ OS/2 Warp}

\begin{enumerate}
\item Èç¹ûÄã»¹Ã»ÎªÄãµÄÒÒÌ«ÍøÂ·×ª½ÓÆ÷°²×°ÊÊµ±µÄÇý¶¯³ÌÊ½£¬×îºÃÏÖÔÚ¾Í×÷¡£
\item Èç¹ûÄã»¹Ã»×° TCP/IP Í¨Ñ¶Ð­¶¨µÄ»°ÏÖÔÚ¾Í×°¡£
\item ¿ªÆô {\itshape Programms/TCP/IP (LAN) / TCP/IP\/} Éè¶¨
\item ÔÚ {\itshape 'Network'\/} À¸Î»¼ÓÉÏÄãµÄ TCP/IP Î»Ö·²¢Éè¶¨ÄãµÄ netmask (255.255.255.0)
\item ÔÚ {\itshape 'Routing'\/} À¸Î»°´ÏÂ {\itshape 'Add'\/}¡£½« {\itshape Type\/} À¸Î»Éè¶¨Îª 
{\itshape 'default'\/} ²¢ÔÚ {\itshape 'Router Address'\/} À¸Î»ÖÐ¼üÈëÄãµÄ Linux Ö÷»úµÄ IP Î»Ö· (192.168.1.1)¡£
\item ½« {\itshape 'Hosts'\/} À¸Î»Éè¶¨ÓëÄãµÄ Linux Ö÷»úÊ¹ÓÃÏàÍ¬µÄ DNS (Ãû³ÆËÅ·þÆ÷)Î»Ö·¡£
\item ¹Ø±Õ TCP/IP ¿ØÖÆÌ¨¡£ÔÚ½ÓÏÂÀ´µÄÎÊÌâÖÐ»Ø´ð yes¡£
\item ÖØÐÂÆô¶¯ÄãµÄÏµÍ³
\item Äã¿ÉÒÔ ping ÄãµÄ Linux Ö÷»úÒÔ²âÊÔÍøÂ·ÅäÖÃ¡£ÔÚ 'OS/2 ÃüÁîÊÓ´°' ÉÏ¼üÈë {\ttfamily 'ping 192.168.1.1'}¡£Èç¹ûÊÕµ½ ping ·â°üÒ»ÇÐ¾ÍÃ»ÎÊÌâ¡£
\end{enumerate}





\subsubsection{ÅäÖÃÆäËüÏµÍ³}

ÏàÍ¬µÄÂß¼­Ó¦¿ÉÊÊÓÃì¶ÅäÖÃÆäËüµÄÆ½Ì¨¡£²éÔÄÉÏÊöµÄÐ¡½ÚµÄËµÃ÷¡£
Èç¹ûÄãÓÐÐËÈ¤Ð´¹Øì¶ÆäËüµÄ×÷ÒµÏµÍ³µÄÅäÖÃ£¬
ÇëËÍÏêÏ¸µÄ½¨Á¢Ö¸Òýµ½
\onlynameurl{ambrose@writeme.com} ¼°
\onlynameurl{dranch@trinnet.net}¡£






\subsection{ÅäÖÃ IP ×ªËÍ(Forwarding)µÄ·½Ê½}

µ½Ä¿Ç°ÎªÖ¹£¬ÄãÓ¦¸ÃÒÑ¾­°²×°ºÃºËÐÄÒÔ¼°ÆäËüÐèÒªµÄÌ×¼þ£¬Ò²ÔØÈëÁËÄãµÄÄ£×é¡£Í¬Ê±£¬{\bfseries ÆäËü}»úÆ÷µÄ IP Î»Ö·£¬Õ¢µÀ£¬ÒÔ¼°¡¡DNS Ò²¸ÃÈ«¶¼Éè¶¨Íê³É¡£

ÏÖÔÚ£¬Î¨Ò»Ê£ÏÂÒª×öµÄÊÂÊÇÊ¹ÓÃ IP ·À»ðÇ½¹¤¾ßÀ´×ªËÍÊÊµ±µÄ·â°ü¸øÊÊµ±µÄ»úÆ÷:

\begin{quotation}
{\bfseries ** Õâ¿ÉÒÔÓÃÐí¶à²»Í¬µÄ·½Ê½À´´ï³É¡£ÏÂÁÐµÄ½¨ÒéÓëÀý×Ó¶ÔÎÒÀ´ËµÄÜÓÃ£¬µ«Äã¿ÉÄÜÓÐ²»Í¬µÄÖ÷Òâ£¬Ïê½Ú²¿·ÝÇë²Î¿¼ 4.4 ½Ú¼° ipchains(2.2.x) / ipfwadm(2.0.x) µÄÏßÉÏÊÖ²á¡£ **}
\end{quotation}


\begin{quotation}
{\bfseries ** ±¾½Ú½öÌá¹©Äã½¨Á¢ IP Î±×°¹¦ÄÜËùÐèµÄ×îÉÙ¹æÔò£¬Ò»Ð©°²È«µÄ¿¼Á¿²¢Î´°üº¬½øÈ¥¡£
Ç¿ÁÒ½¨ÒéÄã»¨Ò»Ð©Ê±¼äÈ¥ÑÐ¾¿ÊÊµ±µÄ·À»ðÇ½¹æÔòÀ´¼ÓÇ¿°²È«ÐÔ¡£ **}
\end{quotation}





\subsubsection{Linux 2.2.x ºËÐÄ}



{\bfseries Ipfwadm ÒÑ¾­ÎÞ·¨ÔÚ 2.2.x °æµÄºËÐÄÖÐ´¦Àí IP ·â°üµÄÎ±×°¹æÔò£¬Çë¸ÄÓÃ ipchains¡£}

\begin{tscreen}
\begin{verbatim}
ipchains -P forward DENY
ipchains -A forward -s yyy.yyy.yyy.yyy/x -j MASQ
\end{verbatim}
\end{tscreen}

ÆäÖÐ x ÊÓÄãµÄ×ÓÍøÂ·¶ø¶¨£¬ÎªÏÂÁÐÊý×ÖÖ®Ò»£¬¶ø yyy.yyy.yyy.yyy ÔòÊÇÄãµÄÍøÂ·Î»Ö·¡£
\begin{tscreen}
\begin{verbatim}
netmask         | x  | Subnet
~~~~~~~~~~~~~~~~|~~~~|~~~~~~~~~~~~~~~
255.0.0.0       | 8  | Class A
255.255.0.0     | 16 | Class B
255.255.255.0   | 24 | Class C
255.255.255.255 | 32 | Point-to-point
\end{verbatim}
\end{tscreen}


ÄãÒ²¿ÉÒÔÊ¹ÓÃÕâÖÖ¸ñÊ½ yyy.yyy.yyy.yyy/xxx.xxx.xxx.xxx,
ÆäÖÐ xxx.xxx.xxx.xxx Ö¸¶¨ÄãµÄ×ÓÍøÂ·ÕÚÕÖ£¬Èç 255.255.255.0¡£

ÀýÈç£¬Èç¹ûÎÒÊÇÔÚÒ»¸ö class C ×ÓÍøÂ·ÉÏ£¬ÎÒµÃÊäÈë:
\begin{tscreen}
\begin{verbatim}
ipchains -P forward DENY
ipchains -A forward -s 192.168.1.0/24 -j MASQ
\end{verbatim}
\end{tscreen}

»ò
\begin{tscreen}
\begin{verbatim}
ipchains -P forward DENY
ipchains -A forward -s 192.168.1.0/255.255.255.0 -j MASQ
\end{verbatim}
\end{tscreen}




ÄãÒ²¿ÉÒÔ·Ö±ð¶ÔÃ¿Ì¨»úÆ÷Éè¶¨¡£
ÀýÈç£¬Èç¹ûÎÒÏëÈÃ 192.168.1.2 ¼° 192.168.1.8 ÄÜ¹»´æÈ¡Íø¼ÊÍøÂ·£¬µ«²»ÔÊÐíÆäËü»úÆ÷Ê¹ÓÃµÄ»°£¬ÎÒµÃÊäÈë:
\begin{tscreen}
\begin{verbatim}
ipchains -P forward DENY
ipchains -A forward -s 192.168.1.2/32 -j MASQ
ipchains -A forward -s 192.168.1.8/32 -j MASQ
\end{verbatim}
\end{tscreen}




{\bfseries ²»Òª}°ÑÄãµÄÔ¤Éè·½Ê½(policy)¶¨ÎªÎ±×°(masquerading) £­ ·ñÔò¿ÉÒÔ²Ù¿ØËûÃÇµÄµÝËÍÂ·¾¶(routing) µÄÈË½«ÄÜ¹»Ö±½Ó´©¹ý(tunnel)ÄãµÄÕ¢µÀ£¬ÒÔ´ËÎ±×°ËûÃÇµÄÉí·Ö!





Í¬ÑùµØ£¬Äã¿ÉÒÔ°ÑÕâÐ©¼ÓÈë {\ttfamily /etc/rc.d/rc.local} µµ°¸£¬ÈÎºÎÒ»¸öÄã±È½ÏÏ²»¶µÄ rc µµ°¸£¬»òÊÇÔÚÃ¿´ÎÄãÐèÒª IP Masquerade Ê±ÊÖ¶¯Ö´ÐÐÖ®¡£

¹Øì¶ ipchains µÄÏêÏ¸Ê¹ÓÃ·½·¨£¬Çë²Î¿¼
\nameurl{http://metalab.unc.edu/mdw/HOWTO/IPCHAINS-HOWTO.html}{Linux IPCHAINS HOWTO}




\subsubsection{Linux 2.0.x ºËÐÄ}



\begin{tscreen}
\begin{verbatim}
ipfwadm -F -p deny
ipfwadm -F -a m -S yyy.yyy.yyy.yyy/x -D 0.0.0.0/0
\end{verbatim}
\end{tscreen}

»ò
\begin{tscreen}
\begin{verbatim}
ipfwadm -F -p deny
ipfwadm -F -a masquerade -S yyy.yyy.yyy.yyy/x -D 0.0.0.0/0
\end{verbatim}
\end{tscreen}

ÆäÖÐ x ÊÓÄãµÄ×ÓÍøÂ·¶ø¶¨£¬ÎªÏÂÁÐÊý×ÖÖ®Ò»£¬¶ø yyy.yyy.yyy.yyy ÔòÊÇÄãµÄÍøÂ·Î»Ö·¡£
\begin{tscreen}
\begin{verbatim}
netmask         | x  | Subnet
~~~~~~~~~~~~~~~~|~~~~|~~~~~~~~~~~~~~~
255.0.0.0       | 8  | Class A
255.255.0.0     | 16 | Class B
255.255.255.0   | 24 | Class C
255.255.255.255 | 32 | Point-to-point
\end{verbatim}
\end{tscreen}


ÄãÒ²¿ÉÒÔÊ¹ÓÃÕâÖÖ¸ñÊ½ yyy.yyy.yyy.yyy/xxx.xxx.xxx.xxx,
ÆäÖÐ xxx.xxx.xxx.xxx Ö¸¶¨ÄãµÄ×ÓÍøÂ·ÕÚÕÖ£¬Èç 255.255.255.0¡£

ÀýÈç£¬Èç¹ûÎÒÊÇÔÚÒ»¸ö class C ×ÓÍøÂ·ÉÏ£¬ÎÒµÃÊäÈë:
\begin{tscreen}
\begin{verbatim}
ipfwadm -F -p deny
ipfwadm -F -a m -S 192.168.1.0/24 -D 0.0.0.0/0
\end{verbatim}
\end{tscreen}


ÒòÎª bootp ÇëÇó·â°üÃ»ÓÐºÏ·¨µÄ IP's £¬¿Í»§¶Ë²¢²»ÖªµÀËüµÄÎ»Ö·£¬¶Ôì¶ÔÚÎ±×°/·À»ðÇ½ÉÏÖ´ÐÐ bootp ËÅ·þÆ÷µÄÈË±ØÐëÔÚ deny Ö®Ç°Ö´ÐÐÏÂÁÐÖ¸Áî:
\begin{tscreen}
\begin{verbatim}
ipfwadm -I -a accept -S 0/0 68 -D 0/0 67 -W bootp_clients_net_if_name -P udp
\end{verbatim}
\end{tscreen}




ÄãÒ²¿ÉÒÔ·Ö±ð¶ÔÃ¿Ì¨»úÆ÷Éè¶¨¡£
ÀýÈç£¬Èç¹ûÎÒÏëÈÃ 192.168.1.2 ¼° 192.168.1.8 ÄÜ¹»´æÈ¡Íø¼ÊÍøÂ·£¬µ«²»ÔÊÐíÆäËü»úÆ÷Ê¹ÓÃµÄ»°£¬ÎÒµÃÊäÈë:
\begin{tscreen}
\begin{verbatim}
ipfwadm -F -p deny
ipfwadm -F -a m -S 192.168.1.2/32 -D 0.0.0.0/0
ipfwadm -F -a m -S 192.168.1.8/32 -D 0.0.0.0/0
\end{verbatim}
\end{tscreen}




³£¼ûµÄ´íÎóÊÇÏñÕâÑùµÄµÚÒ»ÐÐÖ¸Áî
\begin{verbatim}
ipfwadm -F -p masquerade
\end{verbatim}

{\bfseries ²»Òª}°ÑÄãµÄÔ¤Éè·½Ê½(policy)¶¨ÎªÎ±×°(masquerading) £­ ·ñÔò¿ÉÒÔ²Ù¿ØËûÃÇµÄµÝËÍÂ·¾¶(routing) µÄÈË½«ÄÜ¹»Ö±½Ó´©¹ý(tunnel)ÄãµÄÕ¢µÀ£¬ÒÔ´ËÎ±×°ËûÃÇµÄÉí·Ö!

Í¬ÑùµØ£¬Äã¿ÉÒÔ°ÑÕâÐ©¼ÓÈë {\ttfamily /etc/rc.d/rc.local} µµ°¸£¬ÈÎºÎÒ»¸öÄã±È½ÏÏ²»¶µÄ rc µµ°¸£¬»òÊÇÔÚÃ¿´ÎÄãÐèÒª IP Masquerade Ê±ÊÖ¶¯Ö´ÐÐÖ®¡£

ÇëÔÄ¶Á 4.4  ½ÚÓÐ¹Ø Ipfwadm µÄÏêÏ¸Ö¸Òý¡£






\subsection{²âÊÔ IP Masquerade}

ÔÚÕâÐ©¹¤×÷Íê³Éáá£¬ÏÖÔÚÊÇÊÔÊÔ¿´µÄÊ±ºòÁË¡£È·¶¨ÄãµÄ Linux  Ö÷»úµ½Íø¼ÊÍøÂ·µÄÁ¬ÏßÊÇÍ¨µÄ¡£

Äã¿ÉÒÔÔÚ{\bfseries ÆäËü}»úÆ÷ÉÏÊÔÖøä¯ÀÀÒ»Ð©{\itshape 'Íø¼ÊÍøÂ·!!!'\/} ÉÏµÄÍøÒ³£¬¿´ÊÇ·ñÄÜ¼ûµ½¡£ÎÒ½¨ÒéµÚÒ»´Î³¢ÊÔÊ±Ê¹ÓÃ IP Î»Ö·¶ø²»ÒªÓÃÖ÷»úÃû³Æ£¬ÒòÎªÄãµÄ DNS  Éè¶¨ÓÐ¿ÉÄÜ²¢²»ÕýÈ·¡£

ÀýÈç£¬Äã¿ÉÒÔÊ¹ÓÃ \onlynameurl{http://152.19.254.81/mdw/linux.html} À´´æÈ¡ Linux ÎÄ¼þ¼Æ»­ÍøÒ³ http://metalab.unc.edu/mdw/linux.html

Èç¹ûÄã¿´¼û The Linux Documentation Project µÄ×ÖÑù£¬ÄÇ÷á¹§Ï²! Ëü¿ÉÒÔÔË×÷ÁË! ½ÓÖøÄã¿ÉÒÔÊ¹ÓÃÖ÷»úÃû³ÆÊÔÊÔ¿´£¬È»ááÊÇ telnet, ftp, RealAudio, True Speech£¬ÒÔ¼°ÈÎºÎ IP Masquerade Ö§Ô®µÄ¶«Î÷¡£

µ½Ä¿Ç°ÎªÖ¹£¬ÎÒ»¹²»ÔøÔÚÉÏÃæµÄÉè¶¨ÉÏ·¢Éú¹ýÎÊÌâ£¬¶øÄÇÐ©»¨ÏÂÊ±¼äÈÃÕâ¸ö¾øÃî¹¦ÄÜÔË×÷µÄÈËÍêÈ«Í¬ÒâÕâÐ©Éè¶¨¡£






\section{ÆäËü IP Masquerade µÄÎÊÌâ¼°ÈíÌåÖ§Ô®}






\subsection{IP Masquerade µÄÎÊÌâ}

Ä³Ð©Ð­¶¨ÏÖÔÚÎÞ·¨ÅäºÏ masquerading Ê¹ÓÃ£¬ÒòÎªËüÃÇ²»ÊÇ¼ÙÉèÓÐ¹Ø²ººÅµÄÒ»Ð©ÊÂÇé£¬¾ÍÊÇÔÚÎ»Ö·¼°²ººÅµÄ×ÊÁÏÁ÷Àï±àÂë×ÊÁÏ £­ ááÃæÕâÐ©Ð­¶¨ÐèÒªÔÚ masquerading ³ÌÊ½ÂëÀï½¨Á¢ÌØ¶¨µÄ´úÀí³ÌÊ½Ê¹ËüÃÇÄÜÔË×÷¡£




\subsection{½øÈëÏµÍ³µÄ·þÎñ(incoming services)}

Masquerading ÍêÈ«²»ÄÜ´¦ÀíÍâ½çµÄ·þÎñÇëÇó (incoming services)¡£
Ö»ÓÐ¼«ÉÙ·½·¨ÄÜÔÊÐíËüÃÇ£¬µ«ÕâÍêÈ«Óë masquerading ÎÞ¹Ø£¬¶øÇÒÊµÔÚÊÇ±ê×¼µÄ·À»ðÇ½·½Ê½¡£

Èç¹ûÄã²¢²»ÒªÇó¸ß¶ÈµÄ°²È«ÐÔÄÇ÷áÄã¿ÉÒÔ¼òµ¥µØÖØµ¼(redirect)ÕâÐ©²º¡£
ÓÐ¼¸ÖÖ²»Í¬µÄ·½·¨¿ÉÒÔ×öÕâ¼þÊÂ £­ ÎÒÊ¹ÓÃÒ»Ö»ÐÞ¸Ä¹ýµÄ redir ³ÌÊ½(ÎÒÏ£ÍûÕâÖ»³ÌÊ½ºÜ¿ì¾ÍÄÜ´Ó sunsite  ¼°Æä mirrors È¡µÃ)¡£
Èç¹ûÄãÏ£ÍûÄÜ¹»¶ÔÍâ½ç½øÈëÏµÍ³µÄ·þÎñÇëÇóÓÐÄ³ÖÖ³Ì¶ÈµÄÉí·ÖÑéÈÏ(authorisation) ÄÇ÷áÄã¿ÉÒÔÔÚ redir µÄ¶¥²ã(0.7 or above) Ê¹ÓÃ TCP wrappers »òÊÇ Xinetd À´ÔÊÐíÌØ¶¨ IP Î»Ö·Í¨¹ý£¬»òÊ¹ÓÃÆäËüµÄ¹¤¾ß¡£TIS ·À»ðÇ½¹¤¾ß¼¯ÊÇÑ°ÕÒ¹¤¾ß¼°×ÊÑ¶µÄºÃµØ·½¡£

¸ü¶àµÄÏê½Ú¿ÉÔÚ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource} ÕÒµ½¡£

½«»á¼ÓÉÏÒ»Ð¡½Ú¸ü¶à¹Øì¶×ªËÍ·þÎñµÄµÄ×ÊÑ¶¡£






\subsection{ÒÑÖ§Ô®µÄ¿Í»§¶ËÈíÌåÒÔ¼°ÆäËüÉè¶¨·½ÃæµÄ×¢ÒâÊÂÏî}

\begin{quotation}
{\bfseries ** ÏÂÃæµÄÁÐ±í½«²»ÔÙ±»Î¬»¤ÁË¡£¿É¾­ÓÉ Linux IP masquerading ÔË×÷µÄÓ¦ÓÃ³ÌÊ½Çë²Î¿¼\nameurl{http://dijon.nais.com/~nevo/masq/}{ÕâÀï} ºÍ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource} ÒÔÈ¡µÃ½øÒ»²½µÄÏ¸½Ú¡£ **}
\end{quotation}


Ò»°ãËµÀ´£¬Ê¹ÓÃ´«Êä¿ØÖÆÐ­¶¨(TCP) »òÊÇÊ¹ÓÃÕß¶¨Òå×ÊÁÏÐ­¶¨ (UDP)µÄÓ¦ÓÃ³ÌÊ½Ó¦¸Ã¶¼ÄÜÔË×÷¡£
Èç¹ûÄãÓÐÈÎºÎ¹Øì¶Ó¦ÓÃ³ÌÊ½Óë IP Masquerade ÏàÈÝµÄ½¨Òé£¬ÌáÊ¾»òÎÊÌâ£¬Çë°Ý·ÃÓÉ Lee Nevo Î¬»¤µÄ
\nameurl{http://dijon.nais.com/~nevo/masq/}{¿ÉÓë Linux IP masquerading ÔË×÷µÄÓ¦ÓÃ³ÌÊ½} ÍøÒ³¡£




\subsubsection{¿ÉÒÔÊ¹ÓÃµÄ¿Í»§¶ËÈíÌå}

Ò»°ã¿Í»§¶ËÈíÌå
\begin{description}
\item[HTTP] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬ä¯ÀÀÍøÒ³

\item[POP \& SMTP] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬µç×ÓÓÊ¼þÈíÌå

\item[Telnet] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬Ô¶¶ËÇ©Èë×÷Òµ

\item[FTP] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬ÅäºÏ ip\_masq\_ftp.o Ä£×é(²»ÊÇËùÓÐÕ¾Ì¨¶¼ÄÜÅäºÏ¸÷ÖÖ¿Í»§¶ËÈíÌå£»ÀýÈçÄ³Ð©²»ÄÜÊ¹ÓÃ ws\_ftp32 ´¥¼°µÄÕ¾Ì¨È´ÄÜÊ¹ÓÃ netscape ½øÈë)

\item[Archie] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬µµ°¸ËÑÑ°ÈíÌå(²¢·ÇËùÓÐ archie ¿Í»§¶ËÈíÌå¶¼Ö§Ô®)

\item[NNTP (USENET)] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬ÍøÂ·ÐÂÎÅÈíÌå 

\item[VRML] \mbox{}

Windows (¿ÉÄÜËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨¶¼¿ÉÒÔ)£¬ÐéÄâÊµ¾³ä¯ÀÀ

\item[traceroute] \mbox{}

Ö÷ÒªÊÇ UNIX ÏµÁÐµÄÆ½Ì¨£¬Ä³Ð©±äÖÖ¿ÉÄÜÎÞ·¨ÔË×÷

\item[ping] \mbox{}

ËùÓÐÆ½Ì¨£¬ÅäºÏ ICMP ÐÞ²¹µµ

\item[anything based on IRC] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬ÅäºÏ ip\_masq\_irc.o Ä£×é

\item[Gopher client] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨

\item[WAIS client] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨

\end{description}




¶àÃ½Ìå¿Í»§¶ËÈíÌå
\begin{description}
\item[Real Audio Player] \mbox{}

Windows, ÍøÂ·×ÊÁÏÁ÷ÒôÑ¶£¬ÅäºÏÔØÈë ip\_masq\_raudio Ä£×é  

\item[True Speech Player 1.1b] \mbox{}

Windows, ÍøÂ·×ÊÁÏÁ÷ÒôÑ¶

\item[Internet Wave Player] \mbox{}

Windows, ÍøÂ·×ÊÁÏÁ÷ÒôÑ¶

\item[Worlds Chat 0.9a] \mbox{}

Windows, ¿Í»§£­ËÅ·þ¶ËÁ¢Ìå½»Ì¸(3D chat) ³ÌÊ½

\item[Alpha Worlds] \mbox{}

Windows, Windows, ¿Í»§£­ËÅ·þ¶ËÁ¢Ìå½»Ì¸(3D chat) ³ÌÊ½

\item[Powwow] \mbox{}

Windows, µã¶ÔµãÎÄ×ÖÉùÒô°×°åÍ¨Ñ¶£¬Èç¹ûÄãºô½Ð±ðÈË£¬ÈËÃÇ¿ÉÒÔÓëÄã½»Ì¸£¬µ«ÊÇËûÃÇ²»ÄÜºô½ÐÄã¡£

\item[CU-SeeMe] \mbox{}

ËùÓÐÓÐÖ§Ô®µÄÆ½Ì¨£¬ÅäºÏÔØÈë cuseeme  Ä£×é£¬ÏêÏ¸Ï¸½ÚÇë²Î ÔÄ \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource}

\item[VDOLive] \mbox{}

Windows, ÅäºÏ vdolive  ÐÞ²¹µµ

\end{description}


×¢Òâ: ¼´Ê¹²»ÊÇÓÉÄãºô½Ð±ðÈË£¬Ê¹ÓÃ {\itshape ipautofw\/} Ì×¼þÄ³Ð©¿Í»§¶ËÈíÌåÏñÊÇ IPhone ÒÔ¼° Powwow ¿ÉÄÜ»¹ÊÇ¿ÉÒÔÔË×÷(²ÎÔÄ 4.6  ½Ú)



ÆäËü¿Í»§¶ËÈíÌå
\begin{description}
\item[NCSA Telnet 2.3.08] \mbox{}

DOS, °üº¬ telnet, ftp, ping  µÈµÈµÄÒ»×éÌ×¼þ¡£

\item[PC-anywhere for windows 2.0] \mbox{}

MS-Windows, ¾­ÓÉ TCP/IP Ô¶¶ËÒ£¿Ø PC £¬Ö»ÓÐÔÚ×÷Îª¿Í»§¶Ë¶ø·ÇÖ÷»ú¶ËµÄÇéÐÎÏÂ²ÅÄÜÔË×÷

\item[Socket Watch] \mbox{}

Ê¹ÓÃ ntp £­ ÍøÂ·Ê±¼äÐ­¶¨

\item[Linux net-acct package] \mbox{}

Linux, ÍøÂ·ÕÊºÅ¹ÜÀíÌ×¼þ

\end{description}





\subsubsection{ÎÞ·¨Ê¹ÓÃµÄ¿Í»§¶ËÈíÌå}

 
\begin{description}
\item[Intel Internet Phone Beta 2] \mbox{}

¿ÉÒÔÁ¬ÉÏµ«ÉùÒôÖ»ÄÜµ¥Ïò(ÍùÍâ)´«ËÍ

\item[Intel Streaming Media Viewer Beta 1] \mbox{}

ÎÞ·¨Á¬ÉÏËÅ·þÆ÷

\item[Netscape CoolTalk] \mbox{}

ÎÞ·¨Á¬½Ó¶Ô·½

\item[talk,ntalk] \mbox{}

Õâ½«²»»áÔË×÷ £­ ÐèÒª×«Ð´Ò»·ÝºËÐÄ´úÀí³ÌÊ½¡£

\item[WebPhone] \mbox{}

Ä¿Ç°ÎÞ·¨ÔË×÷(Ëü×öÁË²»ºÏ·¨µÄÎ»Ö·¼ÙÉè)¡£

\item[X] \mbox{}

Ã»ÓÐ²âÊÔ¹ý£¬µ«ÎÒÏë³ý·ÇÓÐÈË½¨Á¢Ò»Ì× X  ´úÀí³ÌÊ½·ñÔòËüÎÞ·¨ÔË×÷£¬Õâ¿ÉÄÜÊÇ masquerading ³ÌÊ½ÂëÖ®ÍâµÄÒ»¸öÍâ²¿³ÌÊ½¡£Ò»¸öÈÃËüÔË×÷µÄ·½Ê½ÊÇÊ¹ÓÃ ssh ×÷ÎªÁ´½á²¢ÇÒÊ¹ÓÃÆäÄÚ²¿µÄ X ´úÀí¹¦ÄÜÀ´Ö´ÐÐ!



\end{description}





\subsubsection{ÒÑ²âÊÔ¹ý¿ÉÒÔ×÷Îª{\bfseries ÆäËü}»úÆ÷µÄÆ½Ì¨/×÷ÒµÏµÍ³}

 
\begin{itemize}
\item Linux 
\item Solaris
\item Windows 95 
\item Windows NT (both workstation and server) 
\item Windows For Workgroup 3.11 (with TCP/IP package) 
\item Windows 3.1 (with Chameleon package) 
\item Novel 4.01 Server
\item OS/2 (including Warp v3) 
\item Macintosh OS (with MacTCP or Open Transport) 
\item DOS (with NCSA Telnet package, DOS Trumpet works partially)
\item Amiga (with AmiTCP or AS225-stack) 
\item VAX Stations 3520 and 3100 with UCX (TCP/IP stack for VMS)
\item Alpha/AXP with Linux/Redhat
\item SCO Openserver (v3.2.4.2 and 5)
\item IBM RS/6000 running AIX
\end{itemize}


»ù±¾ÉÏ£¬ËùÓÐÖ§Ô® TCP/IP ¶øÇÒÔÊÐíÄãÖ¸¶¨Ï»µÀÆ÷/Â·ÓÉÆ÷(gateway/router)µÄ×÷ÒµÏµÍ³¶¼Ó¦¸ÃÄÜºÍ IP Masquerade Ò»Æð¹¤×÷¡£




\subsection{IP ·À»ðÇ½¹ÜÀí (ipfwadm) }

ÕâÒ»½ÚÌá¹©¹Øì¶ ipfwadm  ¸üÉîÈëµÄÊ¹ÓÃÖ¸Òý¡£

ÕâÊÇÒ»¸ö¸øÔÚ¹Ì¶¨ PPP Î»Ö·Ö® PPP Á¬ÏßááÃæµÄ·À»ðÇ½/Î±×°ÏµÍ³Ê¹ÓÃµÄÉè¶¨¡£ÐÅÀµ(trusted) ½çÃæÎª 192.168.255.1, PPP ½çÃæÒÑ¾­ÐÞ¸Ä¹ýÒÔ±ÜÃâ·¸´í :) ¡£ÎÒ·Ö±ðÁÐ³öÃ¿Ò»¸ö½øÈë(incoming)ÒÔ¼°ËÍ³ö(outgoing)½çÃæÀ´×¥³ö±ä¸üµÝËÍÂ·¾¶(stuffed routing) ÒÔ¼°/»òÊÇÎ±×°(masquerading)µÈµÈÕâÐ©¸ö IP spoofing ¼¼ÇÉ¡£Í¬Ê±ÈÎºÎÃ»ÓÐÃ÷È·ÔÊÐíµÄ¶«Î÷¶¼ÊÇ½ûÖ¹µÄ!



\begin{verbatim}
#!/bin/sh
#
# /etc/rc.d/rc.firewall,  ¶¨Òå·À»ðÇ½ÅäÖÃ£¬´Ó rc.local Ö´ÐÐ¡£
#

PATH=/sbin:/bin:/usr/sbin:/usr/bin

# ²âÊÔÓÃ£¬µÈ´ýÒ»¶ÎÊ±¼äÈ»ááÇå³ýËùÓÐµÄ·À»ðÇ½¹æÔò¡£
# Èç¹ûÄãÏ£Íû·À»ðÇ½Ê®·ÖÖÓÖ®áá×Ô¶¯¹Ø±Õ¾ÍÈ¡ÏûÏÂÁÐ¼¸ÐÐµÄ×¢½â¡£
# (sleep 600; \
# ipfwadm -I -f; \
# ipfwadm -I -p accept; \
# ipfwadm -O -f; \
# ipfwadm -O -p accept; \
# ipfwadm -F -f; \
# ipfwadm -F -p accept; \
# ) &

# ½øÈëÎ±×°Õ¢µÀµÄÉè¶¨£¬¸üÐÂÒÔ¼°Éè¶¨¾Ü¾øµÄ²ßÂÔ(policy)¡£ÊÂÊµÉÏ
# Ô¤ÉèµÄ²ßÂÔÃ»Ê²÷á¹ØÏµ£¬ÒòÎªÔ­ÏÈ¾ÍÏ£Íû¾Ü¾øÒÔ¼°¼ÇÂ¼ËùÓÐ¹æÔò
ipfwadm -I -f
ipfwadm -I -p deny
# Î±×°Õ¢µÀµÄ±¾µØ(local) ½çÃæ£¬ÇøÓòÍøÂ·ÀïµÄ»úÆ÷£¬ÔÊÐíÁ¬ÍùÈÎºÎ
# µØ·½
ipfwadm -I -a accept -V 192.168.255.1 -S 192.168.0.0/16 -D 0.0.0.0/0
# Î±×°Õ¢µÀµÄÔ¶¶Ë(remote)½çÃæ£¬Éù³ÆÊÇÇøÓòÍøÂ·ÀïµÄ»úÆ÷£¬IP spoofing
# ¾Ü¾ø
ipfwadm -I -a deny -V your.static.PPP.address -S 192.168.0.0/16 -D 0.0.0.0/0 -o
# Î±×°Õ¢µÀµÄÔ¶¶Ë½çÃæ£¬ÈÎºÎÀ´Ô´£¬ÔÊÐíËÍÍù¹Ì¶¨ (permanent) PPP
# Î»Ö·
ipfwadm -I -a accept -V your.static.PPP.address -S 0.0.0.0/0 -D your.static.PPP.address/32
# »ØÊÚ(loopback)½çÃæÊÇÔÊÐíµÄ
ipfwadm -I -a accept -V 127.0.0.1 -S 0.0.0.0/0 -D 0.0.0.0/0
# ²¶×½ËùÓÐ¹æÔò£¬ÈÎºÎÆäËüµÄ½øÈë·½Ê½¶¼»á±»¾Ü¾ø²¢¼ÇÂ¼¡£¿ÉÏ§Ã»ÓÐ
# ¼ÇÂ¼ÓÃµÄÑ¡Ïîµ«Õâ¿ÉÒÔ´úÌæ
ipfwadm -I -a deny -S 0.0.0.0/0 -D 0.0.0.0/0 -o

# ËÍ³öÎ±×°Õ¢µÀµÄÉè¶¨£¬¸üÐÂÒÔ¼°Éè¶¨¾Ü¾øµÄ²ßÂÔ(policy)¡£ÊÂÊµÉÏ
# Ô¤ÉèµÄ²ßÂÔÃ»Ê²÷á¹ØÏµ£¬ÒòÎªÔ­ÏÈ¾ÍÏ£Íû¾Ü¾øÒÔ¼°¼ÇÂ¼ËùÓÐ¹æÔò
ipfwadm -O -f
ipfwadm -O -p deny
# ±¾µØ½çÃæ£¬ÔÊÐíÈÎºÎÀ´Ô´ËÍ³öÖÁÇøÓòÍøÂ·
ipfwadm -O -a accept -V 192.168.255.1 -S 0.0.0.0/0 -D 192.168.0.0/16
# Ô¶¶Ë½çÃæËÍ³öÖÁÇøÓòÍøÂ·£¬stuffed routing £¬¾Ü¾ø
ipfwadm -O -a deny -V your.static.PPP.address -S 0.0.0.0/0 -D 192.168.0.0/16 -o
# ÇøÓòÍøÂ·µÄ»úÆ÷´ÓÔ¶¶Ë½çÃæËÍ³ö£¬stuffed masquerading£¬¾Ü¾ø
ipfwadm -O -a deny -V your.static.PPP.address -S 192.168.0.0/16 -D 0.0.0.0/0 -o
# ÇøÓòÍøÂ·µÄ»úÆ÷´ÓÔ¶¶Ë½çÃæËÍ³ö£¬stuffed masquerading£¬¾Ü¾ø
ipfwadm -O -a deny -V your.static.PPP.address -S 0.0.0.0/0 -D 192.168.0.0/16 -o
# ÈÎºÎÆäËüÔ¶¶Ë½çÃæËÍ³öµÄ¶«Î÷¶¼ÊÇÔÊÐíµÄ
ipfwadm -O -a accept -V your.static.PPP.address -S your.static.PPP.address/32 -D 0.0.0.0/0
# »ØÊÚ(loopback)½çÃæÊÇÔÊÐíµÄ
ipfwadm -O -a accept -V 127.0.0.1 -S 0.0.0.0/0 -D 0.0.0.0/0
# ²¶×½ËùÓÐ¹æÔò£¬ÈÎºÎÆäËüµÄËÍ³ö·½Ê½¶¼»á±»¾Ü¾ø²¢¼ÇÂ¼¡£¿ÉÏ§Ã»ÓÐ
# ¼ÇÂ¼ÓÃµÄÑ¡Ïîµ«Õâ¿ÉÒÔ´úÌæ
ipfwadm -O -a deny -S 0.0.0.0/0 -D 0.0.0.0/0 -o

# Î±×°Õ¢µÀµÄ×ªËÍÉè¶¨£¬¸üÐÂÒÔ¼°Éè¶¨¾Ü¾øµÄ²ßÂÔ(policy)¡£ÊÂÊµÉÏ
# Ô¤ÉèµÄ²ßÂÔÃ»Ê²÷á¹ØÏµ£¬ÒòÎªÔ­ÏÈ¾ÍÏ£Íû¾Ü¾øÒÔ¼°¼ÇÂ¼ËùÓÐ¹æÔò
ipfwadm -F -f
ipfwadm -F -p deny
# Î±×°ÇøÓòÍøÂ·µÄ»úÆ÷´Ó±¾µØ½çÃæËÍ³öÖÁÈÎºÎµØ·½µÄ×ÊÁÏ
ipfwadm -F -a masquerade -W ppp0 -S 192.168.0.0/16 -D 0.0.0.0/0
# ²¶×½ËùÓÐ¹æÔò£¬ÈÎºÎÆäËüµÄ×ªËÍ·½Ê½¶¼»á±»¾Ü¾ø²¢¼ÇÂ¼¡£¿ÉÏ§Ã»ÓÐ
# ¼ÇÂ¼ÓÃµÄÑ¡Ïîµ«Õâ¿ÉÒÔ´úÌæ
ipfwadm -F -a deny -S 0.0.0.0/0 -D 0.0.0.0/0 -o
\end{verbatim}


Äã¿ÉÒÔÊ¹ÓÃ -I, -O »òÊÇ -F À´¿ØÖÆµ½Ä³ÌØ¶¨½ÚµãµÄÁ÷Á¿¡£¼ÇµÃÕâÐ©¹æÔò¼¯ÊÇÓÉÉÏÍùÏÂÉ¨ÃèµÄ¶ø -a ´ú±í"¸½¼Ó(append)"µ½Ä¿Ç°ÏÖÓÐµÄ¹æÔò¼¯ÖÐËùÒÔÈÎºÎÏÞÖÆ±ØÐëÔÚÈ«Óò(global)¹æÔòÖ®Ç°³öÏÖ¡£ÀýÈç(Ã»²âÊÔ¹ý) :-

Ê¹ÓÃ -I ¹æÔò¡£¿ÉÄÜÊÇËÙ¶È×î¿ìµÄµ«ÊÇËüÖ»ÄÜ×èÖ¹ÇøÓòÍøÂ·ÀïµÄ»úÆ÷£¬·À»ðÇ½±¾ÉíÈÔÈ»¿ÉÒÔ´æÈ¡"½ûÖ¹"µÄ½Úµã¡£µ±È»Äã¿ÉÄÜÏëÔÊÐíÕâÑùµÄ×éºÏ¡£



\begin{verbatim}
... start of -I rules ...
# ¾Ü¾ø²¢¼ÇÂ¼±¾µØ½çÃæ£¬ÇøÓòÍøÂ·ÀïµÄ»úÆ÷Í¨Íù 204.50.10.13
ipfwadm -I -a reject -V 192.168.255.1 -S 192.168.0.0/16 -D 204.50.10.13/32 -o
# ±¾µØ½çÃæ£¬ÇøÓòÍøÂ·ÀïµÄ»úÆ÷£¬ÔÊÐíÍ¨ÍùÈÎºÎµØ·½
ipfwadm -I -a accept -V 192.168.255.1 -S 192.168.0.0/16 -D 0.0.0.0/0
... end of -I rules ...
\end{verbatim}


Ê¹ÓÃ -O ¹æÔò¡£×îÂý£¬ÒòÎª·â°üÊ×ÏÈ¾­¹ýÎ±×°µ«Õâ¸ö¹æÔò×èÖ¹·À»ðÇ½´æÈ¡½ûÖ¹µÄ½Úµã¡£

\begin{verbatim}
... start of -O rules ...
# ¾Ü¾ø²¢¼ÇÂ¼ËÍ³öÖÁ 204.50.10.13 µÄ×ÊÁÏ
ipfwadm -O -a reject -V your.static.PPP.address -S your.static.PPP.address/32 -D 204.50.10.13/32 -o
# ÔÊÐíÈÎºÎÆäËüÔ¶¶Ë½çÃæËÍ³öµÄ¶«Î÷
ipfwadm -O -a accept -V your.static.PPP.address -S your.static.PPP.address/32 -D 0.0.0.0/0
... end of -O rules ...
\end{verbatim}


Ê¹ÓÃ -F ¹æÔò¡£¿ÉÄÜ±È -I Âý¶øÕâÈÔÈ»Ö»ÄÜ×èÖ¹Î±×°µÄ»úÆ÷(ÀýÈçÄÚ²¿µÄ»úÆ÷)£¬·À»ðÇ½ÈÔÈ»¿ÉÒÔÈ¡µÃ½ûÖ¹µÄ½Úµã¡£

\begin{verbatim}
... start of -F rules ...
# ¾Ü¾ø²¢¼ÇÂ¼ PPP  ½çÃæËÍ³ö´ÓÇøÓòÍøÂ·µ½ 204.50.10.13 µÄ×ÊÁÏ¡£
ipfwadm -F -a reject -W ppp0 -S 192.168.0.0/16 -D 204.50.10.13/32 -o
# Î±×°±¾µØ½çÃæ´ÓÇøÓòÍøÂ·ËÍ³öÖÁÈÎºÎµØ·½µÄ×ÊÁÏ¡£
ipfwadm -F -a masquerade -W ppp0 -S 192.168.0.0/16 -D 0.0.0.0/0
... end of -F rules ...
\end{verbatim}


²»ÐèÒªÓÐ¸öÌØ¶¨µÄ¹æÔòÀ´ÔÊÐí 192.168.0.0/16 Í¨Íù 204.50.11.0, Õâº­¸Çì¶È«Óò¹æÔòÖÐ¡£

ÓÐÒ»ÖÖÒÔÉÏµÄ·½·¨¿ÉÒÔ¶Ô½çÃæÉè¶¨ÉÏÊö¹æÔò¡£ÀýÈç¿ÉÒÔÊ¹ÓÃ -W eth0 À´È¡´ú -V 192.168.255.1£¬¿ÉÒÔÊ¹ÓÃ -W ppp0  À´È¡´ú -V your.static.PPP.address¡£¸öÈËµÄÑ¡Ôñ×îÖØÒª¡£






\subsection{IP ·À»ðÇ½Á´ (ipchains)}

Õâ¸öÖ÷ÒªÊÇ¸ø 2.2.x ºËÐÄÊ¹ÓÃµÄ·À»ðÇ½¹æÔò¹ÜÀí¹¤¾ß(¼ÓÉÏÒ»¸öÐÞ²¹µµááÒ²¿ÉÔÚ 2.0.x ÉÏÔË×÷)¡£

ÎÒÃÇ»á¾¡¿ì¸üÐÂ´Ë½Ú£¬¸øÒ»Ð©Ê¹ÓÃ ipchains µÄ¡õÀý¡£

Ï¸½ÚÇë²Î¿¼ 
\nameurl{http://www.rustcorp.com/linux/ipchains/}{Linux IP Firewalling Chains page} ÒÔ¼°
\nameurl{http://metalab.unc.edu/mdw/HOWTO/IPCHAINS-HOWTO.html}{Linux IPCHAINS HOWTO}¡£






\subsection{IP Masquerade ÒÔ¼°ÐèÇóÊ½²¦½Ó(Demand-Dial-Up)}

\begin{enumerate}
\item Èç¹ûÄãÏë°ÑÍøÂ·Éè¶¨³É×Ô¶¯²¦½ÓÉÏÍø¼ÊÍøÂ·£¬ÄÇ÷á  {\itshape diald\/} demand ²¦½ÓÌ×¼þ½«»áÊÇºÜ°ôµÄ¹¤¾ß¡£
\item ÒªÉè¶¨ diald, Çë²é¿´ \nameurl{http://home.pacific.net.sg/harish/diald.config.html}{Setting Up Diald for Linux Page} ÍøÒ³
\item Ò»µ© diald ÒÔ¼° IP masq  Éè¶¨Íê³É£¬Äã¿ÉÒÔÔÚÈÎºÎ¿Í»§¶Ë»úÆ÷ÉÏÆô¶¯ web, telnet  »òÊÇ ftp Á¬Ïß¡£
\item Diald ½«»áÕì²âµ½½øÈëÏµÍ³µÄÇëÇó£¬È»áá²¦½Óµ½ÄãµÄ ISP ²¢½¨Á¢Á¬Ïß¡£
\item µÚÒ»´ÎÁ¬Ïß½«»á·¢ÉúÓâÊ±(timeout) µÄÇéÐÎ¡£Èç¹ûÄãÊ¹ÓÃÀà±ÈÊ½µÄÊý¾Ý»úÄÇÕâÊÇÎÞ¿É±ÜÃâµÄ¡£
½¨Á¢Êý¾Ý»úÁ¬½áÒÔ¼° PPP  Á¬ÏßËù»¨·ÑµÄÊ±¼ä½«»áÊ¹ÄãµÄ¿Í»§¶ËÈíÌå²»ÄÍ¡£
Èç¹ûÄãÊ¹ÓÃ ISDN Á¬ÏßÄÇÕâÊÇ¿ÉÒÔ±ÜÃâµÄ¡£ÄãµÃ×öµÄÖ»ÊÇ½áÊø¿Í»§¶ËÈíÌåÏÖÐÐµÄ³ÌÐòÔÙÖØÐÂÆô¶¯¼´¿É¡£
\end{enumerate}







\subsection{IPautofw ·â°ü×ªËÍ³ÌÊ½}

\nameurl{ftp://ftp.netis.com/pub/members/rlynch/ipautofw.tar.gz}{IPautofw} ÊÇÒ»¸ö¸ø Linux masquerading Ê¹ÓÃµÄÒ»°ãÐÔ TCP ¼° UDP ×ªËÍ³ÌÊ½¡£Ò»°ãÊ¹ÓÃÐèÒª UDP  µÄÌ×¼þµÄÊ±ºò£¬ÐèÒªÔØÈëÌØ¶¨µÄ ip\_masq Ä£×é£»ip\_masq\_raudio, ip\_masq\_cuseeme,... Ipautofw  ÒÔ¸üÒ»°ã»¯µÄ·½Ê½ÔË×÷£¬Ëü½«»á×ªËÍ°üº¬ÕâÐ©Ó¦ÓÃ³ÌÊ½ÌØ¶¨Ä£×é¶¼²»»á×ªËÍµÄÈÎºÎ×ÊÁÏÁ÷ÐÍÌ¬¡£Èç¹ûÃ»ÓÐÕýÈ·µØ¹ÜÀíÕâ¿ÉÄÜÔì³É°²È«ÉÏµÄÂ©¶´¡£






\subsection{CU-SeeMe Óë Linux IP-Masquerade µÄ¼ò¶ÌËµÃ÷}



ÓÉ \nameurl{mailto:mikey@swampgas.com}{Michael Owings} ËùÌá¹©¡£




\subsubsection{¼ò½é}



\begin{quotation}
±¾½Ú½âÊÍÈÃ CU-SeeMe (°üÀ¨ Cornell ¼° White Pine °æ±¾) Óë Linux µÄ IP Î±×°¹¦ÄÜÒ»ÆðÔË×÷µÄ·½·¨¡£
\end{quotation}


CU-SeeMe ÊÇÒ»¸ö×ÀÉÏÊÓÑ¶»áÒéµÄÈíÌå£¬ÓÐ Windows ¼° Macintosh Á½ÖÖ¿Í»§¶Ë¡£
Ò»¸öÃâ·ÑµÄ°æ±¾¿É´Ó
\nameurl{http://cu-seeme.cornell.edu}{Cornell University}
È¡µÃ¡£ÉÌÒµµÄ¼ÓÇ¿°æ¿É´Ó
\nameurl{http://www.wpine.com}{White Pine Software}
È¡µÃ¡£

IP Î±×°ÔÊÐíÒ»²¿»ò¸ü¶à²¿ÔÚÇøÓòÍøÂ·ÉÏµÄ¹¤×÷Õ¾"Î±×°"ÔÚÒ»²¿Á¬½Óµ½Íø¼ÊÍøÂ·µÄ Linux Ö÷»úÖ®áá¡£
ÇøÓòÍøÂ·ÄÚµÄ¹¤×÷Õ¾¿ÉÒÔ¼¸ºõÍ¸Í¨µØÈ¡ÓÃÍø¼ÊÍøÂ·£¬¼´Ê¹ËüÃ»ÓÐºÏ·¨µÄ IP µØÖ·¡£
Linux Ö÷»úÖØÐ´´ÓÄÚ²¿ÍøÂ·µ½Íø¼ÊÍøÂ·µÄÍâËÍ·â°ü£¬Ê¹ËüÃÇ¿´ÆðÀ´¾ÍÏñÊÇ´ÓÕâ²¿ Linux »úÆ÷·¢³öµÄÒ»Ñù¡£
ËÍ½øÀ´µÄ»ØÓ¦·â°üÒ²±»¸ÄÐ´²¢×ªËÍÖÁÄÚ²¿ÍøÂ·µÄÕýÈ·¹¤×÷Õ¾ÉÏ¡£
ÕâÏî°²ÅÅÊ¹µÃÐí¶àÍø¼ÊÍøÂ·µÄÓ¦ÓÃ³ÌÊ½¿ÉÒÔÍ¸Í¨µØ´ÓÄÚ²¿ÍøÂ·µÄ¹¤×÷Õ¾ÉÏÖ´ÐÐ¡£
È»¶ø£¬¶ÔÄ³Ð©Ó¦ÓÃ³ÌÊ½À´Ëµ(Ïñ CU-SeeMe), Linux µÄÎ±×°³ÌÊ½ÐèÒªÒ»Ð©Ð¡¼¼ÇÉµÄ¸¨Öú²ÅÄÜÊ¹µÃ·â°ü×ªËÍµÃÒÔÕýÈ·ÔË×÷¡£
ÕâÐ©¸¨Öú¼¼ÇÉÍ¨³£À´×Ôì¶Ä³Ð©ÌØÊâµÄºËÐÄ¿ÉÔØÈëÄ£×é¡£
¹Øì¶ IP-Masquerading µÄ¸ü¶à×ÊÑ¶£¬Çë²Î¿¼
\nameurl{http://www.indyramp.com/masq/}{The Linux IP Masquerading Website}¡£




\subsubsection{ÈÃËüÔË×÷}

Ê×ÏÈÄãÐèÒªÊÊµ±µØÅäÖÃºËÐÄ¡£ÄãÓ¦¸Ã¼ÓÈë IP-Masquerading ¼° IP AutoForwarding
µÄÍêÕûÖ§Ô®¡£IP Autoforwarding ³öÏÖÔÚ 2.0.30 ¼°ÆäááµÄºËÐÄÑ¡Ïî -- ¸üÔçµÄºËÐÄÄãÐèÒªÐÞ²¹µµ¡£
²Î¼û
\nameurl{http://ipmasq.cjb.net}{Linux IP Masquerade Resource} 
¹Øì¶ IP-Autoforwarding µÄ×ÊÑ¶Ö¸Òý¡£

½ÓÏÂÀ´£¬ÄãÒªÈ¡µÃ×îÐÂ°æ±¾µÄ {\ttfamily ip\_masq\_cuseeme.c}¡£
Õâ¿É¾­ÓÉÄäÃû FTP ´Ó
\onlynameurl{ftp://ftp.swampgas.com/pub/cuseeme/ip\_masq\_cuseeme.c}
È¡µÃ¡£
Õâ¸öÐÂµÄÄ£×éÒ²ÒÑ¾­¼ÓÈë 2.0.31 µÄºËÐÄÖ®ÖÐ¡£Äã¿ÉÒÔÓÃÐÂµÄ°æ±¾À´È¡´úºËÐÄÖÐµÄ°æ±¾¡£
{\ttfamily ip\_masq\_cuseeme.c} Í¨³£Î»ì¶ Linux ºËÐÄÔ­Ê¼ÂëµÄ {\ttfamily net/ipv4} Ä¿Â¼ÖÐ¡£
Äã±ØÐë±àÒë²¢°²×°´ËÄ£×é¡£

½ÓÏÂÀ´£¬Äã±ØÐë½¨Á¢ UDP ²ººÅ 7648-7649 µÄ×Ô¶¯×ªËÍÈçÏÂ:

\begin{tscreen}
\begin{verbatim}
ipautofw -A -r udp 7648 7649 -c udp 7648 -u
\end{verbatim}
\end{tscreen}

»ò
\begin{tscreen}
\begin{verbatim}
ipautofw -A -r udp 7648 7649 -h www.xxx.yyy.zzz 
\end{verbatim}
\end{tscreen}


µÚÒ»¸öÐÎÊ½ÔÊÐíºô½ÐÀûÓÃ²ººÅ 7648 (Ö÷ÒªµÄ cu-seeme ²ººÅ)½ø³ö¹¤×÷Õ¾¡£
µÚ¶þ¸öÊ¹ÓÃ ipautofw µÄ·½Ê½½öÔÊ¼Æ cu-seeme ½ø³ö www.xxx.yyy.zzz¡£
ÎÒ½ÏÏ²»¶Ç°ÃæÕâÖÖÐÎÊ½£¬ÒòÎªËü¸üÓÐµ¯ÐÔ¶øÇÒÃ»ÓÐ±ØÒªÖ¸¶¨Ò»¸öÌØ±ðµÄ¹¤×÷Õ¾ IP¡£
È»¶ø£¬Õâ¸ö·½Ê½»áÒªÇóÒ»¹¤×÷Õ¾ÄÜÊÕµ½ºô½ÐÇ°ÏÈËÍ³öºô½Ð¡£

×¢ÒâÕâÁ½ÖÖ·½Ê½¶¼½«¿Í»§¶Ë»úÆ÷µÄ UDP ²ººÅ 7648-7649 ¿ª·Å¸øÍâ½ç --
ËäÈ»Õâ²»ÖÁì¶ÓÐÑÏÖØµÄ°²È«Î£ÏÕ£¬Äã»¹ÊÇÓ¦ÌØ±ðÐ¡ÐÄ¡£

×îáá£¬ÒÔÏÂ·¨ÔØÈëÐÂµÄ {\ttfamily ip\_masq\_cuseeme} Ä£×é:

\begin{verbatim}
modprobe ip_masq_cuseeme 
\end{verbatim}


ÏÖÔÚÄã¿ÉÒÔ´ÓÄãÇøÓòÍøÂ·ÉÏÒ»²¿±»Î±×°µÄ»úÆ÷ÉÏÖ´ÐÐ CU-SeeMe ²¢Á¬½Óµ½Ô¶¶ËµÄ»ØÓ¦Æ÷(reflector)ÉÏ£¬»òÁíÒ»¸ö CU-SeeMe µÄÊ¹ÓÃÕß¡£
ÄãÓ¦¸ÃÒ²¿ÉÒÔÊÕµ½ºô½Ð¡£×¢ÒâÍâ½çµÄºô½ÐÕß±ØÐëÊ¹ÓÃÄã Linux Ï»µÀÆ÷µÄ IP, ¶ø²»ÊÇ±»Î±×°¹¤×÷Õ¾µÄ IP¡£




\subsubsection{ÏÞÖÆ/¾¯¸æ}






\paragraph{ÃÜÂë±£»¤µÄ»ØÓ¦Æ÷}

Ä¿Ç°Ã»ÓÐÈÎºÎ°ì·¨Ê¹ÓÃ¡£
White Pine Ê¹ÓÃÀ´Ô´ IP (ÓÉ¿Í»§¶Ë³ÌÊ½¼ÆËã)ÔÚ´«ËÍÇ°½«ÃÜÂë±àÂë±£»¤¡£
ÒòÎªÎÒÃÇ¸ÄÐ´ÁËÎ»Ö·£¬»ØÓ¦Æ÷Ê¹ÓÃ´íÎóµÄÀ´Ô´ IP À´½âÂë£¬Òò´ËµÃµ½²»ÕýÈ·µÄÃÜÂë¡£
³ý·Ç White Pine ¸Ä±äËûÃÇÃÜÂë±àÂëµÄ²ßÂÔ(ÎÒÒÑ¾­½¨Òé¹ýÁË)£¬»òÊÇËûÃÇÔ¸Òâ¿ª·ÅËûÃÇÃÜÂë±àÂëµÄ¹«Ê½ÒÔ±ãÈÃÎÒÄÜ¼Óµ½ {\ttfamily ip\_masq\_cuseeme}¡£
ÓÉì¶ááÃæÒ»¸ö°ì·¨µÄ¿ÉÄÜÐÔºÜÐ¡£¬Òò´ËÎÒ·Ç³£¹ÄÀø¿´µ½Õâ·ÝÎÄ¼þµÄÈËÓë White Pine ÁªÂç²¢½¨ÒéËûÃÇ²ÉÓÃÇ°Ò»ÖÖ×÷·¨¡£
ÒòÎª±¾Ò³µÄÁ÷Á¿Ïàµ±Âú¸ßµÄ£¬ÎÒ»³ÒÉÎÒÃÇÄÜ·ñ²úÉú×ã¹»µÄµç×ÓÓÊ¼þÒÔÊ¹´ËÎÊÌâÄÜ½øÈë White Pine µÄÓÅÏÈ´¦ÀíÃûµ¥ÖÐ¡£

¸ÐÐ» Thomas Griwenka ÌáÐÑÎÒÕâ¼þÊÂ¡£




\paragraph{Ö´ÐÐ»ØÓ¦Æ÷}

Äã²»ÄÜ³¢ÊÔÔÚÄãÅÜ {\ttfamily ip\_masq\_cuseeme} ¼° ipautoforwarding ²ººÅ 7648 µÄÏàÍ¬»úÆ÷ÉÏÖ´ÐÐ»ØÓ¦Æ÷(reflector)¡£
ÕâÃ»ÓÐÓÃ£¬ÒòÎªÁ½Õß¶¼ÐèÒªÅäÖÃ²ººÅ 7648¡£
»òÕßÓÃÁíÒ»²¿¿ÉÖ±´ïÍø¼ÊÍøÂ·µÄÖ÷»úÀ´Ö´ÐÐ£¬»òÊÇÔÚÖ´ÐÐ»ØÓ¦Æ÷Ç°Ð¶ÏÂ CU-SeeMe µÄ¿Í»§¶ËÖ§Ô®¡£




\paragraph{¶à CU-SeeMe Ê¹ÓÃÕß}

Äã²»ÄÜÒ»´ÎÓÐ¶àÎ» CU-SeeMe Ê¹ÓÃÕßÍ¬Ê±ÔÚÒ»¸öÇøÓòÍøÂ·ÉÏÃæ¡£
ÕâÊÇÓÉì¶ CU-SeeMe Íç¹ÌµØ¼á³ÖÊ¹ÓÃ²ººÅ 7648, Ê¹µÃÔÚÇøÓòÍøÂ·ÄÚÒ»´Î½öÄÜÓÐÒ»Ì¨¹¤×÷Õ¾ÄÜ(ÈÝÒ×µØ)±»ÖØµ¼Ïò¡£

Ê¹ÓÃ -c (control port) À´ºô½Ð {\ttfamily ipautofw}, Äã¿ÉÒÔ±ÜÃâÖ¸¶¨Ò»¹Ì¶¨µÄ¹¤×÷Õ¾Î»Ö·È¥Ê¹ÓÃ CU-SeeMe --
µÚÒ»²¿Ê¹ÓÃ¿ØÖÆ²ººÅ 7648 ËÍ³öÈÎºÎ¶«Î÷µÄ¹¤×÷Õ¾»á±»Ö¸¶¨Îª½ÓÊÕÀ´×Ô²ººÅ 7648-7649 µÄÁ÷Á¿¡£
Èç¹û¾­¹ýÎå·ÖÖÓ×óÓÒÕâ²¿¹¤×÷Õ¾²»ÔÙÊ¹ÓÃ²ººÅ 7648, ÁíÒ»²¿¹¤×÷Õ¾¾Í¿É½ÓÖøÊ¹ÓÃ¡£




\paragraph{Ð­ÖúÉè¶¨ CU-SeeMe}



ÈôÓÐÈÎºÎÆÀÂÛ»òÎÊÌâÇëÐ´ÐÅµ½
\onlynameurl{mikey@swampgas.com}¡£
»òÕßÈç¹ûÄãÔ¸ÒâµÄ»°£¬Äã¿ÉÒÔ
\nameurl{http://www.swampgas.com/vc/vc.htm}{Í¸¹ý CU-SeeMe À´ºô½ÐÎÒ}¡£






\subsection{ÆäËüÏà¹Ø¹¤¾ß}

ÎÒÃÇ»á¾¡¿ì¸üÐÂ´Ë½Ú¼ÓÉÏ¸ü¶àÆäËüÎ±×°Ïà¹ØµÄ¹¤¾ßÈç ipportfw ÒÔ¼° masqadmin¡£








\section{³£¼ûÎÊÌâ½â´ð}

Èç¹ûÄãÏëµ½ÈÎºÎÓÐÓÃµÄ³£¼ûÎÊÌâÓë½â´ð£¬ÇëÐ´ÐÅµ½
\onlynameurl{ambrose@writeme.com} ¼°
\onlynameurl{dranch@trinnet.net}¡£
ÇëÇå³þµØËµÃ÷ÎÊÌâ²¢¸½ÉÏÊÊµ±µÄ½â´ð¡£Ð»Ð»!




\subsection{IP Masquerade ÄÜ·ñºÍ¶¯Ì¬ÅäÖÃµÄ IP ¹²Í¬ÔË×÷?}

ÊÇµÄ£¬ËüÄÜºÍÄã ISP ¶¯Ì¬ÅäÖÃµÄ IP, Í¨³£ÊÇÓÉÒ»²¿ DHCP ËÅ·þÆ÷·ÖÅäµÄÎ»Ö·Ò»ÆðÔË×÷¡£
Ö»ÒªÄãÓÐÒ»¸öºÏ·¨µÄÍø¼ÊÍøÂ·Î»Ö·£¬Ëü¾ÍÄÜÔË×÷¡£µ±È»£¬¹Ì¶¨µÄ IP Ò»ÑùÃ»ÎÊÌâ¡£




\subsection{ÎÒÄÜÊ¹ÓÃÊý¾Ý»ú£¬DSL, ÎÀÐÇÁ¬ÏßµÈÀ´Á¬½ÓÍø¼ÊÍøÂ·²¢Ê¹ÓÃ IP Masquerade Âð?}

µ±È»£¬Ö»Òª Linux Ö§Ô®¸ÃÍøÂ·½çÃæ£¬Ëü¾ÍÄÜÔË×÷¡£




\subsection{IP Masquerade Ö§Ô®Ê²÷áÓ¦ÓÃ³ÌÊ½?}

Òª±£³ÖÒ»·Ý"ÄÜÓÃµÄÓ¦ÓÃ³ÌÊ½"ÁÐ±íÊÇÏàµ±À§ÄÑµÄ¡£
²»¹ý£¬´ó²¿·ÖÕý³£µÄÍø¼ÊÍøÂ·Ó¦ÓÃ³ÌÊ½¶¼±»Ö§Ô®£¬ÀýÈçä¯¡õÆ÷(Netscape, MSIE µÈ),
ftp (Ïñ WS\_FTP), Real Audio, telnet, SSH, POP3 (ÊÕÐÅ³ÌÊ½ - Pine, Outlook µÈ),
SMTP(ËÍÐÅ³ÌÊ½), µÈµÈ¡£

Ê¹ÓÃ¸´ÔÓÐ­¶¨»òÌØÊâÁ¬Ïß·½Ê½µÄÓ¦ÓÃ³ÌÊ½£¬ÀýÈçÊÓÑ¶»áÒéÈíÌå¾ÍÐèÒªÌØ±ðµÄ¸¨Öú¹¤¾ß¡£

½øÒ»²½µÄÏ¸½Ú£¬Çë²Î¿¼ Lee Nevo Î¬»¤µÄ
\nameurl{http://dijon.nais.com/~nevo/masq/}{applications that work thru Linux IP masquerading}¡£




\subsection{ÎÒÈçºÎÔÚ Redhat, Debian, Slackware µÈÊ¹ÓÃ IP Masquerade ÄØ?}

²»ÂÛÄãÊ¹ÓÃºÎÖÖ·¢ÐÐÌ×¼þ£¬±¾ÎÄ¼þÖÐÃèÊöµÄ·½·¨¶¼Ó¦¸ÃÄÜÊÊÓÃ¡£
Ä³Ð©Ì×¼þ¿ÉÄÜ°üº¬ÁË GUI »òÊÇÌØ±ðµÄÉè¶¨µµ°¸ÄÜ¼ò»¯ÅäÖÃµÄ²½Öè¡£
ÎÒÃÇÊÇ¾¡Á¦ÈÃÕâ·ÝÎÄ¼þÐ´µÃÊÊÓÃ×îÒ»°ã»¯µÄÇéÐÎ¡£




\subsection{ÎÒÉý¼¶µ½ 2.2.x µÄºËÐÄ£¬ÎªÊ²÷á IP Masquerade ²»ÄÜÓÃÁË?}

¼ÙÉèÄãµÄ Linux Ö÷»úÒÑ¾­ÊÊµ±µØÁ¬ÉÏÍø¼ÊÍøÂ·ÓëÄãµÄÄÚ²¿ÍøÂ·£¬ÓÐ¼¸¼þÊÂÄã±ØÐè¼ì²é:

\begin{itemize}
\item È·¶¨ÄãÒÑ±àÒë²¢ÔØÈë±ØÒªµÄÌØÐÔÓëÄ£×é¡£²Î¼ûÇ°ÃæÕÂ½ÚµÄËµÃ÷¡£
\item ¼ì²é {\ttfamily /usr/src/linux/Documentation/Changes} ²¢È·¶¨Äã°²×°ÁË×îµÍÐèÇóµÄÍøÂ·¹¤¾ß¡£
\item È·¶¨Äã´ò¿ªÁË IP ×ªËÍ»úÖÆ¡£ÊÔÖøÖ´ÐÐ
\begin{tscreen}
\begin{verbatim}
echo "1" > /proc/sys/net/ipv4/ip_forwarding
\end{verbatim}
\end{tscreen}
\item Äã±ØÐëÊ¹ÓÃ
\nameurl{http://www.rustcorp.com/linux/ipchains/}{ipchains}
À´´¦Àí IP Î±×°¼°·À»ðÇ½¹æÔò¡£
\item ½«Õû¸öÉè¶¨ÅäÖÃµÄ¹ý³ÌÔÙ×öÒ»´Î! ºÜ¶àÊ±ºòÖ»ÊÇ´ò´í×Ö»òÊÇÄãºöÂÔÁËÒ»¸öÓÞ´ÀµÄ´íÎó¡£
\end{itemize}





\subsection{ÎÒÒÑ¾­Éý¼¶µ½ 2.0.30 ááµÄºËÐÄ£¬ÎªÊ²÷á IP Masquerade »¹²»ÄÜÓÃ?}

¼ÙÉèÄãµÄ Linux Ö÷»úÒÑ¾­ÊÊµ±µØÁ¬ÉÏÍø¼ÊÍøÂ·ÓëÄãµÄÄÚ²¿ÍøÂ·£¬ÓÐ¼¸¼þÊÂÄã±ØÐè¼ì²é:

\begin{itemize}
\item È·¶¨ÄãÒÑ±àÒë²¢ÔØÈë±ØÒªµÄÌØÐÔÓëÄ£×é¡£²Î¼ûÇ°ÃæÕÂ½ÚµÄËµÃ÷¡£
\item ¼ì²é {\ttfamily /usr/src/linux/Documentation/Changes} ²¢È·¶¨Äã°²×°ÁË×îµÍÐèÇóµÄÍøÂ·¹¤¾ß¡£
\item È·¶¨Äã´ò¿ªÁË IP ×ªËÍ»úÖÆ¡£ÊÔÖøÖ´ÐÐ
\begin{tscreen}
\begin{verbatim}
echo "1" > /proc/sys/net/ipv4/ip_forwarding
\end{verbatim}
\end{tscreen}
\item Äã±ØÐëÊ¹ÓÃ
\nameurl{http://www.xos.nl/}{ipfwadm}
À´´¦Àí IP Î±×°¼°·À»ðÇ½¹æÔò¡£ÒªÔÚ 2.0.x Ê¹ÓÃ ipchains µÄ»°Äã±ØÐë¼ÓÉÏÐÞ²¹¡£
\item ½«Õû¸öÉè¶¨ÅäÖÃµÄ¹ý³ÌÔÙ×öÒ»´Î! ºÜ¶àÊ±ºòÖ»ÊÇ´ò´í×Ö»òÊÇÄãºöÂÔÁËÒ»¸öÓÞ´ÀµÄ´íÎó¡£
\end{itemize}





\subsection{ÎÒÎÞ·¨ÈÃ IP Masquerade ÔË×÷! ÓÐ Windows Æ½Ì¨µÄÑ¡ÔñÂð?}

ËùÒÔÄãÒª·ÅÆúÒ»¸ö¿ÉÔÚ×îµÍÓ²ÌåÐèÇóÊ¹ÓÃµÄÃâ·Ñ£¬¿É¿¿£¬¸ßÐ§ÂÊµÄ½â¾ö·½°¸£¬¶øÏë»¨Ç®ÔÚÄ³¸öÐèÒª¸ü¸ßÓ²Ìå£¬µÍÐ§ÂÊÇÒ²»¿É¿¿µÄÎ´À´?
(àÅ£¬ÊÇµÄ£¬ÎÒÕæµÄÓö¹ýÕâÑùµÄ¾­Ñé ;-) )

ºÃ°É£¬ÄÇÊÇÄãµÄÊÂ¡£ÓÃËÑÑ°ÒýÇæÕÒÕÒ MS Proxy Server, Wingate, »ò¿´¿´ www.winfiles.com¡£ ±ðËµÊÇÎÒ¸æËßÄã¡£




\subsection{ÎÒ¼ì²é¹ýÎÒËùÓÐµÄÉè¶¨ÁË£¬ÈÔÎÞ·¨ÈÃ IP Masquerade ¹¤×÷¡£ÎÒ¸ÃÔõ÷á°ì?}

\begin{itemize}
\item Àä¾²Ò»ÏÂ¡£¸øÄã×Ô¼ºÒ»±­¿§·È²¢ÐÝÏ¢Ò»ÏÂ£¬È»ááÊÔÊÔÏÂÃæµÄ½¨Òé¡£
\item ¿´Ò»ÏÂ \nameurl{http://home.indyramp.com/lists/masq/}{IP Masquerade Mailing List Archive},
´ó²¿·ÝÄãÒªµÄ´ð°¸ÒÑ¾­ÔÚµÈÖøÄãÁË¡£
\item °ÑÄãµÄÎÊÌâËÍµ½ IP Masquerade Í¨ÐÅÂÛÌ³ÉÏ£¬Ï¸½ÚÇë¿´ÏÂÒ»ÔòÎÊÌâ¡£
Çë½öÓÐÔÚÄãÎÞ·¨ÕÒµ½´ð°¸Ê±²ÅÕâ÷á×ö¡£
\item ÔÚ Linux µÄÍøÂ·Ïà¹ØÌÖÂÛÈºÖÐ·¢ÎÊ¡£
\item Ð´ÐÅµ½ \onlynameurl{ambrose@writeme.com}
¼° \onlynameurl{dranch@trinnet.net}¡£
Í¬Ê±ËÍÐÅ¸øÎÒÃÇÄã»áÓÐ½Ï¼ÑµÄ»ú»áµÃµ½»ØÓ¦¡£David »ØÐÅµÄÇé¿ö½Ï¼Ñ£¬ÖÁì¶ÎÒµÄ»ØÓ¦Ê±¼äÂï£¬²»ÓèÖÃÆÀ¡£
\item ÔÙ´Î¼ì²éÄãµÄÉè¶¨ :-)
\end{itemize}





\subsection{ÎÒÈçºÎ¼ÓÈë IP Masquerade Í¨ÐÅÂÛÌ³?}

Òª¼ÓÈë IP Masquerade Í¨ÐÅÂÛÌ³µÄ»°£¬Ð´ÐÅµ½
\onlynameurl{masq-subscribe@indyramp.com}¡£

±êÌâÓëÐÅ¼þÄÚÈÝ½«±»ºöÂÔ¡£Õâ¿ÉÊ¹µÃÄãÊÕµ½À´×ÔÂÛÌ³µÄÃ¿Ò»¸öÑ¶Ï¢¡£
Èç¹ûÄãÐèÒªµÄ»°£¬»¶Ó­ÄãÊ¹ÓÃ´Ë·½Ê½¡£µ«Èç¹û¿ÉÒÔµÄ»°£¬Çë¸ÄÓÃ¾«»ªÇø(digest)¡£
Ê¹ÓÃ¾«»ªÇø¿É¼õÇáËÅ·þÆ÷µÄ¸ºÔØ¡£×¢ÒâÄãÖ»ÄÜÊ¹ÓÃÄãÓÃÀ´¶©ÔÄµÄÕÊºÅ/Î»Ö··¢ËÍÐÅ¼þ¡£

ÏëµÃµ½¸ü¶àÖ¸ÁîµÄËµÃ÷£¬Ð´ÐÅµ½
\onlynameurl{masq-help@tori.indyramp.com}¡£




\subsection{ÎÒÏëÐ­Öú IP Masquerade µÄ·¢Õ¹¡£ÎÒ¸ÃÔõ÷á×ö?}

Ð´ÐÅµ½
\onlynameurl{masq-dev-subscribe@tori.indyramp.com} 
(»òÊÇ¾«»ªÇøÐÎÊ½£¬Ê¹ÓÃ
\onlynameurl{masq-dev-digest-subscribe@tori.indyramp.com})¡£
¼ÓÈë IP Masquerading DEVELOPERS µÄÍ¨ÐÅÂÛÌ³²¢Çë½ÌÄÇ±ßÎ°´óµÄ¿ª·¢Õß¡£

±ðÔÚÄÇ±ßÑ¯ÎÊÓë IP Masquerade ·¢Õ¹ÎÞ¹ØµÄÎÊÌâ!!!!




\subsection{ÔÚÄÇÀï¿ÉÕÒµ½¸ü¶à IP Masquerade µÄ×ÊÑ¶?}

Äã¿ÉÔÚ David ¼°ÎÒÌá¹ýµÄ
\nameurl{http://ipmasq.cjb.net/}{Linux IP Masquerade Resource}
ÕÒµ½¸ü¶à IP Masquerade µÄ×ÊÑ¶¡£²Î¼û 6.2 Ð¡½Ú¡£

ÄãÒ²¿ÉÔÚ Indyramp Consulting Î¬»¤µÄ
\nameurl{http://www.indyramp.com/masq/}{The Semi-Original Linux IP Masquerading Web Site} 
ÕÒµ½¸ü¶à×ÊÑ¶¡£ÕâÒ²ÊÇÌá¹© IP Masquerade Í¨ÐÅÂÛÌ³µÄµØ·½¡£




\subsection{ÎÒÏë·­Òë±¾ÎÄ¼þ³ÉÆäËüÓïÑÔ£¬ÎÒ¸ÃÔõ÷á×ö?}

ÇëÏÈÈ·¶¨ÄãÏë·­ÒëµÄÓïÑÔ»¹Ã»ÓÐÆäËüÈË×ö¹ý¡£
Ò»·Ý¿ÉÈ¡µÃµÄ·­ÒëÎÄ¼þÁÐ±í¿É´Ó
\nameurl{http://ipmasq.cjb.net/}{Linux IP Masquerade Resource}
µÃµ½¡£

Ð´ÐÅ¸øÎÒµ½ \onlynameurl{ambrose@writeme.com},
ÎÒ»á¼Ä×îÐÂ°æµÄ SGML Ô­Ê¼µµ¸øÄã¡£






\subsection{ÕâÎÄ¼þÓÐµã¹ýÊ±ÁË£¬Äã»¹ÓÐÔÚÎ¬»¤Âð?
ÄãÄÜ¼Ó½ø¸ü¶à ... µÄ×ÊÑ¶Âð? ÓÐÈÎºÎ¸ÄÉÆµÄ¼Æ»®Âð?}

ÊÇµÄ£¬±¾ÎÄ¼þÓÐ±»Î¬»¤¡£ÒòÎªÁ½·Ý¹¤×÷Ê¹ÎÒÌ«Ã¦¶øÃ»ÓÐÌ«¶àÊ±¼ä·ÅÔÚÕâ±ßÊ¹ÎÒ¸Ðµ½ÄÚ¾Î£¬ÎÒºÜ±§Ç¸¡£
È»¶ø£¬ÓÐÁË David Ranch ¼ÓÈë±¾ÎÄ¼þµÄÎ¬»¤£¬Çé¿öÓ¦ÓÐ¸ÄÉÆ¡£

Èç¹ûÄã¾õµÃÄ³Ò»Ö÷ÌâÓ¦±»¼Óµ½ÎÄ¼þÖÐ£¬ÇëÐ´ÐÅ¸øÎÒ¼° David¡£
×îºÃÄã¿ÉÒÔÌá¹©¸Ã×ÊÑ¶¡£Èç¹ûºÏÊÊµÄ»°ÎÒ¼° David »á°ÑÕâ×ÊÑ¶¼Óµ½ÎÄ¼þÖÐ¡£·Ç³£¸ÐÐ»ÄãµÄ¹±Ï×¡£

ÎÒÃÇÒ²ÓÐÒ»Ð©ÐÂµÄµã×ÓÓë¼Æ»®À´¸Ä½øÕâ·ÝÎÄ¼þ£¬ÏñÊÇ°üº¬²»Í¬ÍøÂ·Éè¶¨µÄ°¸ÀýÌ½ÌÖ£¬
¸ü¶à¹Øì¶°²È«ÐÔ£¬ipchains µÄÊ¹ÓÃ£¬ipfwadm/ipchains ¹æÔò¡õÀý£¬¸ü¶àµÄ³£¼ûÎÊÌâÓë½â´ð£¬
ÒÔ¼°°üº¬¸ü¶àÐ­¶¨Óë²ººÅ×ªËÍµÄ¹¤¾ßÏñÊÇ {\ttfamily masqadmin} µÈµÈ¡£
Èç¹ûÄã¾õµÃÄã¿ÉÒÔ°ïÃ¦µÄ»°£¬Çë¾¡¹Ü×ö¡£Ð»Ð»¡£




\subsection{ÎÒÖÕì¶ÈÃ IP Masquerade ÄÜ¶¯ÁË£¬ºÃ°ô! ÎÒÏëÐ»Ð»ÄãÃÇ£¬ÎÒ¸ÃÔõ÷á×ö?}

¸ÐÐ»ÕâÐ©·¢Õ¹Õß²¢¸Ð¼¤ËûÃÇËùÍ¶ÈëµÄÊ±¼äÓëÅ¬Á¦¡£Ð´ÐÅ¸øÎÒÃÇ²¢ÈÃÎÒÃÇÖªµÀÄãÓÐ¶à¿ìÀÖ¡£
ÏòÆäËüÈË½éÉÜ Linux ²¢°ïËûÃÇ½â¾öÎÊÌâ¡£






\section{ÆäËü}






\subsection{ÓÐÓÃµÄ×ÊÔ´}

\begin{itemize}
\item \nameurl{http://ipmasq.cjb.net/}{IP Masquerade Resource page}
Ó¦ÓÐ¸ü¶à½¨Á¢ IP Masquerade µÄ×ÊÑ¶¡£\\ 
\item \nameurl{http://www.indyramp.com/masq/list/}{IP masquerade mailing list archive}
°üº¬×î½üËÍµ½Í¨ÐÅÂÛÌ³ÉÏµÄÐÅ¼þ¡£
\item ¸øºËÐÄ 2.2.x Óë 2.0.x µÄ \nameurl{http://ipmasq.cjb.net/ipmasq-HOWTO.html}{Linux IP Masquerade mini HOWTO}¡£
\item Èç¹ûÄãÓÃ¸ü¾ÉµÄºËÐÄ£¬Çë¿´ \nameurl{http://ipmasq.cjb.net/ipmasq-HOWTO-1.2.x.txt}{IP Masquerade HOWTO for kernel 1.2.x}
\item \nameurl{http://www.indyramp.com/masq/ip_masquerade.txt}{IP masquerade FAQ}
ÓÐÄ³Ð©Ò»°ãµÄ×ÊÑ¶¡£
\item \nameurl{http://metalab.unc.edu/mdw/HOWTO/IPCHAINS-HOWTO.html}{Linux IPCHAINS HOWTO} ¼° \onlynameurl{http://www.rustcorp.com/linux/ipchains/}
ÓÐÐí¶à¹Øì¶ ipchains Ê¹ÓÃµÄ×ÊÑ¶£¬²¢ÓÐ ipchains µÄÔ­Ê¼Âë¼°¶þ½øÎ»Ö´ÐÐµµ¡£
\item \nameurl{http://www.xos.nl/linux/ipfwadm/}{X/OS Ipfwadm page} 
°üº¬ {\ttfamily ipfwadm} Ì×¼þµÄÔ­Ê¼Âë£¬Ö´ÐÐµµ£¬ÎÄ¼þ¼°ÆäËüµÄ×ÊÑ¶¡£
\item ÓÉ Lee Nevo ËùÎ¬»¤µÄÍøÒ³ \nameurl{http://dijon.nais.com/~nevo/masq/}{¿ÉÓë Linux IP masquerading ÔË×÷µÄÓ¦ÓÃ³ÌÊ½} 
Ìá¹©ÌáÊ¾Óë¼¼ÇÉÊ¹µÃÓ¦ÓÃ³ÌÊ½ÄÜÓë IP Masquerade ÔË×÷¡£
\item The \nameurl{http://metalab.unc.edu/mdw/LDP/nag/nag.html}{LDP Network Administrator's Guide} 
ÕâÊÇÐÂÊÖ³¢ÊÔÉè¶¨ÍøÂ·µÄ±ØÒª×ÊÑ¶¡£
\item \nameurl{http://www.ecst.csuchico.edu/~dranch/LINUX/TrinityOS.wri}{Trinity OS Doc},
Ò»·Ý¹Øì¶ Linux ÍøÂ·Ïàµ±ÈÝÒ×Àí½âµÄÖ¸Òý¡£
\item \nameurl{http://metalab.unc.edu/mdw/HOWTO/NET-3-HOWTO.html}{Linux NET-3 HOWTO}
Ò²ÓÐÐí¶à¹Øì¶ Linux ÍøÂ··½ÃæÓÐÓÃµÄ×ÊÑ¶¡£
\item \nameurl{http://metalab.unc.edu/mdw/HOWTO/ISP-Hookup-HOWTO.html}{Linux ISP Hookup HOWTO} ÒÔ¼°
\nameurl{http://metalab.unc.edu/mdw/HOWTO/PPP-HOWTO.html}{Linux PPP HOWTO}
¸øÄãÈçºÎ°Ñ Linux Ö÷»úÁ¬ÉÏÍø¼ÊÍøÂ·µÄÏà¹Ø×ÊÑ¶¡£
\item \nameurl{http://metalab.unc.edu/mdw/HOWTO/Ethernet-HOWTO.html}{Linux Ethernet-Howto}
ÓÐ¹ØÉè¶¨Ö´ÐÐÒÒÌ«ÍøÂ·µÄÇøÓòÍøÂ·ºÜ°ôµÄ×ÊÑ¶À´Ô´¡£
\item ÄãÒ²¿ÉÄÜ¶Ô \nameurl{http://metalab.unc.edu/mdw/HOWTO/Firewall-HOWTO.html}{Linux Firewalling and Proxy Server HOWTO} ÓÐÐËÈ¤¡£
\item \nameurl{http://metalab.unc.edu/mdw/HOWTO/Kernel-HOWTO.html}{Linux Kernel HOWTO}
½«»áÖ¸ÒýÄã±àÒëºËÐÄµÄ¹ý³Ì¡£
\item ÆäËüµÄ \nameurl{http://metalab.unc.edu/mdw/HOWTO/HOWTO-INDEX-3.html}{Linux HOWTOs}
ÏñÊÇ Kernel HOWTO¡£
\item ÕÅÌùµ½Õâ¸ö USENET ÐÂÎÅÈº×é: \onlynameurl{comp.os.linux.networking}
\end{itemize}





\subsection{Linux IP Masquerade ×ÊÔ´}

\nameurl{http://ipmasq.cjb.net/}{Linux IP Masquerade Resource}
ÊÇÒ»×¨ÃÅÓÃÀ´Ìá¹© Linux IP Masquerade ×ÊÑ¶µÄÕ¾Ì¨£¬Ò²ÊÇÓÉ David Ranch ¼°ÎÒÀ´Î¬»¤¡£
Õâ±ßÓÐ¹Øì¶ IP Masquerade ×îÐÂµÄ×ÊÑ¶£¬¿ÉÄÜÒ²ÓÐÎ´°üº¬ÔÚ±¾ÎÄ¼þµÄÆäËü×ÊÑ¶¡£

Äã¿ÉÔÚÏÂÁÐµØµãÕÒµ½ Linux IP Masquerade Resource:
\begin{itemize}
\item \onlynameurl{http://ipmasq.cjb.net/},
Ö÷Õ¾Ì¨£¬ÖØµ¼ÖÁ \onlynameurl{http://www.tor.shaw.wave.ca/\~{}ambrose/}
\item \onlynameurl{http://ipmasq2.cjb.net/}, 
µÚ¶þ·ÖÕ¾, ÖØµ¼ÖÁ
\onlynameurl{http://www.geocities.com/SiliconValley/Heights/2288/}
\end{itemize}







\subsection{¸ÐÐ»}

\begin{itemize}
\item  David Ranch, dranch@trinnet.net\\ 
 Ð­ÖúÎ¬»¤±¾ÎÄ¼þ¼° Linux IP Masquerade ×ÊÔ´ÍøÒ³, ..., ×å·±²»¼°±¸ÔØ :-)
\item  Michael Owings, mikey@swampgas.com\\ 
 Ìá¹©¹Øì¶ CU-SeeMe µÄ¼ò¶ÌËµÃ÷ÎÄ¼þ¡£
\item  Gabriel Beitler, gbeitler@aciscorp.com\\ 
 on providing section 3.3.8 (setting up Novel)
\item Ed Doolittle, dolittle@math.toronto.edu \\ 
 ½¨ÒéÔÚ {\ttfamily ipfwadm} ¼ÓÉÏ {\ttfamily -V} Ñ¡ÏîÒÔÔö¼Ó°²È«ÐÔ¡£
\item Matthew Driver, mdriver@cfmeu.asn.au\\ 
on helping extensively on this HOWTO, and providing section 3.3.1 (setting up Windows 95)
\item Ken Eves, ken@eves.com\\ 
on the FAQ that provides invaluable information for this HOWTO 
\item Ed. Lott, edlott@neosoft.com\\ 
for a long list of tested system and software
\item Nigel Metheringham, Nigel.Metheringham@theplanet.net\\ 
on contributing his version of IP Packet Filtering and IP Masquerading HOWTO, which make this HOWTO a better and technical in-depth document\\ 
section 4.1, 4.2, and others
\item Keith Owens, kaos@ocs.com.au\\ 
on providing an excellent guide on ipfwadm section 4.2\\ 
on correction to {\ttfamily ipfwadm -deny} option which avoids a security hole, and clarified the status of {\ttfamily ping} over IP Masquerade 
\item Rob Pelkey, rpelkey@abacus.bates.edu\\ 
on providing section 3.3.6 and 3.3.7 (setting up MacTCP and Open Transport)
\item Harish Pillay, h.pillay@ieee.org \\ 
on providing section 4.5 (dial-on-demand using diald)
\item Mark Purcell, purcell@rmcs.cranfield.ac.uk\\ 
on providing section 4.6 (IPautofw)
\item Ueli Rutishauser, rutish@ibm.net\\ 
on providing section 3.3.9 (setting up OS/2 Warp)
\item John B. (Brent) Williams, forerunner@mercury.net\\ 
on providing section 3.3.7 (setting up Open Transport)
\item Enrique Pessoa Xavier, enrique@labma.ufrj.br\\ 
on the bootp setup suggestion
\item developers of IP Masquerade for this great feature
\begin{quotation}
\begin{itemize}
\item Delian Delchev, delian@wfpa.acad.bg
\item Nigel Metheringham, Nigel.Metheringham@theplanet.net 
\item Keith Owens, kaos@ocs.com.au 
\item Jeanette Pauline Middelink, middelin@polyware.iaf.nl 
\item David A. Ranch, trinity@value.net
\item Miquel van Smoorenburg, miquels@q.cistron.nl
\item Jos Vos, jos@xos.nl
\item Paul Russell, Paul.Russell@rustcorp.com.au
\item »¹ÓÐÆäËüÎÒÍüÁËÌáµÄ(ÇëÈÃÎÒÖªµÀ)
\end{itemize}
\end{quotation}

\item ËùÓÐËÍ»ØÀ¡¼°½¨Òéµ½Í¨ÐÅÂÛÌ³ÉÏµÄÊ¹ÓÃÕß£¬ÌØ±ðÊÇÄÇÐ©±¨¸æÎÄ¼þÉÏµÄ´íÎóÒÔ¼°ÒÑÖ§Ô®ÓëÎ´Ö§Ô®µÄ¿Í»§¶ËµÄ¡£
\item Èç¹ûÎÒÃ»ÓÐ°üÀ¨Ä³Ð©Ê¹ÓÃÕßËÍ¸øÎÒµÄ×ÊÑ¶ÎÒ¸Ðµ½±§Ç¸¡£ÓÐÈç´Ë¶àµÄ½¨ÒéÓëÏë·¨ËÍµ½ÎÒÕâÀï£¬µ«ÎÒÖ»ÊÇÃ»ÓÐ×ã¹»µÄÊ±¼äÈ¥È·¶¨»òÕßÎÒ²»Ð¡ÐÄ¶ªÁË¡£
ÎÒÕý¾¡ÎÒ×î´óµÄÅ¬Á¦ÕûºÏËùÓÐËÍ¸øÎÒµÄ×ÊÑ¶µ½Õâ·ÝÎÄ¼þÀï¡£¸ÐÐ»ÄãµÄÐÁÀÍ£¬¶øÎÒÒ²Ï£ÍûÄãÄÜÌåÁÂÎÒµÄÇé¿ö¡£
\end{itemize}







\subsection{²Î¿¼×ÊÁÏ}

\begin{itemize}
\item Ken Eves µÄ IP masquerade ³£¼ûÎÊ´ð¼¯
\item Indyramp Consulting Ö® IP masquerade Í¨ÐÅÂÛÌ³
\item X/OS µÄ Ipfwadm  ÍøÒ³
\item ¸÷¸ö¹Øì¶ÍøÂ·µÄ Linux HOWTOs
\end{itemize}






\end{document}
