Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG)

Property
Languagejavascript
Severitylow
CWECWE-338: Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG)
OWASPA02:2021 - Cryptographic Failures
Confidence LevelLow
Impact LevelLow
Likelihood LevelLow

Description

The code is using crypto.pseudoRandomBytes, which does not generate cryptographically secure random values. This means random numbers produced by this function can be predicted or reproduced by attackers.

Impact

If insecure random numbers are used for generating secrets, tokens, or cryptographic keys, attackers may be able to guess these values, leading to compromised authentication, session hijacking, or exposure of sensitive data.

Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG)

Property
Languageswift
Severitylow
CWECWE-338: Use of Cryptographically Weak Pseudo-Random Number Generator (PRNG)
OWASPA02:2021 - Cryptographic Failures
Confidence LevelLow
Impact LevelLow
Likelihood LevelLow

Description

The code uses random number generators that are not cryptographically secure, such as random(), arc4random(), or Int.random(). These should not be used for generating secrets, tokens, or any values related to security.

Impact

If insecure random number generators are used in security-sensitive contexts, attackers may be able to predict values like authentication tokens or cryptographic keys, leading to compromised user data, account takeovers, or other serious breaches.

Use of Externally-Controlled Format String

Property
Languagec
Severitymedium
CWECWE-134: Use of Externally-Controlled Format String
Confidence LevelLow
Impact LevelHigh
Likelihood LevelMedium

Description

Using user-supplied input directly as the format string in functions like sprintf, printf, or vsprintf is dangerous. This allows attackers to manipulate the format string, leading to unexpected behavior or memory access.

Impact

An attacker could exploit this to read sensitive memory, crash the program, or execute arbitrary code, leading to data breaches or full system compromise. This vulnerability is severe and can be used to take control of the application or leak confidential information.

Use of Externally-Controlled Format String

Property
Languagejavascript
Severitylow
CWECWE-134: Use of Externally-Controlled Format String
OWASPA01:2021 - Broken Access Control
Confidence LevelLow
Impact LevelLow
Likelihood LevelMedium

Description

Using variables or user input as the format string in util.format or console.log can let attackers inject unexpected format specifiers, altering log messages or causing confusing output. It’s safer to use constant format strings to prevent manipulation.

Impact

If exploited, attackers could forge or obscure log messages, making it harder to track activity or debug issues. This can hide malicious actions, hinder incident response, and reduce the trustworthiness of your application’s logs.

Use of Externally-Controlled Format String

Property
Languagepython
Severitylow
CWECWE-134: Use of Externally-Controlled Format String
Confidence LevelLow
Impact LevelMedium
Likelihood LevelLow

Description

User input is being directly inserted into a string with .format() and then used to build a request URL in a Flask API controller. This allows untrusted data to shape outgoing requests, which can introduce security risks.

Impact

An attacker could manipulate the API to send requests to unintended or malicious destinations, potentially enabling server-side request forgery (SSRF), data leakage, or unauthorized access to internal services. This could compromise sensitive information or expose internal systems.

Use of Externally-Controlled Input to Select Classes or Code (‘Unsafe Reflection’)

Property
Languagego
Severitylow
CWECWE-470: Use of Externally-Controlled Input to Select Classes or Code (‘Unsafe Reflection’)
OWASPA03:2021 - Injection
Confidence LevelLow
Impact LevelLow
Likelihood LevelLow

Description

The code uses user-supplied input to dynamically select methods or fields via reflect.MethodByName or reflect.FieldByName in Go. This allows external input to control which function or field is accessed at runtime, which is unsafe.

Impact

An attacker could manipulate input to invoke unintended methods or access sensitive fields, potentially bypassing authentication or authorization checks. This can lead to unauthorized actions, data leaks, or unexpected application behavior.

Use of Externally-Controlled Input to Select Classes or Code (‘Unsafe Reflection’)

Property
Languagejava
Severitylow
CWECWE-470: Use of Externally-Controlled Input to Select Classes or Code (‘Unsafe Reflection’)
OWASPA03:2021 - Injection
Confidence LevelLow
Impact LevelLow
Likelihood LevelLow

Description

The code uses Class.forName with a class name that can be influenced by user input. This allows attackers to control which classes are loaded at runtime, leading to unexpected or unsafe application behavior.

Impact

An attacker could load arbitrary classes, potentially bypassing security checks, executing unauthorized code, or causing the application to malfunction. This could lead to privilege escalation, data exposure, or compromise of the application’s integrity.

Use of Externally-Controlled Input to Select Classes or Code (‘Unsafe Reflection’)

Property
Languagephp
Severitymedium
CWECWE-470: Use of Externally-Controlled Input to Select Classes or Code (‘Unsafe Reflection’)
OWASPA03:2021 - Injection
Confidence LevelMedium
Impact LevelMedium
Likelihood LevelMedium

Description

The code creates a new object using a class name that comes directly from user input, such as GET, POST, COOKIE, REQUEST, or SERVER variables. This allows attackers to control which class is instantiated, leading to unsafe behavior.

Use of Hard-coded Credentials

Property
Languageyaml
Severitymedium
CWECWE-798: Use of Hard-coded Credentials
OWASPA07:2021 - Identification and Authentication Failures
Confidence LevelMedium
Impact LevelMedium
Likelihood LevelLow

Description

Sensitive information such as passwords, API keys, or tokens is being stored directly in Kubernetes configuration files. This makes secrets visible to anyone with access to the codebase or version control.

Impact

If these files are leaked or accessed by unauthorized users, attackers can obtain credentials and gain access to critical systems or data. This could result in compromised infrastructure, data breaches, or unauthorized actions within your Kubernetes environment.