Skip to content

pihole-FTL --config sometimes returns the wrong value if sudo is not used #2849

@rdwebdesign

Description

@rdwebdesign

Expected behavior

pihole-FTL --config <option> should return the current value of <option>.
If FTL can't read the current value, an error message or warning should be returned.

Actual behavior / bug

In some cases, when sudo is not used, the command pihole-FTL --config <option> returns the default value for <option>, instead of the current selected value.
No error or warning messages are shown. Just the default value is returned.

Repeating the same command with sudo (sudo pihole-FTL --config <option>), returns the expected value.

This is a problem when Pi-hole user expects to see the current selected value, but is using an OS user without enough permissions and forgets to add sudo.

Note: the issue depends on the user permissions and it happens only in some cases. Some tests returned the expected value even without sudo.

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions