Skip to content

autoloader.php could raise Not AllowedException - #16813

Merged
blizzz merged 1 commit into
nextcloud:masterfrom
compagnon:fix/noid/AutoloadNotAllowedException-theming-off
Aug 21, 2019
Merged

autoloader.php could raise Not AllowedException#16813
blizzz merged 1 commit into
nextcloud:masterfrom
compagnon:fix/noid/AutoloadNotAllowedException-theming-off

Conversation

@compagnon

@compagnoncompagnon commented Aug 20, 2019

Copy link
Copy Markdown
Contributor

name: NotAllowedException raised by autoloader.php if Theming app is disabled / off
about: Internal Server error just after the login
labels: bug, 0. Needs triage

Steps to reproduce

  1. Disable Theming App (for example to get back the default theming)
  2. Logout
  3. Login

Expected behaviour

layout.user page with app/files

Actual behaviour

Internal server error and log

Server configuration

Operating system:
WSL2
Web server:
nginx
Database:
postgresql
PHP version:
7.3
Nextcloud version:
master / 17.0.0 Beta 1

{"reqId":"FTdKwXVIUVbZCODMZiGT","level":3,"time":"2019-08-20T14:39:21+00:00","remoteAddr":"127.0.0.1","user":"sagis","app":"index","method":"GET","url":"/apps/files/","message":{"Exception":"OCP\AutoloadNotAllowedException","Message":"Autoload path not allowed: /mnt/c/localGIT/compagnon/nextcloud-server-master/apps/theming/lib/util.php","Code":0,"Trace":[{"file":"/mnt/c/localGIT/compagnon/nextcloud-server-master/lib/autoloader.php","line":162,"function":"isValidPath","class":"OC\Autoloader","type":"->","args":["/mnt/c/localGIT/compagnon/nextcloud-server-master/apps/theming/lib/util.php"]},{"function":"load","class":"OC\Autoloader","type":"->","args":["OCA\Theming\Util"]},{"function":"spl_autoload_call","args":["OCA\Theming\Util"]},{"file":"/mnt/c/localGIT/compagnon/nextcloud-server-master/lib/private/AppFramework/Utility/SimpleContainer.php","line":97,"function":"__construct","class":"ReflectionClass","type":"->","args":["OCA\Theming\Util"]},{"file":"/mnt/c/localGIT/compagnon/nextcloud-server-master/lib/private/AppFramework/Utility/SimpleContainer.php","line":114,"function":"resolve","class":"OC\AppFramework\Utility\SimpleContainer","type":"->","args":["OCA\Theming\Util"]},{"file":"/mnt/c/localGIT/compagnon/nextcloud-server-master/lib/private/ServerContainer.php","line":145,"function":"query","class":"OC\AppFramework\Utility\SimpleContainer","type":"->","args":["OCA\Theming\Util",true]},....{"file":"/mnt/c/localGIT/compagnon/nextcloud-server-master/lib/base.php","line":1000,"function":"match","class":"OC\Route\Router","type":"->","args":["/apps/files/"]},{"file":"/mnt/c/localGIT/compagnon/nextcloud-server-master/index.php","line":42,"function":"handleRequest","class":"OC","type":"::","args":[]}],"File":"/mnt/c/localGIT/compagnon/nextcloud-server-master/lib/autoloader.php","Line":137,"CustomMessage":"--"},"userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Firefox/68.0","version":"17.0.0.2"}

when theming is off
Signed-off-by: Guillaume Compagnon <gcompagnon@outlook.com>
modified: lib/private/TemplateLayout.php
@compagnon
compagnonforce-pushed the fix/noid/AutoloadNotAllowedException-theming-off branch from d0c2785 to 0516675CompareAugust 20, 2019 15:12
@gary-kimgary-kim added 3. to review Waiting for reviews bug labels Aug 20, 2019
@juliusknorrjuliusknorr added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Aug 21, 2019
@blizzz
blizzz merged commit 9ac15bc into nextcloud:masterAug 21, 2019
@welcome

welcomeBot commented Aug 21, 2019

Copy link
Copy Markdown

Thanks for your first pull request and welcome to the community! Feel free to keep them coming! If you are looking for issues to tackle then have a look at this selection: https://github.com/nextcloud/server/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22
Most developers hang out on IRC. So join #nextcloud-dev on Freenode for a chat!

@blizzzblizzz added this to the Nextcloud 17 milestone Aug 21, 2019
@rullzerrullzer mentioned this pull request Aug 22, 2019
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4. to releaseReady to be released and/or waiting for tests to finishbug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@compagnon@blizzz@juliusknorr@gary-kim