The vulnerability is a bypass of a previous prototype pollution fix (CVE-2023-26132) in the dottie.js library. The initial fix was incomplete, as it only prevented prototype pollution when __proto__ was the first segment in a dot-separated path. This allowed attackers to circumvent the protection by placing __proto__, constructor, or prototype in subsequent path segments.
The fixing commit, 7e8fa1345a4b46325f0eab8d7aeb1c4deaefdb14, reveals the exact locations of the vulnerability. The patch modifies both the Dottie.set and Dottie.transform functions. In both functions, a simple check (if (pieces[0] === '__proto__')) was replaced with a more robust validation that inspects every segment of the path (pieces.some(...)) for a list of dangerous keys (__proto__, constructor, prototype).
The removed lines are direct evidence of the flawed logic. The set function, which sets a value on a nested path, and the transform function, which converts a flat object with dot-notation keys into a nested object, were both susceptible. Exploitation would involve calling either of these functions with a specially crafted path string, leading to the modification of an object's prototype chain.