Visitar URL original
Java: PRNG used when CSPRNG is required · Issue #30 · github/securitylab · GitHub
The Wayback Machine - https://web.archive.org/web/20200908014845/https://github.com/github/securitylab/issues/30
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Java: PRNG used when CSPRNG is required #30

Open
JLLeitschuh opened this issue Jan 24, 2020 · 0 comments
Open

Java: PRNG used when CSPRNG is required #30

JLLeitschuh opened this issue Jan 24, 2020 · 0 comments
Labels

Comments

@JLLeitschuh
Copy link

@JLLeitschuh JLLeitschuh commented Jan 24, 2020 •

PRNG -> Pseudorandom Number Generator (predictably random)
CSPRNG -> Cryptographically Secure Pseudorandom Number Generator

CVE ID(s)

Most of these were not found using CodeQL. Most of them were found using GitHub's fuzzy code search.

I've got at least one CVE in flight for this currently.

Report

The goal of this query is to detect the use of a PRNG like java.util.Random, org.apache.commons.lang.RandomStringUtils, org.apache.commons.text.RandomStringGenerator, or java.util.concurrent.ThreadLocalRandom in a security sensitive context.
Security sensitive would be things like password reset URLs, token cookies, & temporary reset passwords.

This vulnerability can have up to a CVSSv3 score of 9.8/10 depending upon the use of the insecure data generated.

Query

The query can be found here: github/codeql#2694

Talk about the Query?

Sure, why not.

  • Are you planning to discuss this vulnerability submission publicly? (Blog Post, social networks, etc). We would love to have you spread the word about the good work you are doing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.