{"id":201691,"date":"2020-09-30T08:44:01","date_gmt":"2020-09-30T00:44:01","guid":{"rendered":"https:\/\/lrxjmw.cn\/?p=201691"},"modified":"2020-09-24T11:44:49","modified_gmt":"2020-09-24T03:44:49","slug":"frp-tcpstcp-ssh-homelinux","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/frp-tcpstcp-ssh-homelinux.html","title":{"rendered":"Frp\u5206\u522b\u7528tcp\u548cstcp\u6a21\u5f0fssh\u8fde\u63a5\u5230\u5185\u7f51Linux"},"content":{"rendered":"

\"\"<\/p>\n

TCP\u6a21\u5f0f<\/strong><\/div>\n
\u670d\u52a1\u5668frps\u914d\u7f6e<\/strong><\/span><\/div>\n

\u516c\u7f51\u670d\u52a1\u5668\u7684\u914d\u7f6e\u7167\u65e7\uff0c\u6ce8\u610f\u9632\u706b\u5899\u6216\u8005\u5b9d\u5854\u4e4b\u7c7b\u7684\u653e\u884cfrps\u7528\u7684\u7aef\u53e3\u3002\u53ef\u4ee5\u53c2\u8003\u4e4b\u524d\u7684\u6587\u7ae0:\u7528FRP\u505a\u5185\u7f51\u7a7f\u900f\u4f7f\u7528\u8fdc\u7a0b\u684c\u9762\u8fde\u63a5\u5bb6\u91cc\u7684windows\u7535\u8111\u3002<\/a><\/p>\n

[common]\r\nbind_addr=0.0.0.0\r\nbind_port = 7000\r\ntoken=12310086\r\n\r\ndashboard_port = 7500\r\ndashboard_user = admin\r\ndashboard_pwd = admin123<\/pre>\n
.\/frps -c frps.ini<\/pre>\n
\u5185\u7f51\u7a7f\u900f\u7684frpc\u914d\u7f6e<\/strong><\/span><\/div>\n
[common]\r\nserver_addr = \u670d\u52a1\u7aefip\r\nserver_port = 7000\r\ntoken=12310086\r\n\r\n[ssh]\r\ntype = tcp\r\nlocal_ip = 127.0.0.1\r\nlocal_port = 22\r\nremote_port = 30022\r\n<\/pre>\n
\u8fde\u63a5<\/strong><\/span><\/div>\n
ssh -p 30022 root@ip<\/pre>\n
STCP\u6a21\u5f0f<\/strong><\/div>\n

\u670d\u52a1\u5668\u7aef\u914d\u7f6e\u5982\u4e0a\u3002<\/p>\n

\u5185\u7f51\u88ab\u8fde\u63a5Linux<\/strong><\/span><\/div>\n
[common]\r\nserver_addr = \u670d\u52a1\u5668ip\r\nserver_port = 7000\r\ntoken=12310086N\r\n\r\n[secret_ssh]\r\ntype = stcp\r\nsk = 4u4rUif0vm9zn6dZ\r\nlocal_ip = 127.0.0.1\r\nlocal_port = 22\r\n<\/pre>\n
frpc.exe -c frpc.ini<\/pre>\n
\u5916\u90e8\u8fde\u63a5\u7aef\u914d\u7f6e<\/strong><\/span><\/div>\n

\u7f16\u8f91 fcpc.ini\u6587\u4ef6\uff0c\u914d\u7f6e\u4e0a\"role = visitor\"\u8eab\u4efd\u3002<\/p>\n

[common]\r\nserver_addr = \u670d\u52a1\u5668ip\r\nserver_port = 7000\r\ntoken=12310086N\r\n\r\n[secret_ssh_visitor]\r\ntype = stcp\r\nrole = visitor\r\nsk = 4u4rUif0vm9zn6dZ\r\nserver_name = secret_ssh\r\nbind_addr = 127.0.0.1\r\nbind_port = 30022\r\n<\/pre>\n
frpc.exe -c frpc.ini\r\n<\/pre>\n

\u7136\u540e\u4f7f\u7528ssh\u547d\u4ee4\u6216\u8005xshell\u4e4b\u7c7b\u7684ssh\u8f6f\u4ef6\uff0c\u8fde\u63a5\u672c\u5730\u768430022\u7aef\u53e3<\/p>\n

ssh root@127.0.0.1 -p 30022<\/pre>\n","protected":false},"excerpt":{"rendered":"

\u516c\u7f51\u670d\u52a1\u5668\u7684\u914d\u7f6e\u7167\u65e7\uff0c\u6ce8\u610f\u9632\u706b\u5899\u6216\u8005\u5b9d\u5854\u4e4b\u7c7b\u7684\u653e\u884cfrps\u7528\u7684\u7aef\u53e3\u3002\u53ef\u4ee5\u53c2\u8003\u4e4b\u524d\u7684\u6587\u7ae0:\u7528FRP\u505a\u5185\u7f51\u7a7f\u900f\u4f7f\u7528 […]<\/p>\n","protected":false},"author":362,"featured_media":201834,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[55],"tags":[],"class_list":["post-201691","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-thread"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/201691","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/362"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=201691"}],"version-history":[{"count":10,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/201691\/revisions"}],"predecessor-version":[{"id":201879,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/201691\/revisions\/201879"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/201834"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=201691"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=201691"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=201691"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}