Skip to content

Conversation

@cwaldren-ld
Copy link
Contributor

Current API of EvaluationStack is very easy to accidentally misuse because it takes a reference to its key argument. If the arg is destroyed, then we'll have a use-after-free.

@cwaldren-ld cwaldren-ld requested a review from a team July 19, 2023 21:12
@cwaldren-ld cwaldren-ld changed the base branch from main to server-side July 19, 2023 21:12
@cwaldren-ld cwaldren-ld requested a review from kinyoklion July 19, 2023 21:13
@kinyoklion kinyoklion self-requested a review July 19, 2023 21:15

Guard::Guard(std::unordered_set<std::string>& set, std::string const& key)
Guard::Guard(std::unordered_set<std::string>& set, std::string key)
: set_(set), key_(key) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Linter would like a move for the key.

@cwaldren-ld cwaldren-ld merged commit 0ead705 into server-side Jul 19, 2023
@cwaldren-ld cwaldren-ld deleted the cw/guard-uaf-fix branch July 19, 2023 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants