Hello,
I use only HTTPS for my nextcloud. I installed today update for windows desktop client and it required open web link to grant access. I was able to login, but when I clicked on grant access it just froze.
After digging in console, I found error :
Content Security Policy: The page鈥檚 settings blocked the loading of a resource at [my server with http]. Since I was connected via https it was not allowed.
The POST link for grant should be https
The POST link for grant is http - CSP error
Operating system:
ubuntu 18 lts
Web server:
nginx + lighttpd
Database:
mysql
PHP version:
7.2.24
Nextcloud version: (see Nextcloud admin page)
17.0.3
Updated from an older Nextcloud/ownCloud or fresh install:
long ago it was even owncloud
Where did you install Nextcloud from:
updater
Nextcloud configuration:
$CONFIG = array (
'instanceid' => '[redacted]',
'passwordsalt' => '[redacted]',
'secret' => '[redacted]',
'trusted_domains' =>
array (
0 => '[redacted]',
),
'datadirectory' => '/opt/owncloud/data',
'overwrite.cli.url' => '[redacted]',
'dbtype' => 'mysql',
'version' => '17.0.3.1',
'dbname' => 'owncloud',
'dbhost' => 'localhost',
'dbtableprefix' => 'oc_',
'dbuser' => 'owncloud',
'dbpassword' => '[redacted]',
'logtimezone' => 'UTC',
'installed' => true,
'loglevel' => 2,
'theme' => '',
'maintenance' => false,
'mysql.utf8mb4' => true,
'updater.release.channel' => 'stable',
);
If you would need any additional info, please tell.
If https detection fails use overwriteprotocol.
thanks, did not know about this one, will try. Anyway I edited link in inspect and now its fine.
I added overwriteprotocol to config.php as documented here and it fixed the problem for me. Thanks for the tip @kesselb.
Editing the overwriteprotocol does no good when the Nextcloud installation is behind a reverse proxy and communicates with the proxy through http (as when using the docker image, for example).
This issue has been automatically marked as stale because it has not had recent activity and seems to be missing some essential information. It will be closed if no further activity occurs. Thank you for your contributions.