{"id":151,"date":"2018-07-29T08:33:53","date_gmt":"2018-07-29T00:33:53","guid":{"rendered":"https:\/\/pfsense.freeddns.org\/wp\/?p=151"},"modified":"2020-09-01T14:35:00","modified_gmt":"2020-09-01T06:35:00","slug":"pfsense-book%e4%b9%8b%e7%bd%91%e7%bb%9c%e6%a6%82%e5%bf%b5","status":"publish","type":"post","link":"https:\/\/blog.pfchina.org\/?p=151","title":{"rendered":"pfSense book\u4e4b\u7f51\u7edc\u6982\u5ff5"},"content":{"rendered":"<p style=\"text-align: justify;\">\u672c\u4e66\u4e0d\u662f\u5bf9\u7f51\u7edc\u7684\u4ecb\u7ecd\uff0c\u4f46\u4e00\u4e9b\u7f51\u7edc\u6982\u5ff5\u9700\u8981\u7406\u89e3\u3002 \u5bf9\u4e8e\u6ca1\u6709\u7f51\u7edc\u57fa\u7840\u77e5\u8bc6\u7684\u8bfb\u8005\uff0c\u6211\u4eec\u5efa\u8bae\u9605\u8bfb\u5176\u4ed6\u5165\u95e8\u8d44\u6599\uff0c\u56e0\u4e3a\u672c\u7ae0\u4e0d\u4f1a\u63d0\u4f9b\u6240\u6709\u5fc5\u8981\u7684\u4fe1\u606f\u3002 IPv6\u6982\u5ff5\u5c06\u5728\u672c\u7ae0\u540e\u9762\u7684IPv6\u4e2d\u4ecb\u7ecd\u3002 \u4e3a\u4e86\u6e05\u695a\u8d77\u89c1\uff0c\u4f20\u7edf\u7684IP\u5730\u5740\u88ab\u79f0\u4e3aIPv4\u5730\u5740\u3002 \u9664\u53e6\u6709\u8bf4\u660e\u5916\uff0c\u5927\u591a\u6570\u529f\u80fd\u90fd\u53ef\u4ee5\u4f7f\u7528IPv4\u6216IPv6\u5730\u5740\u3002 \u901a\u7528\u672f\u8bedIP\u5730\u5740\u662f\u6307IPv4\u6216IPv6\u3002<\/p>\n<h1 style=\"text-align: justify;\"><strong>OSI\u6a21\u578b\u5c42\u4ecb\u7ecd<\/strong><\/h1>\n<p style=\"text-align: justify;\">OSI\u6a21\u578b\u662f\u7531\u4e03\u4e2a\u5c42\u7ea7\u7ec4\u6210\u7684\u7f51\u7edc\u6846\u67b6\u3002\u8fd9\u4e9b\u5c42\u7ea7\u6309\u4ece\u4f4e\u5230\u9ad8\u7684\u5c42\u6b21\u7ed3\u6784\u5217\u51fa\u3002<\/p>\n<ul style=\"text-align: justify;\">\n<li><span style=\"font-weight: bold;\">\u7b2c1\u5c42-\u7269\u7406\u5c42\uff1a<\/span>\u5728\u5c40\u57df\u7f51\u4e0a\u4f20\u9001\u6570\u636e\u5e27(data frame)\uff0c\u5b83\u8d1f\u8d23\u7ba1\u7406\u8ba1\u7b97\u673a\u901a\u4fe1\u8bbe\u5907\u548c\u7f51\u7edc\u5a92\u4f53\u4e4b\u95f4\u7684\u4e92\u901a\u3002\u5305\u62ec\u4e86\u9488\u811a\u3001\u7535\u538b\u3001\u7ebf\u7f06\u89c4\u8303\u3001\u96c6\u7ebf\u5668\u3001\u4e2d\u7ee7\u5668\u3001\u7f51\u5361\u3001\u4e3b\u673a\u9002\u914d\u5668\u7b49\u3002<\/li>\n<li><span style=\"font-weight: bold;\"><span style=\"font-weight: bold;\">\u7b2c2\u5c42-\u6570\u636e\u94fe\u8def\u5c42\uff1a<\/span><\/span>\u8d1f\u8d23\u7f51\u7edc\u5bfb\u5740\u3001\u9519\u8bef\u4fa6\u6d4b\u548c\u6539\u9519\u3002\u5f53\u8868\u5934\u548c\u8868\u5c3e\u88ab\u52a0\u81f3\u6570\u636e\u5305\u65f6\uff0c\u4f1a\u5f62\u6210\u5e27\u3002\u6570\u636e\u94fe\u8868\u5934(DLH)\u662f\u5305\u542b\u4e86\u7269\u7406\u5730\u5740\u548c\u9519\u8bef\u4fa6\u6d4b\u53ca\u6539\u9519\u7684\u65b9\u6cd5\u3002\u6570\u636e\u94fe\u8868\u5c3e(DLT)\u662f\u4e00\u4e32\u6307\u793a\u6570\u636e\u5305\u672b\u7aef\u7684\u5b57\u7b26\u4e32\u3002\u4f8b\u5982\u4ee5\u592a\u7f51\u3001\u65e0\u7ebf\u5c40\u57df\u7f51(Wi-Fi)\u548c\u901a\u7528\u5206\u7ec4\u65e0\u7ebf\u670d\u52a1(GPRS)\u7b49\u3002\u5206\u4e3a\u4e24\u4e2a\u5b50\u5c42\uff1a\u903b\u8f91\u94fe\u8def\u63a7\u5236(logic link control\uff0cLLC)\u5b50\u5c42\u548c\u4ecb\u8d28\u8bbf\u95ee\u63a7\u5236(media access control\uff0cMAC)\u5b50\u5c42\u3002<\/li>\n<li><span style=\"font-weight: bold;\">\u7b2c3\u5c42-\u7f51\u7edc\u5c42\uff1a<\/span>\u51b3\u5b9a\u6570\u636e\u7684\u8def\u5f84\u9009\u62e9\u548c\u8f6c\u5bc4\uff0c\u5c06\u7f51\u7edc\u8868\u5934(NH)\u52a0\u81f3\u6570\u636e\u5305\uff0c\u4ee5\u5f62\u6210\u5206\u7ec4\u3002\u7f51\u7edc\u8868\u5934\u5305\u542b\u4e86\u7f51\u7edc\u6570\u636e\u3002\u4f8b\u5982:\u4e92\u8054\u7f51\u534f\u8bae(IP)\u7b49\u3002<\/li>\n<li><span style=\"font-weight: bold;\">\u7b2c4\u5c42-\u4f20\u8f93\u5c42\uff1a<\/span>\u628a\u4f20\u8f93\u8868\u5934(TH)\u52a0\u81f3\u6570\u636e\u4ee5\u5f62\u6210\u6570\u636e\u5305\u3002\u4f20\u8f93\u8868\u5934\u5305\u542b\u4e86\u6240\u4f7f\u7528\u7684\u534f\u8bae\u7b49\u53d1\u9001\u4fe1\u606f\u3002\u4f8b\u5982:\u4f20\u8f93\u63a7\u5236\u534f\u8bae(TCP)\u7b49\u3002<\/li>\n<li><span style=\"font-weight: bold;\">\u7b2c5\u5c42-\u4f1a\u8bdd\u5c42\uff1a<\/span>\u8d1f\u8d23\u5728\u6570\u636e\u4f20\u8f93\u4e2d\u8bbe\u7f6e\u548c\u7ef4\u62a4\u8ba1\u7b97\u673a\u7f51\u7edc\u4e2d\u4e24\u53f0\u8ba1\u7b97\u673a\u4e4b\u95f4\u7684\u901a\u4fe1\u8fde\u63a5\u3002<\/li>\n<li><span style=\"font-weight: bold;\">\u7b2c6\u5c42-\u8868\u793a\u5c42\uff1a<\/span>\u628a\u6570\u636e\u8f6c\u6362\u4e3a\u80fd\u4e0e\u63a5\u6536\u8005\u7684\u7cfb\u7edf\u683c\u5f0f\u517c\u5bb9\u5e76\u9002\u5408\u4f20\u8f93\u7684\u683c\u5f0f\u3002<\/li>\n<li><span style=\"font-weight: bold;\">\u7b2c7\u5c42-\u5e94\u7528\u5c42\uff1a<\/span>\u63d0\u4f9b\u4e3a\u5e94\u7528\u8f6f\u4ef6\u800c\u8bbe\u7684\u63a5\u53e3\uff0c\u4ee5\u8bbe\u7f6e\u4e0e\u53e6\u4e00\u5e94\u7528\u8f6f\u4ef6\u4e4b\u95f4\u7684\u901a\u4fe1\u3002\u4f8b\u5982: HTTP\uff0cHTTPS\uff0cFTP\uff0cTELNET\uff0cSSH\uff0cSMTP\uff0cPOP3\u7b49\u3002<\/li>\n<\/ul>\n<h1 style=\"text-align: justify;\"><span style=\"color: #000000; font-weight: bold;\">\u516c\u5171\u548c\u79c1\u6709IP\u5730\u5740<\/span><\/h1>\n<h2 style=\"text-align: justify;\">\u79c1\u6709IP\u5730\u5740<\/h2>\n<p style=\"text-align: justify;\">\u7f51\u7edc\u6807\u51c6RFC 1918\u5b9a\u4e49\u4e86\u4fdd\u7559\u7684IPv4\u5b50\u7f51\uff0c\u4ec5\u7528\u4e8e\u79c1\u6709\u7f51\u7edc(\u8868RFC 1918\u79c1\u6709IP\u5730\u5740\u7a7a\u95f4)\u3002 RFC 4193\u4e3aIPv6(\u8868RFC 4193\u552f\u4e00\u672c\u5730\u5730\u5740\u7a7a\u95f4)\u5b9a\u4e49\u4e86\u552f\u4e00\u7684\u672c\u5730\u5730\u5740(ULA)\u3002 \u5728\u5927\u591a\u6570\u73af\u5883\u4e2d\uff0cRFC 1918\u7684\u79c1\u6709IP\u5b50\u7f51\u88ab\u9009\u62e9\u5e76\u7528\u4e8e\u6240\u6709\u5185\u90e8\u7f51\u7edc\u8bbe\u5907\u3002 \u7136\u540e\u901a\u8fc7\u7f51\u7edc\u5730\u5740\u8f6c\u6362(NAT)\u8f6f\u4ef6(\u5982pfSense)\u7684\u9632\u706b\u5899\u6216\u8def\u7531\u5668\u5c06\u8bbe\u5907\u8fde\u63a5\u5230Internet\u3002 IPv6\u901a\u8fc7\u5168\u7403\u5355\u64ad\u5730\u5740\uff08GUA\uff09\u4ece\u5185\u90e8\u7f51\u7edc\u5b8c\u5168\u8def\u7531\u800c\u65e0\u9700NAT\u3002<\/p>\n<table id=\"id1\" class=\"docutils\">\n<caption><span class=\"caption-text\">RFC 1918 \u79c1\u6709IP\u5730\u5740\u7a7a\u95f4<\/span><\/caption>\n<colgroup>\n<col width=\"33%\" \/>\n<col width=\"67%\" \/><\/colgroup>\n<thead valign=\"bottom\">\n<tr class=\"row-odd\">\n<th class=\"head\">CIDR\u00a0\u8303\u56f4<\/th>\n<th class=\"head\">IP\u00a0\u5730\u5740\u8303\u56f4<\/th>\n<\/tr>\n<\/thead>\n<tbody valign=\"top\">\n<tr class=\"row-even\">\n<td>10.0.0.0\/8<\/td>\n<td>10.0.0.0 &#8211; 10.255.255.255<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>172.16.0.0\/12<\/td>\n<td>172.16.0.0 &#8211; 172.31.255.255<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>192.168.0.0\/16<\/td>\n<td>192.168.0.0 &#8211; 192.168.255.255<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<table id=\"id2\" class=\"docutils\">\n<caption><span class=\"caption-text\">RFC 4193\u552f\u4e00\u672c\u5730\u5730\u5740\u7a7a\u95f4<\/span><\/caption>\n<colgroup>\n<col width=\"14%\" \/>\n<col width=\"86%\" \/><\/colgroup>\n<thead valign=\"bottom\">\n<tr class=\"row-odd\">\n<th class=\"head\">\u524d\u7f00<\/th>\n<th class=\"head\">IP\u00a0\u5730\u5740\u8303\u56f4<\/th>\n<\/tr>\n<\/thead>\n<tbody valign=\"top\">\n<tr class=\"row-even\">\n<td>fc00::\/7<\/td>\n<td>fc00:: &#8211; fdff:ffff:ffff:ffff:ffff:ffff:ffff:ffff<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"text-align: justify;\">\u7279\u6b8a\u7528\u9014IPv4\u7f51\u7edc\u7684\u5b8c\u6574\u5217\u8868\u53ef\u4ee5\u5728RFC 3330\u4e2d\u627e\u5230\u3002\u6709\u4e00\u4e9b\u79c1\u6709IPv4\u5730\u5740\uff0c\u4f8b\u59821.0.0.0\/8\u548c2.0.0.0\/8\uff0c\u8fd9\u4e9bIPv4\u5730\u5740\u5df2\u7ecf\u5206\u914d\u7ed9\u65e5\u76ca\u7f29\u5c0f\u7684IPv4\u6c60\u3002 \u4f7f\u7528\u8fd9\u4e9b\u5730\u5740\u6709\u95ee\u9898\u4e0d\u5efa\u8bae\u4f7f\u7528\u3002 \u6b64\u5916\u907f\u514d\u4f7f\u7528169.254.0.0\/16\uff0c\u6839\u636eRFC 3927\u4fdd\u7559\u201cLink-Local\u201d\u4e3a\u81ea\u52a8\u914d\u7f6e\uff0c\u5b83\u4e0d\u5e94\u8be5\u7531DHCP\u5206\u914d\u6216\u624b\u52a8\u8bbe\u7f6e\uff0c\u5e76\u4e14\u8def\u7531\u5668\u5c06\u4e0d\u5141\u8bb8\u6765\u81ea\u8be5\u5b50\u7f51\u7684\u6570\u636e\u5305\u5728\u7279\u5b9a\u7684\u5e7f\u64ad\u57df\u5916\u4f20\u64ad\u3002 RFC 1918\u6709\u8db3\u591f\u7684\u5730\u5740\u7a7a\u95f4\uff0c\u6240\u4ee5\u4e0d\u9700\u8981\u7a81\u7834RFC 1918\u79c1\u6709IP\u5730\u5740\u7a7a\u95f4\u4e2d\u7684\u5730\u5740\u8303\u56f4\u3002 \u9519\u8bef\u7684\u5bfb\u5740\u5c06\u5bfc\u81f4\u7f51\u7edc\u6545\u969c\uff0c\u5e94\u4e88\u4ee5\u7ea0\u6b63\u3002<\/p>\n<h2 style=\"text-align: justify;\">\u516c\u5171 IP\u5730\u5740<\/h2>\n<p style=\"text-align: justify;\">\u9664\u6700\u5927\u7684\u7f51\u7edc\u5916\uff0c\u516c\u5171IP\u5730\u5740\u7531\u4e92\u8054\u7f51\u670d\u52a1\u63d0\u4f9b\u5546\u5206\u914d\u3002\u9700\u8981\u6570\u767e\u6216\u6570\u5343\u4e2a\u516c\u5171IP\u5730\u5740\u7684\u7f51\u7edc\u901a\u5e38\u5177\u6709\u76f4\u63a5\u4ece\u5176\u5730\u533a\u4e92\u8054\u7f51\u6ce8\u518c\u673a\u6784(RIR)\u5206\u914d\u7684\u5730\u5740\u7a7a\u95f4\u3002 RIR\u662f\u4e00\u4e2a\u76d1\u7763\u5728\u4e16\u754c\u6307\u5b9a\u5730\u533a\u5206\u914d\u548c\u6ce8\u518c\u516c\u5171IP\u5730\u5740\u7684\u7ec4\u7ec7\u3002<\/p>\n<p style=\"text-align: justify;\">\u5927\u591a\u6570\u4f4f\u5b85\u4e92\u8054\u7f51\u8fde\u63a5\u88ab\u5206\u914d\u4e00\u4e2a\u516c\u5171IPv4\u5730\u5740\u3002\u5927\u591a\u6570\u4e1a\u52a1\u7c7b\u8fde\u63a5\u88ab\u5206\u914d\u591a\u4e2a\u516c\u5171IP\u5730\u5740\u3002\u4e00\u822c\u60c5\u51b5\u4e0b\uff0c\u5355\u4e2a\u516c\u5171IP\u5730\u5740\u5c31\u8db3\u591f\u4e86\uff0c\u53ef\u4ee5\u914d\u5408\u4e0eNAT\u4e00\u8d77\u4f7f\u7528\uff0c\u5c06\u6570\u767e\u4e2a\u79c1\u6709\u5730\u5740\u7cfb\u7edf\u8fde\u63a5\u5230Internet\u3002\u8fd9\u672c\u4e66\u5c06\u5e2e\u52a9\u786e\u5b9a\u6240\u9700\u7684\u516c\u5171IP\u5730\u5740\u7684\u6570\u91cf\u3002<\/p>\n<p style=\"text-align: justify;\">\u5927\u591a\u6570IPv6\u90e8\u7f72\u90fd\u4f1a\u4e3a\u6700\u7ec8\u7528\u6237\u63d0\u4f9b\u81f3\u5c11\u4e00\u4e2a\/64\u524d\u7f00\u7f51\u7edc\uff0c\u4ee5\u7528\u4f5c\u8def\u7531\u5185\u90e8\u7f51\u7edc\u3002\u5bf9\u4e8e\u6bcf\u4e2a\u7ad9\u70b9\uff0c\u8fd9\u5927\u7ea6\u662f2\u00a0<sup>64\u4e2a<\/sup> IPv6\u5730\u5740(\u537318\u4ebf\u4e2a\u5730\u5740)\uff0c\u5b8c\u5168\u4eceInternet\u8def\u7531\u800c\u65e0\u9700NAT\u3002<\/p>\n<h2 style=\"text-align: justify;\">\u4fdd\u7559\u548c\u6587\u6863\u5730\u5740<\/h2>\n<p style=\"text-align: justify;\">\u9664\u4e86\u5728RFC 1918\u4e2d\u5b9a\u4e49\u7684\u8303\u56f4\u4e4b\u5916\uff0cRFC 5735\u8fd8\u63cf\u8ff0\u4e86\u4e3a\u5176\u4ed6\u7279\u6b8a\u7528\u9014(\u5982\u6587\u6863\uff0c\u6d4b\u8bd5\u548c\u57fa\u51c6\u6d4b\u8bd5)\u4fdd\u7559\u7684IP\u8303\u56f4\u3002 RFC 6598\u66f4\u65b0\u4e86RFC 5735\uff0c\u5e76\u4e3a\u8fd0\u8425\u5546\u7ea7NAT\u5b9a\u4e49\u4e86\u5730\u5740\u7a7a\u95f4\u3002 \u8fd9\u4e9b\u7279\u6b8a\u7684\u7f51\u7edc\u5305\u62ec\uff1a<\/p>\n<table id=\"id3\" class=\"docutils\">\n<caption><span class=\"caption-text\">RFC 5735 \u4fdd\u7559\u5730\u5740\u7a7a\u95f4<\/span><\/caption>\n<colgroup>\n<col width=\"33%\" \/>\n<col width=\"67%\" \/><\/colgroup>\n<thead valign=\"bottom\">\n<tr class=\"row-odd\">\n<th class=\"head\">CIDR\u00a0\u8303\u56f4<\/th>\n<th class=\"head\">\u76ee\u7684<\/th>\n<\/tr>\n<\/thead>\n<tbody valign=\"top\">\n<tr class=\"row-even\">\n<td>192.0.2.0\/24<\/td>\n<td>\u6587\u6863\u548c\u793a\u4f8b\u4ee3\u7801<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>198.51.100.0\/24<\/td>\n<td>\u6587\u6863\u548c\u793a\u4f8b\u4ee3\u7801<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>203.0.113.0\/24<\/td>\n<td>\u6587\u6863\u548c\u793a\u4f8b\u4ee3\u7801<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>198.18.0.0\/25<\/td>\n<td>\u5bf9\u7f51\u7edc\u8bbe\u5907\u8fdb\u884c\u57fa\u51c6\u6d4b\u8bd5<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>100.64.0.0\/10<\/td>\n<td>\u7535\u4fe1\u7ea7NAT\u7a7a\u95f4<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"text-align: justify;\">\u5728\u672c\u4e66\u4e2d\uff0c\u793a\u4f8b\u6240\u4f7f\u7528\u7684\u5730\u5740\u6765\u81ea\u4e0a\u8ff0\u6587\u6863\u8303\u56f4\u4ee5\u53caRFC 1918\u7f51\u7edc\uff0c\u5b83\u4eec\u5bf9\u4e8e\u4e00\u822c\u7528\u6237\u6765\u8bf4\u66f4\u52a0\u719f\u6089\u3002<\/p>\n<p style=\"text-align: justify;\">\u6709\u4e9b\u4eba\u53d1\u73b0\u8fd9\u4e9b\u5730\u5740\u5f88\u60f3\u7528\u4e8eVPN\u751a\u81f3\u5c40\u57df\u7f51\u3002\u6211\u4eec\u4e0d\u5efa\u8bae\u5c06\u5b83\u4eec\u7528\u4e8e\u5176\u4ed6\u7528\u9014\uff0c\u4f46\u662f\u4e0eRFC 1918\u7f51\u7edc\u76f8\u6bd4\uff0c\u5b83\u4eec\u5728\u201c\u91ce\u5916\u201d\u51fa\u73b0\u7684\u53ef\u80fd\u6027\u8981\u5c0f\u5f97\u591a\u3002<\/p>\n<h1 style=\"text-align: justify;\">IP\u5b50\u7f51\u5212\u5206\u6982\u5ff5<\/h1>\n<p style=\"text-align: justify;\">\u5728\u8bbe\u5907\u4e0a\u914d\u7f6eTCP\/IP\u8bbe\u7f6e\u65f6\uff0c\u5fc5\u987b\u6307\u5b9a\u5b50\u7f51\u63a9\u7801(\u6216IPv6\u7684\u524d\u7f00\u957f\u5ea6)\u3002 \u6b64\u63a9\u7801\u4f7f\u8bbe\u5907\u80fd\u591f\u786e\u5b9a\u672c\u5730\u7f51\u7edc\u4e0a\u7684\u54ea\u4e9bIP\u5730\u5740\uff0c\u4ee5\u53ca\u8bbe\u5907\u8def\u7531\u8868\u4e2d\u7684\u7f51\u5173\u5fc5\u987b\u5230\u8fbe\u54ea\u4e9bIP\u5730\u5740\u3002\u9ed8\u8ba4LAN IP\u5730\u5740\u4e3a192.168.1.1\uff0c\u63a9\u7801\u4e3a255.255.255.0\uff0c\u6216CIDR\u8868\u793a\u6cd5\u4e2d\u7684\/ 24\uff0c\u5176\u7f51\u7edc\u5730\u5740\u4e3a192.168.1.0\/24\u3002\u5728<span class=\"doc\">CIDR\u5b50\u7f51\u63a9\u7801\u8868\u793a\u6cd5\u4e2d<\/span>\u8ba8\u8bba\u4e86\u00a0<span class=\"doc\">CIDR<\/span>\u3002<\/p>\n<h1 style=\"text-align: justify;\">IP\u5730\u5740\uff0c\u5b50\u7f51\u548c\u7f51\u5173\u914d\u7f6e<\/h1>\n<p style=\"text-align: justify;\">\u4e3b\u673a\u7684TCP\/IP\u914d\u7f6e\u7531\u5730\u5740\u3001\u5b50\u7f51\u63a9\u7801(\u6216IPv6\u7684\u524d\u7f00\u957f\u5ea6)\u548c\u7f51\u5173\u7ec4\u6210\u3002 IP\u5730\u5740\u4e0e\u5b50\u7f51\u63a9\u7801\u7684\u7ed3\u5408\u662f\u4e3b\u673a\u5982\u4f55\u8bc6\u522b\u672c\u5730\u7f51\u7edc\u4e0a\u7684\u54ea\u4e9bIP\u5730\u5740\u3002\u672c\u5730\u7f51\u7edc\u4ee5\u5916\u7684\u5730\u5740\u88ab\u53d1\u9001\u5230\u4e3b\u673a\u914d\u7f6e\u7684\u9ed8\u8ba4\u7f51\u5173\uff0c\u5b83\u5047\u5b9a\u5c06\u628a\u6d41\u91cf\u4f20\u9012\u5230\u6240\u9700\u7684\u76ee\u7684\u5730\u3002\u8be5\u89c4\u5219\u7684\u4e00\u4e2a\u4f8b\u5916\u662f\u9759\u6001\u8def\u7531\uff0c\u8be5\u8def\u7531\u6307\u793a\u8bbe\u5907\u8054\u7cfb\u53ef\u901a\u8fc7\u672c\u5730\u8fde\u63a5\u7684\u8def\u7531\u5668\u8bbf\u95ee\u7684\u7279\u5b9a\u975e\u672c\u5730\u5b50\u7f51\u3002\u7f51\u5173\u548c\u9759\u6001\u8def\u7531\u7684\u6b64\u5217\u8868\u4fdd\u7559\u5728\u6bcf\u4e2a\u4e3b\u673a\u7684\u8def\u7531\u8868\u4e2d\u3002<\/p>\n<p style=\"text-align: justify;\">\u5728\u5178\u578b\u7684pfSense\u90e8\u7f72\u4e2d\uff0c\u4e3b\u673a\u4f1a\u5728pfSense\u8bbe\u5907\u7684LAN\u8303\u56f4\u5185\u5206\u914d\u4e00\u4e2aIP\u5730\u5740\u3001\u5b50\u7f51\u63a9\u7801\u548c\u7f51\u5173\u3002 pfSense\u4e0a\u7684LAN IP\u5730\u5740\u6210\u4e3a\u9ed8\u8ba4\u7f51\u5173\u3002\u5bf9\u4e8e\u901a\u8fc7LAN\u4ee5\u5916\u7684\u63a5\u53e3\u8fde\u63a5\u7684\u4e3b\u673a\uff0c\u8bf7\u4f7f\u7528\u9002\u7528\u4e8e\u8bbe\u5907\u8fde\u63a5\u7684\u63a5\u53e3\u7684\u76f8\u5e94\u914d\u7f6e\u3002<\/p>\n<p style=\"text-align: justify;\">\u5355\u4e2a\u7f51\u7edc\u4e2d\u7684\u4e3b\u673a\u76f4\u63a5\u76f8\u4e92\u901a\u4fe1\uff0c\u800c\u65e0\u9700\u9ed8\u8ba4\u7f51\u5173\u7684\u53c2\u4e0e\u3002\u8fd9\u610f\u5473\u7740\u6ca1\u6709\u9632\u706b\u5899(\u5305\u62ecpfSense)\u53ef\u4ee5\u63a7\u5236\u7f51\u6bb5\u5185\u4e3b\u673a\u5230\u4e3b\u673a\u7684\u901a\u4fe1\u3002\u5982\u679c\u9700\u8981\u6b64\u529f\u80fd\uff0c\u5219\u9700\u8981\u901a\u8fc7\u4f7f\u7528\u591a\u4e2a\u4ea4\u6362\u673a\uff0cVLAN\u6216\u91c7\u7528\u7b49\u6548\u7684\u4ea4\u6362\u673a\u529f\u80fd(\u4f8b\u5982PVLAN)\u6765\u5bf9\u4e3b\u673a\u8fdb\u884c\u5206\u6bb5\u3002<\/p>\n<h1 style=\"text-align: justify;\">CIDR\u5b50\u7f51\u63a9\u7801\u8868\u793a\u6cd5<\/h1>\n<p style=\"text-align: justify;\">\u5728\u914d\u7f6e\u5730\u5740\u548c\u7f51\u7edc\u65f6\uff0cpfSense\u4f7f\u7528CIDR(Classless Inter-Domain Routing\uff0c\u4e5f\u53eb\u65e0\u7c7b\u57df\u95f4\u8def\u7531\uff0c\u5b83\u6d88\u9664\u4e86\u4f20\u7edf\u7684A\u7c7b\u3001B\u7c7b\u548cC\u7c7b\u5730\u5740\u4ee5\u53ca\u5212\u5206\u5b50\u7f51\u7684\u6982\u5ff5\uff0c\u56e0\u800c\u53ef\u4ee5\u66f4\u52a0\u6709\u6548\u5730\u5206\u914dIPv4\u7684\u5730\u5740\u7a7a\u95f4\u3002\u5b83\u53ef\u4ee5\u5c06\u597d\u51e0\u4e2aIP\u7f51\u7edc\u7ed3\u5408\u5728\u4e00\u8d77\uff0c\u4f7f\u7528\u4e00\u79cd\u65e0\u7c7b\u7684\u57df\u95f4\u8def\u7531\u9009\u62e9\u7b97\u6cd5\uff0c\u4f7f\u5b83\u4eec\u5408\u5e76\u6210\u4e00\u6761\u8def\u7531\u4ece\u800c\u51cf\u5c11\u8def\u7531\u8868\u4e2d\u7684\u8def\u7531\u6761\u76ee\uff0c\u51cf\u8f7bInternet\u8def\u7531\u5668\u7684\u8d1f\u62c5\u3002)\u8868\u793a\u6cd5\uff0c\u800c\u4e0d\u662f\u901a\u7528\u5b50\u7f51\u63a9\u7801255.x.x.x\u3002 \u8bf7\u53c2\u9605\u4e0b\u8868CIDR\u5b50\u7f51\u8868\uff1a\u67e5\u627e\u5341\u8fdb\u5236\u5b50\u7f51\u63a9\u7801\u7684CIDR\u503c\u3002<\/p>\n<table>\n<caption><span class=\"caption-text\">CIDR \u5b50\u7f51\u8868<\/span><\/caption>\n<colgroup>\n<col width=\"18%\" \/>\n<col width=\"13%\" \/>\n<col width=\"21%\" \/>\n<col width=\"22%\" \/>\n<col width=\"26%\" \/><\/colgroup>\n<thead valign=\"bottom\">\n<tr class=\"row-odd\">\n<th class=\"head\">\u5b50\u7f51\u63a9\u7801<\/th>\n<th class=\"head\">CIDR\u00a0\u524d\u7f00<\/th>\n<th class=\"head\">\u603bIP\u5730\u5740\u6570<\/th>\n<th class=\"head\">\u53ef\u7528IP\u5730\u5740\u6570<\/th>\n<th class=\"head\">24\u7f51\u7edc\u6570\u91cf<\/th>\n<\/tr>\n<\/thead>\n<tbody valign=\"top\">\n<tr class=\"row-even\">\n<td>255.255.255.255<\/td>\n<td>\/32<\/td>\n<td>1<\/td>\n<td>1<\/td>\n<td>1\/256th<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.255.254<\/td>\n<td>\/31<\/td>\n<td>2<\/td>\n<td>2*<\/td>\n<td>1\/128th<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.255.252<\/td>\n<td>\/30<\/td>\n<td>4<\/td>\n<td>2<\/td>\n<td>1\/64th<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.255.248<\/td>\n<td>\/29<\/td>\n<td>8<\/td>\n<td>6<\/td>\n<td>1\/32nd<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.255.240<\/td>\n<td>\/28<\/td>\n<td>16<\/td>\n<td>14<\/td>\n<td>1\/16th<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.255.224<\/td>\n<td>\/27<\/td>\n<td>32<\/td>\n<td>30<\/td>\n<td>1\/8th<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.255.192<\/td>\n<td>\/26<\/td>\n<td>64<\/td>\n<td>62<\/td>\n<td>1\/4th<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.255.128<\/td>\n<td>\/25<\/td>\n<td>128<\/td>\n<td>126<\/td>\n<td>1 half<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.255.0<\/td>\n<td>\/24<\/td>\n<td>256<\/td>\n<td>254<\/td>\n<td>1<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.254.0<\/td>\n<td>\/23<\/td>\n<td>512<\/td>\n<td>510<\/td>\n<td>2<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.252.0<\/td>\n<td>\/22<\/td>\n<td>1024<\/td>\n<td>1022<\/td>\n<td>4<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.248.0<\/td>\n<td>\/21<\/td>\n<td>2048<\/td>\n<td>2046<\/td>\n<td>8<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.240.0<\/td>\n<td>\/20<\/td>\n<td>4096<\/td>\n<td>4094<\/td>\n<td>16<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.224.0<\/td>\n<td>\/19<\/td>\n<td>8192<\/td>\n<td>8190<\/td>\n<td>32<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.192.0<\/td>\n<td>\/18<\/td>\n<td>16,384<\/td>\n<td>16,382<\/td>\n<td>64<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.255.128.0<\/td>\n<td>\/17<\/td>\n<td>32,768<\/td>\n<td>32,766<\/td>\n<td>128<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.255.0.0<\/td>\n<td>\/16<\/td>\n<td>65,536<\/td>\n<td>65,534<\/td>\n<td>256<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.254.0.0<\/td>\n<td>\/15<\/td>\n<td>131,072<\/td>\n<td>131,070<\/td>\n<td>512<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.252.0.0<\/td>\n<td>\/14<\/td>\n<td>262,144<\/td>\n<td>262,142<\/td>\n<td>1024<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.248.0.0<\/td>\n<td>\/13<\/td>\n<td>524,288<\/td>\n<td>524,286<\/td>\n<td>2048<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.240.0.0<\/td>\n<td>\/12<\/td>\n<td>1,048,576<\/td>\n<td>1,048,574<\/td>\n<td>4096<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.224.0 0<\/td>\n<td>\/11<\/td>\n<td>2,097,152<\/td>\n<td>2,097,150<\/td>\n<td>8192<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.192.0.0<\/td>\n<td>\/10<\/td>\n<td>4,194,304<\/td>\n<td>4,194,302<\/td>\n<td>16,384<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>255.128.0.0<\/td>\n<td>\/9<\/td>\n<td>8,388,608<\/td>\n<td>8,388,606<\/td>\n<td>32,768<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>255.0.0.0<\/td>\n<td>\/8<\/td>\n<td>16,777,216<\/td>\n<td>16,777,214<\/td>\n<td>65,536<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>254.0.0.0<\/td>\n<td>\/7<\/td>\n<td>33,554,432<\/td>\n<td>33,554,430<\/td>\n<td>131,072<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>252.0.0.0<\/td>\n<td>\/6<\/td>\n<td>67,108,864<\/td>\n<td>67,108,862<\/td>\n<td>262,144<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>248.0.0.0<\/td>\n<td>\/5<\/td>\n<td>134,217,728<\/td>\n<td>134,217,726<\/td>\n<td>1,048,576<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>240.0.0.0<\/td>\n<td>\/4<\/td>\n<td>268,435,456<\/td>\n<td>268,435,454<\/td>\n<td>2,097,152<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>224.0.0.0<\/td>\n<td>\/3<\/td>\n<td>536,870,912<\/td>\n<td>536,870,910<\/td>\n<td>4,194,304<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>192.0.0.0<\/td>\n<td>\/2<\/td>\n<td>1,073,741,824<\/td>\n<td>1,073,741,822<\/td>\n<td>8,388,608<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>128.0.0.0<\/td>\n<td>\/1<\/td>\n<td>2,147,483,648<\/td>\n<td>2,147,483,646<\/td>\n<td>16,777,216<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>0.0.0.0<\/td>\n<td>\/0<\/td>\n<td>4,294,967,296<\/td>\n<td>4,294,967,294<\/td>\n<td>33,554,432<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p class=\"first admonition-title\" style=\"text-align: justify;\">\u6ce8\u610f\uff1a\u4f7f\u7528\/31\u7f51\u7edc\u662fRFC 3021\u5b9a\u4e49\u7684\u7279\u6b8a\u60c5\u51b5\uff0c\u5176\u4e2d\u5b50\u7f51\u4e2d\u7684\u4e24\u4e2aIP\u5730\u5740\u53ef\u7528\u4e8e\u70b9\u5bf9\u70b9\u94fe\u63a5\u4ee5\u8282\u7701IPv4\u5730\u5740\u7a7a\u95f4\u3002 \u5e76\u975e\u6240\u6709\u7cfb\u7edf\u90fd\u652f\u6301RFC 3021\uff0c\u6240\u4ee5\u8bf7\u8c28\u614e\u4f7f\u7528\u3002 \u5728\u4e0d\u652f\u6301RFC 3021\u7684\u7cfb\u7edf\u4e0a\uff0c\u5b50\u7f51\u662f\u4e0d\u53ef\u7528\u7684\uff0c\u56e0\u4e3a\u5b50\u7f51\u63a9\u7801\u5b9a\u4e49\u7684\u4ec5\u6709\u4e24\u4e2a\u5730\u5740\u662f\u7a7a\u8def\u7531\u548c\u5e7f\u64ad\uff0c\u4e14\u6ca1\u6709\u53ef\u7528\u7684\u4e3b\u673a\u5730\u5740\u3002<\/p>\n<p style=\"text-align: justify;\">pfSense 2..45\u652f\u6301\u4f7f\u7528\/31\u7f51\u7edc\u63a5\u53e3\u548c\u865a\u62dfIP\u5730\u5740\u3002<\/p>\n<h2 style=\"text-align: justify;\">CIDR\u503c\u5982\u4f55\u8ba1\u7b97<\/h2>\n<p style=\"text-align: justify;\">\u5f53\u8f6c\u6362\u4e3a\u4e8c\u8fdb\u5236\u65f6\uff0cCIDR\u7f16\u53f7\u6765\u81ea\u5b50\u7f51\u63a9\u7801\u4e2d\u76841\u3002<\/p>\n<p style=\"text-align: justify;\">\u516c\u7528\u5b50\u7f51\u63a9\u7801255.255.255.0\u662f\u4e8c\u8fdb\u5236\u768411111111.11111111.11111111.00000000\u3002\u603b\u8ba1\u4e3a24\u4e2a1\uff0c\u6240\u4ee5\u4e3a\/ 24\u3002<\/p>\n<p style=\"text-align: justify;\">\u5b50\u7f51\u63a9\u7801255.255.255.192\u662f\u4e8c\u8fdb\u5236\u768411111111.11111111.11111111.11000000\uff0c\u537326\u4e2a1\uff0c\u56e0\u6b64\u4e3a\/ 26\u3002<\/p>\n<h1 style=\"text-align: justify;\">CIDR\u6982\u8ff0<\/h1>\n<p style=\"text-align: justify;\">\u9664\u4e86\u6307\u5b9a\u5b50\u7f51\u63a9\u7801\u4e4b\u5916\uff0cCIDR\u8fd8\u53ef\u4ee5\u7528\u4e8eIP\u6216\u7f51\u7edc\u6c47\u603b\u3002<span class=\"std std-ref\">CIDR\u5b50\u7f51\u8868\u4e2d<\/span>\u7684\u201c\u603bIP\u5730\u5740\u201d\u5217\u6307\u793a\u7ed9\u5b9a\u7684CIDR\u63a9\u7801\u6c47\u603b\u4e86\u591a\u5c11\u4e2a\u5730\u5740\u3002\u51fa\u4e8e\u7f51\u7edc\u6c47\u603b\u7684\u76ee\u7684\uff0c\u201c\/ 24\u7f51\u7edc\u6570\u91cf\u201d\u5217\u5f88\u6709\u7528\u3002CIDR\u6458\u8981\u53ef\u7528\u4e8epfSense\u00aeWeb\u754c\u9762\u7684\u591a\u4e2a\u90e8\u5206\uff0c\u5305\u62ec\u9632\u706b\u5899\u89c4\u5219\u3001NAT\u3001\u865a\u62dfIP\u3001IPsec\u548c\u9759\u6001\u8def\u7531\u3002<\/p>\n<p style=\"text-align: justify;\">\u53ef\u4ee5\u5305\u542b\u5728\u5355\u4e2aCIDR\u63a9\u7801\u4e2d\u7684IP\u5730\u5740\u6216\u7f51\u7edc\u79f0\u4e3a\u201c CIDR\u53ef\u6c47\u603b\u201d\u3002<\/p>\n<p style=\"text-align: justify;\">\u8bbe\u8ba1\u7f51\u7edc\u65f6\uff0c\u8bf7\u786e\u4fdd\u5728\u7279\u5b9a\u4f4d\u7f6e\u4f7f\u7528\u7684\u6240\u6709\u79c1\u6709IP\u5b50\u7f51\u90fd\u662f\u53ef\u6c47\u603b\u7684CIDR\u3002\u4f8b\u5982\uff0c\u5982\u679c\u5728\u4e00\u4e2a\u4f4d\u7f6e\u9700\u8981\u4e09\u4e2a\/24\u5b50\u7f51\uff0c\u5219\u5e94\u4f7f\u7528\u4e00\u4e2a\u5206\u4e3a\u56db\u4e2a\/ 24\u7f51\u7edc\u7684\/ 22\u7f51\u7edc\u3002\u4e0b\u8868\u663e\u793a\u4e86\u4e0e\u5b50\u7f5110.70.64.0\/22\u4e00\u8d77\u4f7f\u7528\u7684\u56db\u4e2a\/24\u5b50\u7f51\u3002<\/p>\n<table class=\"docutils\">\n<caption><span class=\"caption-text\">CIDR \u8def\u7531\u6c47\u603b<\/span><\/caption>\n<colgroup>\n<col width=\"100%\" \/><\/colgroup>\n<thead valign=\"bottom\">\n<tr class=\"row-odd\">\n<th class=\"head\">10.70.64.0\/22 \u5206\u621024\u7f51\u7edc<\/th>\n<\/tr>\n<\/thead>\n<tbody valign=\"top\">\n<tr class=\"row-even\">\n<td>10.70.64.0\/24<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>10.70.65.0\/24<\/td>\n<\/tr>\n<tr class=\"row-even\">\n<td>10.70.66.0\/24<\/td>\n<\/tr>\n<tr class=\"row-odd\">\n<td>10.70.67.0\/24<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p style=\"text-align: justify;\">\u901a\u8fc7\u4f7f\u7528\u4e13\u7528WAN\u7ebf\u8def\u6216VPN\uff0c\u4f7f\u8fde\u63a5\u5230\u53e6\u4e00\u4e2a\u7269\u7406\u4f4d\u7f6e\u7684\u591a\u7ad9\u70b9\u7f51\u7edc\u7684\u8def\u7531\u66f4\u6613\u4e8e\u7ba1\u7406\u3002\u4f7f\u7528CIDR\u53ef\u6982\u62ec\u5b50\u7f51\uff0c\u4e00\u4e2a\u8def\u7531\u76ee\u6807\u53ef\u4ee5\u8986\u76d6\u6bcf\u4e2a\u4f4d\u7f6e\u7684\u6240\u6709\u7f51\u7edc\u3002\u6ca1\u6709\u5b83\uff0c\u6bcf\u4e2a\u4f4d\u7f6e\u90fd\u6709\u51e0\u4e2a\u4e0d\u540c\u7684\u76ee\u6807\u7f51\u7edc\u3002<\/p>\n<p style=\"text-align: justify;\">\u53ef\u4ee5\u5728<a title=\"\" href=\"http:\/\/www.subnetmask.info\/\" target=\"_blank\" rel=\"noopener noreferrer\">subnetmask.info<\/a>\u7f51\u7ad9\u4e0a\u4f7f\u7528\u7f51\u7edc\u8ba1\u7b97\u5668\u8fdb\u884cCIDR\u8ba1\u7b97\u3002<\/p>\n<p style=\"text-align: justify;\">\u8ba1\u7b97\u5668\u5c06\u70b9\u5206\u5341\u8fdb\u5236\u8f6c\u6362\u4e3aCIDR\u63a9\u7801\uff0c\u53cd\u4e4b\u4ea6\u7136\uff0c\u5982\u4e0b\u56fe\u6240\u793a\u3002\u5982\u679c\u672c\u7ae0\u63d0\u4f9b\u7684\u00a0<span class=\"std std-ref\">CIDR\u5b50\u7f51\u8868<\/span>\u4e0d\u53ef\u7528\uff0c\u5219\u53ef\u4ee5\u4f7f\u7528\u6b64\u5de5\u5177\u5c06CIDR\u524d\u7f00\u8f6c\u6362\u4e3a\u70b9\u5206\u5341\u8fdb\u5236\u8868\u793a\u6cd5\u3002\u8f93\u5165CIDR\u524d\u7f00\u6216\u70b9\u5206\u5341\u8fdb\u5236\u63a9\u7801\uff0c\u7136\u540e\u5355\u51fb\u76f8\u5e94\u7684\u201c<strong>\u8ba1\u7b97\u201d<\/strong>\u00a0\u6309\u94ae\u6765\u67e5\u627e\u8f6c\u6362\u7684\u503c\u3002<\/p>\n<p style=\"text-align: justify;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1658\" src=\"https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-subnet-mask-converter.png\" alt=\"\" width=\"752\" height=\"94\" srcset=\"https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-subnet-mask-converter.png 752w, https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-subnet-mask-converter-300x38.png 300w, https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-subnet-mask-converter-500x63.png 500w\" sizes=\"auto, (max-width: 752px) 100vw, 752px\" \/><br \/>\n<span id=\"figure-subnet-mask-converter\"><\/span><\/p>\n<p style=\"text-align: justify;\">\u5728Network\/Node Calculator\uff08\u7f51\u7edc\/\u8282\u70b9\u8ba1\u7b97\u5668\uff09\u90e8\u5206\u8f93\u5165\u5341\u8fdb\u5236\u63a9\u7801\u548cIP\u5730\u5740\uff0c \u70b9\u51fbCalculate\uff0c \u4e0b\u9762\u5c31\u4f1a\u663e\u793a\u8ba1\u7b97\u7684\u7ed3\u679c\u3002 \u5728\u672c\u4f8b\u4e2d\uff0c\u7f51\u7edc\u5730\u5740\u662f10.70.64.0\/22\uff0c\u53ef\u7528\u7684\/ 24\u7f51\u7edc\u662f64\u523067\u3002\u672c\u8868\u4e2d\u7684\u672f\u8bed\u201cBroadcast Address(\u5e7f\u64ad\u5730\u5740)\u201d\u662f\u6307\u8be5\u8303\u56f4\u5185\u7684\u6700\u9ad8\u5730\u5740\u3002<\/p>\n<p style=\"text-align: justify;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1657\" src=\"https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-network-node-calc.png\" alt=\"\" width=\"753\" height=\"179\" srcset=\"https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-network-node-calc.png 753w, https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-network-node-calc-300x71.png 300w, https:\/\/blog.pfchina.org\/wp-content\/uploads\/2018\/07\/subnetmask-info-network-node-calc-500x119.png 500w\" sizes=\"auto, (max-width: 753px) 100vw, 753px\" \/><br \/>\n<span id=\"figure-network-node-calculator\"><\/span><\/p>\n<p class=\"caption\" style=\"text-align: justify;\"><span class=\"caption-text\">Network\/Node Calculator\uff08\u7f51\u7edc\/\u8282\u70b9\u8ba1\u7b97\u5668\uff09<\/span><\/p>\n<h2 style=\"text-align: justify;\">\u627e\u5230\u4e00\u4e2a\u5339\u914d\u7684CIDR\u7f51\u7edc<\/h2>\n<p style=\"text-align: justify;\">\u522b\u540d\u652f\u6301\u683c\u5f0f\u4e3ax.x.x.x-y.y.y.y\u7684IPv4\u5730\u5740\u8303\u56f4\u3002 \u5bf9\u4e8e\u7f51\u7edc\u7c7b\u578b\u522b\u540d\uff0cIPv4\u8303\u56f4\u5c06\u81ea\u52a8\u8f6c\u6362\u4e3a\u7b49\u6548\u7684CIDR\u5757\u3002 \u5bf9\u4e8e\u4e3b\u673a\u7c7b\u578b\u522b\u540d\uff0c\u8303\u56f4\u5c06\u8f6c\u6362\u4e3aIPv4\u5730\u5740\u5217\u8868\u3002<\/p>\n<p style=\"text-align: justify;\">\u5982\u679c\u4e0d\u9700\u8981\u5b8c\u5168\u5339\u914d\uff0c\u5219\u53ef\u4ee5\u5c06\u6570\u5b57\u8f93\u5165\u5230Network\/Node Calculator\uff08\u7f51\u7edc\/\u8282\u70b9\u8ba1\u7b97\u5668\uff09\u8fdb\u884c\u8ba1\u7b97\u3002<\/p>\n<h1 style=\"text-align: justify;\">\u5e7f\u64ad\u57df<\/h1>\n<p style=\"text-align: justify;\">\u5e7f\u64ad\u57df\u662f\u7f51\u7edc\u5171\u4eab\u540c\u4e00\u7b2c2\u5c42\u7f51\u6bb5\u7684\u90e8\u5206\u3002\u5728\u4e0d\u5e26VLAN\u7684\u5355\u4e2a\u4ea4\u6362\u673a\u7684\u7f51\u7edc\u4e2d\uff0c\u5e7f\u64ad\u57df\u5c31\u662f\u6574\u4e2a\u4ea4\u6362\u673a\u3002\u5728\u591a\u4e2a\u4e92\u8fde\u4ea4\u6362\u673a\u4e14\u4e0d\u4f7f\u7528VLAN\u7684\u7f51\u7edc\u91cc\uff0c\u5e7f\u64ad\u57df\u5305\u542b\u6240\u6709\u8fd9\u4e9b\u4ea4\u6362\u673a\u3002<\/p>\n<p style=\"text-align: justify;\">\u5355\u4e2a\u5e7f\u64ad\u57df\u53ef\u4ee5\u5305\u542b\u591a\u4e2aIPv4\u6216IPv6\u5b50\u7f51\uff0c\u4f46\u8fd9\u4e0d\u662f\u597d\u7684\u7f51\u7edc\u8bbe\u8ba1\u3002IP\u5b50\u7f51\u5e94\u901a\u8fc7\u4f7f\u7528\u5355\u72ec\u7684\u4ea4\u6362\u673a\u6216VLAN\u9694\u79bb\u5230\u5355\u72ec\u7684\u5e7f\u64ad\u57df\u4e2d\u3002\u4f8b\u5916\u662f\u5728\u5355\u4e2a\u5e7f\u64ad\u57df\u4e2d\u540c\u65f6\u8fd0\u884cIPv4\u548cIPv6\u7f51\u7edc\u3002\u8fd9\u79f0\u4e3a\u53cc\u6808\uff0c\u8fd9\u662f\u5bf9\u4e3b\u673a\u540c\u65f6\u4f7f\u7528IPv4\u548cIPv6\u8fde\u63a5\u7684\u4e00\u79cd\u5e38\u89c1\u4e14\u6709\u7528\u7684\u6280\u672f\u3002<\/p>\n<p style=\"text-align: justify;\">\u53ef\u4ee5\u901a\u8fc7\u5c06\u4e24\u4e2a\u7f51\u7edc\u63a5\u53e3\u6865\u63a5\u5728\u4e00\u8d77\u6765\u7ec4\u5408\u5e7f\u64ad\u57df\uff0c\u4f46\u662f\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u5fc5\u987b\u5c0f\u5fc3\u907f\u514d\u4ea4\u6362\u73af\u8def\u3002\u5bf9\u4e8e\u67d0\u4e9b\u534f\u8bae\uff0c\u4e5f\u5b58\u5728\u4e00\u4e9b\u4ee3\u7406\uff0c\u8fd9\u4e9b\u4ee3\u7406\u6ca1\u6709\u7ec4\u5408\u5e7f\u64ad\u57df\uff0c\u4fdd\u6301\u4e86\u7f51\u7edc\u7684\u5e72\u51c0\uff0c\u4f8b\u5982DHCP\u4e2d\u7ee7\uff0c\u5b83\u5c06DHCP\u8bf7\u6c42\u4e2d\u7ee7\u5230\u53e6\u4e00\u4e2a\u63a5\u53e3\u7684\u5e7f\u64ad\u57df\u4e2d\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u672c\u4e66\u4e0d\u662f\u5bf9\u7f51\u7edc\u7684\u4ecb\u7ecd\uff0c\u4f46\u4e00\u4e9b\u7f51\u7edc\u6982\u5ff5\u9700\u8981\u7406\u89e3\u3002 \u5bf9\u4e8e\u6ca1\u6709\u7f51\u7edc\u57fa\u7840\u77e5\u8bc6\u7684\u8bfb\u8005\uff0c\u6211\u4eec &hellip; <a href=\"https:\/\/blog.pfchina.org\/?p=151\">\u7ee7\u7eed\u9605\u8bfb <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[28],"tags":[240],"class_list":["post-151","post","type-post","status-publish","format-standard","hentry","category-pfsense","tag-240"],"_links":{"self":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/posts\/151","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=151"}],"version-history":[{"count":0,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/posts\/151\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=151"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=151"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=151"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}