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

balrog shouldn't serve update xml that is invalid #3119

Open
bhearsum opened this issue May 22, 2024 · 1 comment
Open

balrog shouldn't serve update xml that is invalid #3119

bhearsum opened this issue May 22, 2024 · 1 comment

Comments

@bhearsum
Copy link
Contributor

In https://bugzilla.mozilla.org/show_bug.cgi?id=1893487 we had an issue that resulted in us serving update xml such as:

<?xml version="1.0"?>
<updates>
    <update type="minor" displayVersion="125.0a1" appVersion="125.0a1" platformVersion="125.0a1" buildID="20240301094944">
    </update>
</updates>

This is not valid, because it doesn't contain any patch entries, and Firefox was unable to parse it. (There are probably other ways the xml can be invalid as well, this is just one example.)

In cases like this we should probably throw a 500, and ensure that an Exception ends up in Sentry for visibility.

@bytesized - cc'ing you for visibility, and also in case you are aware of any existing schemas or validation code we have for these responses.

@bytesized
Copy link
Contributor

If you want to look, the parsing code lives here. I'm also happy to weigh in if there are any questions.

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

No branches or pull requests

2 participants