Sponsored Content
Special Forums IP Networking Problem Receiving the first OSPF packet Post 302239596 by cosmic_egg on Wednesday 24th of September 2008 04:53:04 AM
Old 09-24-2008
Thanks for the reply and sorry for late reply. but I think that problem is not understood correctly.
I will try more explanation.
This is what I do. I do not interact with a an OSPF client as yet.
I am trying to develop code which could just send and receive OSPF packet.

Scenario1:
PC1

1) send any ospf packet(need not be an Hello packet) to PC2.
and wait for a OSPF packet.

PC2

2) See in Ethereal packet sniffer the packet

PC2

3) Send any OSPF packet to PC1.

PC1

4) My application is able to receive the OSPF packet. and also can see the packet in the ethereal packet sniffer

The above scenario works as expected but when
scenario2.

PC1

1) Wait for any OSPF packet(Application has not sent an OSPF packet yet)

PC2

2) Send an OSPF packet to PC1

PC1

3) Can see the packet in ethereal packet sniffer but my application times out waiting on the raw socket(Not received the data).

Why in the second scenario would my application not get the data from the kernal/os?

Well for fimblo's question

1) What happens when you send yourself a hello packet? Have you tried sending a HELLO packet from another client? (zebra, cisco, etc).

Ans. I just receive and ICMP message (Destination Unreacable | Protocol Unreachable). As I do not have a OSPF client on the other machine.
However this gives me an idea of going through zebra code. and figuring out how are they able to receive the packets.
I will also try doing as suggested in coming days. as that is my next step.

2) Are you listening on 224.0.0.5? or 224.0.0.6?
If the IP next-header field set correctly? (89)

Ans. I was just listening on the raw socket that I used to send and receive data in scenario 1.

Please Forgive me any inconsistencies I am just an amateur programmer and new to discussion forums.
 

9 More Discussions You Might Find Interesting

1. Ubuntu

packet inconsistency problem

Hello everyone, I was trying to install db2 on Ubuntu, but got messed up with manual installation and Synaptic. At the moment, I find myself with a filesystem where DB2 is NOT installed ( I removed it with a sudo rm :o ) and with Synaptic still flagging db2exc as installed. The problem is that... (1 Reply)
Discussion started by: clalfa
1 Replies

2. IP Networking

Importance of LS length in DB exchange start packet (OSPF protocol)?

Is there any importance of LS length in DB exchange packet of OSPF protocol as its should be always be 20 bytes. Is this length to be ignored (2 Replies)
Discussion started by: cosmic_egg
2 Replies

3. Programming

problem receiving data from TCP socket

Hi all, I'm writing a socket program which sends a structure from one machine to another. When I run my client first time it runs well, however after the first time I couldn't receive all the data inside the structure (it is like, half of the array is received and the other half is not set). I... (1 Reply)
Discussion started by: SaTYR
1 Replies

4. IP Networking

packet loss problem

I have 4 network ports on our T5240 sun server. all but 1 gives packet losses (nxge1) nxge0 gives on average 50% packet loss, very bad. nxge2 gives on average 1-2% packet loss. nxge3 gives on average 20% packet loss. Is there a tool or something to help me find the problem? (11 Replies)
Discussion started by: photon
11 Replies

5. Programming

Receiving broadcast packets using packet socket

Hello I try to send DHCP RENEW packets to the network and receive the responses. I broadcast the packet and I can see that it's successfully sent using Wireshark. But I have difficulties receiving the responses.I use packet sockets to catch the packets. I can see that there are responses to my... (0 Replies)
Discussion started by: xyzt
0 Replies

6. UNIX for Dummies Questions & Answers

Problem when I try to install a wireshark packet

Hi Gurus of UNIX, I has a problem when I try to install a packet in my virtual box. (I install solaris in it) Any want can help whith it: The problem is the following # pkgadd -d wireshark-1.2.10-sol10-x86-local The following packages are available: 1 SMCwires wireshark ... (5 Replies)
Discussion started by: andresguillen
5 Replies

7. Programming

Receiving JPEG packet from camera

