Invidious is an alternative front-end to YouTube
do a sanity check on the provided ucid
ChunkyProgrammer1838ac4c99e4
diff --git a/src/invidious/routes/feeds.cr b/src/invidious/routes/feeds.crindex dd8175dc..1b2cfba0 100644--- a/src/invidious/routes/feeds.cr+++ b/src/invidious/routes/feeds.cr@@ -146,7 +146,11 @@ module Invidious::Routes::Feedsenv.response.headers["Content-Type"] = "application/atom+xml"env.response.content_type = "application/atom+xml"- ucid = env.params.url["ucid"]+ if env.params.url["ucid"].matches?(/^[\w-]+$/)+ ucid = env.params.url["ucid"]+ else+ return error_atom(400, InfoException.new("Invalid channel ucid provided."))+ endparams = HTTP::Params.parse(env.params.query["params"]? || "")