Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKristof Provost <kp@FreeBSD.org>2021-05-20 12:54:41 +0300
committerSebastian Huber <sebastian.huber@embedded-brains.de>2022-07-11 14:19:29 +0300
commit5260d10c985fd87e1d1aaed3c437cf272af024e0 (patch)
treeea3afec55a114f7a18189dc36d89f47fc70d9941 /newlib/libc/sys
parentb89c5a3e88c6ba876dd0d4ffedc49b17040c903c (diff)
pf: syncookie support
Import OpenBSD's syncookie support for pf. This feature help pf resist TCP SYN floods by only creating states once the remote host completes the TCP handshake rather than when the initial SYN packet is received. This is accomplished by using the initial sequence numbers to encode a cookie (hence the name) in the SYN+ACK response and verifying this on receipt of the client ACK. Reviewed by: kbowling Obtained from: OpenBSD MFC after: 1 week Sponsored by: Modirum MDPay Differential Revision: https://reviews.freebsd.org/D31138
Diffstat (limited to 'newlib/libc/sys')
-rw-r--r--newlib/libc/sys/rtems/include/netinet/tcp.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/newlib/libc/sys/rtems/include/netinet/tcp.h b/newlib/libc/sys/rtems/include/netinet/tcp.h
index 45bece9fa..a79dbeaad 100644
--- a/newlib/libc/sys/rtems/include/netinet/tcp.h
+++ b/newlib/libc/sys/rtems/include/netinet/tcp.h
@@ -105,6 +105,8 @@ struct tcphdr {
#define TCPOPT_FAST_OPEN 34
#define TCPOLEN_FAST_OPEN_EMPTY 2
+#define MAX_TCPOPTLEN 40 /* Absolute maximum TCP options len */
+
/* Miscellaneous constants */
#define MAX_SACK_BLKS 6 /* Max # SACK blocks stored at receiver side */
#define TCP_MAX_SACK 4 /* MAX # SACKs sent in any segment */