Classless routing protocols, on the other hand, do advertise the subnet mask.
So as an example, they would advertise network 10.0.0.0/24 or 10.0.0.0/30
They are advertising both the network and the subnet mask
in the routing protocol advertisements
routers are therefore able to see the exact network mask
and do not have to assume what the network mask is
on routing updates received from neighbors
classless routing protocols also support Variable Length Subnet Mask or VLSM
in other words, the mask of interfaces do not have to be the same.
one interface could have a mask of /24
and another interface could have a mask of /20
as an example on serial interfaces or serial links
you may want to use a /30 mask on a loopback interface on a router
you may wanna use a /32 mask and on networks
where hosts reside you may wanna use /24 mask
in other words, on routers, Variable Length Subnet Mask are supported
different interfaces can have different masks.
Classless routing protocols also support manual summarization of routes.
This depends on the routing protocol as an example
OSPF supports summarization on what are called Area Border Routers or ABR's
as well as Autonomous System Border Routers or ASBR's
EIGRP supports summarization on any interface
examples of classless routing protocols include RIP version 2, EIGRP, OSPF and ISIS.