Skip to content

randomize hash values per process #37166

@StefanKarpinski

Description

@StefanKarpinski

Other languages randomize their hash values per process to protect against DOS attacks on hash tables by intentionally causing hash table collisions. This also forces users not to rely on accidental dictionary ordering in their code. Even in languages where dictionaries are ordered, it's a good DOS prevention measure to randomize the hashing per process: the change becomes invisible (because of ordering), but since attackers can't predict hash collisions, they can't force them. Regardless of whether we go with ordered dicts or not, we may want to do this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    hashingrandomnessRandom number generation and the Random stdlibsecuritySystem security concerns and vulnerabilities

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions