summaryrefslogtreecommitdiffstats
path: root/xlators/performance/quick-read
diff options
context:
space:
mode:
authorRaghavendra Bhat <raghavendra@redhat.com>2015-05-26 19:22:14 +0530
committerVenky Shankar <vshankar@redhat.com>2015-06-27 04:17:33 -0700
commit15dcfe98caa573e87d898cb66c13ef7187730c6b (patch)
tree0b4e523a9d34f71020200fb543e90ee248bcf7cf /xlators/performance/quick-read
parentc2f577c1caea959caf6d3c4b00f7c68c34a26edb (diff)
downloadglusterfs-15dcfe98caa573e87d898cb66c13ef7187730c6b.tar.gz
glusterfs-15dcfe98caa573e87d898cb66c13ef7187730c6b.tar.xz
glusterfs-15dcfe98caa573e87d898cb66c13ef7187730c6b.zip
features/bit-rot-stub: deny access to bad objects
* Access to bad objects (especially operations such as open, readv, writev) should be denied to prevent applications from getting wrong data. * Do not allow anyone apart from scrubber to set bad object xattr. * Do not allow bad object xattr to be removed. Change-Id: Ia9185a067233a9f26e3d41d41d11d9a4eb0da827 BUG: 1210689 Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com> Signed-off-by: Venky Shankar <vshankar@redhat.com> Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com> Reviewed-on: http://review.gluster.org/11126 Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Diffstat (limited to 'xlators/performance/quick-read')
-rw-r--r--xlators/performance/quick-read/src/quick-read.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/xlators/performance/quick-read/src/quick-read.c b/xlators/performance/quick-read/src/quick-read.c
index c6913ee471..1426ae5760 100644
--- a/xlators/performance/quick-read/src/quick-read.c
+++ b/xlators/performance/quick-read/src/quick-read.c
@@ -409,6 +409,11 @@ qr_lookup_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
goto out;
}
+ if (dict_get (xdata, GLUSTERFS_BAD_INODE)) {
+ qr_inode_prune (this, inode);
+ goto out;
+ }
+
if (dict_get (xdata, "sh-failed")) {
qr_inode_prune (this, inode);
goto out;