udp-portal
tunnel udp traffic over tcp
Last updated 6 years ago by shtylman .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install udp-portal 
SYNC missed versions from official npm registry.

udp-portal

tunnel UDP traffic over TCP

CLI

udp-portal server udp://239.5.5.5:4005 tcp://localhost:8000
udp-portal client tcp://hostname:8080 udp://239.5.5.5:4005

API

Server

var portal = require('udp-portal');

var server = portal.server('udp://239.5.5.5:4005');
server.listen(function() {
    server.address().port;
});

Client

The client API is can connect to the udp-portal server as well as replay udp packets.

To just connect and listen for forwarded udp messages.

var client = portal.client('tcp://localhost:port');
client.on('message', function(msg) {
    client.close();
});

Alternatively, you can have the client replay messages back out to a UDP address/port.

var client = portal.client('tcp://localhost:port', 'udp://239.6.6.6:4005');

License

MIT

Current Tags

  • 0.1.0                                ...           latest (6 years ago)

1 Versions

  • 0.1.0                                ...           6 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (0)
None
Dev Dependencies (1)
Dependents (2)

Copyright 2014 - 2016 © taobao.org |