Skip to content

Setting route 0.0.0.0/1 makes the bind_device_by_index_v4 of socket2 unusable #25

@xmh0511

Description

@xmh0511

When setting 0.0.0.0/1, almost traffic are routing to tun, and bind_device_by_index_v4 is used to make the socket binding to the specified network interface such that the traffic of the socket does not pass through the routing table. However, it seems not work when using net-route, the approach does work when using tproxy-config.

The error is

called Result::unwrap() on an Err value: Os { code: 51, kind: NetworkUnreachable, message: "Network is unreachable" }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions