/* Copyright 1986 by the Massachusetts Institute of Technology */


/* Hand initialized network interface IN address tables. Also various
 * other externals that can be set here.
 */

/*
 *------------------------------------------------------------------
 *
 * $Source: /u1/jis/gw/cgw/conf/mitgw/RCS/incnf.mitgw.c,v $
 * $Revision: 1.21 $
 * $Date: 89/05/03 20:10:27 $
 * $State: Exp $
 * $Author: jis $
 * $Locker:  $
 *
 * $Log:	incnf.mitgw.c,v $
 * Revision 1.21  89/05/03  20:10:27  jis
 * Add Thinking Machines Inc.
 * 
 * Revision 1.20  89/04/09  23:33:23  jon
 * add BMILMTR since BBN doesn't seem reachable
 * 
 * Revision 1.19  89/04/09  23:09:42  jon
 * switch from LSI11 EGP peers to the new Butterflies
 * 
 * Revision 1.18  89/03/16  21:05:59  jon
 * try advertising seconardy harvard nets at metric 2 instead of metric
 * 9
 * 
 * Revision 1.17  89/03/06  00:41:28  jon
 * add cayman
 * 
 * Revision 1.16  89/02/22  22:47:13  jon
 * change number of metrics
 * 
 * Revision 1.15  89/02/22  22:39:59  jon
 * add harvard's old nets at metric 8!
 * 
 * Revision 1.14  89/02/18  16:07:58  jon
 * add egp for ailab, bu, and nearnet backbone
 * 
 * Revision 1.13  89/01/28  18:08:24  jon
 * stop chaining the addresses
 * and fix the subnet mask for the 18.26 address
 * 
 * Revision 1.12  89/01/28  16:23:25  jon
 * give the ethernet interface an address on 18.26
 * 
 * Revision 1.11  89/01/10  17:02:46  jon
 * try harvard at metric of 2
 * 
 * Revision 1.10  89/01/10  16:15:15  jon
 * make harvard metric be 3 not 4 (cornell is adv at 4)
 * 
 * Revision 1.9  89/01/10  16:09:18  jon
 * add Harvard EGP backup with metric of four
 * 
 * Revision 1.8  88/06/08  23:50:01  jon
 * Advertise Apollo (129.248)
 * 
 * Revision 1.7  88/05/30  21:21:50  jon
 * Add Gold Hill and set the BBN peer as primary ...
 * 
 * Revision 1.6  88/05/05  00:06:27  jon
 * Advertise Proteon and Symbolics at metric 2 instead of metric 1.
 * 
 * Revision 1.5  87/12/11  16:35:44  jon
 * Type fix in rcs header
 * 
 * Revision 1.4  87/12/11  16:32:04  jon
 * Advertise ftp net (128.127) via egp.
 * 
 *------------------------------------------------------------------
 */

#ifndef lint
static char *rcsid_mit_gw_c = "$Header: incnf.mitgw.c,v 1.21 89/05/03 20:10:27 jis Exp $";
#endif	lint

#include <types.h>
#include <sys.h>
#include <gw/src/const.h>
#include <gw/src/defs.h>
#include <gw/src/net.h>
#include <gw/in/in.h>
#include <gw/in/egp.h>

#include "netcnf.h"


/* Network interface address tables. These define the relationship
 * between network interfaces and their IN addresses. The table comes
 * in two parts; one is a table indexed by interface number that
 * lists a chain of IN addresses for that interface number, the first
 * being the primary, and the second is the interface address chains.
 * If an entry in the first table is NULL, that net has no IN address.
 */

#define	NINADDR	3

inia	iniatbl[NINADDR] =

{ { { 10, 0, 0, 77 }, NULL, { 0, 0, 0, 0 }, IF_RIP_IGN },
  { { 18, 10, 0, 4 }, NULL, { 255, 255, 0, 0 }, IF_RIP_IGN },
  { { 18, 26, 0, 138 }, NULL, { 255, 255, 0, 0 }, IF_RIP_IGN },
};

inia	*iniatlst[NNETS] =

{	&iniatbl[0],
	&iniatbl[1],
	&iniatbl[2],
};

/*
 * EGP Configuration info.
 */
unsw mysystem = 3;

/* BBN recommends just BMILBBN and BMILMTR, but they're on the same PSN, 
   so I'm also going to try one other east cost peer */

#define NNEIGH	3
unsw nneigh = NNEIGH;
egpng	egpngh[NNEIGH];
struct egpnn	egpnn[NNEIGH] =	{
    { { 10, 3, 0,   5 }, COREGW }, /* BMILBBN */
    { { 10, 6, 0,  20 }, COREGW }, /* BMILDCEC */
    { { 10, 3, 0, 111 }, COREGW }, /* BMILMTR */ 
};

/* number of different metrics */
#define NMETRICS 4
unsw nmetrics = NMETRICS;

struct egpnetinfo egp_net_info [NMETRICS] = {
  0, /* metric */
  1, /* number of networks */

  1, /* metric */
  6, /* number of networks */
  
  2, /* metric */
  6, /* number of networks */
  };

struct egpnet egp_nets [] = {
  /* 0 hops -- Us */
  18, 0, 0, 0,
  /* 1 hop  -- Primary connections */
  128, 127, 0, 0,    /* FTP Software */
  128, 168, 0, 0,    /* Gold Hill */
  129, 248, 0, 0,    /* Apollo Computer */
  128,  52, 0, 0,    /* MIT AI Lab */
  131, 192, 0, 0,    /* NearNet Backbone */
  192,  31, 222, 0,  /* Cayman Systems */
  192, 5, 104, 0,    /* Thinking Machines Inc. */
  131, 239, 0, 0,    /* Thinking Machines Inc. */
  /* 2 hops -- Backup connections */
  128, 185, 0, 0,    /* Proteon */
  128,  81, 0, 0,    /* Symbolics */
  128, 103, 0, 0,    /* Harvard (main campus) */
  128, 197, 0, 0,    /* Boston University */ 
  192, 31, 246, 0,   /* Harvard */
  192,  5, 66, 0,    /* Harvard */
  };

/* Various externals that can be set at compile time from info in
 * this file. Do not touch!
 */

unsb	ninaddr = NINADDR;		/* Number of IN net addresses */
unsw	inovfin[NNETS];			/* IP queue overflow discards */
