Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot save WOPI allow list when wopi_allowlist setting needs creating #3446

Closed
artfulrobot opened this issue Feb 1, 2024 · 3 comments
Closed
Labels
1. to develop Waiting for a developer bug Something isn't working feature: settings

Comments

@artfulrobot
Copy link

artfulrobot commented Feb 1, 2024

Describe the bug

Entering an IP address in the allow list box and clicking the → button causes the box to get blanked; the IP is not saved.

To Reproduce
Steps to reproduce the behavior:

  1. Go to /index.php/settings/admin/richdocuments
  2. Enter an IP address
  3. Click →
  4. pause while it loads then box goes blank.

Expected behavior
Save the IP

Screenshots
Screencast from 2024-02-01 08-19-47.webm

Client details:

  • OS: Fedora 39
  • Browser Firefox
  • Version 123.0b4
  • Device: desktop

Server details

Operating system: Debian

Web server: nginx

Database: MariaDB

PHP version: 8.1

Nextcloud version: 28.0.1

Version of the richdocuments app 8.3.1

Version of Collabora Online 23.5.705

Configuration of the richdocuments app

{                                                                                                                                                     
    "apps": {                                                                                                                                         
        "richdocuments": {                                                                                                                            
            "canonical_webroot": "",                                                                                                                  
            "disable_certificate_verification": "yes",                                                                                                
            "enabled": "yes",                                                                                                                         
            "installed_version": "8.3.1",                                                                                                             
            "public_wopi_url": "https:\/\/xxxx.uk",                                                                                       
            "types": "prevent_group_restriction",                                                                                                     
            "wopi_url": "https:\/\/xxxx.uk\/apps\/richdocumentscode\/proxy.php?req="                                                      
        }                                                                                                                                             
    }                                                                                                                                                 
} 

Browser log

It seems the problem is that the browser is sending null to https://safe.artfulrobot.uk/index.php/apps/richdocuments/ajax/admin.php

Body of the POST request:

{"wopi_allowlist":null}
@artfulrobot
Copy link
Author

The fix seems to be to set it from the command line, after that the UI works:

./occ  config:app:set richdocuments wopi_allowlist --value  '127.0.0.1' 

After doing this - which created the config value ,the UI shows 127... and also lets me update and save that value ok.

(If I was to guess it would be something javascripty around binding of things that don't exist.)

@artfulrobot artfulrobot changed the title Cannot save WOPI allow list Cannot save WOPI allow list when wopi_allowlist setting needs creating Feb 1, 2024
@Routhinator
Copy link

Confirming the bug with the latest helm chart and Nextcloud 28.0.1 and 28.0.2, and Nextcloud Office 8.3.1

Also confirming the workaround, and adding a quick one liner for those running with the helm chart:

kubectl -n nextcloud exec -it service/nextcloud -c nextcloud -- su -s /bin/sh www-data -c "php occ config:app:set richdocuments wopi_allowlist --value  '127.0.0.1,10.0.0.0/8'"
Config value wopi_allowlist for app richdocuments set to 127.0.0.1,10.0.0.0/8

@joshtrichards joshtrichards added bug Something isn't working 1. to develop Waiting for a developer feature: settings labels Feb 9, 2024
@joshtrichards
Copy link
Member

Duplicate of #3377

@joshtrichards joshtrichards marked this as a duplicate of #3377 Feb 12, 2024
@joshtrichards joshtrichards closed this as not planned Won't fix, can't repro, duplicate, stale Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1. to develop Waiting for a developer bug Something isn't working feature: settings
Projects
None yet
Development

No branches or pull requests

3 participants