CIS Linkerd Benchmark

Security configuration benchmark for Linkerd service mesh

v1.0.0 03-2025

Overview

▶

This benchmark provides prescriptive guidance for establishing a secure configuration posture for Linkerd. It covers mTLS enforcement, authorization policies, dashboard access control, proxy logging, resource limits, identity certificate management, service profiles, traffic splitting, and upgrade procedures.

14Recommendations
7Sections
2Profile Levels
SectionAreaFocus
1Installation & IdentityVersion management, custom CA
2mTLS & AuthorizationMutual TLS, authorization policies
3Dashboard & RBACViz access control, namespace RBAC
4Logging & ObservabilityProxy logs, Prometheus metrics
5Traffic ManagementRetry budgets, canary splits
6Proxy HardeningResource limits, opaque ports
7Maintenance & UpgradesHealth checks, cert rotation

Profile Definitions

▶
ProfileDescriptionIntended Use
L1Level 1 — StandardEssential security for all Linkerd deployments; minimal performance impact.
L2Level 2 — HardenedAdvanced hardening for PCI-DSS, HIPAA, or high-security environments.

1 — Installation & Identity

▶

1.1 Deployment & Trust Anchor

▶
1.1.1 Ensure Linkerd is running the latest stable version (Manual)
L1 Manual
Description

This recommendation verifies that Linkerd is running the latest stable version on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Verify Linkerd version
linkerd version
linkerd check --pre
Remediation
# Install latest Linkerd
curl --proto '=https' -sL https://run.linkerd.io/install | sh
linkerd install --crds | kubectl apply -f -
linkerd install | kubectl apply -f -
linkerd check
1.1.2 Ensure custom trust anchor CA is configured (Automated)
L1 Auto
Description

This recommendation verifies that custom trust anchor CA is configured on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check Linkerd identity trust anchor
linkerd check | grep -A2 identity
kubectl get secret -n linkerd linkerd-identity-issuer -o yaml | grep -c 'tls.crt'
Remediation
# Configure custom trust anchor CA
step certificate create root.linkerd.cluster.local ca.crt ca.key --profile root-ca --no-password --insecure
step certificate create identity.linkerd.cluster.local issuer.crt issuer.key --profile intermediate-ca --ca ca.crt --ca-key ca.key --no-password --insecure
linkerd install --identity-trust-anchors-file ca.crt --identity-issuer-certificate-file issuer.crt --identity-issuer-key-file issuer.key | kubectl apply -f -

2 — mTLS & Authorization

▶

2.1 Encryption & Policy

▶
2.1.1 Ensure mutual TLS is enforced for all meshed traffic (Automated)
L1 Auto
Description

This recommendation ensures that mutual TLS is enforced for all meshed traffic on the Linkerd service mesh. Enforcing this requirement establishes a minimum security standard and prevents insecure configurations.

Rationale

Without this enforcement, the Linkerd service mesh may accept insecure configurations that weaken overall security posture. Mandating this control ensures consistent protection against common attack vectors.

Audit
# Check mTLS is enabled
linkerd viz stat deploy -n default
linkerd viz edges deploy -n default | head -10
Remediation
# Ensure mTLS is enforced
# Inject Linkerd proxy into deployments:
kubectl get deploy -n default -o yaml | linkerd inject - | kubectl apply -f -
# Verify mTLS:
linkerd viz stat deploy -n default
# All traffic should show 100% meshed
2.1.2 Ensure authorization policies restrict service access (Automated)
L1 Auto
Description

This recommendation verifies that authorization policies restrict service access on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check authorization policies
kubectl get authorizationpolicies -A
kubectl get serverauthorizations -A
kubectl get servers -A
Remediation
# Configure authorization policies
apiVersion: policy.linkerd.io/v1beta2
kind: Server
metadata:
  name: web-server
  namespace: default
spec:
  podSelector:
    matchLabels:
      app: web
  port: 8080
---
apiVersion: policy.linkerd.io/v1beta2
kind: AuthorizationPolicy
metadata:
  name: web-authz
spec:
  targetRef:
    group: policy.linkerd.io
    kind: Server
    name: web-server
  requiredAuthenticationRefs:
  - name: web-clients
    kind: MeshTLSAuthentication

3 — Dashboard & RBAC

▶

3.1 Viz Access & Permissions

▶
3.1.1 Ensure dashboard is not publicly exposed without authentication (Automated)
L1 Auto
Description

This recommendation verifies that dashboard is not publicly exposed without authentication on the Linkerd service mesh. Disabling or removing unnecessary components reduces the attack surface and limits potential vectors for exploitation.

Rationale

Running unnecessary components on the Linkerd service mesh increases the attack surface and the risk of exploitation. Disabling or removing them follows the principle of least functionality and reduces exposure to known vulnerabilities.

Audit
# Check Linkerd Viz dashboard access
kubectl get svc -n linkerd-viz
kubectl get ingress -n linkerd-viz 2>/dev/null
Remediation
# Restrict dashboard access
# Do NOT expose dashboard without auth
# Use port-forward for local access:
# linkerd viz dashboard &
# If exposing via ingress, add auth:
# nginx.ingress.kubernetes.io/auth-type: basic
# nginx.ingress.kubernetes.io/auth-secret: linkerd-dashboard-auth
3.1.2 Ensure RBAC restricts access to Linkerd namespaces (Automated)
L1 Auto
Description

