Wrong route is published if an incomplete subnet mask is entered into the static route table

book

Article ID: 167661

calendar_today

Updated On:

Products

ProxySG Software - SGOS

Issue/Introduction

When an incomplete subnet mask is entered into the static route table, SG would wrongly interpret the route and publish a wrong route into the routing table. For example, the following static route is entered:

inline static-route-table xxx
192.168.1.0 255.255.255 10.1.1.253
192.168.0.0 255.255.0.0 10.1.1.254
xxx

The subnet mask of the first route should be 255.255.255.0 instead of just 255.255.255.

You will see the following route in the routing table:

Destination        Gateway            Flags    Refs      Use      Netif Expire
192.168.0/16       10.1.1.253         UGS         1        0        0:0 =>
192.168.0/16       10.1.1.254         UGS         1        0        0:0

The first entry above should have the destination 192.168.1/24 instead of 192.168.0/16. The "=>" at the end of the entry means it is a duplicate route (more than one route for same destination).

If we correct the static route the following:

inline static-route-table xxx
192.168.1.0 255.255.255.0 10.1.1.253
192.168.0.0 255.255.0.0 10.1.1.254
xxx

Then the right routing table is published:

Destination        Gateway            Flags    Refs      Use      Netif Expire
192.168.0/16       10.1.1.254         UGS         1        0        0:0
192.168.1          10.1.1.253         UGS         1        0        0:0

 

Resolution

SG cannot interpret incomplete subnet mask. Make sure complete subnet mask is entered into the static route table.