Skip to content
This repository has been archived by the owner on Jul 6, 2020. It is now read-only.

script tag in entry content is not stripped out #723

Closed
heubergen opened this issue Feb 9, 2015 · 10 comments
Closed

script tag in entry content is not stripped out #723

heubergen opened this issue Feb 9, 2015 · 10 comments

Comments

@heubergen
Copy link

I have install ownCloud 8, Opera 27.0 and install all Dependencies.
When I read a article from a feed I see some not nice code, that I don't see on other feed reader like tiny-tiny.
bildschirmfoto 2015-02-09 um 13 26 33

The Bug depend not only the web client, I have the same issue on my mobile client so I think it is problem here.

@cosenal
Copy link
Contributor

cosenal commented Feb 9, 2015

Please read this: https://github.com/owncloud/news#bugs

@heubergen
Copy link
Author

The feed is a valid Atom 1.0 feed.
bildschirmfoto 2015-02-10 um 11 19 53

Bug is also happen on supported browser:
bildschirmfoto 2015-02-10 um 11 21 32

@cosenal
Copy link
Contributor

cosenal commented Feb 10, 2015

Does it happen only with this particular feed? Do you mind to share the feed address?

@heubergen
Copy link
Author

Hmm, bug seems to happen only with this specific feed.
I can not share the address from this feed public (its a paid subscription) but I will share it with you.

Here a screenshot how other feed reader render this code:
bildschirmfoto 2015-02-10 um 17 02 39

Anyway I send you @cosenal a mail with the feed so you can test it.

@cosenal
Copy link
Contributor

cosenal commented Feb 10, 2015

Thanks a lot. I will have a look

@cosenal
Copy link
Contributor

cosenal commented Feb 11, 2015

It's a valid feed, but so many warnings!

Anyway, it looks like we don't strip out the script tag (see http://validator.w3.org/feed/docs/warning/SecurityRisk.html) cc @Raydiation

I created a demo feed with the same issue:
https://gist.githubusercontent.com/cosenal/b803844b747e180cec92/raw/786320a8f5f2a4e72ac42eb1c5bb2c0ffd5f8b38/feed.xml

gist: https://gist.github.com/cosenal/b803844b747e180cec92

@cosenal cosenal changed the title Can not read code (maybe php) script tag in entry content is not stripped out Feb 11, 2015
@BernhardPosselt
Copy link
Contributor

Hm we run it through two sanitizers and it's quite a trivial thing to sanitize. Will take a look next week once I'm back from holidays

@BernhardPosselt
Copy link
Contributor

PS, not a security issue since the script tag is converted to text, can confirm the bug.

Actually why the fuck are these guys serving a script tag in their feeds xD?

Are they trying to XSS their subscribers?

@cosenal
Copy link
Contributor

cosenal commented Feb 15, 2015

You're right, no security issue (my link to w3 was just to explain what a reader is supposed to do).

Also, I have no idea why their feeds suck so much, I run the OP's feed through w3 validator and it counts more than a thousand warnings!

@cosenal
Copy link
Contributor

cosenal commented Feb 24, 2015

It works perfectly on OP's feed. Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants