Skip to content

occ encryption:scan:legacy-format not available at 20.0.3 #24681

Description

@frlan

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Steps to reproduce

  1. Upgrade to 20.0.3 (I was coming from 19.0.6)
  2. Go to Administration->Overview
  3. Check the section Security & setup warnings and follow link to documentation (here: https://docs.nextcloud.com/server/20/go.php?to=admin-sse-legacy-format)

Expected behaviour

Documentation tells a valid command

Actual behaviour

Command mentioned in documentation does not exist

$ php occ encryption:scan:legacy-format

                                                                     
  There are no commands defined in the "encryption:scan" namespace.  
                                                                     
  Did you mean this?                                                 
      encryption                                                     
                                                                     

$ php occ encryption:scan --help

                                             
  Command "encryption:scan" is not defined.  
                                             
  Did you mean one of these?                 
      encryption:change-key-storage-root     
      encryption:decrypt-all                 
      encryption:disable                     
      encryption:enable                      
      encryption:encrypt-all                 
      encryption:list-modules                
      encryption:migrate-key-storage-format  
      encryption:set-default-module          
      encryption:show-key-storage-root       
      encryption:status                      
      files:scan                             
      files:scan-app-data                    
      maps:scan-photos                       
      maps:scan-tracks                       
      music:scan                             
                                             


Server configuration

Operating system:

Web server:

Database:

PHP version:

Nextcloud version: (see Nextcloud admin page)

Updated from an older Nextcloud/ownCloud or fresh install:

Where did you install Nextcloud from:

Signing status:

Signing status
Login as admin user into your Nextcloud and access 
http://example.com/index.php/settings/integrity/failed 
paste the results here.

List of activated apps:

App list
If you have access to your command line run e.g.:
sudo -u www-data php occ app:list
from within your Nextcloud installation folder

Nextcloud configuration:

Config report
If you have access to your command line run e.g.:
sudo -u www-data php occ config:list system
from within your Nextcloud installation folder

or 

Insert your config.php content here. 
Make sure to remove all sensitive content such as passwords. (e.g. database password, passwordsalt, secret, smtp password, …)

Are you using external storage, if yes which one: local/smb/sftp/...

Are you using encryption: no (turned off after repeatly loosing data due to other bugs

Are you using an external user-backend, if yes which one: no

Client configuration

Browser:

Operating system:

Logs

Web server error log

Web server error log
Insert your webserver log here

Nextcloud log (data/nextcloud.log)

Nextcloud log
Insert your Nextcloud log here

Browser log

Browser log
Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log
c) ...

Activity

  1. added
    0. Needs triagePending check for reproducibility or if it fits our roadmap
    on Dec 13, 2020
  2. changed the title [-]occ encryption:scan:legacy-format not availabel at 20.0.3[/-] [+]occ encryption:scan:legacy-format not available at 20.0.3[/+] on Dec 13, 2020
  3. kesselb commented on Dec 14, 2020

    @kesselb
    Contributor

    https://github.com/nextcloud/documentation/ is the repository for the documentation.

    However the command name is correct

    protected function configure() {
    $this
    ->setName('encryption:scan:legacy-format')
    ->setDescription('Scan the files for the legacy format');
    }

    but the command is only loaded if the encryption app is enabled. The warning is shown if encryption.legacy_format_support in your config.php is true. That's usually the case if the encryption app was enabled during the update and old key format use.

    I guess if you enable the encryption app you can run the command. We should probably check if the app is enabled in the setup check.

    cc @rullzer @MorrisJobke

  4. frlan commented on Dec 15, 2020

    @frlan
    Author

    I disabled the app I guess at some early 19.0.x (or even 18.0.x) state due to regular data loss. So this actually was not done by the update 19->20. However, I support the idea to consider whether he app is activated at all at this point.

  5. danielb42 commented on Dec 19, 2020

    @danielb42

    Same here, my Encryption app is disabled since ages/versions ago (also was never used). I followed the yellow warning in admin page to docs, to the "unknown command" error, to this issue...

  6. adrienafl commented on Dec 23, 2020

    @adrienafl

    Same here, I never used encryption before and I started to get the warning after upgrading to v20 without possibility to scan my files because, as mentioned before, the module isn't enabled in my setup.
    @danielb42 I just switched the legacy setting encryption in my config.php to false to get rid of the warning. Hope it helps

  7. kobuki commented on Dec 28, 2020

    @kobuki

    Same thing happens here on 20.0.3 after upgrading from 19.0.6. The documentation should be updated with a working how-to.

  8. Croydon commented on Jan 1, 2021

    @Croydon

    Also please update the documentation. I don't understand currently which kind of encryption is deprecated and if and how it potentially impacts me

  9. shelterx commented on Apr 20, 2021

    @shelterx

    I get this error in NC 21.

    I enabled the encryption module and ran
    occ encryption:scan:legacy-format
    It said: "All scanned files are properly encrypted. You can disable the legacy compatibility mode."
    I then disabled the encryption module app and the server still said:
    "The old server-side-encryption format is enabled. We recommend disabling this. For more details see the documentation."

    Then I ran
    occ encryption:disable
    It said "Encryption is already disabled"

    So I don't know why the server still complains about it.

  10. etnepresli commented on Apr 30, 2021

    @etnepresli

    A friendly guy from a reddit forum has shown a way to get rid of the message: (https://www.reddit.com/r/NextCloud/comments/jyej7d/issue_with_occ_encryptionscanlegacyformat_command/)

    1. make sure you are not using the legacy encrytion with: occ encryption:status
    2. change the following parameter inside the config.php (should be in your nextcloud folder; e.g. /var/www/nextcloud/config/config.php) to false: 'encryption.legacy_format_support' => false,
  11. szaimen commented on Jul 2, 2021

    @szaimen
    Contributor

    Is this Issue still valid in NC21.0.3? If not, please close this issue. Thanks! :)

  12. ghost added
    staleTicket or PR with no recent activity
    on Aug 1, 2021
  13. ghost closed this as completedon Aug 15, 2021
  14. Wikinaut commented on Mar 6, 2022

    @Wikinaut
    Contributor

    occ encryption:scan:legacy-format

    Should be removed from the documentation, as the command is not longer available.

    https://docs.nextcloud.com/server/22/admin_manual/configuration_files/encryption_migration.html

  15. giox069 commented on Nov 11, 2022

    @giox069

    This issue is still here.
    This page is wrong: https://docs.nextcloud.com/server/24/admin_manual/configuration_files/encryption_migration.html
    the command occ encryption:scan:legacy-format does not work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions