Skip to content

open_basedir errors after upgrade to PHP 7.4.21 (from 7.4.20), BUT... #39034

@criwayc

Description

@criwayc

Steps to reproduce

  1. Upgrade or switch to PHP 7.4.21 from any other (7.2, 7.3) or older PHP version (<=7.4.20)
  2. Open Owncloud login page in webbrowser
  3. Check owncloud.log

Expected behaviour

no error/warning messages in owncloud.log

Actual behaviour

logs this error:

{"reqId":"7IbUb9x1ecNegVjEk5cV","level":3,"time":"2021-07-20T12:07:42+02:00","remoteAddr":"194.246.xxx.xxx","user":"--","app":"PHP","method":"GET","url":"\/index.php\/core\/js\/oc.js?v=0a6bc82e3b6d497ce779c3020f959136","message":"file_exists(): open_basedir restriction in effect. File(\/appinfo\/routes.php) is not within the allowed path(s): (\/webhome\/myowncloud.net\/:\/usr\/share\/php\/:\/usr\/bin\/:\/tmp\/:\/dev\/urandom:\/zpool1\/myowncloud.net) at \/webhome\/myowncloud.net\/lib\/private\/Route\/Router.php#136"

Server configuration

Operating System: Debian 10.10, Debian 9.13

Web server: Apache2, Nginx

Database: MariaDB 10.1, MariaDB 10.5

PHP version: PHP 7.4.21 (libapache2-mod-php7.4 & php7.4-fpm)

ownCloud version: 10.7.0.4

Updated from an older ownCloud or fresh install: fresh install

Where did you install ownCloud from: https://download.owncloud.org/community/owncloud-10.7.0.tar.bz2

Signing status (ownCloud 9.0 and above):

No errors have been found.

The content of config/config.php:

{
    "system": {
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "myowncloud.net",
            "www.myowncloud.net"
        ],
        "datadirectory": "\/zpool1\/myowncloud.net",
        "overwrite.cli.url": "https:\/\/myowncloud.net",
        "dbtype": "mysql",
        "version": "10.7.0.4",
        "dbname": "myowncloudnet",
        "dbhost": "localhost",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "logtimezone": "Europe\/Zurich",
        "apps_paths": [
            {
                "path": "\/webhome\/myowncloud.net\/apps",
                "url": "\/apps",
                "writable": false
            },
            {
                "path": "\/webhome\/myowncloud.net\/apps-external",
                "url": "\/apps-external",
                "writable": true
            }
        ],
        "installed": true,
        "instanceid": "oclzcbvgb3ae",
        "mail_smtpmode": "php",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "activity_expire_days": 93,
        "log_rotate_size": 104857600,
        "loglevel": 3,
        "filelocking.enabled": true,
        "memcache.local": "\\OC\\Memcache\\APCu",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "\/run\/redis\/redis-server.sock",
            "port": 0,
            "timeout": 0
        },
    }
}

List of activated apps:

Enabled:
  - comments:
    - Version: 0.3.0
    - Path: /webhome/myowncloud.net/apps/comments
  - configreport:
    - Version: 0.2.0
    - Path: /webhome/myowncloud.net/apps/configreport
  - dav:
    - Version: 0.6.0
    - Path: /webhome/myowncloud.net/apps/dav
  - federatedfilesharing:
    - Version: 0.5.0
    - Path: /webhome/myowncloud.net/apps/federatedfilesharing
  - federation:
    - Version: 0.1.0
    - Path: /webhome/myowncloud.net/apps/federation
  - files:
    - Version: 1.5.2
    - Path: /webhome/myowncloud.net/apps/files
  - files_external:
    - Version: 0.7.1
    - Path: /webhome/myowncloud.net/apps/files_external
  - files_mediaviewer:
    - Version: 1.0.4
    - Path: /webhome/myowncloud.net/apps/files_mediaviewer
  - files_sharing:
    - Version: 0.14.0
    - Path: /webhome/myowncloud.net/apps/files_sharing
  - files_trashbin:
    - Version: 0.9.1
    - Path: /webhome/myowncloud.net/apps/files_trashbin
  - files_versions:
    - Version: 1.3.0
    - Path: /webhome/myowncloud.net/apps/files_versions
  - firstrunwizard:
    - Version: 1.2.0
    - Path: /webhome/myowncloud.net/apps/firstrunwizard
  - market:
    - Version: 0.6.1
    - Path: /webhome/myowncloud.net/apps-external/market
  - notifications:
    - Version: 0.5.2
    - Path: /webhome/myowncloud.net/apps/notifications
  - provisioning_api:
    - Version: 0.5.0
    - Path: /webhome/myowncloud.net/apps/provisioning_api
  - systemtags:
    - Version: 0.3.0
    - Path: /webhome/myowncloud.net/apps/systemtags
  - updatenotification:
    - Version: 0.2.1
    - Path: /webhome/myowncloud.net/apps/updatenotification
Disabled:
  - encryption:
    - Path: /webhome/myowncloud.net/apps/encryption
  - external:
    - Path: /webhome/myowncloud.net/apps/external
  - user_external:
    - Path: /webhome/myowncloud.net/apps/user_external

Are you using external storage, if yes which one: No

Are you using encryption: no

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

Client configuration

Browser: Firefox, Chrome

Operating system: Windows

Logs

ownCloud log (data/owncloud.log)

{"reqId":"7IbUb9x1ecNegVjEk5cV","level":3,"time":"2021-07-20T12:07:42+02:00","remoteAddr":"194.246.xxx.xxx","user":"--","app":"PHP","method":"GET","url":"\/index.php\/core\/js\/oc.js?v=0a6bc82e3b6d497ce779c3020f959136","message":"file_exists(): open_basedir restriction in effect. File(\/appinfo\/routes.php) is not within the allowed path(s): (\/webhome\/myowncloud.net\/:\/usr\/share\/php\/:\/usr\/bin\/:\/tmp\/:\/dev\/urandom:\/zpool1\/myowncloud.net) at \/webhome\/myowncloud.net\/lib\/private\/Route\/Router.php#136"

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