T09 · Insecure Skill Coding Practices
- Location
SKILL.md:82- Finding
Plaintext gRPC Transport May Expose Sensitive Service Traffic
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:82-89
Vulnerability Type: Plaintext transport of potentially sensitive authentication and tenant context
Risk Level: MediumComplete Code Snippet:
yaml grpc: client: energy-app-middle: address: dns:///energy-app-middle.${K8S_POD_NS}.svc.cluster.local:9090 negotiationType: PLAINTEXT enableKeepAlive: trueTechnical Analysis
The documented gRPC client configuration explicitly uses
negotiationType: PLAINTEXT, which provides neither transport confidentiality nor TLS-based peer authentication. Elsewhere in the same document, service requests are described as carrying JWT access tokens, tenant identifiers, and user identifiers through headers such asX-ACCESS-TOKEN,X-Tenant,X-UID, andX-PUID.If this authentication or identity context is propagated over the configured gRPC channel, any attacker capable of observing or intercepting the relevant cluster network path could read sensitive metadata. An active network attacker could potentially alter requests or responses because the transport does not provide TLS integrity protection or authenticated service identity.
The cluster-local DNS address limits direct external exposure, but it does not eliminate threats from compromised pods, nodes, sidecars, proxies, cluster networking components, or excessively privileged internal workloads.
Attack Path
- An attacker compromises a pod, node, proxy, or networking component with access to the internal service traffic.
- The attacker observes or intercepts the plaintext gRPC connection to port
9090. - If authentication or tenant metadata is forwarded on this connection, the attacker captures JWTs, tenant codes, or user identifiers.
- The attacker may replay reusable credentials against accessible services or inspect tenant-scoped requests and responses.
- If positioned for active interception, the attacker m ...[truncated 843 chars]
- Remediation
View remediation
Remediation Suggestions
- Replace
negotiationType: PLAINTEXTwith TLS-enabled gRPC transport. - Prefer mutual TLS so both client and server authenticate their service identities.
- Validate server certificates and service names; do not disable hostname or certificate verification.
- Provision and rotate certificates through the platform's approved secret-management mechanism rather than storing private keys in the Skill or source repository.
- Apply Kubernetes NetworkPolicies or equivalent controls to restrict access to port
9090to explicitly authorized workloads. - Avoid forwarding reusable end-user bearer tokens where scoped, short-lived service credentials or token exchange can satisfy the use case.
- Preserve application-level authorization and tenant-boundary validation even after transport encryption is enabled.
- Monitor for anomalous internal gRPC connections and credential replay attempts.
- Replace
