From simon@comsys.ntu-kpi.kiev.ua  Wed Apr 24 09:44:18 2013
Return-Path: <simon@comsys.ntu-kpi.kiev.ua>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1])
	by hub.freebsd.org (Postfix) with ESMTP id 81B052EB
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 24 Apr 2013 09:44:18 +0000 (UTC)
	(envelope-from simon@comsys.ntu-kpi.kiev.ua)
Received: from comsys.kpi.ua (comsys.kpi.ua [77.47.192.42])
	by mx1.freebsd.org (Postfix) with ESMTP id 405901A88
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 24 Apr 2013 09:44:17 +0000 (UTC)
Received: from pm513-1.comsys.kpi.ua ([10.18.52.101] helo=pm513-1.comsys.ntu-kpi.kiev.ua)
	by comsys.kpi.ua with esmtpsa (TLSv1:AES256-SHA:256)
	(Exim 4.63)
	(envelope-from <simon@comsys.ntu-kpi.kiev.ua>)
	id 1UUwFL-0001vI-86
	for FreeBSD-gnats-submit@freebsd.org; Wed, 24 Apr 2013 12:44:15 +0300
Received: by pm513-1.comsys.ntu-kpi.kiev.ua (Postfix, from userid 1001)
	id AC0621E089; Wed, 24 Apr 2013 12:44:14 +0300 (EEST)
Message-Id: <20130424094414.GA18874@pm513-1.comsys.ntu-kpi.kiev.ua>
Date: Wed, 24 Apr 2013 12:44:14 +0300
From: Andrey Simonenko <simon@comsys.ntu-kpi.kiev.ua>
To: FreeBSD-gnats-submit@freebsd.org
Subject: Correct support of index files for WebNFS exports

>Number:         178103
>Category:       kern
>Synopsis:       [kernel] [nfs] [patch] Correct support of index files for WebNFS exports
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-fs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Apr 24 09:50:00 UTC 2013
>Closed-Date:    Mon Sep 23 13:21:07 UTC 2013
>Last-Modified:  Mon Sep 23 13:21:07 UTC 2013
>Originator:     Andrey Simonenko
>Release:        FreeBSD 10-CURRENT amd64
>Organization:
>Environment:
>Description:

RFC 2055 describes index files for WebNFS exports.  The exports(5) manual
page has description of the -index option, but this option does not work
because of mistakes in mountd and kernel part of the NFS server.

The following change:

1. corrects handling of the -index option in usr.sbin/mountd/mountd.c;

2. corrects fetching of the index file in sys/kern/vfs_export.c;

3. corrects locking if a directory does not have the index file in
   sys/nfsserver/nfs_serv.c

This change is for the old NFS server, since new NFS server uses
another API for WebNFS settings and its logic of index files does not
correspond to RFC 2055.

>How-To-Repeat:

Export some file system with options "-public -index 123", then mount it
using NFSv2/3 client and public filehandle.  Create a regular file "123"
in some directory and try to read that directory on a client.  Do the same,
but create directory "123" with some content.  In both cases the content
of a directory with the index file in NFS mounted file system should
be altered.

>Fix:
 [patch elided - gavin@]
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-fs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Mon May 20 03:29:52 UTC 2013 
Responsible-Changed-Why:  
Involves NFS, but also a kernel and binary change.  Perhaps the NFS 
folks can review. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=178103 
State-Changed-From-To: open->closed 
State-Changed-By: gavin 
State-Changed-When: Mon Sep 23 13:16:49 UTC 2013 
State-Changed-Why:  
PR closed at submitters request. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=178103 
>Unformatted:
