2 \todo{write this subsection}
4 \label{section:IPSECgeneral}
9 \item[Settings:] \mbox{}
11 \paragraph*{Assumptions}\mbox{}\\
13 We assume the use of IKE (v1 or v2) and ESP for this document.
15 \paragraph*{Authentication}\mbox{}\\
17 IPSEC authentication should optimally be performed via RSA signatures,
18 with a key size of 2048 bits or more. Configuring only the trusted CA
19 that issued the peer certificate provides for additional protection
20 against fake certificates.
22 If you need to use Pre-Shared Key authentication:
25 \item Choose a \textbf{random}, \textbf{long enough} PSK (see below)
26 \item Use a \textbf{separate} PSK for any IPSEC connection
27 \item Change the PSKs regularily
30 The size of the PSK should not be shorter than the output size of
31 the hash algorithm used in IKE \footnote{It is used in a HMAC, see
32 \url{http://www.ietf.org/rfc/rfc2104.txt}.}.
34 For a key composed of upper- and lowercase letters, numbers, and two
35 additional symbols \footnote{64 possible values = 6 bits}, that gives
36 the following minimum lengths in characters:
43 IKE Hash & PSK length \\
52 \paragraph*{Cryptographic Suites}\mbox{}\\
54 IPSEC Cryptographic Suites are pre-defined settings for all the
55 items of a configuration; they try to provide a balanced security
56 level and make setting up VPNs easier.
58 When using any of those suites, make sure to enable ``Perfect Forward
59 Secrecy`` for Phase 2, as this is not specified in the suites. The
60 equivalents to the recommended ciphers suites in section
61 \ref{section:recommendedciphers} are:
68 Configuration A & Configuration B & Notes\\
70 \verb|Suite-B-GCM-256|\footnote{\url{http://tools.ietf.org/html/rfc6379}} &
71 \verb|Suite-B-GCM-128| & All Suite-B variants use NIST elliptic curves
72 \\ \verb|Suite-B-GMAC-256| & \verb|Suite-B-GMAC-128| &
73 \\ & \verb|VPN-B|\footnote{\url{http://tools.ietf.org/html/rfc4308}} &
79 \paragraph*{IKE or Phase 1}\mbox{}\\
81 Alternatively to the pre-defined cipher suites, you can define your
82 own, as described in this and the next section.
84 IKE or Phase 1 is the mutual authentication and key exchange phase.
86 Use only ``main mode``, as ``aggressive mode`` has known security
87 vulnerabilities \footnote{\url{http://ikecrack.sourceforge.net/}}.
89 \todo{how to make footnotes in a table appear in the output document?}
96 & Configuration A & Configuration B \\
98 Mode & Main Mode & Main Mode \\
99 Encryption & AES-256 & AES, CAMELLIA (-256 or -128) \\
100 Hash & SHA2-* & SHA2-*, SHA1 \\
101 DH Group & Group 14--18 \footnote{2048--8192 bit DH},
102 19--21\footnote{(256--521 bit ECDH)} & Group 14--21 \\
103 Lifetime & \todo{need recommendations; 1 day seems to be common
109 \paragraph*{ESP or Phase 2}\mbox{}\\
111 ESP or Phase 2 is where the actual data are protected.
113 \todo{make the tables appear right here!}
120 & Configuration A & Configuration B \\
122 Perfect Forward Secrecy & yes & yes \\
123 Encryption & AES-GCM-16, AES-CTR, AES-CCM-16, AES-256 &
124 AES-GCM-16, AES-CTR, AES-CCM-16, AES-256, CAMELLIA-256, AES-128, CAMELLIA-128 \\
125 Hash & SHA2-* (or none for AES-GCM) & SHA2-*, SHA1 (or none for AES-GCM) \\
126 DH Group & Same as Phase 1 & Same as Phase 1 \\
127 Lifetime & \todo{need recommendations; 1-8 hours is common} & \\
132 \item[References:] \mbox{}
134 ``A Cryptographic Evaluation of IPsec'', Niels Ferguson and Bruce
135 Schneier: \url{https://www.schneier.com/paper-ipsec.pdf}
139 \subsubsection{Check Point FireWall-1}
142 \item[Tested with Version:] \mbox{}
145 \item R77 (should work with any currently supported version)
148 \item[Settings:] \mbox{}
150 Please see section \ref{section:IPSECgeneral} for guidance on
151 parameter choice. In this section, we will configure a strong setup
152 according to ``Configuration A''.
154 This is based on the concept of a ``VPN Community'', which has all the
155 settings for the gateways that are included in that community.
156 Communities can be found in the ``IPSEC VPN'' tab of SmartDashboard.
158 \todo{make those graphics prettier -- whoever has the right LaTeX
161 \includegraphics{checkpoint_1.png}
163 Either chose one of the encryption suites here, or proceed to
164 ``Custom Encryption...'', where you can set encryption and hash for
167 \includegraphics{checkpoint_2.png}
169 The Diffie-Hellman groups and Perfect Forward Secrecy Settings can be
170 found under ``Advanced Settings'' / ``Advanced VPN Properties'':
172 \includegraphics{checkpoint_3.png}
174 \item[Additional settings:]
176 For remote Dynamic IP Gateways, the settings are not taken from the
177 community, but set in the ``Global Properties'' dialog under ``Remote
178 Access'' / ``VPN Authentication and Encryption''. Via the ``Edit...''
179 button, you can configure sets of algorithms that all gateways support:
181 \includegraphics{checkpoint_4.png}
183 Please note that these settings restrict the available algorithms for
184 \textbf{all} gateways, and also influence the VPN client connections.
186 %\item[Justification for special settings (if needed):]
190 \item[References:]\mbox{}
195 \href{https://sc1.checkpoint.com/documents/R77/CP_R77_VPN_AdminGuide/html_frameset.htm}{VPN
196 R77 Administration Guide} (may require a
197 UserCenter account to access)
201 % \item[How to test:]
206 \subsubsection{OpenVPN}
210 \item[Tested with Version:] \mbox{}\\
213 \item OpenVPN 2.3.2 from Debian ``wheezy-backports'' linked against openssl (libssl.so.1.0.0)
214 \item OpenVPN 2.2.1 from Debian 7.0 linked against openssl
216 \item OpenVPN 2.3.2 for Windows
219 \item[Settings:] \mbox{}
221 \paragraph{General}\mbox{}
223 We describe a configuration with certificate-based authentication; see
224 below for details on the \verb|easyrsa| tool to help you with that.
226 OpenVPN uses TLS only for authentication and key exchange. The
227 bulk traffic is then encrypted and authenticated with the OpenVPN
228 protocol using those keys.
230 Note that while the \verb|tls-cipher| option takes a list of ciphers
231 that is then negotiated as usual with TLS, the \verb|cipher|
232 and \verb|auth| options both take a single argument that must match on
235 \paragraph{Server Configuration}\mbox{}
237 % this is only a DoS-protection, out of scope:
238 % # TLS Authentication
243 % ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-SHA384:DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-CAMELLIA256-SHA:ECDHE-RSA-AES256-SHA:DHE-RSA-AES256-SHA:AES256-SHA
244 % the cipherlist here is config B without the ECDHE strings, because
245 % it must fit in 256 bytes...
246 \begin{lstlisting}[breaklines]
247 tls-cipher DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES128-SHA256:DHE-RSA-CAMELLIA256-SHA:DHE-RSA-AES256-SHA:DHE-RSA-CAMELLIA128-SHA:DHE-RSA-AES128-SHA:CAMELLIA256-SHA:AES256-SHA:CAMELLIA128-SHA:AES128-SHA
250 # generate with 'openssl dhparam -out dh2048.pem 2048':
254 \paragraph{Client Configuration}\mbox{}
256 Client and server have to use compatible configurations, otherwise they can't communicate.
257 The \verb|cipher| and \verb|auth| directives have to be identical.
259 \begin{lstlisting}[breaklines]
260 tls-cipher DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES128-SHA256:DHE-RSA-CAMELLIA256-SHA:DHE-RSA-AES256-SHA:DHE-RSA-CAMELLIA128-SHA:DHE-RSA-AES128-SHA:CAMELLIA256-SHA:AES256-SHA:CAMELLIA128-SHA:AES128-SHA
264 # http://openvpn.net/index.php/open-source/documentation/howto.html#mitm
265 remote-cert-tls server
267 tls-remote server.example.com
270 \item[Justification for special settings (if needed):] \mbox{}\\
272 OpenVPN 2.3.1 changed the values that the \verb|tls-cipher| option
273 expects from OpenSSL to IANA cipher names. That means from that
274 version on you will get ``Deprecated TLS cipher name'' warnings for
275 the configurations above. You cannot use the selection strings from
276 section \ref{section:recommendedciphers} directly from 2.3.1 on, which
277 is why we give an explicit cipher list here.
279 In addition, there is a 256 character limit on configuration file line
280 lengths; that limits the size of cipher suites, so we dropped all
283 The configuration shown above is compatible with all tested versions.
285 \item[References:] \mbox{}\\
287 \url{http://openvpn.net/index.php/open-source/documentation/security-overview.html}
292 \item[Additional settings:] \mbox{}
294 \paragraph{Key renegotiation interval}\mbox{}
296 The default for renegotiation of encryption keys is one hour
297 (\verb|reneg-sec 3600|). If you
298 transfer huge amounts of data over your tunnel, you might consider
299 configuring a shorter interval, or switch to a byte- or packet-based
300 interval (\verb|reneg-bytes| or \verb|reneg-pkts|).
302 \paragraph{Fixing ``easy-rsa''}\mbox{}
304 When installing an OpenVPN server instance, you are probably using
305 {\it easy-rsa} to generate keys and certificates.
306 The file \verb|vars| in the easyrsa installation directory has a
307 number of settings that should be changed to secure values:
309 \begin{lstlisting}[breaklines]
311 export KEY_EXPIRE=365
312 export CA_EXPIRE=1826
315 This will enhance the security of the key generation by using RSA keys
316 with a length of 2048 bits, and set a lifetime of one year for the
317 server/client certificates and five years for the CA certificate.
319 In addition, edit the \verb|pkitool| script and replace all occurences
320 of \verb|sha1| with \verb|sha256|, to sign the certificates with
323 \item[Limitations:] \mbox{}
325 Note that the ciphersuites shown by \verb|openvpn --show-tls| are {\it
326 known}, but not necessarily {\it
327 supported} \footnote{\url{https://community.openvpn.net/openvpn/ticket/304}}.
329 Which cipher suite is actually used can be seen in the logs:
331 \verb|Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-CAMELLIA256-SHA, 2048 bit RSA|
338 PPTP is considered insecure, Microsoft recommends to ``use a more secure VPN
339 tunnel''\footnote{\url{http://technet.microsoft.com/en-us/security/advisory/2743314}}.
341 There is a cloud service that cracks the underlying MS-CHAPv2
342 authentication protocol for the price of USD~200\footnote{\url{https://www.cloudcracker.com/blog/2012/07/29/cracking-ms-chap-v2/}},
343 and given the resulting MD4 hash, all PPTP traffic for a user can
346 \subsubsection{Cisco ASA}
347 The following settings reflect our recommendations as best as possible on the Cisco ASA platform. These are - of course - just settings regarding SSL/TLS (i.e. Cisco AnyConnect) and IPSec. For further security settings regarding this platform the appropriate Cisco guides should be followed.
349 \item[Tested with Version:]
351 \item[Settings:] \mbox{}
352 \begin{lstlisting}[breaklines]
353 crypto ipsec ikev2 ipsec-proposal AES-Fallback
354 protocol esp encryption aes-256 aes-192 aes
355 protocol esp integrity sha-512 sha-384 sha-256
356 crypto ipsec ikev2 ipsec-proposal AES-GCM-Fallback
357 protocol esp encryption aes-gcm-256 aes-gcm-192 aes-gcm
358 protocol esp integrity sha-512 sha-384 sha-256
359 crypto ipsec ikev2 ipsec-proposal AES128-GCM
360 protocol esp encryption aes-gcm
361 protocol esp integrity sha-512
362 crypto ipsec ikev2 ipsec-proposal AES192-GCM
363 protocol esp encryption aes-gcm-192
364 protocol esp integrity sha-512
365 crypto ipsec ikev2 ipsec-proposal AES256-GCM
366 protocol esp encryption aes-gcm-256
367 protocol esp integrity sha-512
368 crypto ipsec ikev2 ipsec-proposal AES
369 protocol esp encryption aes
370 protocol esp integrity sha-1 md5
371 crypto ipsec ikev2 ipsec-proposal AES192
372 protocol esp encryption aes-192
373 protocol esp integrity sha-1 md5
374 crypto ipsec ikev2 ipsec-proposal AES256
375 protocol esp encryption aes-256
376 protocol esp integrity sha-1 md5
377 crypto ipsec ikev2 sa-strength-enforcement
378 crypto ipsec security-association pmtu-aging infinite
379 crypto dynamic-map SYSTEM_DEFAULT_CRYPTO_MAP 65535 set pfs group14
380 crypto dynamic-map SYSTEM_DEFAULT_CRYPTO_MAP 65535 set ikev2 ipsec-proposal AES256-GCM AES192-GCM AES128-GCM AES-GCM-Fallback AES-Fallback
381 crypto map Outside-DMZ_map 65535 ipsec-isakmp dynamic SYSTEM_DEFAULT_CRYPTO_MAP
382 crypto map Outside-DMZ_map interface Outside-DMZ
384 crypto ikev2 policy 1
385 encryption aes-gcm-256
388 prf sha512 sha384 sha256 sha
389 lifetime seconds 86400
390 crypto ikev2 policy 2
391 encryption aes-gcm-256 aes-gcm-192 aes-gcm
394 prf sha512 sha384 sha256 sha
395 lifetime seconds 86400
396 crypto ikev2 policy 3
397 encryption aes-256 aes-192 aes
398 integrity sha512 sha384 sha256
400 prf sha512 sha384 sha256 sha
401 lifetime seconds 86400
402 crypto ikev2 policy 4
403 encryption aes-256 aes-192 aes
404 integrity sha512 sha384 sha256 sha
406 prf sha512 sha384 sha256 sha
407 lifetime seconds 86400
408 crypto ikev2 enable Outside-DMZ client-services port 443
409 crypto ikev2 remote-access trustpoint ASDM_TrustPoint0
411 ssl server-version tlsv1-only
412 ssl client-version tlsv1-only
413 ssl encryption dhe-aes256-sha1 dhe-aes128-sha1 aes256-sha1 aes128-sha1
414 ssl trust-point ASDM_TrustPoint0 Outside-DMZ
417 \item[Justification for special settings (if needed):] \mbox{}
418 New IPsec policies have been defined which do not make use of ciphers that may be cause for concern. Policies have a "Fallback" option to support legacy devices.
420 % in case you have the need for further justifications why you chose this and that setting or if the settings do not fit into the standard Variant A or Variant B schema, please document this here
423 \url{http://www.cisco.com/en/US/docs/security/asa/roadmap/asaroadmap.html}
425 % add any further references or best practice documents here
427 %%\item[How to test:]
428 % describe here or point the admin to tools (can be a simple footnote or \ref{} to the tools section) which help the admin to test his settings.
438 %%\subsubsection{Juniper VPN}
439 %%\todo{write this subsubsection. AK: ask Hannes}
442 %%\begin{description}
443 %%\item[Tested with Version:] \todo{version?}
445 %%\item[Settings:] \mbox{}
447 %%\begin{lstlisting}[breaklines]
448 %% %Here goes your setting string
451 %%\item[Additional settings:] \mbox{}
453 %Here you can add additional settings
455 %%\begin{lstlisting}[breaklines]
456 %% %copy \& paste additional settings
459 %%\item[Justification for special settings (if needed):] \mbox{}
461 % in case you have the need for further justifications why you chose this and that setting or if the settings do not fit into the standard Variant A or Variant B schema, please document this here
463 %%\item[References:] \todo{add references}
465 % add any further references or best practice documents here
467 %%\item[How to test:]
468 % describe here or point the admin to tools (can be a simple footnote or \ref{} to the tools section) which help the admin to test his settings.
474 \subsubsection{L2TP over IPSec}
475 \todo{write this subsubsection}
479 \item[Tested with Version:] \todo{version?}
481 \item[Settings:] \mbox{}
483 \begin{lstlisting}[breaklines]
484 %Here goes your setting string
487 \item[Additional settings:] \mbox{}
489 %Here you can add additional settings
491 \begin{lstlisting}[breaklines]
492 %copy \& paste additional settings
495 \item[Justification for special settings (if needed):] \mbox{}
497 % in case you have the need for further justifications why you chose this and that setting or if the settings do not fit into the standard Variant A or Variant B schema, please document this here
499 \item[References:] \todo{add references}
501 % add any further references or best practice documents here
504 % describe here or point the admin to tools (can be a simple footnote or \ref{} to the tools section) which help the admin to test his settings.
513 \subsubsection{Racoon}
514 \todo{write this subsubsection}
518 \item[Tested with Version:] \todo{version?}
520 \item[Settings:] \mbox{}
522 \begin{lstlisting}[breaklines]
523 %Here goes your setting string
526 \item[Additional settings:] \mbox{}
528 %Here you can add additional settings
530 \begin{lstlisting}[breaklines]
531 %copy \& paste additional settings
534 \item[Justification for special settings (if needed):] \mbox{}
536 % in case you have the need for further justifications why you chose this and that setting or if the settings do not fit into the standard Variant A or Variant B schema, please document this here
538 \item[References:] \todo{add references}
540 % add any further references or best practice documents here
543 % describe here or point the admin to tools (can be a simple footnote or \ref{} to the tools section) which help the admin to test his settings.