PDA

View Full Version : Reading all UDP packets



moron
21st May 2008, 17:11
Is it possible to read UDP packets sent to all ports?

I seem to be able to get something read while the QUdpSocket is binded on some port but this blocks the port from other programs. I'm trying to achieve some sort of "forwarder" that reads certain UDP packets with right port addresses and forwards them over internet.

Is this possible with Qt4(.4)?

jacek
26th May 2008, 02:58
It's not a limitation of Qt, but the way sockets work. You will have to plug into the kernel or use raw sockets to achieve this.

moron
27th May 2008, 11:06
If I have to use raw sockets and Qt doesn't support raw sockets then it is the limitation of Qt.

jacek
27th May 2008, 15:51
Yes, you can say it this way, but all UDP socket implementations are limited this way then.