ofir vainshtein has uploaded this change for review.

View Change

Refactor: Add bounds-checked fattr comparison in nfs4_Fattr_cmp

Introduced a helper function `fattrs_is_equal` to safely compare portions of fattr4 buffers, including bounds checks. Replaced direct memcmp calls in `nfs4_Fattr_cmp` with calls to this new helper. Also, optimized the FATTR4_ACL comparison to use a single memcmp call for the entire attribute value.

Change-Id: Ifbd2905b8d4e41ffb58f0b43ba7b0b70977443c3
Signed-off-by: Ofir Vainshtein <ofirvins@google.com>
---
M src/Protocols/NFS/nfs_proto_tools.c
1 file changed, 42 insertions(+), 36 deletions(-)

git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha refs/changes/47/1238447/1

To view, visit change 1238447. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: newchange
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Change-Id: Ifbd2905b8d4e41ffb58f0b43ba7b0b70977443c3
Gerrit-Change-Number: 1238447
Gerrit-PatchSet: 1
Gerrit-Owner: ofir vainshtein <ofirvins@google.com>