Am 2021-02-01 um 10:51 schrieb Mark Thomas:
On 01/02/2021 09:29, micha...@apache.org wrote:
<snip/>
commit a616bf385a350175a33a0ebf09d8b6688344e9e3
Author: minfrin <minf...@users.noreply.github.com>
AuthorDate: Fri Jan 15 17:12:51 2021 +0000

<snip/>

+        if (family == Socket.APR_UNIX) {
+            if (getUnixDomainSocketPathPermissions() != null) {
+                FileAttribute<Set<PosixFilePermission>> attrs =
+                         
PosixFilePermissions.asFileAttribute(PosixFilePermissions.fromString(
+                                 getUnixDomainSocketPathPermissions()));
+                Files.setAttribute(Paths.get(getUnixDomainSocketPath()), 
attrs.name(), attrs.value());
+            }
+            else {
+                java.io.File file = 
Paths.get(getUnixDomainSocketPath()).toFile();
+                file.setReadable(true, false);
+                file.setWritable(true, false);
+                file.setExecutable(false, false);

There appears to be scope to simplify this. See
https://github.com/apache/tomcat/commit/8706f885a

I'll check.

<snip/>

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 86123e9..ee05083 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -314,6 +314,11 @@
          specified to wait for client connections to complete and close before
          the Container hierarchy is stopped. (markt)
        </add>
+      <add>
+        <bug>64943</bug>: Add support for Unix Domain Sockets to
+        <code>org.apache.coyote.http11.Http11AprProtocol</code>. Depends on
+        <code>tomcat-native</code> 1.2.26 and up. (minfrin)
+      </add>

Wrong section. This belongs in Coyote.

Will fix.

        <fix>
          <bug>64921</bug>: Ensure that the 
<code>LoadBalancerDrainingValve</code>
          uses the correct setting for the secure attribute for any session
diff --git a/webapps/docs/config/http.xml b/webapps/docs/config/http.xml
index 4f2d17b..fdb86cd 100644
--- a/webapps/docs/config/http.xml
+++ b/webapps/docs/config/http.xml
@@ -898,12 +898,8 @@
        <attribute name="unixDomainSocketPath" required="false">
          <p>Where supported, the path to a Unix Domain Socket that this
          <strong>Connector</strong> will create and await incoming connections.
-        Tomcat will NOT automatically remove the socket on server shutdown.
-        If the socket already exists, care must be taken by the administrator
-        to remove the socket after verifying that the socket isn't already
-        being used by an existing Tomcat process. Using this requires
-        Java 16 or later. When this is specified, the otherwise mandatory
-        <code>port</code> attribute may be omitted.</p>
+        When this is specified, the otherwise mandatory <code>port</code>
+        attribute may be omitted.</p>
        </attribute>

If you are going to remove the warning from this section then you should
add a link to the more detailed information on UDS supported added in
this commit.

Makes sense, will add.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to