UDP仅发送设备 [英] UDP send only device

查看:123
本文介绍了UDP仅发送设备的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以使用只传输UDP数据的以太网接口的设备?没有传入,没有握手。我只是想知道它是否可行,而不是它是否可行。我需要一种不会收听任何传入信号的设备,但会不断将其数据发送到网络,或者标记出能够在给定封闭或隔离网络的情况下识别信号源的方式。



我尝试了什么:



此时只是理论上的。我只尝试过思考实验。

解决方案

是的,有可能做到这一点。我实现了类似的东西来监听传入的消息,但很少收到任何消息。偶尔它一次几周都没有收到任何东西,所以它接近你所追求的。


当然。 UDP是无连接的。它并不关心是否有人在听。它只是将数据发送到您告诉它的任何目的地,包括广播地址。没有退回消息告诉发件人目的地不存在或者没有收听您发送到的端口。



目前为止识别发件人时,您可以使用IP数据包中的源地址,或者更好的是,创建自己的应用程序级协议,并在设备发送的数据中发送标识符信息。



您甚至可以通过UDP配置设备,告诉它应该是什么标识符。



这完全取决于你...

Is it possible to have a device with an Ethernet interface that only transmits UDP data? No incoming, no handshaking. I just want to know if it is possible, not if it is advisable. I need a device that will not listen to any incoming signal, but continuously sends it's data out to the network perhaps tagged a way to be able to identify the source given a closed or isolated network.

What I have tried:

Just theoretical at this point. I have only tried thought experiments.

解决方案

Yes, it is possible to do that. I implemented something similar that listens for incoming messages but only rarely receives any. Occasionally it doesn't receive anything for weeks at a time so it is close to what you are after.


Sure. UDP is "connectionless". It doesn't care if anyone is listening. It just sends the data to whatever destination you tell it to, including broadcast addresses. There are no "bounce back" messages that tell the sender the destination doesn't exist or isn't listening on the port you're sending to.

As far as identifying the sender, you could either use the source address in the IP packets, or better yet, create your own application-level protocol and send the identifier information in the data your device is sending.

You could even go so far as to have the device configurable over UDP to tell it what its identifier should be.

It's entirely up to you...


这篇关于UDP仅发送设备的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