Skip to content

Commit

Permalink
OS-4331 lxbrand RPC: Authentication error while mounting nfs
Browse files Browse the repository at this point in the history
  • Loading branch information
jjelinek committed Sep 11, 2015
1 parent 04e897a commit 9acc669
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions usr/src/lib/brand/lx/lx_brand/common/mount_nfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -2002,6 +2002,7 @@ convert_nfs_arg_str(char *srcp, char *mntopts)
char *key, *val, *p;
char tmpbuf[MAX_MNTOPT_STR];
char *tbp = tmpbuf;
boolean_t no_sec = B_TRUE;

(void) strlcpy(tmpbuf, mntopts, sizeof (tmpbuf));
*mntopts = '\0';
Expand Down Expand Up @@ -2043,6 +2044,8 @@ convert_nfs_arg_str(char *srcp, char *mntopts)
*/
if (atoi(val) != 4)
return (-EINVAL);
} else if (strcmp(key, "sec") == 0) {
no_sec = B_FALSE;
} else {
int r;

Expand All @@ -2060,6 +2063,18 @@ convert_nfs_arg_str(char *srcp, char *mntopts)
}
}

if (no_sec) {
/*
* XXX Temporarily work around missing DES auth by defaulting
* to sec=sys.
*/
int r;

r = append_opt(mntopts, MAX_MNTOPT_STR, "sec", "sys");
if (r != 0)
return (r);
}

return (0);
}

Expand Down

0 comments on commit 9acc669

Please sign in to comment.