This recommendation verifies that RBAC restricts access to Linkerd namespaces on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check RBAC for Linkerd namespaces
kubectl get rolebindings,clusterrolebindings -A | grep linkerd
Remediation
# Restrict Linkerd namespace access
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  name: linkerd-readonly
rules:
- apiGroups: ["linkerd.io"]
  resources: ["*"]
  verbs: ["get", "list", "watch"]
---
# Bind to specific groups only

4 — Logging & Observability

▶

4.1 Proxy Logs & Metrics

▶
4.1.1 Ensure proxy log levels are appropriately configured (Automated)
L1 Auto
Description

This recommendation verifies that proxy log levels are appropriately configured on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check proxy log level
kubectl get deploy -n linkerd -o yaml | grep -E 'LINKERD2_PROXY_LOG|log-level'
Remediation
# Configure proxy logging
# Set proxy log level via annotation:
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    config.linkerd.io/proxy-log-level: "warn,linkerd=info"
# For control plane:
linkerd install --set proxyLogLevel=warn,linkerd=info | kubectl apply -f -
4.1.2 Ensure monitoring with alerting is configured (Automated)
L1 Auto
Description

This recommendation verifies that monitoring with alerting is configured on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check Linkerd Viz metrics
linkerd viz stat deploy -A | head -20
kubectl get prometheusrules -n linkerd-viz 2>/dev/null
Remediation
# Configure monitoring and alerting
# Ensure Viz extension is installed:
linkerd viz install | kubectl apply -f -
# Export metrics to external Prometheus:
# linkerd viz install --set prometheusUrl=http://prometheus:9090 | kubectl apply -f -
# Set up alerts for:
# - High error rates (>1%)
# - High latency (p99 > 500ms)
# - Proxy injection failures

5 — Traffic Management

▶

5.1 Retries & Splitting

▶
5.1.1 Ensure service profiles define timeouts and retry budgets (Automated)
L1 Auto
Description

This recommendation verifies that service profiles define timeouts and retry budgets on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check retry and timeout configuration
kubectl get serviceprofiles -A
kubectl get httproutes -A 2>/dev/null
Remediation
# Configure service profiles for retries/timeouts
apiVersion: linkerd.io/v1alpha2
kind: ServiceProfile
metadata:
  name: web.default.svc.cluster.local
spec:
  routes:
  - name: "GET /api"
    condition:
      method: GET
      pathRegex: "/api/.*"
    timeout: 5s
    isRetryable: true
    retryBudget:
      retryRatio: 0.2
      minRetriesPerSecond: 10
      ttl: 10s
5.1.2 Ensure traffic splitting is used for safe deployments (Automated)
L2 Auto
Description

This recommendation verifies that traffic splitting is used for safe deployments on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check traffic split configuration
kubectl get trafficsplits -A 2>/dev/null
Remediation
# Configure traffic management
apiVersion: split.smi-spec.io/v1alpha2
kind: TrafficSplit
metadata:
  name: web-canary
spec:
  service: web
  backends:
  - service: web-stable
    weight: 900
  - service: web-canary
    weight: 100

6 — Proxy Hardening

▶

6.1 Resources & Ports

▶
6.1.1 Ensure proxy resource limits are configured (Automated)
L1 Auto
Description

This recommendation verifies that proxy resource limits are configured on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check proxy resource limits
kubectl get deploy -n default -o yaml | grep -A5 'proxy-cpu\|proxy-memory'
Remediation
# Set proxy resource limits
# Via annotations:
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    config.linkerd.io/proxy-cpu-request: "100m"
    config.linkerd.io/proxy-cpu-limit: "500m"
    config.linkerd.io/proxy-memory-request: "128Mi"
    config.linkerd.io/proxy-memory-limit: "256Mi"
6.1.2 Ensure opaque ports are configured for non-HTTP traffic (Automated)
L1 Auto
Description

This recommendation verifies that opaque ports are configured for non-HTTP traffic on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check opaque ports
kubectl get deploy -n default -o yaml | grep 'opaque-ports'
Remediation
# Configure opaque ports for non-HTTP traffic
# Via annotation:
apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    config.linkerd.io/opaque-ports: "3306,6379,27017"
# This ensures mTLS is applied to non-HTTP protocols

7 — Maintenance & Upgrades

▶

7.1 Health & Rotation

▶
7.1.1 Ensure all health checks pass including certificate validity (Automated)
L1 Auto
Description

This recommendation verifies that all health checks pass including certificate validity on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Run Linkerd health checks
linkerd check
linkerd check --proxy -n default
Remediation
# Ensure all health checks pass
linkerd check
# Fix certificate rotation before expiry:
linkerd identity
# Check certificate expiry:
kubectl get secret linkerd-identity-issuer -n linkerd -o jsonpath='{.data.tls\.crt}' | base64 -d | openssl x509 -noout -dates
7.1.2 Ensure Linkerd and extensions are regularly updated (Manual)
L1 Manual
Description

This recommendation verifies that Linkerd and extensions are regularly updated on the Linkerd service mesh. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Linkerd service mesh vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check Linkerd extensions
linkerd check --extensions
Remediation
# Update Linkerd and extensions
linkerd upgrade | kubectl apply -f -
linkerd viz install | kubectl apply -f -
linkerd check
# Rotate identity certificates annually:
step certificate create root.linkerd.cluster.local ca.crt ca.key --profile root-ca --not-after=8760h