View previous topic :: View next topic |
Author |
Message |
Arera
Joined: 23 Sep 2007 Posts: 386 Location: Wuppertal, Germany
|
Posted: Fri Mar 08, 2013 12:35 pm Post subject: check / Scan a port |
|
|
Hi,
I'm using the WIZ820IO to send messages to a couple of destinations, via UDP and as TCP client.
By socketconnecting to the TCP server, I can find out if the server accepts the message by checking the result of socketconnect.
But what about UDP?
I can ping the destination IP, but that still does not say if the port is open.
Is there way to determin, if destination-port is open? |
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Fri Mar 08, 2013 2:22 pm Post subject: |
|
|
UDP is a connectionless protocol. So you never know if your data arrives. Only if you get an answer. But then you are making some kind of protocol.
UDP is good for raw data since it has less overhead. But for own development i would advise to use TCP. _________________ Mark |
|
Back to top |
|
|
MAK3
Joined: 24 Sep 2010 Posts: 449 Location: Germany
|
|
Back to top |
|
|
Arera
Joined: 23 Sep 2007 Posts: 386 Location: Wuppertal, Germany
|
Posted: Sat Mar 09, 2013 10:50 am Post subject: |
|
|
I m bound to udp, because it is standard for professional syslogging software.
I am not a network expert, but there are programs available to check open ports on a pc (portscanners). My idea is to build a portscanner to find out, if the desination port is open.
At this point my knowledge ends, so I hoped to find some ideas here!
Ben, evert and many others seem to know quite everything. Go ahrad, think!!!
|
|
Back to top |
|
|
MAK3
Joined: 24 Sep 2010 Posts: 449 Location: Germany
|
Posted: Sat Mar 09, 2013 11:36 am Post subject: |
|
|
Hi,
Quote: | I m bound to udp, because it is standard for professional syslogging software. |
Then you need to dig into the datasheet of W5200 and search for IPRAW and ICMP.
Ping for example is also ICMP: "The ‘ping’ of ICMP or IGMP v1/v2 is already included in W5200 by hardware logic."
See also: http://en.wikipedia.org/wiki/Port_scanner#UDP_scanning
MAK3 |
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Sat Mar 09, 2013 10:23 pm Post subject: |
|
|
Thanks for your tutorials MAK3, i recently got a wiz820 . So it is good to have this info clearly presented.
About UDP : ping is essentially a protocol too : you send some data and when it is received by the host, it will send some data back.
But most servers have ports blocked or a stealth mode where they simply do not answer.
So my point is still that you can not know if a server is active, listening or whatever unless there is some protocol that uses UDP.
You should check the protocol for your equipment. _________________ Mark |
|
Back to top |
|
|
six1
Joined: 27 Feb 2009 Posts: 553
|
Posted: Sun Mar 10, 2013 10:42 am Post subject: |
|
|
not possible to scan Ports on UDP if you don't know exactly, what the Server does! (if you know details from how the server works, there is a little chance!)
http://de.wikipedia.org/wiki/Portscanner
UDP Scan
Ein direkter Scan von UDP Ports ist nicht möglich, da das Protokoll verbindungslos arbeitet. _________________ For technical reasons, the signature is on the back of this message. |
|
Back to top |
|
|
|