Skip to content

config_save_dir may cause buffer overflow #2665

@partimScurra

Description

@partimScurra

Describe the issue
config_save_dir var is used in save_config func, where it is written into buf[128] array. Other strings that get written along with it only allow filepath to be ~90 chars long - longer filepath will result in buffer overflow.

To Reproduce
Is a code-related issue. Probably reproducible by setting config_save_dir >100 chars long.

Expected behavior
A check for the filepath size is needed to avoid overflow.

Keepalived version
2.3.4`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions