Package Exports
- is-dtls
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (is-dtls) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
is-dtls
Check if a Buffer is a DTLS message. Used for demultiplex packets that are arriving on the same port. Follows RFC7983.
Usage
const dgram = require('dgram')
const is_dtls = require('is-dtls')
const socket = dgram.createSocket('udp4')
socket.on('message', (packet) => {
if (is_dtls(packet)) {
// handle DTLS...
}
})
socket.bind(0)
Related projects
is-stun
- Check if a Buffer is a STUN message.is-turn
- Check if a Buffer is a TURN message.is-rtp
- Check if a Buffer is a RTP/RTCP message.
License
MIT, 2017 (c) Dmitry Tsvettsikh