Skip to content

push checker uses wrong url for cookie - leads to 403 #691

@nivadis

Description

@nivadis

the command occ notify_push:setup http://nextcloud.url/push

produeces requests to

127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /push/test/cookie HTTP/1.1" 301 162 "-" "Nextcloud Server Crawler"
127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /push/test/cookie HTTP/1.1" 200 9 "-" "Nextcloud Server Crawler"
127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /push/test/mapping/1 HTTP/1.1" 301 162 "-" "Nextcloud Server Crawler"
127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /push/test/mapping/1 HTTP/1.1" 200 1 "-" "Nextcloud Server Crawler"
127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /push/test/reverse_cookie HTTP/1.1" 301 162 "-" "Nextcloud Server Crawler"
127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /index.php/apps/notify_push/test/cookie HTTP/1.1" 403 0 "-" "-"
127.0.0.1 - - [16/Mar/2026:15:04:01 +0100] "GET /push/test/reverse_cookie HTTP/1.1" 200 27 "-" "Nextcloud Server Crawler"

shouldn't the second cookie url be /push/test/cookie instead of /index.php/apps/notify_push/test/cookie

as the redirect only works for /push/

with a rewrite in nginx it validates the second cookie with 200

		location ^~ /index.php/apps/notify_push/test/cookie {
			rewrite ^ https://nextcloud.url/push/test/cookie permanent;
		}

probably because of
https://github.com/nextcloud/notify_push/blob/main/src/nc.rs#L88

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions