You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For VPN/proxy-like programs, it's useful to listen to all traffic on all ports. For example, see this library. I'm currently using it, but it would be nice to be able to use smoltcp for this use case as well.
How this would be implemented:
For TCP sockets, very little has to change - port 0 should listen on all ports instead of being forbidden (the address tuple will be changed after accepting a packet so this is fine), the state machine is obviously socket-specific so the user will be responsible for creating additional sockets as necessary.
For UDP sockets, it's somewhat harder as the implementation is very tied to being available only for a single port right now. Nonetheless, even just implementing sockets that listen for any traffic, then bind to the port where traffic arrived would probably be helpful. Alternatively, new code for wildcard UDP sockets with recv_to and send_from functions can be added, as UDP is a relatively simple protocol.
For other sockets, nothing needs to be done as they are either port-specific or port-agnostic
The text was updated successfully, but these errors were encountered:
@chayleaf: I've created a basic TCP/IP stack for Narrowlink, currently in a somewhat unstable state but functioning adequately. I invite you to review it and contribute if you're interested until this issue gets merged. https://github.com/narrowlink/ipstack
For VPN/proxy-like programs, it's useful to listen to all traffic on all ports. For example, see this library. I'm currently using it, but it would be nice to be able to use smoltcp for this use case as well.
How this would be implemented:
recv_to
andsend_from
functions can be added, as UDP is a relatively simple protocol.The text was updated successfully, but these errors were encountered: