nerdexam
Docker

DCA · Question #9

Which of the following statements is true about secrets?

The correct answer is D. Secrets can be created using standard input (STDIN) and a file. Docker Swarm secrets are immutable and encrypted, and they can be created from either a file or standard input.

Submitted by jordan8· Apr 18, 2026Security

Question

Which of the following statements is true about secrets?

Options

  • ASecrets can be created from any node in the cluster.
  • BSecrets can be modified after they are created.
  • CSecret are stored unencrypted on manager nodes.
  • DSecrets can be created using standard input (STDIN) and a file.

How the community answered

(57 responses)
  • A
    4% (2)
  • B
    4% (2)
  • C
    2% (1)
  • D
    91% (52)

Why each option

Docker Swarm secrets are immutable and encrypted, and they can be created from either a file or standard input.

ASecrets can be created from any node in the cluster.

Secrets can only be created, updated, or removed from a Docker Swarm manager node, not from any node in the cluster.

BSecrets can be modified after they are created.

Docker secrets are immutable once created; they cannot be modified and must be removed and recreated if any changes are needed.

CSecret are stored unencrypted on manager nodes.

Docker Swarm encrypts secrets both at rest on manager nodes and in transit to worker nodes to protect sensitive information.

DSecrets can be created using standard input (STDIN) and a file.Correct

Docker Swarm secrets offer flexibility in creation, allowing users to pass secret data via standard input (`docker secret create my_secret -`) or by specifying a file containing the secret (`docker secret create my_secret --file /path/to/secret.txt`).

Concept tested: Docker Swarm secret management

Source: https://docs.docker.com/engine/swarm/secrets/#create-a-secret

Topics

#Docker Secrets#Secret Management#Docker Swarm#Security Best Practices

Community Discussion

No community discussion yet for this question.

Full DCA Practice