Claude Skill TLS Security: Why rejectUnauthorized:false and NODE_TLS_REJECT_UNAUTHORIZED=0 Are Critical Vulnerabilities
TLS certificate validation bypass is not a minor configuration issue. In an MCP skill context it is a credential exfiltration vector for every secret the process holds — simultaneously. A typical production skill has an Anthropic API key, a Stripe or payment key, a GitHub token, a database connection string, and a handful of third-party service credentials all loaded into environment variables. When rejectUnauthorized: false is present, a man-in-the-middle attacker who intercepts any outbound HTTPS connection made by that skill process reads every request and response, including the Authorization and x-api-key headers carrying those credentials, in a single session. The bypass that felt necessary to get local development working against a self-signed internal certificate often never gets removed, and NODE_TLS_REJECT_UNAUTHORIZED=0 in a Dockerfile ENV line is invisible in the typical code review pass. This post covers the complete attack surface, all four SA-SKL-TLS bypass patterns, the MITM mechanics inside a container network, and the correct fix.
Why TLS bypass in MCP skills is worse than in a typical API server
Every HTTPS server on the public internet that ships with rejectUnauthorized: false is doing something dangerous. But the particular danger in an MCP skill context is the breadth of credentials held by a single process. A REST API server for a narrow-purpose microservice might have one outbound credential: its database password. A Claude MCP skill is an aggregation layer by design. Its value comes from connecting to many services simultaneously — which means its process environment is an aggregate credential store.
Consider a mid-complexity skill for engineering team automation. It holds:
ANTHROPIC_API_KEY— for model calls, billed per token at non-trivial ratesGITHUB_TOKEN— a fine-grained PAT with read/write access to your org’s private repositoriesJIRA_API_TOKEN— access to your project tracking and all issues, attachments, and commentsSLACK_BOT_TOKEN— a bot token with read access to every channel it’s been added toDB_URL— a connection string with credentials for a read-replica of the production databaseOPENAI_API_KEY— a fallback or embedding model key
When rejectUnauthorized: false is set — either in one https.request() call or globally via NODE_TLS_REJECT_UNAUTHORIZED=0 — a MITM on any single outbound TLS connection exposes all of these credentials simultaneously. The attacker intercepts the first HTTPS request the skill makes after startup, reads the full HTTP request including headers, and has everything they need to impersonate the skill across every integrated service. A single intercepted connection to https://api.github.com reveals the GitHub token; that same session reveals the Authorization header sent to Anthropic; a request to Jira reveals the Jira token. The credential surface is the full breadth of everything the skill touches.
Container deployments compound this. MCP skills running in Docker or Kubernetes are frequently deployed on shared container networking layers. Within a VPC or a Kubernetes cluster, the network is not as controlled as developers assume. Other pods, sidecars, service meshes, and node-level processes share the same underlying network fabric. ARP spoofing within a VPC subnet or DNS hijacking via a compromised CoreDNS instance are realistic attack paths that do not require internet-facing exposure. If the skill process has disabled TLS validation, an attacker who gains any foothold in the container network can silently MITM every outbound connection the skill makes.
The aggregate credential problem: rejectUnauthorized: false does not disable validation for one connection. It disables validation for every HTTPS connection made by the Node.js process. In a skill that integrates N services, a single successful MITM session intercepts credentials for all N services simultaneously. The blast radius is the full breadth of the skill’s integration surface.
TLS-001: rejectUnauthorized: false in https.request() and axios httpsAgent
The most direct form of the bypass is passing rejectUnauthorized: false in the options object of an individual HTTPS request. This disables certificate chain validation and hostname verification for that specific request. It is most commonly introduced when a developer needs to call an internal service that uses a self-signed certificate and cannot immediately get the certificate properly trusted. The fix “works” and the developer moves on, leaving the flag in place:
// VULNERABLE: TLS-001 — rejectUnauthorized: false in https.request()
import https from 'https';
function callInternalService(path: string, body: object): Promise<object> {
return new Promise((resolve, reject) => {
const req = https.request(
{
hostname: 'internal-api.corp.internal',
port: 8443,
path,
method: 'POST',
// This disables ALL certificate validation for this request
// A MITM sees: the full request body, all headers including Authorization
rejectUnauthorized: false, // <-- SA-SKL-TLS-001
headers: {
'Authorization': `Bearer ${process.env.INTERNAL_API_TOKEN}`,
'Content-Type': 'application/json',
},
},
(res) => {
let data = '';
res.on('data', (chunk) => data += chunk);
res.on('end', () => resolve(JSON.parse(data)));
}
);
req.on('error', reject);
req.write(JSON.stringify(body));
req.end();
});
}
The axios equivalent is equally common, using an httpsAgent configured with the bypass. Axios does not expose rejectUnauthorized as a top-level option, so developers use a custom agent:
// VULNERABLE: TLS-001 — rejectUnauthorized: false via axios httpsAgent
import axios from 'axios';
import https from 'https';
// This agent object is often defined once at module scope and reused
// across all requests, applying the bypass globally to the skill's
// entire outbound axios traffic
const insecureAgent = new https.Agent({
rejectUnauthorized: false, // <-- SA-SKL-TLS-001
});
async function fetchFromCorp(endpoint: string): Promise<object> {
const response = await axios.get(endpoint, {
httpsAgent: insecureAgent, // bypass applied to this request
headers: { 'x-api-key': process.env.CORP_API_KEY },
});
return response.data;
}
The correct fix is to supply the internal CA certificate using NODE_EXTRA_CA_CERTS (covered in depth below) or by passing the CA certificate directly in the agent options. This preserves full certificate validation while trusting the specific CA that signed the internal certificate:
// SECURE: use CA certificate for internal services, full validation preserved
import https from 'https';
import fs from 'fs';
// Load the internal CA cert once at startup
// Set via NODE_EXTRA_CA_CERTS env var (preferred) or hard-path for containers
const internalCaCert = fs.readFileSync(
process.env.INTERNAL_CA_CERT_PATH ?? '/etc/ssl/certs/corp-internal-ca.pem'
);
const secureInternalAgent = new https.Agent({
ca: internalCaCert,
// rejectUnauthorized defaults to true — do NOT set it to false
});
function callInternalService(path: string, body: object): Promise<object> {
return new Promise((resolve, reject) => {
const req = https.request(
{
hostname: 'internal-api.corp.internal',
port: 8443,
path,
method: 'POST',
agent: secureInternalAgent, // trusts internal CA, validates everything else
headers: {
'Authorization': `Bearer ${process.env.INTERNAL_API_TOKEN}`,
'Content-Type': 'application/json',
},
},
(res) => {
let data = '';
res.on('data', (chunk) => data += chunk);
res.on('end', () => resolve(JSON.parse(data)));
}
);
req.on('error', reject);
req.write(JSON.stringify(body));
req.end();
});
}
TLS-002: checkServerIdentity: () => undefined — hostname binding disabled
The checkServerIdentity option is a function called by the TLS stack after the certificate chain has been validated. Its job is to verify that the certificate’s Subject Alternative Names (SANs) or Common Name match the hostname the client intended to connect to. Overriding it with a no-op function defeats hostname binding: the certificate may be valid (signed by a trusted CA) but it may not be the certificate for the server you’re actually connecting to. This creates a scenario where a MITM can present any certificate signed by any trusted CA — for example, a certificate for attacker.example.com presented during a connection to internal-api.corp.internal — and the client will accept it without complaint.
// VULNERABLE: TLS-002 — checkServerIdentity no-op disables hostname validation
import https from 'https';
const req = https.request({
hostname: 'internal-api.corp.internal',
port: 8443,
path: '/api/data',
method: 'GET',
// Certificate chain IS validated (rejectUnauthorized is not false)
// But hostname matching is disabled — any valid cert is accepted
checkServerIdentity: () => undefined, // <-- SA-SKL-TLS-002
headers: { 'Authorization': `Bearer ${process.env.API_TOKEN}` },
}, handleResponse);
// SECURE: remove checkServerIdentity override entirely
// The default implementation does the right thing for public CAs.
// For internal CAs where the hostname might not match standard patterns,
// use the ca option to trust the internal CA instead of disabling hostname checks.
const secureReq = https.request({
hostname: 'internal-api.corp.internal',
port: 8443,
path: '/api/data',
method: 'GET',
ca: internalCaCert, // Trust the internal CA; keep hostname validation intact
headers: { 'Authorization': `Bearer ${process.env.API_TOKEN}` },
}, handleResponse);
The sneaky variant: some codebases use checkServerIdentity: (_host, _cert) => undefined or checkServerIdentity: function() {}. The pattern is the same regardless of the syntax: a function that returns undefined (instead of throwing an Error on mismatch) disables hostname validation. SkillAudit’s AST check looks for any checkServerIdentity value whose function body does not contain a conditional throw.
TLS-003: minVersion: 'TLSv1' or 'TLSv1.1' — deprecated protocols re-enabled
TLS 1.0 was deprecated in RFC 8996 (March 2021). TLS 1.1 was deprecated at the same time. Node.js 12+ disabled both by default. The motivation to re-enable them is the same as the other bypasses: an internal service that hasn’t been updated to TLS 1.2+ forces developers to downgrade. TLS 1.0 and 1.1 have known cryptographic weaknesses — BEAST, POODLE, and others — that make downgrade attacks and session decryption feasible under realistic conditions:
// VULNERABLE: TLS-003 — minVersion set to deprecated protocol
import https from 'https';
// Setting minVersion to TLSv1 or TLSv1.1 re-enables deprecated protocols
// with known cryptographic weaknesses (BEAST, POODLE, RC4 suites)
const insecureAgent = new https.Agent({
minVersion: 'TLSv1', // <-- SA-SKL-TLS-003
// Also seen as: minVersion: 'TLSv1.1'
});
// SECURE: enforce TLS 1.2 as absolute minimum; prefer TLS 1.3
const secureAgent = new https.Agent({
minVersion: 'TLSv1.2', // TLS 1.2 is the minimum acceptable
// maxVersion: 'TLSv1.3' is unnecessary — the default allows both 1.2 and 1.3
});
// If the internal service cannot support TLS 1.2, the correct path is
// to upgrade the service, not to downgrade the client. If that is not
// immediately possible, isolate the connection behind a TLS-terminating
// proxy (e.g. nginx, Envoy) that speaks TLS 1.2+ externally and handles
// the legacy protocol internally, so the skill process itself never
// negotiates below TLS 1.2.
TLS-004: NODE_TLS_REJECT_UNAUTHORIZED=0 in Dockerfile ENV and docker-compose
This is the most dangerous form of the bypass because it is the most invisible. NODE_TLS_REJECT_UNAUTHORIZED=0 is an environment variable that, when present in the Node.js process environment, disables TLS certificate validation globally for every HTTPS connection made by the process — regardless of what any individual https.request() call specifies in its options. It applies to all third-party libraries, all native HTTPS calls, and all HTTP client wrappers. It is the nuclear option.
The pattern typically enters the codebase through a Dockerfile or docker-compose environment block:
# VULNERABLE: TLS-004 — NODE_TLS_REJECT_UNAUTHORIZED=0 in Dockerfile ENV FROM node:20-alpine WORKDIR /app COPY package*.json ./ RUN npm ci --omit=dev COPY . . # This single line disables TLS validation for the ENTIRE Node.js process # It applies to every HTTPS call: Anthropic API, GitHub, Stripe, databases # It is invisible in code review unless specifically scanning Dockerfiles ENV NODE_TLS_REJECT_UNAUTHORIZED=0 # <-- SA-SKL-TLS-004 EXPOSE 3000 CMD ["node", "dist/index.js"]
# VULNERABLE: TLS-004 in docker-compose environment block
services:
skill:
build: .
environment:
- NODE_ENV=production
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY}
- GITHUB_TOKEN=${GITHUB_TOKEN}
- NODE_TLS_REJECT_UNAUTHORIZED=0 # <-- SA-SKL-TLS-004: disables ALL TLS validation
The correct remediation is a one-line removal, combined with establishing the correct trust mechanism for internal CAs. But it also requires understanding why the variable was added in the first place — which is almost always “to make self-signed certificates work” — and providing the right alternative:
# SECURE: Dockerfile with NODE_EXTRA_CA_CERTS instead of TLS bypass FROM node:20-alpine WORKDIR /app COPY package*.json ./ RUN npm ci --omit=dev COPY . . # Copy the internal CA certificate into the container image COPY certs/corp-internal-ca.pem /etc/ssl/certs/corp-internal-ca.pem # NODE_EXTRA_CA_CERTS adds the specified PEM file to Node.js's trusted CA store # WITHOUT removing any of the built-in trusted CAs and WITHOUT disabling validation # This trusts the internal CA for internal services while maintaining full # certificate validation for all public internet connections ENV NODE_EXTRA_CA_CERTS=/etc/ssl/certs/corp-internal-ca.pem # NODE_TLS_REJECT_UNAUTHORIZED is NOT set — defaults to validation enabled EXPOSE 3000 CMD ["node", "dist/index.js"]
Why this bypass is invisible in code review: most code review tools show diffs of .ts, .js, and .json files. Dockerfiles and docker-compose YAML often receive superficial review or are treated as infrastructure files outside the security review scope. NODE_TLS_REJECT_UNAUTHORIZED=0 in a Dockerfile ENV line does not appear in any JavaScript source file, so AST-based linters that only process .ts/.js miss it entirely. SkillAudit scans Dockerfiles, docker-compose files, .env files, and CI configuration files in addition to source code.
The MITM attack mechanics for a container network scenario
Abstractly, “MITM attack” sounds difficult. In a container network inside a VPC, it is not. Here is the realistic attack path for a Kubernetes deployment where the skill pod has TLS validation disabled:
The attacker gains a foothold in the cluster — this could be a compromised sidecar container, a misconfigured RBAC binding that allows pod creation in a shared namespace, or a supply-chain compromise of a base image. From within the cluster network, the attacker has access to the same private subnet as the skill pod. Kubernetes uses a flat network model: by default, all pods in a cluster can communicate with all other pods. The attacker does not need to be in the same namespace.
With access to the cluster network, the attacker has two primary paths to intercept the skill’s outbound HTTPS traffic:
Path 1: DNS hijack via CoreDNS poisoning. Kubernetes uses CoreDNS for internal service discovery. A compromised pod with appropriate RBAC permissions can modify CoreDNS ConfigMap entries or use a compromised CoreDNS plugin to redirect DNS responses for target hostnames. When the skill process resolves api.github.com or api.anthropic.com, CoreDNS returns the attacker’s pod IP instead. The skill process makes a TLS connection to the attacker’s pod. Because rejectUnauthorized: false is set, it does not matter that the attacker’s pod is presenting a self-signed certificate or a certificate for the wrong hostname. The connection succeeds. The attacker proxies the request to the real upstream service, intercepting all credentials and request bodies in both directions.
Path 2: ARP spoofing on the container overlay network. Container overlay networks (Flannel, Calico, Weave) are Layer 2 networks at the pod level. ARP is unauthenticated on Layer 2. An attacker with access to a pod on the same overlay network segment can broadcast gratuitous ARP responses claiming to be the default gateway or a target service IP. Pods on the same node that accept the spoofed ARP cache the attacker’s MAC address as the target. Subsequent HTTPS connections from the skill pod to the target IP route through the attacker’s pod first. With TLS bypass enabled, the connection is transparently proxied and all traffic is readable.
The critical point is what the attacker captures in a single session. The skill process makes multiple outbound HTTPS connections at startup and during normal operation: health checks, token validation calls, database connections over TLS, API calls to integrated services. Each of these connections carries an Authorization, x-api-key, or similar credential header. Within the first few seconds of a proxied session, the attacker has captured every credential the skill holds:
# Captured from a single proxied session against a TLS-bypassing skill # (illustrative — this is what the MITM proxy logs during skill startup) [00:00.012] CONNECT api.anthropic.com:443 > POST /v1/messages HTTP/1.1 > Host: api.anthropic.com > x-api-key: sk-ant-api03-CAPTURED-ANTHROPIC-KEY > anthropic-version: 2023-06-01 > Content-Type: application/json [00:00.089] CONNECT api.github.com:443 > GET /user HTTP/1.1 > Host: api.github.com > Authorization: token github_pat_CAPTURED_GITHUB_TOKEN [00:00.134] CONNECT hooks.stripe.com:443 > POST /v1/events HTTP/1.1 > Host: hooks.stripe.com > Authorization: Bearer sk_live_CAPTURED_STRIPE_KEY [00:00.201] CONNECT db.internal:5432 (TLS over TCP) > Connection string: postgresql://app:CAPTURED_DB_PASSWORD@db.internal:5432/prod
Four credentials, four services, 200 milliseconds. That is the actual blast radius of a TLS bypass in an MCP skill.
NODE_EXTRA_CA_CERTS: the correct internal CA trust mechanism
Every case of rejectUnauthorized: false added to work with an internal service has the same root cause: the internal service uses a certificate signed by a private CA that is not in Node.js’s built-in trusted CA store (which is Mozilla’s CA bundle). The developer needed to call that service, got a certificate validation error, and took the path of least resistance. The correct path of least resistance — that actually solves the problem without disabling security — is NODE_EXTRA_CA_CERTS.
NODE_EXTRA_CA_CERTS is an environment variable that points to a PEM-format file containing one or more CA certificates to add to Node.js’s trusted store. It does not replace the built-in Mozilla CA bundle; it extends it. It preserves full certificate validation for all public internet connections. It enables certificate validation for internal services signed by the internal CA. It requires no code changes — only an environment variable and a CA certificate file:
# How to get your internal CA certificate (one-time operation per CA)
# From your internal PKI team, or extract from an internal service:
# Option 1: If you have access to the internal service's certificate file
openssl x509 -in internal-service.crt -noout -text | grep "Issuer:"
# Note the CA name, then ask your PKI team for the CA certificate PEM
# Option 2: Extract the CA cert from a live TLS connection
# (temporarily, to get the cert — then validate it with your PKI team)
openssl s_client -connect internal-api.corp.internal:8443 -showcerts 2>/dev/null \
| awk '/-----BEGIN CERTIFICATE-----/{c++} c==2{print} /-----END CERTIFICATE-----/{if(c==2)exit}' \
> corp-internal-ca.pem
# Verify the CA cert is correct before using it
openssl x509 -in corp-internal-ca.pem -noout -subject -issuer -dates
// Using NODE_EXTRA_CA_CERTS in application startup validation
// No code change required for existing https.request() / axios calls —
// the CA trust is applied at the Node.js TLS level automatically
// However, if you have an existing explicit httpsAgent, update it:
import https from 'https';
import fs from 'fs';
// This is the CORRECT axios httpsAgent — no bypass options
const agent = new https.Agent({
// rejectUnauthorized is true by default — do NOT override it
// NODE_EXTRA_CA_CERTS has already added the internal CA to the trusted store
// No other options needed
});
// Or simply: don't pass an httpsAgent at all if you don't need custom options
// axios and https.request() will use the default agent, which respects
// NODE_EXTRA_CA_CERTS automatically
import axios from 'axios';
async function callInternalService(url: string): Promise<object> {
// No httpsAgent needed — NODE_EXTRA_CA_CERTS handles internal CA trust
const response = await axios.get(url, {
headers: { 'Authorization': `Bearer ${process.env.INTERNAL_TOKEN}` },
// No httpsAgent: insecureAgent here — that line is removed
});
return response.data;
}
The assertTlsValidationEnabled() startup guard
Even with correct code, the global bypass via environment variable is a risk. A developer running locally might set NODE_TLS_REJECT_UNAUTHORIZED=0 in their shell to debug something and accidentally commit a modified .env file or a Dockerfile change. A CI pipeline might inject the variable for a step and not clean it up. A runtime guard that throws at startup if the bypass is detected stops the skill from running in an insecure state rather than silently operating with TLS disabled:
// assertTlsValidationEnabled.ts
// Call this at the very start of your skill's main() function,
// before any network connections are made
export function assertTlsValidationEnabled(): void {
const tlsRejectValue = process.env.NODE_TLS_REJECT_UNAUTHORIZED;
// Value '0' (string) is the bypass; '1' (string) is explicit-enable;
// undefined means the default (validation enabled)
if (tlsRejectValue === '0') {
throw new Error(
'[SECURITY] NODE_TLS_REJECT_UNAUTHORIZED=0 is set in the environment. ' +
'This disables TLS certificate validation globally and is not permitted ' +
'in production. If you need to trust an internal CA, use NODE_EXTRA_CA_CERTS ' +
'pointing to your CA certificate file instead. ' +
'See: https://skillaudit.dev/seo/claude-skill-tls-certificate-validation-security'
);
}
// Also check for the numeric form (some tools set it as integer 0)
if (tlsRejectValue !== undefined && tlsRejectValue !== '1' && tlsRejectValue !== '') {
throw new Error(
`[SECURITY] NODE_TLS_REJECT_UNAUTHORIZED has unexpected value: "${tlsRejectValue}". ` +
'Only "1" (explicit enable) or unset (default) are permitted. ' +
'Value "0" disables TLS validation; any other value is invalid.'
);
}
// Validate that NODE_EXTRA_CA_CERTS points to a readable file if set
const extraCaPath = process.env.NODE_EXTRA_CA_CERTS;
if (extraCaPath) {
try {
const { statSync } = require('fs');
statSync(extraCaPath);
} catch {
throw new Error(
`[SECURITY] NODE_EXTRA_CA_CERTS is set to "${extraCaPath}" but the file ` +
'does not exist or is not readable. TLS connections to internal services ' +
'will fail. Ensure the CA certificate file is present in the container.'
);
}
}
}
// In your skill's main entry point:
import { assertTlsValidationEnabled } from './assertTlsValidationEnabled';
async function main(): Promise {
// Run BEFORE any network connections, database connections, or service calls
assertTlsValidationEnabled();
// Now safe to initialise connections
await initDatabase();
await startSkillServer();
}
Fail-fast is better than silent degradation: a skill that crashes at startup with a clear error message pointing to the fix is infinitely better than a skill that starts successfully and silently sends every credential to a MITM. The startup guard makes the bypass impossible to miss and forces remediation before any user traffic flows.
How SkillAudit detects all four SA-SKL-TLS patterns
SkillAudit’s TLS bypass detection runs across the full project: TypeScript and JavaScript source files, Dockerfiles, docker-compose YAML, .env and .env.* files, and CI configuration. The four detection patterns are:
| Finding ID | Pattern | Detection signal | Severity |
|---|---|---|---|
| SA-SKL-TLS-001 | rejectUnauthorized: false in https.request() options or new https.Agent() constructor |
AST: ObjectExpression containing a Property with key rejectUnauthorized and value BooleanLiteral(false), where the containing expression is an argument to https.request, https.get, or the new https.Agent() constructor. Also matches the equivalent in tls.connect() options. |
CRITICAL |
| SA-SKL-TLS-002 | checkServerIdentity: () => undefined or any no-op override of checkServerIdentity |
AST: Property with key checkServerIdentity whose value is a FunctionExpression or ArrowFunctionExpression; function body does not contain a ThrowStatement (or contains only a ReturnStatement with undefined / no value). Functions that always return without throwing are flagged as no-ops. |
CRITICAL |
| SA-SKL-TLS-003 | minVersion: 'TLSv1' or minVersion: 'TLSv1.1' in TLS/HTTPS agent options |
AST: Property with key minVersion and string literal value matching TLSv1 or TLSv1.1 (case-insensitive) in an ObjectExpression that is an argument to new https.Agent(), new tls.TLSSocket(), or tls.createServer(). Also matches the equivalent secureProtocol: 'TLSv1_method' form. |
HIGH |
| SA-SKL-TLS-004 | NODE_TLS_REJECT_UNAUTHORIZED=0 in Dockerfile, docker-compose, .env, or CI config |
Multi-file scan: regex NODE_TLS_REJECT_UNAUTHORIZED\s*[=:]\s*['""]?0['""]? across Dockerfile, docker-compose.yml, docker-compose.yaml, .env, .env.*, GitHub Actions YAML (.github/workflows/*.yml), and CircleCI config. Matches ENV lines, environment: blocks, and env: sections in CI. |
CRITICAL |
The TLS-001 check includes a secondary analysis: when rejectUnauthorized: false is found inside a scope that also creates or uses named credentials (any identifier matching *_KEY, *_TOKEN, *_SECRET, *_PASSWORD, or reading from process.env), the finding is annotated with the credential names visible in that scope. This surfaces the full blast radius of the bypass in the finding report rather than leaving the developer to infer it.
TLS-004 detection is case-insensitive and handles multiple value encodings because the bypass is sometimes written as NODE_TLS_REJECT_UNAUTHORIZED="0" (quoted), NODE_TLS_REJECT_UNAUTHORIZED=0 (unquoted), or via - NODE_TLS_REJECT_UNAUTHORIZED=0 in a YAML list form. The scanner normalises all these forms before matching.
For more detail on TLS security patterns in MCP skills, see the SA-SKL-TLS certificate validation security patterns page. For the outbound network egress security context — including SSRF, webhook validation, and egress filtering — see SA-SKL-NET webhook and network egress security. TLS bypass connects to the broader MCP skill attack surface covered in the MCP server attack surface reference.
Summary: the four SA-SKL-TLS findings
| Finding | Vulnerable pattern | Secure fix | Severity |
|---|---|---|---|
| TLS-001 | rejectUnauthorized: false in https.request() options or new https.Agent() |
Remove the flag; use ca: internalCaCert in the agent or set NODE_EXTRA_CA_CERTS |
CRITICAL |
| TLS-002 | checkServerIdentity: () => undefined — no-op hostname validation override |
Remove the override; use a CA certificate to trust the internal cert chain | CRITICAL |
| TLS-003 | minVersion: 'TLSv1' or 'TLSv1.1' in agent options |
Set minVersion: 'TLSv1.2'; upgrade the internal service if it cannot support TLS 1.2 |
HIGH |
| TLS-004 | NODE_TLS_REJECT_UNAUTHORIZED=0 in Dockerfile ENV, docker-compose, or .env |
Remove the variable; set NODE_EXTRA_CA_CERTS pointing to the internal CA PEM file |
CRITICAL |
Scan your Claude skill for TLS bypass vulnerabilities
SkillAudit detects all four SA-SKL-TLS patterns — including NODE_TLS_REJECT_UNAUTHORIZED=0 hiding in Dockerfiles — across your full project in 60 seconds. See the exact credential blast radius for every finding.