bitshares / bitshares/bitshares-core
Audit charging of per-kilobyte fees
- Dominant language
- C++
- Stars
- 1.2k
- Forks
- 660
- Avg merge
- 8h 17m
- Merged PRs (30d)
- 26
Description
_From @theoreticalbts on July 31, 2015 15:22_
Any operation with potentially unbounded size needs to charge a size fee. Determining whether an operation is variable-size is non-trivial. An operation is variable size if it contains a `vector`, `flat_set` or other potentially variable-size element.
Note that this containment may be through any number of intermediate `struct`s. For example, any operation which contains an `authority` has potentially unbounded size.
We should be able to audit this in a semi-automatic way with logic similar to `js_operation_serializer` which traverses all operations, and noting any variable-size types found (in any number of sub-structures), allowing us to flag each operation as variable-sized (or not). We will still have to manually specify whether any base type is variable-size or not.
_Copied from original issue: cryptonomex/graphene#216_
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by locating and reading the existing js_operation_serializer traversal and the operation and base-type definitions it processes. The audit should follow variable-size elements through nested structs, record which operations can be unbounded, and leave each base type explicitly classified so per-kilobyte fee coverage can be reviewed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- blockchain
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100