Skip to content

Commit f8f7fd2

Browse files
committed
sockets add AF_DIVERT constant.
Allow to bind a socket to a divert port without being concerned by its address. for ipfw filter purpose (SO_USER_COOKIE constant). FreeBSD only. Close GH-10415.
1 parent cf1d21e commit f8f7fd2

File tree

4 files changed

+13
-1
lines changed

4 files changed

+13
-1
lines changed

NEWS

+1
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ PHP NEWS
9494
. Added TCP_QUICKACK constant, to give tigher control over
9595
ACK delays. (David Carlier)
9696
. Added DONTFRAGMENT support for path MTU discovery purpose. (David Carlier)
97+
. Added AF_DIVERT for raw socket for divert ports. (David Carlier)
9798

9899
- Standard:
99100
. E_NOTICEs emitted by unserialize() have been promoted to E_WARNING. (timwolla)

UPGRADING

+1
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ PHP 8.3 UPGRADE NOTES
132132
. IP_PMTUDISC_PROBE (Linux only).
133133
. IP_PMTUDISC_INTERFACE (Linux only).
134134
. IP_PMTUDISC_OMIT (Linux only).
135+
. AF_DIVERT (FreeBSD only).
135136

136137
========================================
137138
11. Changes to INI File Handling

ext/sockets/sockets.stub.php

+7
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,13 @@
1919
*/
2020
const AF_INET6 = UNKNOWN;
2121
#endif
22+
#ifdef AF_DIVERT
23+
/**
24+
* @var int
25+
* @cvalue AF_DIVERT
26+
*/
27+
const AF_DIVERT = UNKNOWN;
28+
#endif
2229
/**
2330
* @var int
2431
* @cvalue SOCK_STREAM

ext/sockets/sockets_arginfo.h

+4-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)