Skip to content

Improper Certificate Validation

Description

The application uses `OpenSSL::SSL::VERIFY_NONE`, which disables the validation of TLS certificates. This allows an adversary to intercept sensitive information or transmit malicious data.

Examples

Insecure Code

ruby
OpenSSL::SSL::VERIFY_NONE

Secure Code

ruby
OpenSSL::SSL::VERIFY_PEER

Remediation

Replace `OpenSSL::SSL::VERIFY_NONE` with `OpenSSL::SSL::VERIFY_PEER`

Rule Details

FieldValue
IDCODE-0553
CategoryCrypto
SeverityMEDIUM
CWECWE-295
ConfidenceHIGH
ImpactHIGH
LikelihoodMEDIUM
ExploitabilityEASY
TagsTLS, certificate validation
OWASPA3:2017-Sensitive Data Exposure, A07:2021-Identification and Authentication Failures

References