protected function validateValue($value)
    {
        // strip empty lines
        $lines = array_filter(
            explode("\n", $value)
        );

        // strip comments (lines beginning with "#")
        $lines = array_filter($lines, function ($line) {
            $line = trim($line);

            return !empty($line) && $line[0] !== '#';
        });

        // validate each line
        foreach ($lines as $line) {
            if (!$this->validateLine($line)) {
                return false;
            }
        }

        return true;
    }