Skip to content

Use secrets.choice and 600,000 iterations for WAMP-CRA keygen helper #1633

@Gax-c

Description

@Gax-c

I've got some suggestions which may be useful and can help make it more secure.

  1. The "random.choice()" used here may be considered vulnerable because the "random" module is not suitable for cryptographic operations as it is not cryptographically secure.
    Adopting "os.urandom" or functions from the 'secrets' module may be a feasible solution.
  2. The default iteration for pbkdf2 should be at least 10000, while the current default iteration here is only 1000.
    You can increase the iteration to at least 10000 to fix it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions