- play_arrow Overview
- Understanding the Common Criteria Evaluated Configuration
- Understanding Junos OS in FIPS Mode of Operation
- Understanding FIPS Mode of Operation Terminology and Supported Cryptographic Algorithms
- Identifying Secure Product Delivery
- Applying Tamper-Evident Seals to the Cryptographic Module
- Understanding Management Interfaces
- play_arrow Configuring Roles and Authentication Methods
- Understanding Roles and Services for Junos OS in FIPS Mode of Operation
- Understanding Services for Junos OS in FIPS Mode of Operation
- Downloading Software Packages from Juniper Networks
- Installing Junos Software Packages
- Understanding Zeroization to Clear System Data for FIPS Mode of Operation
- Loading Firmware on the Device
- How to Enable and Configure Junos OS in FIPS Mode of Operation
- play_arrow Configuring Administrative Credentials and Privileges
- Network Time Protocol
- play_arrow Configuring SSH and Console Connection
- play_arrow Configuring the Remote Syslog Server
- play_arrow Configuring Audit Log Options
- play_arrow Configuring Event Logging
- play_arrow Configuring MACSec
- play_arrow Configuring a Secure Logging Channel
- play_arrow Configuring Security Flow Policies
- play_arrow Configuring Traffic Filtering Rules
- Overview
- Understanding Protocol Support
- Configuring Traffic Filter Rules
- Configuring Default Deny-All and Reject Rules
- Logging the Dropped Packets Using Default Deny-all Option
- Configuring Mandatory Reject Rules for Invalid Fragments and Fragmented IP Packets
- Configuring Default Reject Rules for Source Address Spoofing
- Configuring Default Reject Rules with IP Options
- Configuring Default Reject Rules
- play_arrow Configuring Network Attacks
- Configuring IP Teardrop Attack Screen
- Configuring TCP Land Attack Screen
- Configuring ICMP Fragment Screen
- Configuring Ping-Of-Death Attack Screen
- Configuring tcp-no-flag Attack Screen
- Configuring TCP SYN-FIN Attack Screen
- Configuring TCP fin-no-ack Attack Screen
- Configuring UDP Bomb Attack Screen
- Configuring UDP CHARGEN DoS Attack Screen
- Configuring TCP SYN and RST Attack Screen
- Configuring ICMP Flood Attack Screen
- Configuring TCP SYN Flood Attack Screen
- Configuring TCP Port Scan Attack Screen
- Configuring UDP Port Scan Attack Screen
- Configuring IP Sweep Attack Screen
- play_arrow Configuring the IDP Extended Package
- play_arrow Configuring Cluster Mode
- play_arrow Performing Self-Tests on a Device
- play_arrow Configuration Statements
- checksum-validate
- code
- data-length
- destination-option
- extension-header
- header-type
- home-address
- identification
- icmpv6 (Security IDP Custom Attack)
- ihl (Security IDP Custom Attack)
- option-type
- reserved (Security IDP Custom Attack)
- routing-header
- sequence-number (Security IDP ICMPv6 Headers)
- type (Security IDP ICMPv6 Headers)
Configuring VPN on a Device Running Junos OS
This section describes sample configurations of an IPsec VPN on a Junos OS device using the following IKE authentication methods:
Configuring VPN on a Device Running Junos OS Overview
This section describes sample configurations of an IPsec VPN on a Junos OS device using the following IKE authentication methods:
Configuring an IPsec VPN with a Preshared Key for IKE Authentication
Configuring an IPsec VPN with an RSA Signature for IKE Authentication
Configuring an IPsec VPN with an ECDSA Signature for IKE Authentication
Figure 1 illustrates the VPN topology used in all the examples described in this section. Here, H0 and H1 are the host PCs, R0 and R2 are the two endpoints of the IPsec VPN tunnel, and R1 is a router to route traffic between the two different networks.
The router R1 can be a Linux-based router, a Juniper Networks device, or any other vendor router.

Table 1 provides a complete list of the supported IKE protocols, tunnel modes, Phase 1 negotiation mode, authentication method or algorithm, encryption algorithm, DH groups supported for the IKE authentication and encryption (Phase1, IKE Proposal), and for IPsec authentication and encryption (Phase2, IPsec Proposal). The listed protocols, modes, and algorithms are supported and required for 22.2 R1 S1 Common Criteria.
IKE Protocol | Tunnel Mode | Phase1 Negotiation Mode | Phase 1 Proposal (P1, IKE) | |||
---|---|---|---|---|---|---|
Authentication Method | Authentication Algorithm | DH Group | Encryption Algorithm | |||
IKEv1 | Main | Route | pre-shared-keys | sha-256 | group14 | |
IKEv2 | rsa-signatures-2048 | sha-384 | group19 | aes-128-cbc | ||
ecdsa-signatures-256 | group20 | aes-128-gcm | ||||
ecdsa-signatures-384 | group24 | aes-192-cbc | ||||
aes-256-cbc | ||||||
aes-256-gcm | ||||||
IKE Protocol | Tunnel Mode | Phase1 Negotiation Mode | Phase 2 Proposal (P2, IPsec) | |||
---|---|---|---|---|---|---|
Authentication Algorithm | DH Group (PFS) | Encryption Method | Encryption Algorithm | |||
IKEv1 | Main | Route | hmac-sha1-96 | group14 | ESP | 3des-cbc |
IKEv2 | hmac-sha-256-128 | group19 | aes-128-cbc | |||
group20 | aes-128-gcm | |||||
group24 | aes-192-cbc | |||||
aes-192-gcm | ||||||
aes-256-cbc | ||||||
aes-256-gcm |
The following sections provide sample configurations of IKEv1 IPsec VPN examples for selected
algorithms. Authentication and encryption algorithms can be replaced in the configurations to
accomplish the user’s desired configurations. Use set security ike gateway
<gw-name> version v2-only
command for IKEv2 IPsec VPN.
- Configuring an IPsec VPN with a Preshared Key for IKE Authentication
- Configuring an IPsec VPN with an RSA Signature for IKE Authentication
- Configuring an IPsec VPN with an ECDSA Signature for IKE Authentication
Configuring an IPsec VPN with an RSA Signature for IKE Authentication
The following section provides an example to configure Junos OS devices for IPsec VPN using RSA Signature as IKE Authentication method, whereas, the algorithms used in IKE/IPsec authentication/encryption is as shown in the following table. In this section, you configure devices running Junos OS for IPsec VPN using an RSA signature as the IKE authentication method. The algorithms used in IKE or IPsec authentication or encryption is shown in Table 3.
IKE Protocol | Tunnel Mode | Phase1 Negotiation Mode | Phase 1 Proposal (P1, IKE) | |||
---|---|---|---|---|---|---|
Authentication Method | Authentication Algorithm | DH Group | Encryption Algorithm | |||
IKEv1 | Main | Route | rsa-signatures-2048 | sha-256 | group19 | aes-128-cbc |
IKE Protocol | Tunnel Mode | Phase1 Negotiation Mode | Phase 2 Proposal (P2, IPsec) | |||
---|---|---|---|---|---|---|
Authentication Algorithm | DH Group (PFS) | Encryption Method | Encryption Algorithm | |||
IKEv1 | Main | Route | hmac-sha-256-128 | group19 | ESP | aes-128-cbc |
Configuring IPsec VPN with RSA Signature as IKE Authentication on the Initiator or Responder
To configure the IPsec VPN with RSA signature IKE authentication on the initiator:
Configure the PKI. See Example: Configuring PKI.
Generate the RSA key pair. See Example: Generating a Public-Private Key Pair.
Generate and load the CA certificate. See Example: Loading CA and Local Certificates Manually.
Load the CRL. See Example: Manually Loading a CRL onto the Device .
Generate and load a local certificate. See Example: Loading CA and Local Certificates Manually.
Configure the IKE proposal.
content_copy zoom_out_map[edit security ike] user@host# set proposal ike-proposal1 authentication-method rsa-signatures user@host# set proposal ike-proposal1 dh-group group19 user@host# set proposal ike-proposal1 authentication-algorithm sha-256 user@host# set proposal ike-proposal1 encryption-algorithm aes-128-cbc
Note:Here,
ike-proposal1
is the name given by the authorized administrator.Configure the IKE policy.
content_copy zoom_out_map[edit security ike] user@host# set policy ike-policy1 mode main user@host# set policy ike-policy1 proposals ike-proposal1 user@host# set policy ike-policy1 certificate local-certificate cert1
Note:Here,
ike-policy1
IKE policy name given by the authorized administrator.Configure the IPsec proposal.
content_copy zoom_out_map[edit security ipsec] user@host# set proposal ipsec-proposal1 protocol esp user@host# set proposal ipsec-proposal1 authentication-algorithm hmac-sha-256-128 user@host# set proposal ipsec-proposal1 encryption-algorithm aes-128-cbc
Note:Here,
ipsec-proposal1
is the name given by the authorized administrator.Configure the IPsec policy.
content_copy zoom_out_map[edit security ipsec] user@host# set policy ipsec-policy1 perfect-forward-secrecy keys group19 user@host# set policy ipsec-policy1 proposals ipsec-proposal1
Note:Here,
ipsec-policy1
is the name given by the authorized administrator.Configure the IKE.
content_copy zoom_out_map[edit security ike] user@host# set gateway gw1 ike-policy ike-policy1 user@host# set gateway gw1 address 192.0.2.8 user@host# set gateway gw1 local-identity inet 192.0.2.5 user@host# set gateway gw1 external-interface fe-0/0/1
Note:Here,
192.0.2.8
is the peer VPN endpoint IP,192.0.2.5
is the local VPN endpoint IP, andfe-0/0/1
is the local outbound interface as VPN endpoint. The following configuration is also needed for IKEv2.content_copy zoom_out_map[edit security ike] user@host# set gateway gw1 version v2-only
Configure VPN.
content_copy zoom_out_map[edit security ipsec] user@host# set vpn vpn1 ike gateway gw1 user@host# set vpn vpn1 ike ipsec-policy ipsec-policy1 user@host# set vpn vpn1 bind-interface st0.0
Note:Here,
vpn1
is the VPN tunnel name given by the authorized administrator.content_copy zoom_out_map[edit] user@host# set routing-options static route 192.0.2.10/24 qualified-next-hop st0.0 preference 1
Configure the outbound flow policies.
content_copy zoom_out_map[edit security policies] user@host# set from-zone trustZone to-zone untrustZone policy policy1 match source-address trustLan user@host# set from-zone trustZone to-zone untrustZone policy policy1 match destination-address untrustLan user@host# set from-zone trustZone to-zone untrustZone policy policy1 match application any user@host# set from-zone trustZone to-zone untrustZone policy policy1 then permit user@host# set from-zone trustZone to-zone untrustZone policy policy1 then log session-init user@host# set from-zone trustZone to-zone untrustZone policy policy1 then log session-close
Note:Here,
trustZone
anduntrustZone
are preconfigured security zone andtrustLan
anduntrustLan
are preconfigured network addresses.Configure the inbound flow policies.
content_copy zoom_out_map[edit security policies] user@host# set from-zone untrustZone to-zone trustZone policy policy1 match source-address untrustLan user@host# set from-zone untrustZone to-zone trustZone policy policy1 match destination-address trustLan user@host# set from-zone untrustZone to-zone trustZone policy policy1 match application any user@host# set from-zone untrustZone to-zone trustZone policy policy1 then permit user@host# set from-zone untrustZone to-zone trustZone policy policy1 then log session-init user@host# set from-zone untrustZone to-zone trustZone policy policy1 then log session-close
Note:Here,
trustZone
anduntrustZone
are preconfigured security zones andtrustLan
anduntrustLan
are preconfigured network addresses.Commit the configuration.
content_copy zoom_out_map[edit] user@host# commit
Configuring an IPsec VPN with an ECDSA Signature for IKE Authentication
In this section, you configure devices running Junos OS for IPsec VPN using an ECDSA signature as the IKE authentication method. The algorithms used in IKE or IPsec authentication or encryption are shown in Table 4.
IKE Protocol | Tunnel Mode | Phase1 Negotiation Mode | Phase 1 Proposal (P1, IKE) | |||
---|---|---|---|---|---|---|
Authentication Method | Authentication Algorithm | DH Group | Encryption Algorithm | |||
IKEv1 | Main | Route | ecdsa-signatures-256 | sha-384 | group14 | aes-256-cbc |
IKE Protocol | Tunnel Mode | Phase1 Negotiation Mode | Phase 2 Proposal (P2, IPsec) | |||
---|---|---|---|---|---|---|
Authentication Algorithm | DH Group (PFS) | Encryption Method | Encryption Algorithm | |||
IKEv1 | Main | Route | No Algorithm | group14 | ESP | aes-256-gcm |
- Configuring IPsec VPN with ECDSA signature IKE authentication on the Initiator
- Configuring IPsec VPN with ECDSA signature IKE authentication on the Responder
Configuring IPsec VPN with ECDSA signature IKE authentication on the Initiator
To configure the IPsec VPN with ECDSA signature IKE authentication on the initiator:
Configure the PKI. See Example: Configuring PKI.
Generate the RSA key pair. See Example: Generating a Public-Private Key Pair.
Generate and load the CA certificate. See Example: Loading CA and Local Certificates Manually.
Load the CRL. See Example: Manually Loading a CRL onto the Device .
Generate and load a local certificate. See Example: Loading CA and Local Certificates Manually.
Configure the IKE proposal.
content_copy zoom_out_map[edit security ike] user@host# set proposal ike-proposal1 authentication-method ecdsa-signatures-256 user@host# set proposal ike-proposal1 dh-group group14 user@host# set proposal ike-proposal1 authentication-algorithm sha-384 user@host# set proposal ike-proposal1 encryption-algorithm aes-256-cbc
Note:Here,
ike-proposal1
is the IKE proposal name given by the authorized administrator.Configure the IKE policy.
content_copy zoom_out_map[edit security ike] user@host# set policy ike-policy1 mode main user@host# set policy ike-policy1 proposals ike-proposal1 user@host# set policy ike-policy1 certificate local-certificate cert1
Configure the IPsec proposal.
content_copy zoom_out_map[edit security ipsec] user@host# set proposal ipsec-proposal1 protocol esp user@host# set proposal ipsec-proposal1 encryption-algorithm aes-256-gcm
Note:Here,
ipsec-proposal1
is the IPsec proposal name given by the authorized administrator.Configure the IPsec policy.
content_copy zoom_out_map[edit security ipsec] user@host# set policy ipsec-policy1 perfect-forward-secrecy keys group14 user@host# set policy ipsec-policy1 proposals ipsec-proposal1
Note:Here,
ipsec-policy1
is the IPsec policy name andipsec-proposal1
is the IPsec proposal name given by the authorized administrator.Configure IKE.
content_copy zoom_out_map[edit security ike] user@host# set gateway gw1 ike-policy ike-policy1 user@host# set gateway gw1 address 192.0.2.8 user@host# set gateway gw1 local-identity inet 192.0.2.5 user@host# set gateway gw1 external-interface ge-0/0/2
Note:Here,
gw1
is an IKE gateway name,192.0.2.8
is the peer VPN endpoint IP,192.0.2.5
is the local VPN endpoint IP, andge-0/0/2
is a local outbound interface as the VPN endpoint. The following configuration is also needed for IKEv2.content_copy zoom_out_map[edit security ike] user@host# set gateway gw1 version v2-only
Configure the VPN.
content_copy zoom_out_map[edit] user@host# set security ipsec vpn vpn1 ike gateway gw1 user@host# set security ipsec vpn vpn1 ike ipsec-policy ipsec-policy1 user@host# set security ipsec vpn vpn1 bind-interface st0.0 user@host# set routing-options static route 192.0.2.10/24 qualified-next-hop st0.0 preference 1
Note:Here,
vpn1
is the VPN tunnel name given by the authorized administrator.Configure the outbound flow policies.
content_copy zoom_out_map[edit security policies] user@host# set from-zone trustZone to-zone untrustZone policy policy1 match source-address trustLan user@host# set from-zone trustZone to-zone untrustZone policy policy1 match destination-address untrustLan user@host# set from-zone trustZone to-zone untrustZone policy policy1 match application any user@host# set from-zone trustZone to-zone untrustZone policy policy1 then permit user@host# set from-zone trustZone to-zone untrustZone policy policy1 then log session-init user@host# set from-zone trustZone to-zone untrustZone policy policy1 then log session-close
Note:Here,
trustZone
anduntrustZone
are preconfigured security zones andtrustLan
anduntrustLan
are preconfigured network addresses.Configure the inbound flow policies.
content_copy zoom_out_map[edit security policies] user@host# set from-zone untrustZone to-zone trustZone policy policy1 match source-address untrustLan user@host# set from-zone untrustZone to-zone trustZone policy policy1 match destination-address trustLan user@host# set from-zone untrustZone to-zone trustZone policy policy1 match application any user@host# set from-zone untrustZone to-zone trustZone policy policy1 then permit user@host# set from-zone untrustZone to-zone trustZone policy policy1 then log session-init user@host# set from-zone untrustZone to-zone trustZone policy policy1 then log session-close
Note:Here,
trustZone
anduntrustZone
are preconfigured security zones andtrustLan
anduntrustLan
are preconfigured network addresses.Commit your configuration.
content_copy zoom_out_mapuser@host# commit
Configuring IPsec VPN with ECDSA signature IKE authentication on the Responder
To configure IPsec VPN with ECDSA signature IKE authentication on the responder:
Configure the PKI. See Example: Configuring PKI.
Generate the ECDSA key pair. See Example: Generating a Public-Private Key Pair.
Generate and load the CA certificate. See Example: Loading CA and Local Certificates Manually.
Load the CRL. See Example: Manually Loading a CRL onto the Device .
Configure the IKE proposal.
content_copy zoom_out_map[edit security ike] user@host# set proposal ike-proposal1 authentication-method ecdsa-signatures-256 user@host# set proposal ike-proposal1 dh-group group14 user@host# set proposal ike-proposal1 authentication-algorithm sha-384 user@host# set proposal ike-proposal1 encryption-algorithm aes-256-cbc
Note:Here,
ike-proposal1
is the IKE proposal name given by the authorized administrator.Configure the IKE policy.
content_copy zoom_out_map[edit security ike] user@host# set policy ike-policy1 mode main user@host# set policy ike-policy1 proposals ike-proposal1 user@host# set policy ike-policy1 certificate local-certificate cert1
Configure the IPsec proposal.
content_copy zoom_out_map[edit security ipsec] user@host# set proposal ipsec-proposal1 protocol esp user@host# set proposal ipsec-proposal1 encryption-algorithm aes-256-gcm
Note:Here,
ipsec-proposal1
is the IPsec proposal name given by the authorized administrator.Configure the IPsec policy.
content_copy zoom_out_map[edit security ipsec] user@host# set policy ipsec-policy1 perfect-forward-secrecy keys group14 user@host# set policy ipsec-policy1 proposals ipsec-proposal1
Note:Here,
ipsec-policy1
is the IPsec policy name andipsec-proposal1
is the IPsec proposal name given by the authorized administrator.Configure the IKE.
content_copy zoom_out_map[edit security ike] user@host# set gateway gw1 ike-policy ike-policy1 user@host# set gateway gw1 address 192.0.2.5 user@host# set gateway gw1 local-identity inet 192.0.2.8 user@host# set gateway gw1 external-interface ge-0/0/1
Note:Here,
gw1
is an IKE gateway name,192.0.2.5
is the peer VPN endpoint IP,192.0.2.8
is the local VPN endpoint IP, andge-0/0/1
is a local outbound interface as the VPN endpoint. The following configuration is also needed for IKEv2.content_copy zoom_out_map[edit security ike] user@host# set gateway gw1 version v2-only
Configure the VPN.
content_copy zoom_out_map[edit] user@host# set security ipsec vpn vpn1 ike gateway gw1 user@host# set security ipsec vpn vpn1 ike ipsec-policy ipsec-policy1 user@host# set security ipsec vpn vpn1 bind-interface st0.0 user@host# set routing-options static route 192.0.2.1/24 qualified-next-hop st0.0 preference 1
Note:Here,
vpn1
is the VPN tunnel name given by the authorized administrator.Configure the outbound flow policies.
content_copy zoom_out_map[edit security policies] user@host# set from-zone trustZone to-zone untrustZone policy policy1 match source-address trustLan user@host# set from-zone trustZone to-zone untrustZone policy policy1 match destination-address untrustLan user@host# set from-zone trustZone to-zone untrustZone policy policy1 match application any user@host# set from-zone trustZone to-zone untrustZone policy policy1 then permit user@host# set from-zone trustZone to-zone untrustZone policy policy1 then log session-init user@host# set from-zone trustZone to-zone untrustZone policy policy1 then log session-close
Note:Here,
trustZone
anduntrustZone
are preconfigured security zones andtrustLan
anduntrustLan
are preconfigured network addresses.Configure the inbound flow policies.
content_copy zoom_out_map[edit security policies] user@host# set from-zone untrustZone to-zone trustZone policy policy1 match source-address untrustLan user@host# set from-zone untrustZone to-zone trustZone policy policy1 match destination-address trustLan user@host# set from-zone untrustZone to-zone trustZone policy policy1 match application any user@host# set from-zone untrustZone to-zone trustZone policy policy1 then permit user@host# set from-zone untrustZone to-zone trustZone policy policy1 then log session-init user@host# set from-zone untrustZone to-zone trustZone policy policy1 then log session-close
Note:Here,
trustZone
anduntrustZone
are preconfigured security zones andtrustLan
anduntrustLan
are preconfigured network addresses.Commit your configuration.
content_copy zoom_out_mapuser@host# commit