feat: resolve audit issues #021, #022, #029, #030 - #1434
Conversation
Akanimoh12#30 - Issue Akanimoh12#30: Granular pause with PauseFlag bitmask (Tips=1, Withdrawals=2, Registration=4, Subscriptions=8, Refunds=16). Per-operation pause checks in tips, profile, subscription, refund, and multitoken modules. 7 new tests in test_access_control.rs. - Issue Akanimoh12#29: Storage size limit enforcement for subscriptions (max 20 per subscriber). 2 new tests in test_dos_protection.rs. Storage limits table added to docs/CONTRACT_SPEC.md. - Issue Akanimoh12#22: Anti-wash trading with self-tip exclusion (CannotTipSelf), sender concentration cap (max_sender_contribution_bps), and sender-creator volume tracking. 3 new tests in test_tips.rs. - Issue Akanimoh12#21: Anonymous tips verified. 6/7 tests pass; 1 pre-existing pseudonym stability bug noted. Total new tests: 15. Zero regressions (546 passed, 11 pre-existing failures).
|
@ExcelDsigN-tech Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
|
| GitGuardian id | GitGuardian status | Secret | Commit | Filename | |
|---|---|---|---|---|---|
| 21431574 | Triggered | Generic Password | 93f0226 | .github/workflows/pr-checks.yml | View secret |
🛠 Guidelines to remediate hardcoded secrets
- Understand the implications of revoking this secret by investigating where it is used in your code.
- Replace and store your secret safely. Learn here the best practices.
- Revoke and rotate this secret.
- If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.
To avoid such incidents in the future consider
- following these best practices for managing and storing secrets including API keys and other credentials
- install secret detection on pre-commit to catch secret before it leaves your machine and ease remediation.
🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.
ce69cc0
into
Akanimoh12:test-implement-drips
feat: resolve audit issues Pause Controls, Storage Limits, Anti-Wash Trading, Anonymous Tips
Closes #1168, Closes #1169, Closes #1176, Closes #1177
Overview
Remediates 4 security and operational audit findings across pause granularity, storage resource limits, anti-wash trading mechanisms, and anonymous tip verification logic. Includes 15 new tests with zero regressions (546 passed total).
Feature Summary
PauseFlagbitmask enum for fine-grained operation-level pause controlsdocs/CONTRACT_SPEC.mdTechnical Implementation
PauseFlagbitmask enum (Tips=1,Withdrawals=2,Registration=4,Subscriptions=8,Refunds=16,All=0xFFFFFFFF)pausedstate withpause_flagsstorage keytips.rs,profile.rs,subscription.rs,refund.rs, andmultitoken.rscancel_subscriptionandexecute_due_subscriptionMAX_SUBSCRIPTIONS_PER_SUBSCRIBERcap (max 20 active subscriptions per subscriber), returningStorageLimitExceededwhen exceededdocs/CONTRACT_SPEC.md(social links, suggested amounts, subscriptions, leaderboard, display name, bio, message length)CannotTipSelferrorsender_creator_volumestoragemax_sender_contribution_bpscap against creator's all-time leaderboard totaltips.rsby removingif leaderboard_amount > 0guardupdate_entriesto trim oversized pre-existing leaderboards toMAX_LEADERBOARD_SIZEregister_creatorwithintest_anonymous_tips.rsto ensure unique usernames during test executionTest Coverage
test_access_control.rs: 7 new tests for pause flag granular controls (Passed)test_dos_protection.rs: 2 new tests for subscription storage cap enforcement (Passed)test_tips.rs: 3 new tests for anti-wash trading and concentration caps (Passed)test_anonymous_tips.rs: 3 fixed tests (6/7 passing, 1 pre-existing failure documented)test_pseudonym_stability_and_uniqueness,test_propose_overwrites_existing_proposal, budget/registration fixtures).Checklists
PauseFlagbitmask enum and replace global boolean pause stateMAX_SUBSCRIPTIONS_PER_SUBSCRIBER)docs/CONTRACT_SPEC.mdCannotTipSelf) and apply sender concentration volume limitsMAX_LEADERBOARD_SIZE