Skip to content

Incorrect description for backup encryption configuration #1924

@rndb8418

Description

@rndb8418

The comment above the 'encryption' setting for a backup is incorrect:

https://github.com/spatie/laravel-backup/blob/main/config/backup.php#L169-L176

It states the value can be set to null or false to disable encryption, but neither of these work.

If the value is set to null, this exception will occur:

Spatie\Backup\Config\BackupConfig::__construct(): Argument #10 ($encryption) must be of type string, null given, called in .../vendor/spatie/laravel-backup/src/Config/BackupConfig.php on line 35

If the value is set to false, it is converted to 0 due to the return type here:

https://github.com/spatie/laravel-backup/blob/main/src/Listeners/EncryptBackupArchive.php#L60-L71

This means that encryption can't be disabled using this config option, it can only be disabled by setting an null password.

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