On Sat, 13 Sep 2003, [iso-8859-1] Sörös József wrote:
Hi, Authentication type simple does not work, because bird sends 256 instead of 1 in auth type field. The reason is the wrong byte order. I suggest these corrections in proto/ospf/packet.c to fix this. Best regards: Joseph
Patch added into CVS. It will go to the next release. Thank you very much! Ondrej Filip
# diff -u ../../../tmp/bird-1.0.7/proto/ospf/packet.c packet.c --- ../../../tmp/bird-1.0.7/proto/ospf/packet.c Thu Aug 14 10:13:14 2003 +++ packet.c Fri Sep 12 23:50:45 2003 @@ -32,7 +32,7 @@ ospf_tx_authenticate(struct ospf_iface *ifa, struct ospf_packet *pkt) { int i; - pkt->autype=ifa->autype; + pkt->autype=htons(ifa->autype); memcpy(pkt->authetication, ifa->aukey, 8); return; } @@ -41,7 +41,7 @@ ospf_rx_authenticate(struct ospf_iface *ifa, struct ospf_packet *pkt) { int i; - if(pkt->autype!=ifa->autype) return 0; + if(pkt->autype!=htons(ifa->autype)) return 0; if(ifa->autype==AU_NONE) return 1; if(ifa->autype==AU_SIMPLE) {