gitlab.find_sec_bugs.SSL_CONTEXT-1
unknown
Download Count*
License
A HostnameVerifier that accept any host are often use because of certificate reuse on many hosts. As a consequence, this is vulnerable to Man-in-the-middleattacks attacks since the client will trust any certificate.
Run Locally
Run in CI
Defintion
rules:
- id: find_sec_bugs.SSL_CONTEXT-1
patterns:
- pattern-either:
- pattern: new org.apache.http.impl.client.DefaultHttpClient();
- pattern: javax.net.ssl.SSLContext.getInstance("SSL");
message: >
A HostnameVerifier that accept any host are often use because of
certificate
reuse on many hosts. As a consequence, this is vulnerable to Man-in-the-middleattacks
attacks since the client will trust any certificate.
metadata:
category: security
cwe: "CWE-295: Improper Certificate Validation"
primary_identifier: find_sec_bugs.SSL_CONTEXT-1
secondary_identifiers:
- name: Find Security Bugs-SSL_CONTEXT
type: find_sec_bugs_type
value: SSL_CONTEXT
license: MIT
severity: WARNING
languages:
- java
Short Link: https://sg.run/8k34