Skip to content

bump_storage operator entrypoint wiring (operator-role only) #144

Description

@ibrahimmosouf-png

bump_storage operator entrypoint wiring (operator-role only)

Labels: api, cli, security, priority/low
Difficulty: Low · Effort: S
Backlog slot: 57

Problem Statement

bump_all_persistent(env, milestone_count) exists in storage.rs but no public entrypoint surfaces it.

Why it Matters

Security note: an "any caller can bump TTL" entrypoint would be a gas/DoS vector on storage rent. The new entrypoint must require an explicit operator role (e.g. OperatorData(Address) keyed set, authorised at initialize time) — not a public function.

Expected Outcome

  • pub fn bump_storage(env: Env, operator: Address) requires operator.require_auth() AND that operator ∈ DataKey::Operators.
  • orbitchain-cli bump-storage --id <CID> --operator-secret-key <S> invokes it.

Acceptance Criteria

  • Caller without operator role panics with Error::Unauthorized.
  • CLI option works end-to-end against a freshly authorized operator.

Files Likely Affected

  • campaign/src/lib.rs, campaign/src/storage.rs, crates/tools/src/main.rs

Dependencies

Issue #33 (storage layer), Issue #5 (admin multi-sig).


Metadata

Metadata

Assignees

Labels

GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardOfficial Campaign | FWC26Campaign: Official Campaign | FWC26apiImported from .github/ISSUES_TO_CREATE.mdcliImported from .github/ISSUES_TO_CREATE.mdpriority/lowImported from .github/ISSUES_TO_CREATE.mdsecurityImported from .github/ISSUES_TO_CREATE.md

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions