]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS-Plus/Source/FreeRTOS-Plus-TCP/include/FreeRTOSIPConfigDefaults.h
Fix some build issues in older kernel demo projects.
[freertos] / FreeRTOS-Plus / Source / FreeRTOS-Plus-TCP / include / FreeRTOSIPConfigDefaults.h
index 36781cca5c29d9f0be51bcbc3e55857d3c4855a4..dd8ae07f404e9447b13c70711c039ccd79811bf4 100644 (file)
@@ -1,5 +1,5 @@
 /*\r
- * FreeRTOS+TCP V2.0.3\r
+ * FreeRTOS+TCP V2.0.7\r
  * Copyright (C) 2017 Amazon.com, Inc. or its affiliates.  All Rights Reserved.\r
  *\r
  * Permission is hereby granted, free of charge, to any person obtaining a copy of\r
@@ -389,11 +389,13 @@ from the FreeRTOSIPConfig.h configuration header file. */
 \r
 #if( ipconfigUSE_DNS_CACHE != 0 )\r
        #ifndef ipconfigDNS_CACHE_NAME_LENGTH\r
-               #define ipconfigDNS_CACHE_NAME_LENGTH           ( 16 )\r
+        /* Per https://tools.ietf.org/html/rfc1035, 253 is the maximum string length\r
+        of a DNS name. The following default accounts for a null terminator. */\r
+        #define ipconfigDNS_CACHE_NAME_LENGTH   254\r
        #endif\r
 \r
        #ifndef ipconfigDNS_CACHE_ENTRIES\r
-               #define ipconfigDNS_CACHE_ENTRIES                       0\r
+               #define ipconfigDNS_CACHE_ENTRIES                       1\r
        #endif\r
 #endif /* ipconfigUSE_DNS_CACHE != 0 */\r
 \r
@@ -510,7 +512,7 @@ from the FreeRTOSIPConfig.h configuration header file. */
 #endif\r
 \r
 #ifndef ipconfigTCP_KEEP_ALIVE\r
-       #define ipconfigTCP_KEEP_ALIVE 1\r
+       #define ipconfigTCP_KEEP_ALIVE 0\r
 #endif\r
 \r
 #ifndef ipconfigDNS_USE_CALLBACKS\r
@@ -525,10 +527,17 @@ from the FreeRTOSIPConfig.h configuration header file. */
        #define ipconfigUSE_NBNS 0\r
 #endif\r
 \r
+/* As an attack surface reduction for ports that listen for inbound \r
+connections, hang protection can help reduce the impact of SYN floods. */\r
 #ifndef ipconfigTCP_HANG_PROTECTION\r
        #define ipconfigTCP_HANG_PROTECTION  1\r
 #endif\r
 \r
+/* Non-activity timeout is expressed in seconds. */\r
+#ifndef ipconfigTCP_HANG_PROTECTION_TIME\r
+    #define ipconfigTCP_HANG_PROTECTION_TIME 30\r
+#endif\r
+\r
 #ifndef ipconfigTCP_IP_SANITY\r
        #define ipconfigTCP_IP_SANITY 0\r
 #endif\r