Is there any way to specify my outgoing port when connecting to a remote socket with net socket, rather than the random port defined by the OS.
const host = "127.0.0.1";
const port = 5000;
const client = net.createConnection(port, host, () => {
console.log("Connected");
});
To connect to this server, let’s say I want to also use 5000 as my outgoing port too…