p = &rn->p;
- /* "network" configuration display. */
- if (bgp_option_check(BGP_OPT_CONFIG_CISCO) && afi == AFI_IP) {
- uint32_t destination;
- struct in_addr netmask;
-
- destination = ntohl(p->u.prefix4.s_addr);
- masklen2ip(p->prefixlen, &netmask);
- vty_out(vty, " network %s",
- inet_ntop(p->family, &p->u.prefix, buf,
- SU_ADDRSTRLEN));
-
- if ((IN_CLASSC(destination) && p->prefixlen == 24)
- || (IN_CLASSB(destination) && p->prefixlen == 16)
- || (IN_CLASSA(destination) && p->prefixlen == 8)
- || p->u.prefix4.s_addr == 0) {
- /* Natural mask is not display. */
- } else
- vty_out(vty, " mask %s", inet_ntoa(netmask));
- } else {
- vty_out(vty, " network %s/%d",
- inet_ntop(p->family, &p->u.prefix, buf,
- SU_ADDRSTRLEN),
- p->prefixlen);
- }
+ vty_out(vty, " network %s/%d",
+ inet_ntop(p->family, &p->u.prefix, buf, SU_ADDRSTRLEN),
+ p->prefixlen);
if (bgp_static->label_index != BGP_INVALID_LABEL_INDEX)
vty_out(vty, " label-index %u",
p = &rn->p;
- if (bgp_option_check(BGP_OPT_CONFIG_CISCO) && afi == AFI_IP) {
- struct in_addr netmask;
-
- masklen2ip(p->prefixlen, &netmask);
- vty_out(vty, " aggregate-address %s %s",
- inet_ntop(p->family, &p->u.prefix, buf,
- SU_ADDRSTRLEN),
- inet_ntoa(netmask));
- } else {
- vty_out(vty, " aggregate-address %s/%d",
- inet_ntop(p->family, &p->u.prefix, buf,
- SU_ADDRSTRLEN),
- p->prefixlen);
- }
+ vty_out(vty, " aggregate-address %s/%d",
+ inet_ntop(p->family, &p->u.prefix, buf, SU_ADDRSTRLEN),
+ p->prefixlen);
if (bgp_aggregate->as_set)
vty_out(vty, " as-set");
{
switch (flag) {
case BGP_OPT_NO_FIB:
- case BGP_OPT_CONFIG_CISCO:
case BGP_OPT_NO_LISTEN:
case BGP_OPT_NO_ZEBRA:
SET_FLAG(bm->options, flag);
/* Fall through. */
case BGP_OPT_NO_ZEBRA:
case BGP_OPT_NO_FIB:
- case BGP_OPT_CONFIG_CISCO:
UNSET_FLAG(bm->options, flag);
break;
default:
/* Set default flags. */
FOREACH_AFI_SAFI (afi, safi) {
- if (!bgp_option_check(BGP_OPT_CONFIG_CISCO)) {
- SET_FLAG(peer->af_flags[afi][safi],
- PEER_FLAG_SEND_COMMUNITY);
- SET_FLAG(peer->af_flags[afi][safi],
- PEER_FLAG_SEND_EXT_COMMUNITY);
- SET_FLAG(peer->af_flags[afi][safi],
- PEER_FLAG_SEND_LARGE_COMMUNITY);
-
- SET_FLAG(peer->af_flags_invert[afi][safi],
- PEER_FLAG_SEND_COMMUNITY);
- SET_FLAG(peer->af_flags_invert[afi][safi],
- PEER_FLAG_SEND_EXT_COMMUNITY);
- SET_FLAG(peer->af_flags_invert[afi][safi],
- PEER_FLAG_SEND_LARGE_COMMUNITY);
- }
+ SET_FLAG(peer->af_flags[afi][safi], PEER_FLAG_SEND_COMMUNITY);
+ SET_FLAG(peer->af_flags[afi][safi],
+ PEER_FLAG_SEND_EXT_COMMUNITY);
+ SET_FLAG(peer->af_flags[afi][safi],
+ PEER_FLAG_SEND_LARGE_COMMUNITY);
+
+ SET_FLAG(peer->af_flags_invert[afi][safi],
+ PEER_FLAG_SEND_COMMUNITY);
+ SET_FLAG(peer->af_flags_invert[afi][safi],
+ PEER_FLAG_SEND_EXT_COMMUNITY);
+ SET_FLAG(peer->af_flags_invert[afi][safi],
+ PEER_FLAG_SEND_LARGE_COMMUNITY);
peer->addpath_type[afi][safi] = BGP_ADDPATH_NONE;
}
flag_slcomm = peergroup_af_flag_check(peer, afi, safi,
PEER_FLAG_SEND_LARGE_COMMUNITY);
- if (!bgp_option_check(BGP_OPT_CONFIG_CISCO)) {
- if (flag_scomm && flag_secomm && flag_slcomm) {
- vty_out(vty, " no neighbor %s send-community all\n",
- addr);
- } else {
- if (flag_scomm)
- vty_out(vty,
- " no neighbor %s send-community\n",
- addr);
- if (flag_secomm)
- vty_out(vty,
- " no neighbor %s send-community extended\n",
- addr);
-
- if (flag_slcomm)
- vty_out(vty,
- " no neighbor %s send-community large\n",
- addr);
- }
+ if (flag_scomm && flag_secomm && flag_slcomm) {
+ vty_out(vty, " no neighbor %s send-community all\n", addr);
} else {
- if (flag_scomm && flag_secomm && flag_slcomm) {
- vty_out(vty, " neighbor %s send-community all\n",
+ if (flag_scomm)
+ vty_out(vty, " no neighbor %s send-community\n", addr);
+ if (flag_secomm)
+ vty_out(vty,
+ " no neighbor %s send-community extended\n",
addr);
- } else if (flag_scomm && flag_secomm) {
- vty_out(vty, " neighbor %s send-community both\n",
+
+ if (flag_slcomm)
+ vty_out(vty, " no neighbor %s send-community large\n",
addr);
- } else {
- if (flag_scomm)
- vty_out(vty, " neighbor %s send-community\n",
- addr);
- if (flag_secomm)
- vty_out(vty,
- " neighbor %s send-community extended\n",
- addr);
- if (flag_slcomm)
- vty_out(vty,
- " neighbor %s send-community large\n",
- addr);
- }
}
/* Default information */
struct listnode *node, *nnode;
struct listnode *mnode, *mnnode;
- /* BGP Config type. */
- if (bgp_option_check(BGP_OPT_CONFIG_CISCO)) {
- vty_out(vty, "bgp config-type cisco\n");
- write++;
- }
-
if (bm->rmap_update_timer != RMAP_DEFAULT_UPDATE_TIMER)
vty_out(vty, "bgp route-map delay-timer %u\n",
bm->rmap_update_timer);
? "view" : "vrf", bgp->name);
vty_out(vty, "\n");
- /* No Synchronization */
- if (bgp_option_check(BGP_OPT_CONFIG_CISCO))
- vty_out(vty, " no synchronization\n");
-
/* BGP fast-external-failover. */
if (CHECK_FLAG(bgp->flags, BGP_FLAG_NO_FAST_EXT_FAILOVER))
vty_out(vty, " no bgp fast-external-failover\n");
if (bgp->autoshutdown)
vty_out(vty, " bgp default shutdown\n");
- /* No auto-summary */
- if (bgp_option_check(BGP_OPT_CONFIG_CISCO))
- vty_out(vty, " no auto-summary\n");
-
/* IPv4 unicast configuration. */
bgp_config_write_family(vty, bgp, AFI_IP, SAFI_UNICAST);