lucktu / n2n

Provide the binaries(edges and supernodes) of n2n that I collected
GNU General Public License v3.0
551 stars 144 forks source link

似乎不支持 username / password 方式进行身份验证 #16

Closed Trytoz closed 2 years ago

Trytoz commented 2 years ago

昨天在 centos7.6 上使用 官方代码(稳定版)进行编译安装后进行测试是可用的 我将配置文件拷贝至本地进行测试

使用版本 supernode Welcome to n2n v.3.1.1-16-g23e168b-dirty-r1200 x64_static for Windows Built on May 8 2022 23:43:56

运行后输出以下内容后程序退出

01/Jun/2022 14:07:36 [supernode.c:268] the network range for community ip address service is '172.16.0.0...172.32.255.0/24'
01/Jun/2022 14:07:36 [sn_utils.c:395] added allowed community 'mynetwork' [total: 1]
01/Jun/2022 14:07:36 [sn_utils.c:1296] assigned sub-network 172.26.148.0/24 to community 'mynetwork'
01/Jun/2022 14:07:36 [sn_utils.c:395] added allowed community 'netleo' [total: 2]
01/Jun/2022 14:07:36 [sn_utils.c:1296] assigned sub-network 172.26.204.0/24 to community 'netleo'
01/Jun/2022 14:07:36 [sn_utils.c:340] added user 'logan' with public key 'nHWum+r42k1qDXdIeH-WFKeylK5UyLStRzxofRNAgpG' to community 'netleo'
01/Jun/2022 14:07:36 [sn_utils.c:370] added regular expression for allowed communities 'ntop[0-1][0-9]'
01/Jun/2022 14:07:36 [sn_utils.c:440] loaded 2 fixed-name communities from supernode_list.conf
01/Jun/2022 14:07:36 [sn_utils.c:443] loaded 1 regular expressions for community name matching from supernode_list.conf
01/Jun/2022 14:07:36 [sn_utils.c:115] started shared secrets calculation for edge authentication
01/Jun/2022 14:07:36 [sn_utils.c:131] calculated shared secrets for edge authentication
01/Jun/2022 14:07:36 [sn_utils.c:140] calculating dynamic keys

netstat 与 任务管理器均未检测到程序继续运行 我使用 edge > 连接至linux上运行的服务端同样也无法连接 以下是我所使用的配置 supernode.conf

-p 7655
-a 172.16.0.0-172.32.255.0/24
-v
-F N2N_NN_A
-c supernode_list.conf

supernode_list.conf

# ---------------------------
#
#      these could either be fixed-name communities such as the following lines ...
#
mynetwork
netleo
* logan nHWum+r42k1qDXdIeH-WFKeylK5UyLStRzxofRNAgpG
#
#      ... or regular expressions that a community name must fully match
#      such as ntop[0-1][0-9] for communities from "ntop00" through "ntop19"
# 
ntop[0-1][0-9]

edge.conf

-c netleo
-l  ###:7655
-I logan
-J 007
-A5
-k mySecretKey
-P Y93Jn9AONIZWaeqekna2CJIOLZEejhU29dXFeeQLQJC
-vvvvv
Trytoz commented 2 years ago

@lucktu

lucktu commented 2 years ago

抱歉,对于这样的加密功能,我也没有经验。 建议到官网用英文讨论,那里肯定有人懂的。

Trytoz commented 2 years ago

抱歉,对于这样的加密功能,我也没有经验。 建议到官网用英文讨论,那里肯定有人懂的。

并不是说这个功能的问题,我的意思是 这个功能在centos7上使用源码编译后 使用username/password功能是正常的。也就是说官方是支持此功能的。

但是我使用您编译的windows版本以相同配置运行时异常退出。想问问有没有什么头绪。因为我对windows版本的编译一窍不通。但是我个人看了日志后感觉是无法进行keygen运算 也就是可能官方仓库 tools/n2n-keygen中的部分加密算法运算并没有被打包到windows版本中导致不能正确运行。

lucktu commented 2 years ago

不好意思,前几天看到忙去了,一晃就几天过去了。

这里的程序绝大多数都不是我编译的,是黑夜编译的,你看文件名末尾有标记。

可以进他的QQ群(256572040)与之交流。