Bug 182424

Summary: mount program segfaults when specifying mount program version as 2 over nfs
Product: Red Hat Enterprise Linux 4 Reporter: Neil Horman <nhorman>
Component: util-linuxAssignee: Steve Dickson <steved>
Status: CLOSED ERRATA QA Contact: Ben Levenson <benl>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.0CC: kzak, tao
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: RHBA-2006-0406 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-08-10 21:42:16 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 181409    
Attachments:
Description Flags
patch to correct mount behavior in util-linux-2.12a none

Description Neil Horman 2006-02-22 14:30:06 UTC
Description of problem:
The mount program will segfault if mounting an nfs mount using version 3 of the
nfs rpc program but version 2 of the mount rpc program

mount -t nfs -o nfsvers=3,mountvers=2 rxi600-4:/work /mnt/work
Segmentation fault (core dumped)

Version-Release number of selected component (if applicable):
mount program from util-linux-2.12a

How reproducible:
always

Steps to Reproduce:
1.mount -t nfs -o nfsvers=3,mountvers=2 <nfs server>:<exported path> <local path>


  
Actual results:
segfault

Expected results:
successful mount

Additional info:

Comment 1 Neil Horman 2006-02-22 14:38:15 UTC
Created attachment 125032 [details]
patch to correct mount behavior in util-linux-2.12a

problem turns out to be in nfsmount.  The segfault occurs because we try to
dereference the authentication flavors array, which is returned as NULL.  This
is occuring because we are trying to use the mount rpc program version 3
algorithm to process a mount when we requested the mount to be preformed using
mount rpc program version 2.  This in turn is because when we check the return
data from the rpc call, we select which algorithm we use based on the nfs rpc
program, rather than on the mount rpc version, which we should.  I've written
the attached patch to correct this behavior.  Tested and found working by me.

Comment 2 Karel Zak 2006-02-22 15:01:33 UTC
Steve, check the patch, please. Thanks.

Comment 5 Steve Dickson 2006-04-23 10:50:18 UTC
Fixed in util-linux-2.12a-16.EL4.17

Comment 10 Karel Zak 2006-07-05 21:13:27 UTC
*** Bug 197715 has been marked as a duplicate of this bug. ***

Comment 15 Red Hat Bugzilla 2006-08-10 21:42:16 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2006-0406.html