Handshake service for kernel TLS consumers
Pull the latest version of this image from the Ghost registry. Pulling requires authentication — generate a token and run docker login first (see Authentication below).
The Ghost catalog is public to browse, but pulling images requires an account. Generate a pull token below (or from your Account → Tokens page) — you'll get a ready-to-paste docker login command, then docker pull works.
The username is generated automatically (it looks like robot$<project>+<auto-id>, not the name you typed) and is included in the docker login command above. The secret is shown only once when you create the token.
All Ghost images are signed with cosign. Verifying the signature before deployment ensures the image has not been tampered with.
Install cosign via brew install cosign or download from the Sigstore releases page.
Reference this image in your Dockerfile as a base layer:
This is a vendor-built FIPS-enabled image: its cryptography runs on FIPS 140-3 validated modules configured by the upstream vendor. You can inspect the image metadata:
| Standard | FIPS 140-3 |
| Crypto module | Vendor-configured validated modules |
| Cryptography | Validated modules only |
| Use case | Government, regulated industries, compliance workloads |
All examples in this guide use the public image. If you've mirrored the repository for your own use (for example, to your Docker Hub namespace), update your commands to reference the mirrored image instead of the public one.
For example:
registry.ghost-prod.alphabravo.io/ghost-base/<repository>:<tag><your-namespace>/dhi-<repository>:<tag>For the examples, you must first use docker login registry.ghost-prod.alphabravo.io to authenticate to the registry to pull the images.
Run the following command to start tlshd. Replace <tag> with the image variant you want to run.
docker run -d --name tlshd \
--privileged \
--network host \
registry.ghost-prod.alphabravo.io/ghost-base/ktls-utils:<tag>
Important notes:
--privileged flag is required because tlshd needs to interact with kernel netlink sockets and manage kernel TLS
sessions--network host flag is typically required because tlshd operates on kernel sockets/etc/tlshd for custom configurationStart tlshd with a minimal /etc/tlshd/config configuration file:
# Create a minimal config
mkdir -p /etc/tlshd
cat > /etc/tlshd/config << 'EOF'
[debug]
loglevel = 0
tls = 0
nl = 0
[authenticate]
keyrings =
EOF
# Run tlshd
docker run -d --name tlshd \
--privileged \
--network host \
-v /etc/tlshd:/etc/tlshd:ro \
registry.ghost-prod.alphabravo.io/ghost-base/ktls-utils:<tag>
| Feature | Standard Linux Package | Docker Hardened ktls-utils |
|---|---|---|
| Security | Standard system packages | Minimal, hardened base with security patches |
| Shell access | Full shell available | No shell in runtime variants |
| Package manager | apt/yum available | No package manager in runtime variants |
| User | Runs as root via systemd | Runs as nonroot user |
| Attack surface | Larger due to system utilities | Minimal, only essential components |
| Debugging | Traditional shell debugging | Use Docker Debug or Image Mount for troubleshooting |
| Configuration | /etc/tlshd/config | Same configuration file location |
Ghost hardened images prioritize security through minimalism:
The hardened images intended for runtime don't contain a shell nor any tools for debugging. Common debugging methods for applications built with Ghost hardened images include:
docker logsFor example, you can use Docker Debug:
docker debug tlshd
or mount debugging tools with the Image Mount feature:
docker run --rm -it --pid container:tlshd \
--mount=type=image,source=registry.ghost-prod.alphabravo.io/ghost-base/busybox:1,destination=/dbg,ro \
registry.ghost-prod.alphabravo.io/ghost-base/ktls-utils:<tag> /dbg/bin/sh
Ghost hardened images come in different variants depending on their intended use.
Runtime variants are designed to run your application in production. These images are intended to be used either
directly or as the FROM image in the final stage of a multi-stage build. These images typically:
Build-time variants typically include dev in the variant name and are intended for use in the first stage of a
multi-stage Dockerfile. These images typically:
FIPS variants include fips in the variant name and tag. They come in both runtime and build-time variants. These
variants use cryptographic modules that have been validated under FIPS 140, a U.S. government standard for secure
cryptographic operations. Docker Hardened ktls-utils images include FIPS-compliant variants for environments requiring
Federal Information Processing Standards compliance.
To migrate your tlshd deployment to a Ghost hardened image, you must update your deployment configuration. At minimum, you must update the container image reference to a Ghost hardened image. This and a few other common changes are listed in the following table of migration notes:
| Item | Migration note |
|---|---|
| Base image | Replace your container images with a Ghost hardened image. |
| Package management | Non-dev images, intended for runtime, don't contain package managers. Use package managers only in images with a dev tag. |
| Nonroot user | By default, non-dev images, intended for runtime, run as a nonroot user. However, tlshd requires privileged access to kernel netlink sockets, so you must run with --privileged flag. |
| Configuration | Mount your configuration directory to /etc/tlshd. The configuration file format is identical to the standard ktls-utils package. |
| TLS certificates | Ghost hardened images contain standard TLS certificates by default. Mount your own certificates and configure them in /etc/tlshd/config. |
| Network mode | tlshd typically requires --network host to access kernel sockets directly. |
| Entry point | Docker Hardened ktls-utils maintains the same tlshd command-line options as the standard package. |
| No shell | By default, non-dev images, intended for runtime, don't contain a shell. Use dev images in build stages to run shell commands and then copy artifacts to the runtime stage. |
The following steps outline the general migration process.
Prepare your configuration.
Ensure you have a valid tlshd configuration file at /etc/tlshd/config on your host system. Review the configuration
file reference section above for available options.
Prepare certificates (if using x.509 authentication).
Place your certificates and private keys in a directory that you'll mount into the container. Update your configuration file to reference the paths where these files will be mounted.
Update your container deployment.
Replace your existing tlshd container with the Ghost hardened image:
docker run -d --name tlshd \
--privileged \
--network host \
-v /etc/tlshd:/etc/tlshd:ro \
registry.ghost-prod.alphabravo.io/ghost-base/ktls-utils:<tag>
Verify operation.
Check the container logs to ensure tlshd started successfully:
docker logs tlshd
You should see log messages indicating that tlshd is listening for netlink messages from the kernel.
The following are common issues that you may encounter during migration.
The hardened images intended for runtime don't contain a shell nor any tools for debugging. The recommended method for debugging applications built with Ghost hardened images is to use Docker Debug to attach to these containers. Docker Debug provides a shell, common debugging tools, and lets you install other tools in an ephemeral, writable layer that only exists during the debugging session.
For tlshd-specific debugging:
# View logs
docker logs tlshd
# Run with debug output to stderr
docker run -d --name tlshd \
--privileged \
--network host \
-v /etc/tlshd:/etc/tlshd:ro \
registry.ghost-prod.alphabravo.io/ghost-base/ktls-utils:<tag> \
tlshd --stderr
By default, image variants intended for runtime run as the nonroot user. However, tlshd requires privileged access to
kernel netlink sockets and must run with the --privileged flag to function correctly.
tlshd will exit immediately if /etc/tlshd/config does not exist or is malformed. Ensure your configuration file:
/etc/tlshd/config)tlshd requires Linux kernel 6.5 or later with the following CONFIG options enabled:
CONFIG_TLSCONFIG_KEYSCONFIG_KEYS_REQUEST_CACHEVerify your kernel supports net/handshake:
# Check kernel version
uname -r
# Check if /proc/net/handshake exists
ls /proc/net/handshake 2>/dev/null || echo "Kernel handshake support not available"
If tlshd cannot access certificates or keyrings:
/etc/tlshd/config match mounted locationsBy default, image variants intended for runtime don't contain a shell. Use dev images in build stages to run shell
commands and then copy any necessary artifacts into the runtime stage. In addition, use Docker Debug to debug containers
with no shell.
Docker Hardened ktls-utils maintains the same entry point and command-line options as the standard ktls-utils package.
Use docker inspect to inspect entry points for Ghost hardened images if necessary.