diff options
author | rmacklem <rmacklem@FreeBSD.org> | 2015-08-08 22:06:07 +0000 |
---|---|---|
committer | rmacklem <rmacklem@FreeBSD.org> | 2015-08-08 22:06:07 +0000 |
commit | 83028e54ab8f8b1bab3e88aed286cc829c23f28d (patch) | |
tree | a343d7ad564134b65480a45707e91ffa5fd58c2e /sbin | |
parent | 3682d7b83b63e48c58e8a893a2cb6229a8cb9ae3 (diff) | |
download | FreeBSD-src-83028e54ab8f8b1bab3e88aed286cc829c23f28d.zip FreeBSD-src-83028e54ab8f8b1bab3e88aed286cc829c23f28d.tar.gz |
MFC: r285260
Since the case where secflavor < 0 indicates the security flavor is
to be negotiated, it could be a Kerberized mount. As such, filling
in the "principal" argument using the canonized host name makes sense.
If it is negotiated as AUTH_SYS, the "principal" argument is meaningless
but harmless.
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/mount_nfs/mount_nfs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sbin/mount_nfs/mount_nfs.c b/sbin/mount_nfs/mount_nfs.c index 7f53581..836bc87 100644 --- a/sbin/mount_nfs/mount_nfs.c +++ b/sbin/mount_nfs/mount_nfs.c @@ -591,8 +591,8 @@ getnfsargs(char *spec, struct iovec **iov, int *iovlen) * For a Kerberized nfs mount where the "principal" * argument has not been set, add it here. */ - if (got_principal == 0 && secflavor >= 0 && - secflavor != AUTH_SYS && ai_nfs->ai_canonname != NULL) { + if (got_principal == 0 && secflavor != AUTH_SYS && + ai_nfs->ai_canonname != NULL) { snprintf(pname, sizeof (pname), "nfs@%s", ai_nfs->ai_canonname); build_iovec(iov, iovlen, "principal", pname, |