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

Reject resume data if it contains mismatching info hashes #7597

Merged
merged 1 commit into from
Feb 17, 2024

Conversation

glassez
Copy link
Contributor

@glassez glassez commented Jan 30, 2024

Otherwise, successfully loaded/parsed resume data could lead to an error when adding a torrent to session.

Copy link
Owner

@arvidn arvidn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good. is there a way for this to happen without someone (maliciously) creates a corrupt resume data file?

@arvidn
Copy link
Owner

arvidn commented Feb 1, 2024

I want to add a test as well. I'll land this once I have that ready

@glassez
Copy link
Contributor Author

glassez commented Feb 1, 2024

is there a way for this to happen without someone (maliciously) creates a corrupt resume data file?

In fact, I have not encountered exactly such a problem. I came across this code while dealing with a similar problem that has a different source.
But still, if the format allows for the possibility of containing inconsistent data, then it is better to have such a check when parsing it.

@arvidn arvidn merged commit 4128849 into arvidn:RC_2_0 Feb 17, 2024
41 of 42 checks passed
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

Successfully merging this pull request may close these issues.

None yet

2 participants