Skip to content

IPv6 地址比较错误 #72

@PQHX-BLUE

Description

@PQHX-BLUE

位置:
bpf/filter/net-filter.bpf.c
描述:
for (int i = mem_sz - 1; i >= 0; i--)
{
if (a[i] != b[i])
{
return a[i] > b[i] ? 1 : -1;
}
}
源码使用的小端序比较大小,IPv6是大端序,应该从i=0开始比较

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions