Docker: Several security and compatibility issues

Created on 1 Feb 2019  路  8Comments  路  Source: nextcloud/docker

  1. The __Host Prefix of the cookies isn't set properly -> leads to bad rating in security scan -> cant't influence this as the setting comes from the container
  2. Nextcloud reports that the webserver isn't correctly configured to resolve
    /.well-known/caldav
    /.well-known/carddav
    (using this Image with traefik reverse proxy)
question

Most helpful comment

I was able to resolve the __Host prefix issue with this guide: https://docs.nextcloud.com/server/13/admin_manual/configuration_server/reverse_proxy_configuration.html
but the resolve issue still persits

All 8 comments

Duplicate of #632?

I was able to resolve the __Host prefix issue with this guide: https://docs.nextcloud.com/server/13/admin_manual/configuration_server/reverse_proxy_configuration.html
but the resolve issue still persits

This seems to be an issue with your traefik configuration. The latest default image passes all checks.

See #527 for the .well-known issue, you have to change the .htaccess file.

See #644 for Apache, the .well-known and HSTS errors will be gone. When you run Nextcloud behind a proxy you also need a trusted proxy entry in the config.php, I will create a PR for this next week. Both can be added with environment variables.

I was able to resolve the __Host prefix issue with this guide: https://docs.nextcloud.com/server/13/admin_manual/configuration_server/reverse_proxy_configuration.html

Have to admit you're right :-)
But adding only overwriteprotocol and overwritehost did the thing for me!

@bd8392 The Nextcloud 16 documentation includes a solution for the resolve issue without touching the .htaccess file: click

Add the following labels to your nextcloud container:

traefik.frontend.redirect.permanent: 'true'
traefik.frontend.redirect.regex: https://(.*)/.well-known/(card|cal)dav
traefik.frontend.redirect.replacement: https://$$1/remote.php/dav/

Thanks that did the trick :-) the issue is resolved :-)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tanja84dk picture tanja84dk  路  3Comments

christianvw picture christianvw  路  3Comments

waldner picture waldner  路  3Comments

DisasteR picture DisasteR  路  3Comments

raimund-schluessler picture raimund-schluessler  路  3Comments