-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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: Query to detect weak encryption: insufficient key size #4926
Conversation
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.qhelp
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.qhelp
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.ql
Outdated
Show resolved
Hide resolved
OK sure that's enough factoring, running tests |
Hey @luchua-bc,
|
@JarLob I've made requested changes. Please review. Thanks. |
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.qhelp
Outdated
Show resolved
Hide resolved
Please rebase. Pinged a codeowner for final review. |
bddd738
to
ab7d257
Compare
Thanks @smowton. I've rebased this branch. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks mostly good to me. Just a few comments.
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.java
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.java
Outdated
Show resolved
Hide resolved
java/ql/src/experimental/Security/CWE/CWE-326/InsufficientKeySize.qhelp
Outdated
Show resolved
Hide resolved
Thanks @aschackmull for reviewing this PR. I've made requested text changes. |
Strength of cryptographic algorithms depends on a sufficient key size to be robust against brute-force attacks. A theoretically sound encryption scheme with an insufficient key size can still be subjected to brute force attacks that have a reasonable chance of succeeding using current attack methods and resources.
This type of issues is categorized as CWE-326: Inadequate Encryption Strength.
This query finds uses of strong encryption algorithms (AES, DSA, RSA, and EC) with too small a key size.
Please consider to merge the PR. Thanks.