First, I don't have any upstream gateway. Lans Gateways, which are all connected to the Wan, have to take care themselves about routing table. A default routing entry or running RIP protocol would cost a lot of money on a Wan, based on X.25 (about 150 Lans are interconnected).
route add net lan_ip_b wan_ip_b 1
route add net lan_ip_a wan_ip_a 1
is exactly what I did on my lans gateways.
The problem is that Solaris ( 2.3 or 2.5 ) don't keep subnets in routing table
for routes from subnetted B nets to subnetted A nets (and vice versa).
Only routes from a subnetted B net to another one or from a subnetted A net to another one is ok (still via the wan of course).
The only solution I found is to create a logical interface (subnetted A address for B gateways and subnetted B address for A gateways).
I don't understand why Solaris avoids to route on sub-networks for which
you don't have an interface in the same class with the same netmask.