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

Deserialization security #2

Closed
ilblackdragon opened this issue Aug 17, 2019 · 0 comments · Fixed by #15
Closed

Deserialization security #2

ilblackdragon opened this issue Aug 17, 2019 · 0 comments · Fixed by #15
Assignees

Comments

@ilblackdragon
Copy link
Member

We should add a suit of tests for security of deserialization, specifically:

  • Pass invalid Enum value
  • cc @frol Pass MAX INT length for arrays / strings / hashmaps (the memory allocation issues are preventable by simple check that if len > buf.len() { return Err() } )
  • non utf-8 string
  • missing part of the message
  • extra bytes after the message
voidxnull added a commit to zeropoolnetwork/borsh that referenced this issue Nov 26, 2020
It finally compiles but the design is not finalized.
bare-io and hashbrown are used as temporary (?) shims.
voidxnull added a commit to zeropoolnetwork/borsh that referenced this issue Nov 26, 2020
It finally compiles but the design is not finalized.
bare-io and hashbrown are used as temporary (?) shims.
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 a pull request may close this issue.

2 participants