全球主机交流论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

CeraNetworks网络延迟测速工具IP归属甄别会员请立即修改密码
查看: 3487|回复: 15
打印 上一主题 下一主题

[疑问] cubepaas使用nftables进行中转教程

[复制链接]
跳转到指定楼层
1#
发表于 2020-9-9 12:50:26 | 只看该作者 回帖奖励 |正序浏览 |阅读模式
本帖最后由 zdszf 于 2020-9-9 12:51 编辑

注册和一般设置参考: https://www.lilynana.eu.org/thread-741585-1-1.html
楼主使用的是gost,这里我们可以使用nftables,免去修改host和下载gost的步骤。

以下引用自: https://obvps.com/2020/09/08/nft908.html

卸载iptables,安装启用nftables:
apt purge iptables -y
apt install nftables -y; systemctl enable nftables; systemctl restart nftables


创建转发规则/etc/nft.diy文件,文件每行为一个转发规则,支持端口段第一个为本地端口,第二个为远程域名或IP,第三个为远程端口,以下内容请按需修改
cat <<EOF > /etc/nft.diy
20103/bing.com/443
20104-20108/1.1.1.1/443
30000-30108/www.example.com/30000-30108
EOF

执行脚本,配置端口转发
bash <(curl -s https://raw.githubusercontent.com/mixool/across/master/nftables/nft-nat.sh)

执行时会有sysctl报错 忽略皆可,我猜默认已经开启了吧。

中转oracle韩国和kinto都蛮不错的。


最后可以走下邀请连接:  https://cubepaas.com/?spread=87a00bebda0f4fb385e712748f070e0045xkuu7dz2
推荐
发表于 2020-9-9 15:14:17 | 只看该作者
本帖最后由 Waylon 于 2020-9-9 15:46 编辑

还是习惯用iptables或者firewall

  1. # iptables

  2. iptables -t nat -F
  3. iptables -t nat -A POSTROUTING -j MASQUERADE
  4. iptables -t nat -A PREROUTING -p tcp --dport 8080 -j DNAT --to-destination 192.168.10.10:3000
  5. service iptables save
  6. iptables -t nat -nL --line
复制代码



  1. #firewall

  2. firewall-cmd --permanent --zone=public --add-masquerade
  3. firewall-cmd --permanent --zone=public --add-forward-port=proto=8080:proto=tcp:toaddr=192.168.10.10:toport=3000
  4. firewall-cmd --reload
  5. firewall-cmd --zone=public  --list-all
复制代码
推荐
发表于 2020-9-9 14:59:50 | 只看该作者
搭个车。

https://cubepaas.com/?spread=12a4e278d7cb42dc9a23b8dedd79c622pfmdinrw4k
16#
发表于 2020-9-10 13:02:47 | 只看该作者
https://cubepaas.com/?spread=258aae51ce9e46729313105c85bac69bctm4gmfhun
使用邀请码 “a6ff7dc9” 尽快完成注册避免失效。
15#
发表于 2020-9-9 15:57:42 来自手机 | 只看该作者
虽然没有,但也进来学习下
14#
发表于 2020-9-9 15:45:51 | 只看该作者
刚 FRP 成功了,,,开心
13#
发表于 2020-9-9 15:35:27 | 只看该作者
zdszf 发表于 2020-9-9 15:28
何不用heroku或者kintohub呢
https://github.com/mixool/v2ray

heroku在用,高峰期也是炸得不行,CF自选节点。。
12#
 楼主| 发表于 2020-9-9 15:28:25 | 只看该作者
迷路小刀 发表于 2020-9-9 15:22
填了的,估计被撸炸了,有时telnet都不通了,MJJ真的猛。。

何不用heroku或者kintohub呢
https://github.com/mixool/v2ray
11#
发表于 2020-9-9 15:22:50 | 只看该作者
zdszf 发表于 2020-9-9 15:19
伪装域名要填IBM的域名

填了的,估计被撸炸了,有时telnet都不通了,MJJ真的猛。。
10#
 楼主| 发表于 2020-9-9 15:21:33 来自手机 | 只看该作者
Waylon 发表于 2020-9-9 15:14
还是习惯用iptables或者firewall

顶!
我不会用iptables,直接学了nftables的用法。。
9#
 楼主| 发表于 2020-9-9 15:19:08 来自手机 | 只看该作者
迷路小刀 发表于 2020-9-9 15:05
V2连不上ibm,
cat

伪装域名要填IBM的域名
您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|手机版|小黑屋|全球主机交流论坛

GMT+8, 2025-11-12 04:52 , Processed in 0.125340 second(s), 10 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表