Example: Configuring Spoke 2 in a Hub-and-Spoke VPN (CLI)

The following example describes how to configure spoke 2 in a hub-and-spoke VPN. The hub has two spokes (First and Third) and the configuration is for route-based VPNs. Follow the same process to configure spoke Third as you did to configure spoke First:

  1. Configure Phase 1 of the IPsec tunnel:

    1. Configure IKE Phase 1 proposals:
      user@host# set security ike proposal ike_prop authentication-method pre-shared-keysuser@host# set security ike proposal ike_prop dh-group group2user@host# set security ike proposal ike_prop authentication-algorithm md5user@host# set security ike proposal ike_prop encryption-algorithm 3des-cbc
    2. Configure IKE policies (and reference the proposals):
      user@host# set security ike policy ike_pol mode mainuser@host# set security ike policy ike_pol proposals ike_propuser@host# set security ike policy ike_pol pre-shared-key ascii-text "$9$JrUi.QF/0BEP5BEcyW8ZUj"user@host# set security ike gateway gate ike-policy ike_pol
    3. Configure IKE gateway (and reference the policy):
      user@host# set security ike gateway third address 2.2.2.2user@host# set security ike gateway third external-interface ge-0/0/3.0
  2. Configure Phase 2 of the IPsec tunnel:

    1. Configure Phase 2 proposals:
      user@host# set security ipsec proposal ipsec_prop protocol espuser@host# set security ipsec proposal ipsec_prop authentication-algorithm hmac-md5-96user@host# set security ipsec proposal ipsec_prop encryption-algorithm 3des-cbc
    2. Configure policies (and reference proposals):
      user@host# set security ipsec policy ipsec_pol perfect-forward-secrecy keys group1user@host# set security ipsec policy ipsec_pol proposals ipsec_prop
    3. Configure AutoKey IKE (and reference the policy and gateway):
      user@host# set security ipsec vpn first_vpn bind-interface st0.0user@host# set security ipsec vpn first_vpn ike gateway gateuser@host# set security ipsec vpn first_vpn ike ipsec-policy ipsec_pol
  3. Configure the security policy:
    user@host# set security policies default-policy permit-all
  4. Configure routing options:
    user@host# set routing-options static route3.1.1.0/24 next-hop 7.7.7.1

Related Topics