secretflow/psi

[Bug]: 求交时指定自己的rank为rank0在psi.bucket_psi求交时却报成了mine=target_rank=18446744073709551615

Closed this issue · 3 comments

Issue Type

Performance

Modules Involved

PSI

Have you reproduced the bug with SPU HEAD?

Yes

Have you searched existing issues?

Yes

SPU Version

0.3.3b0

OS Platform and Distribution

Linux Ubuntu20.04

Python Version

3.8

Compiler Version

No response

Current Behavior?

desc.add_party("rank0", "0.0.0.0:7302")
用ECDH_PSI_2PC和CURVE_25519进行求交时报错,rank变成了18446744073709551615
image

Standalone code to reproduce the issue

rank = 0 if self.model_param.rank0_owner == "local" else 1
        if rank:
            desc.add_party(f"rank{rank ^ 1}", self.remote_address)  # 对方的地址
            desc.add_party(f"rank{rank}", self.local_address)  # 自己的地址
        else:
            desc.add_party(f"rank{rank}", self.local_address)  # 自己的地址
            desc.add_party(f"rank{rank ^ 1}", self.remote_address)  # 对方的地址

Relevant log output

No response

参与求交的另外一个节点也是相同的报错
image

参与求交的另外一个节点也是相同的报错 image

打印错误,这个地方代码内部使用了size_t 类型的最大值来表示broadCast,也就是两方都接收结果,但是打日志的时候使用了这个字面值而没有做转换,造成了歧义,将会在下个版本修复。

Stale issue message. Please comment to remove stale tag. Otherwise this issue will be closed soon.