]> git.decadent.org.uk Git - nfs-utils.git/blobdiff - utils/mountd/auth.c
mountd: better hiding of v4root exports from mountd clients
[nfs-utils.git] / utils / mountd / auth.c
index 41a57db8e843e04ff5884f0d54f5f36485eb0cea..13eba70b7bcbab152d2d6a50f4776175c6e48879 100644 (file)
@@ -182,6 +182,10 @@ auth_authenticate_internal(char *what, struct sockaddr_in *caller,
                        return NULL;
                }
        }
+       if (exp->m_export.e_flags & NFSEXP_V4ROOT) {
+               *error = no_entry;
+               return NULL;
+       }
        if (!(exp->m_export.e_flags & NFSEXP_INSECURE_PORT) &&
                     ntohs(caller->sin_port) >= IPPORT_RESERVED) {
                *error = illegal_port;