diff options
| author | David Wolinsky <davidiw@fb.com> | 2015-10-07 15:13:31 -0700 |
|---|---|---|
| committer | Jeff Darcy <jeff@pl.atyp.us> | 2017-07-13 00:54:16 +0000 |
| commit | e8029ec1fc205b5dace0c29ae3d1fe5b960e54fc (patch) | |
| tree | bb077cd22b4ffd3b16128a94eb8237d119a9acdf /xlators/nfs/server/src/nfs3-helpers.c | |
| parent | 90d375de2e1ea49468c432126babbaee66d85fc0 (diff) | |
[nfs] exports_auth per (sub) volume
Summary:
- exports_auth changed to a per-volume option
- parse exports_auth in nfs3.c
- set nfs3_export state for exports_auth
- all calls into mnt3_authenticate_request must pass in volname
- volname is checked to determine if auth is enabled for that volume
Test Plan: manual testing, will look into unit testing
Reviewers: rwareing, sshreyas
Reviewed By: sshreyas
Subscribers: rappleye
Differential Revision: https://phabricator.fb.com/D2519423
Tasks: 6863942
Change-Id: Ia9fd92ca5a5bd4cbb57e9ce61075f024ab7dbc27
Signature: t1:2519423:1444775772:24dc39e22684784b75899e97e9d1e294b059a077
Signed-off-by: Jeff Darcy <jdarcy@fb.com>
Reviewed-on: https://review.gluster.org/17762
Tested-by: Jeff Darcy <jeff@pl.atyp.us>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Smoke: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Jeff Darcy <jeff@pl.atyp.us>
Diffstat (limited to 'xlators/nfs/server/src/nfs3-helpers.c')
| -rw-r--r-- | xlators/nfs/server/src/nfs3-helpers.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/xlators/nfs/server/src/nfs3-helpers.c b/xlators/nfs/server/src/nfs3-helpers.c index 0b977092fbb..1edc2ac4429 100644 --- a/xlators/nfs/server/src/nfs3-helpers.c +++ b/xlators/nfs/server/src/nfs3-helpers.c @@ -3975,11 +3975,18 @@ nfs3_fh_auth_nfsop (nfs3_call_state_t *cs, gf_boolean_t is_write_op) { struct nfs_state *nfs = NULL; struct mount3_state *ms = NULL; + int auth_status = -1; nfs = (struct nfs_state *)cs->nfsx->private; ms = (struct mount3_state *)nfs->mstate; - return mnt3_authenticate_request (ms, cs->req, &cs->resolvefh, NULL, - NULL, NULL, NULL, is_write_op); + auth_status = mnt3_authenticate_request (ms, cs->req, &cs->resolvefh, + cs->vol->name, NULL, NULL, + NULL, is_write_op); + + if (auth_status != 0) { + cs->resolve_errno = auth_status; + } + return auth_status; } int |
