summaryrefslogtreecommitdiff
path: root/proto/rip/rip.h
diff options
context:
space:
mode:
authorPavel Machek <pavel@ucw.cz>1998-07-28 21:44:11 +0000
committerPavel Machek <pavel@ucw.cz>1998-07-28 21:44:11 +0000
commit279f4c7b7b2ebe13793649f191040042a8c4c014 (patch)
tree613c96e03cbf38287dd72796ad5034cdcb722edb /proto/rip/rip.h
parent48b41d58112737f87f1217414291e61f5430f611 (diff)
Rip now includes code to reply, but it is currently broken.
Diffstat (limited to 'proto/rip/rip.h')
-rw-r--r--proto/rip/rip.h17
1 files changed, 13 insertions, 4 deletions
diff --git a/proto/rip/rip.h b/proto/rip/rip.h
index 8bcd0ce8..3af19eee 100644
--- a/proto/rip/rip.h
+++ b/proto/rip/rip.h
@@ -3,6 +3,10 @@
*/
struct rip_connection {
+ node n;
+
+ int num;
+ struct proto *proto;
ip_addr addr;
struct rip_entry *sendptr;
sock *send;
@@ -10,6 +14,11 @@ struct rip_connection {
struct rip_packet_heading {
u8 command;
+#define RIPCMD_REQUEST 1 /* want info */
+#define RIPCMD_RESPONSE 2 /* responding to request */
+#define RIPCMD_TRACEON 3 /* turn tracing on */
+#define RIPCMD_TRACEOFF 4 /* turn it off */
+#define RIPCMD_MAX 5
u8 version;
#define RIP_V1 1
#define RIP_V2 2
@@ -19,9 +28,9 @@ struct rip_packet_heading {
struct rip_block {
u16 family; /* 0xffff on first message means this is authentication */
u16 tag;
- u32 network;
- u32 netmask;
- u32 nexthop;
+ ip_addr network;
+ ip_addr netmask;
+ ip_addr nexthop;
u32 metric;
};
@@ -30,7 +39,7 @@ struct rip_entry {
ip_addr whotoldme;
ip_addr network;
- ip_addr netmask;
+ int pxlen;
ip_addr nexthop;
int metric;