docs: document why Owner::own_result poisoning is safe#626
Conversation
All call sites are in Walker methods where the Owner is dropped immediately on error, making the poisoned state unreachable. Document this analysis so future audits don't attempt to fix a non-issue. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Owner::own_resultwhy the poisoning behavior is not exploitable and does not need to be fixedContext
A security audit flagged that
Owner::own_resultleaves theOwnerin a poisoned state when the closure returnsErr. Investigation confirmed this is not exploitable:Walkermethods (walk,walk_expect,attach,put_value, etc.)Walker(which owns theOwner<TreeNode>) is dropped immediatelyOwneris never accessed afterown_resultreturnsErrChanging the signature to
FnOnce(T) -> Result<T, (T, E)>was evaluated and rejected — it adds complexity to every closure for no practical benefit.This PR adds an "audit note" section to the doc comment so future audits don't re-investigate or attempt to fix this non-issue.
Test plan
🤖 Generated with Claude Code