Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Atom Subscriptions Feed Self Link double XML encoded. #6312

Closed
kevincox opened this issue Apr 4, 2024 · 1 comment
Closed

Atom Subscriptions Feed Self Link double XML encoded. #6312

kevincox opened this issue Apr 4, 2024 · 1 comment
Labels
Component: Subscriptions Type: Bug 🐛 Confirmed bug, at least replicated once by another contributor

Comments

@kevincox
Copy link

kevincox commented Apr 4, 2024

Describe the current behavior

When accessing a subscription feed such as https://peertube.example/feeds/subscriptions.atom?accountId=123&token=efd5ffc4-4dfb-4c19-9b1c-696db563c964 the self link is incorrect as it is double-XML encoded such as <link rel="self" href="https://peertube.example/feeds/videos.atom?accountId=123&amp;amp;token=efd5ffc4-4dfb-4c19-9b1c-696db563c964"/>.

Steps to reproduce

% curl -i 'https://peertube.example/feeds/subscriptions.atom?accountId=123&token=efd5ffc4-4dfb-4c19-9b1c-696db563c964' | grep '<link rel="self"'
    <link rel="self" href="https://peertube.example/feeds/videos.atom?accountId=123&amp;amp;token=efd5ffc4-4dfb-4c19-9b1c-696db563c964"/>

Describe the expected behavior

The value of the href attribute should be the feed link. (Possibly normalized). For this example it should look like:

    <link rel="self" href="https://peertube.example/feeds/videos.atom?accountId=123&amp;token=efd5ffc4-4dfb-4c19-9b1c-696db563c964"/>

Note that the & is encoded once making the value of the attribute the original URL.

Additional information

  • PeerTube instance:

  • Browser name, version and platforms on which you could reproduce the bug: Various clients.

  • Link to browser console log if relevant: N/A

  • Link to server log if relevant (journalctl or /var/www/peertube/storage/logs/): Unknown

@kevincox kevincox changed the title RSS Feed Self Link double-XML encoded. Atom Subscriptions Feed Self Link double-XML encoded. Apr 4, 2024
@kevincox kevincox changed the title Atom Subscriptions Feed Self Link double-XML encoded. Atom Subscriptions Feed Self Link double XML encoded. Apr 4, 2024
@Chocobozzz Chocobozzz added Type: Bug 🐛 Confirmed bug, at least replicated once by another contributor Component: Subscriptions labels Apr 5, 2024
@Chocobozzz
Copy link
Owner

Chocobozzz commented Apr 5, 2024

Thanks! It should be fixed by 7163a1a

(source patch: Chocobozzz/feed@33a0bfe)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Subscriptions Type: Bug 🐛 Confirmed bug, at least replicated once by another contributor
Projects
None yet
Development

No branches or pull requests

2 participants