5.19 Do not set mount propagation mode to shared

Information

Mount propagation mode allows mounting volumes in shared, slave or private mode on a container. Do not use shared mount propagation mode until needed.A shared mount is replicated at all mounts and the changes made at any mount point are propagated to all mounts. Mounting a volume in shared mode does not restrict any other container to mount and make changes to that volume. This might be catastrophic if the mounted volume is sensitive to changes. Do not set mount propagation mode to shared until needed.

Solution

Do not mount volumes in shared mode propagation.
For example, do not start container as below-
docker run <Run arguments>--volume=/hostPath-/containerPath-shared<Container Image Name or ID> <Command>
Impact-
None.
Default Value-
By default, the container mounts are private.

See Also

https://workbench.cisecurity.org/files/516

Item Details

Category: CONFIGURATION MANAGEMENT

References: 800-53|CM-7b.

Plugin: Unix

Control ID: 236c8d71cd732b0d0a1691baca5eae6e3d7812766beb066bfb172a3ee73c775d