#solana-programs #anchor #saber #check #validation #validate #safer

vipers

Assorted checks and validations for writing safer Solana programs

24 stable releases

2.0.6 Jul 20, 2022
2.0.2 Mar 21, 2022
1.6.1 Feb 14, 2022
1.5.5 Dec 4, 2021
0.1.1 Aug 23, 2021

#7 in #saber

Download history 179/week @ 2023-11-19 116/week @ 2023-11-26 99/week @ 2023-12-03 127/week @ 2023-12-10 171/week @ 2023-12-17 151/week @ 2023-12-24 52/week @ 2023-12-31 155/week @ 2024-01-07 158/week @ 2024-01-14 93/week @ 2024-01-21 51/week @ 2024-01-28 152/week @ 2024-02-04 120/week @ 2024-02-11 134/week @ 2024-02-18 251/week @ 2024-02-25 138/week @ 2024-03-03

674 downloads per month
Used in 56 crates (41 directly)

Apache-2.0

35KB
658 lines

vipers 😎

Crates.io License Build Status Contributors Code Coverage

Assorted checks and validations for writing safer Solana programs.

Motivation

Solana's fee mechanism is unlike Ethereum's, in that the number of bytecode instructions executed does not add to the cost of a transaction. Due to this, it is wise to design Solana code with excessive safety checks in order to minimize the chance of exploits.

This library provides several utilities for Anchor programs to validate account structs and check for invariants.

Support

For support, join the Saber Discord at chat.saber.so!

License

Apache 2.0

Dependencies

~10–22MB
~304K SLoC