I am trying to receive a packet of data as bytes in C, but the picture is getting messed up. I am using fwrite to append bytes to jpg file, but the append or write does not seem to be appending jpg correctly. Packet 1 data comes in append to file Packet 2 data comes in append to file ...... (12 Replies)
Discussion started by: photon
12 Replies

8. AIX

Packet loss coming with big packet size ping

(5 Replies)
Discussion started by: Vishal_dba
5 Replies

9. Android

Nexus 7 Bluetooth receiving problem

I have three devices of which one is the Nexus 7. When this detects incoming files from either of the two others, it comes to life and I check that it is paired and connected, but the accept or reject file dialogue does not APPEAR. I have three devices of which one is the Nexus 7. When this ... (0 Replies)
Discussion started by: Royalist
0 Replies
ldns(3) 						     Library Functions Manual							   ldns(3)

NAME
ldns_pkt_edns, ldns_pkt_edns_udp_size, ldns_pkt_edns_extended_rcode, ldns_pkt_edns_version, ldns_pkt_edns_z, ldns_pkt_edns_data, ldns_pkt_set_edns_udp_size, ldns_pkt_set_edns_extended_rcode, ldns_pkt_set_edns_version, ldns_pkt_set_edns_z, ldns_pkt_set_edns_data- SYNOPSIS
#include <stdint.h> #include <stdbool.h> #include <ldns/ldns.h> bool ldns_pkt_edns(const ldns_pkt *packet); uint16_t ldns_pkt_edns_udp_size(const ldns_pkt *packet); uint8_t ldns_pkt_edns_extended_rcode(const ldns_pkt *packet); uint8_t ldns_pkt_edns_version(const ldns_pkt *packet); uint16_t ldns_pkt_edns_z(const ldns_pkt *packet); ldns_rdf* ldns_pkt_edns_data(const ldns_pkt *packet); void ldns_pkt_set_edns_udp_size(ldns_pkt *packet, uint16_t s); void ldns_pkt_set_edns_extended_rcode(ldns_pkt *packet, uint8_t c); void ldns_pkt_set_edns_version(ldns_pkt *packet, uint8_t v); void ldns_pkt_set_edns_z(ldns_pkt *packet, uint16_t z); void ldns_pkt_set_edns_data(ldns_pkt *packet, ldns_rdf *data); DESCRIPTION
ldns_pkt_edns() returns true if this packet needs and EDNS rr to be sent. At the moment the only reason is an expected packet size larger than 512 bytes, but for instance dnssec would be a good reason too. packet: the packet to check Returns true if packet needs edns rr ldns_pkt_edns_udp_size() return the packet's edns udp size packet: the packet Returns the size ldns_pkt_edns_extended_rcode() return the packet's edns extended rcode packet: the packet Returns the rcode ldns_pkt_edns_version() return the packet's edns version packet: the packet Returns the version ldns_pkt_edns_z() return the packet's edns z value packet: the packet Returns the z value ldns_pkt_edns_data() return the packet's edns data packet: the packet Returns the data ldns_pkt_set_edns_udp_size() Set the packet's edns udp size packet: the packet s: the size ldns_pkt_set_edns_extended_rcode() Set the packet's edns extended rcode packet: the packet c: the code ldns_pkt_set_edns_version() Set the packet's edns version packet: the packet v: the version ldns_pkt_set_edns_z() Set the packet's edns z value packet: the packet z: the value ldns_pkt_set_edns_data() Set the packet's edns data packet: the packet data: the data AUTHOR
The ldns team at NLnet Labs. Which consists out of Jelte Jansen and Miek Gieben. REPORTING BUGS
Please report bugs to ldns-team@nlnetlabs.nl or in our bugzilla at http://www.nlnetlabs.nl/bugs/index.html COPYRIGHT
Copyright (c) 2004 - 2006 NLnet Labs. Licensed under the BSD License. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. SEE ALSO
ldns_pkt. And perldoc Net::DNS, RFC1034, RFC1035, RFC4033, RFC4034 and RFC4035. REMARKS
This manpage was automaticly generated from the ldns source code by use of Doxygen and some perl. 30 May 2006 ldns(3)
All times are GMT -4. The time now is 04:04 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy