{"id":18394,"date":"2025-04-19T00:48:03","date_gmt":"2025-04-18T16:48:03","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/18394.html"},"modified":"2025-04-19T00:48:03","modified_gmt":"2025-04-18T16:48:03","slug":"%e3%80%90%e7%bd%91%e7%bb%9c%e7%bc%96%e7%a8%8b%e3%80%91%e5%9f%ba%e4%ba%8e-tcp%e5%8d%8f%e8%ae%ae-%e7%9a%84%e6%9c%8d%e5%8a%a1%e5%99%a8-%e5%ae%a2%e6%88%b7%e7%ab%af%e9%80%9a%e4%bf%a1%e6%a8%a1%e5%9e%8b","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/18394.html","title":{"rendered":"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668"},"content":{"rendered":"<p>\u57fa\u4e8e\u4e0a\u4e00\u7bc7\u4e2d \u7f51\u7edc\u7f16\u7a0b\u57fa\u7840\uff1aTCP\/UDP \u534f\u8bae \u5b9e\u73b0\u4e86\u57fa\u4e8e TCP \u534f\u8bae\u7684\u7f51\u7edc\u901a\u4fe1\u6a21\u578b\u3002\u57fa\u4e8e\u6b64\u4e4b\u4e0a\uff0c\u6211\u4eec\u7ee7\u7eed\u4ecb\u7ecd \u52a0\u5bc6\u4f20\u8f93\u3001\u7528\u591a\u7ebf\u7a0b\u5b9e\u73b0\u5ba2\u6237\u7aef\u7a0b\u5e8f\u4e0e\u7f51\u7edc\u8c03\u8bd5\u52a9\u624b\u8fdb\u884c\u53cc\u5411\u901a\u4fe1\uff08\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668\uff09\u3002<\/p>\n<p>\u8fd9\u662f\u4e00\u4e2a\u57fa\u4e8e OpenSSL \u7684 TLS\uff08SSL\uff09\u52a0\u5bc6\u4f20\u8f93\u7684 TCP \u670d\u52a1\u5668-\u5ba2\u6237\u7aef \u901a\u4fe1\u793a\u4f8b\u3002\u8fd9\u79cd\u65b9\u5f0f\u53ef\u4ee5\u786e\u4fdd\u6570\u636e\u5728\u4f20\u8f93\u8fc7\u7a0b\u4e2d\u88ab\u52a0\u5bc6\uff0c\u9632\u6b62\u4e2d\u95f4\u4eba\u653b\u51fb\u548c\u6570\u636e\u7a83\u53d6\u3002<\/p>\n<h4>\u4ee3\u7801\u8bf4\u660e<\/h4>\n<p>\u4f7f\u7528 OpenSSL\uff1a\u63d0\u4f9bTLS\/SSL\u52a0\u5bc6\u901a\u4fe1\u3002 \u670d\u52a1\u5668\uff08server.c\uff09\uff1a<\/p>\n<li>\u751f\u6210 TLS \u8bc1\u4e66\u5e76\u52a0\u8f7d\uff1b<\/li>\n<li>\u76d1\u542c\u5ba2\u6237\u7aef\u8fde\u63a5\uff1b<\/li>\n<li>\u901a\u8fc7 TLS \u8fdb\u884c\u52a0\u5bc6\u901a\u4fe1\u3002<\/li>\n<p>\u5ba2\u6237\u7aef\uff08client.c\uff09\uff1a\u8fde\u63a5\u670d\u52a1\u5668\u5e76\u4f7f\u7528 TLS \u8fdb\u884c\u52a0\u5bc6\u901a\u4fe1\u3002<\/p>\n<h4>\u751f\u6210 SSL \u8bc1\u4e66\uff08\u81ea\u7b7e\u540d\uff09<\/h4>\n<p>\u5728\u8fd0\u884c\u4ee3\u7801\u4e4b\u524d\uff0c\u6211\u4eec\u9700\u8981\u751f\u6210\u81ea\u7b7e\u540d\u8bc1\u4e66\uff1a<\/p>\n<p>openssl req <span class=\"token parameter variable\">-x509<\/span> <span class=\"token parameter variable\">-newkey<\/span> rsa:2048 <span class=\"token parameter variable\">-keyout<\/span> key.pem <span class=\"token parameter variable\">-out<\/span> cert.pem <span class=\"token parameter variable\">-days<\/span> <span class=\"token number\">365<\/span> <span class=\"token parameter variable\">-nodes<\/span><\/p>\n<p>\u6267\u884c\u540e\u4f1a\u8981\u6c42\u8f93\u5165\u4e00\u4e9b\u4fe1\u606f\uff08\u53ef\u4ee5\u968f\u610f\u586b\u5199\uff09\uff0c\u8fd9\u6837\u4f1a\u751f\u6210\uff1a<\/p>\n<ul>\n<li>cert.pem\uff08SSL \u8bc1\u4e66\uff09<\/li>\n<li>key.pem\uff08\u79c1\u94a5\uff09<\/li>\n<\/ul>\n<h5>\u670d\u52a1\u5668\u4ee3\u7801\uff08server.c\uff09<\/h5>\n<p><span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;stdio.h&gt;<\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;stdlib.h&gt;<\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;string.h&gt;<\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;unistd.h&gt;<\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;arpa\/inet.h&gt;<\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;openssl\/ssl.h&gt;<\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">include<\/span> <span class=\"token string\">&lt;openssl\/err.h&gt;<\/span><\/span><\/p>\n<p><span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">define<\/span> <span class=\"token macro-name\">PORT<\/span> <span class=\"token expression\"><span class=\"token number\">8080<\/span><\/span><\/span><br \/>\n<span class=\"token macro property\"><span class=\"token directive-hash\">#<\/span><span class=\"token directive keyword\">define<\/span> <span class=\"token macro-name\">BUFFER_SIZE<\/span> <span class=\"token expression\"><span class=\"token number\">1024<\/span><\/span><\/span><\/p>\n<p><span class=\"token keyword\">void<\/span> <span class=\"token function\">init_openssl<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n    <span class=\"token function\">SSL_library_init<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token function\">OpenSSL_add_all_algorithms<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token function\">SSL_load_error_strings<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token punctuation\">}<\/span><\/p>\n<p>SSL_CTX <span class=\"token operator\">*<\/span><span class=\"token function\">create_context<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n    <span class=\"token keyword\">const<\/span> SSL_METHOD <span class=\"token operator\">*<\/span>method <span class=\"token operator\">=<\/span> <span class=\"token function\">SSLv23_server_method<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    SSL_CTX <span class=\"token operator\">*<\/span>ctx <span class=\"token operator\">=<\/span> <span class=\"token function\">SSL_CTX_new<\/span><span class=\"token punctuation\">(<\/span>method<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token keyword\">if<\/span> <span class=\"token punctuation\">(<\/span><span class=\"token operator\">!<\/span>ctx<span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n        <span class=\"token function\">perror<\/span><span class=\"token punctuation\">(<\/span><span class=\"token string\">\\&#8221;Unable to create SSL context\\&#8221;<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n        <span class=\"token function\">ERR_print_errors_fp<\/span><span class=\"token punctuation\">(<\/span><span class=\"token constant\">stderr<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n        <span class=\"token function\">exit<\/span><span class=\"token punctuation\">(<\/span>EXIT_FAILURE<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token punctuation\">}<\/span><br \/>\n    <span class=\"token keyword\">return<\/span> ctx<span class=\"token punctuation\">;<\/span><br \/>\n<span class=\"token punctuation\">}<\/span><\/p>\n<p><span class=\"token keyword\">void<\/span> <span class=\"token function\">configure_context<\/span><span class=\"token punctuation\">(<\/span>SSL_CTX <span class=\"token operator\">*<\/span>ctx<span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n    <span class=\"token keyword\">if<\/span> <span class=\"token punctuation\">(<\/span><span class=\"token function\">SSL_CTX_use_certificate_file<\/span><span class=\"token punctuation\">(<\/span>ctx<span class=\"token punctuation\">,<\/span> <span class=\"token string\">\\&#8221;cert.pem\\&#8221;<\/span><span class=\"token punctuation\">,<\/span> SSL_FILETYPE_PEM<span class=\"token punctuation\">)<\/span> <span class=\"token operator\">&lt;=<\/span> <span class=\"token number\">0<\/span> <span class=\"token operator\">||<\/span><br \/>\n        <span class=\"token function\">SSL_CTX_use_PrivateKey_file<\/span><span class=\"token punctuation\">(<\/span>ctx<span class=\"token punctuation\">,<\/span> <span class=\"token string\">\\&#8221;key.pem\\&#8221;<\/span><span class=\"token punctuation\">,<\/span> SSL_FILETYPE_PEM<span class=\"token punctuation\">)<\/span> <span class=\"token operator\">&lt;=<\/span> <span class=\"token number\">0<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n        <span class=\"token function\">ERR_print_errors_fp<\/span><span class=\"token punctuation\">(<\/span><span class=\"token constant\">stderr<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n        <span class=\"token function\">exit<\/span><span class=\"token punctuation\">(<\/span>EXIT_FAILURE<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token punctuation\">}<\/span><br \/>\n<span class=\"token punctuation\">}<\/span><\/p>\n<p><span class=\"token keyword\">int<\/span> <span class=\"token function\">main<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n    <span class=\"token keyword\">int<\/span> server_fd<span class=\"token punctuation\">,<\/span> client_fd<span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token keyword\">struct<\/span> <span class=\"token class-name\">sockaddr_in<\/span> address<span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token class-name\">socklen_t<\/span> addr_len <span class=\"token operator\">=<\/span> <span class=\"token keyword\">sizeof<\/span><span class=\"token punctuation\">(<\/span>address<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token keyword\">char<\/span> buffer<span class=\"token punctuation\">[<\/span>BUFFER_SIZE<span class=\"token punctuation\">]<\/span> <span class=\"token operator\">=<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><span class=\"token number\">0<\/span><span class=\"token punctuation\">}<\/span><span class=\"token punctuation\">;<\/span><\/p>\n<p>    <span class=\"token function\">init_openssl<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    SSL_CTX <span class=\"token operator\">*<\/span>ctx <span class=\"token operator\">=<\/span> <span class=\"token function\">create_context<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token function\">configure_context<\/span><span class=\"token punctuation\">(<\/span>ctx<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><\/p>\n<p>    server_fd <span class=\"token operator\">=<\/span> <span class=\"token function\">socket<\/span><span class=\"token punctuation\">(<\/span>AF_INET<span class=\"token punctuation\">,<\/span> SOCK_STREAM<span class=\"token punctuation\">,<\/span> <span class=\"token number\">0<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token keyword\">if<\/span> <span class=\"token punctuation\">(<\/span>server_fd <span class=\"token operator\">&lt;<\/span> <span class=\"token number\">0<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token punctuation\">{<br \/>\n   <\/span><br \/>\n        <span class=\"token function\">perror<\/span><span class=\"token punctuation\">(<\/span><span class=\"token string\">\\&#8221;Socket creation failed\\&#8221;<\/span><span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n        <span class=\"token function\">exit<\/span><span class=\"token punctuation\">(<\/span>EXIT_FAILURE<span class=\"token punctuation\">)<\/span><span class=\"token punctuation\">;<\/span><br \/>\n    <span class=\"token punctuation\">}<\/span><\/p>\n<p>    address<span class=\"token punctuation\">.<\/span>sin_family <span class=\"token operator\">=<\/span> AF_INET<span class=\"token punctuation\">;<\/span><br \/>\n    address<span class=\"token punctuation\">.<\/span>sin_addr<span class=\"token punctuation\">.<\/span>s_addr <span class=\"token operator\">=<\/span> INADDR_ANY<span class=\"token punctuation\">;<\/span><br \/>\n    address<span class=\"token punctuation\">.<\/span>sin_port <span class=\"token operator\">=<\/span> <span class=\"token function\">htons<\/span><span class=\"token punctuation\">(<\/span>PORT<span class=\"token punctuation\">)<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb922\u6b21\uff0c\u70b9\u8d5e27\u6b21\uff0c\u6536\u85cf29\u6b21\u3002\u57fa\u4e8e\u4e0a\u4e00\u7bc7\u4e2d\u5b9e\u73b0\u4e86\u57fa\u4e8e TCP \u534f\u8bae\u7684\u7f51\u7edc\u901a\u4fe1\u6a21\u578b\u3002\u57fa\u4e8e\u6b64\u4e4b\u4e0a\uff0c\u6211\u4eec\u7ee7\u7eed\u4ecb\u7ecd\uff08\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668\uff09\u3002\u8fd9\u662f\u4e00\u4e2a\u901a\u4fe1\u793a\u4f8b\u3002\u8fd9\u79cd\u65b9\u5f0f\u53ef\u4ee5\u786e\u4fdd\u3002<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[174,205,103,270,43,191,396],"topic":[],"class_list":["post-18394","post","type-post","status-publish","format-standard","hentry","category-server","tag-c","tag-tcp-ip","tag-ubuntu","tag-270","tag-43","tag-191","tag-396"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/18394.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb922\u6b21\uff0c\u70b9\u8d5e27\u6b21\uff0c\u6536\u85cf29\u6b21\u3002\u57fa\u4e8e\u4e0a\u4e00\u7bc7\u4e2d\u5b9e\u73b0\u4e86\u57fa\u4e8e TCP \u534f\u8bae\u7684\u7f51\u7edc\u901a\u4fe1\u6a21\u578b\u3002\u57fa\u4e8e\u6b64\u4e4b\u4e0a\uff0c\u6211\u4eec\u7ee7\u7eed\u4ecb\u7ecd\uff08\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668\uff09\u3002\u8fd9\u662f\u4e00\u4e2a\u901a\u4fe1\u793a\u4f8b\u3002\u8fd9\u79cd\u65b9\u5f0f\u53ef\u4ee5\u786e\u4fdd\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/18394.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2025-04-18T16:48:03+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/18394.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/18394.html\",\"name\":\"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2025-04-18T16:48:03+00:00\",\"dateModified\":\"2025-04-18T16:48:03+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/18394.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/18394.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/18394.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/18394.html","og_locale":"zh_CN","og_type":"article","og_title":"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb922\u6b21\uff0c\u70b9\u8d5e27\u6b21\uff0c\u6536\u85cf29\u6b21\u3002\u57fa\u4e8e\u4e0a\u4e00\u7bc7\u4e2d\u5b9e\u73b0\u4e86\u57fa\u4e8e TCP \u534f\u8bae\u7684\u7f51\u7edc\u901a\u4fe1\u6a21\u578b\u3002\u57fa\u4e8e\u6b64\u4e4b\u4e0a\uff0c\u6211\u4eec\u7ee7\u7eed\u4ecb\u7ecd\uff08\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668\uff09\u3002\u8fd9\u662f\u4e00\u4e2a\u901a\u4fe1\u793a\u4f8b\u3002\u8fd9\u79cd\u65b9\u5f0f\u53ef\u4ee5\u786e\u4fdd\u3002","og_url":"https:\/\/www.wsisp.com\/helps\/18394.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2025-04-18T16:48:03+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"1 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/18394.html","url":"https:\/\/www.wsisp.com\/helps\/18394.html","name":"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2025-04-18T16:48:03+00:00","dateModified":"2025-04-18T16:48:03+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/18394.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/18394.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/18394.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u3010\u7f51\u7edc\u7f16\u7a0b\u3011\u57fa\u4e8e TCP\u534f\u8bae \u7684\u670d\u52a1\u5668-\u5ba2\u6237\u7aef\u901a\u4fe1\u6a21\u578b\u7684\u52a0\u5bc6\u4f20\u8f93\u3001\u591a\u7ebf\u7a0b\u5e76\u53d1\u670d\u52a1\u5668"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/18394","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=18394"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/18394\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=18394"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=18394"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=18394"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=18394"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}