Skip to content

glusterfsd crash caused by unprotected list traversal in gf_server_check_setxattr_cmd() #4639

@jiankyu

Description

@jiankyu

glusterfs version: v10.5

We encountered a glusterfsd crash issue recently, after analyzing the core dump, we are able to identify the crash happens in the server-helpers.c file, inside the gf_server_check_setxattr_cmd() function. When it traverses the xptr_list, it hit a nullptr, then when it wants to access the xprt->total_bytes_read, it hit the segmentation fault.

Access to the conf->xprt_list member must be protected by the conf->mutex lock, all other places follow this rule, unfortunately this function doesn't.

This problem exists in all active branches. (release-10, release-11, devel).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions