Skip to content

Conversation

@swimricky
Copy link
Contributor

@swimricky swimricky commented May 16, 2023

Summary

Address fixes from TOB audit report

Changes

  1. Initialize - remove admin pubkey parameter & rename payer to admin in Initialize context and use admin.key() as whitelist.admin (TOB-PYTH-5)
  2. Delete - remove auth check (TOB-PYTH-7)
  3. Resize - add explicit max size of u16::MAX + MessageBuffer::HEADER_LEN and add check (TOB-PYTH-10)
  4. PutAll
    1. add bounds check for end_offset index (TOB-PYTH-9)
    2. fix truncation in put_all_in_buffer (TOB-PYTH-10)
  5. use consts for seeds

@vercel
Copy link

vercel bot commented May 16, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Ignored Deployments
Name Status Preview Comments Updated (UTC)
example-oracle-amm ⬜️ Ignored (Inspect) May 16, 2023 4:07pm
xc-admin-frontend ⬜️ Ignored (Inspect) May 16, 2023 4:07pm

Copy link
Collaborator

@ali-behjati ali-behjati left a comment

Choose a reason for hiding this comment

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

Nice! And great that you have added more tests to it 🙇

refactor missed consts, make initialize more readable
@swimricky swimricky merged commit f088854 into main May 16, 2023
@swimricky swimricky deleted the message-buffer/audit-fixes branch May 16, 2023 16:08
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.

4 participants