Appendix C: Interview Preparation and Self-Test
This appendix helps you demonstrate what you have learned convincingly in a conversation. It has four parts: a storytelling method for your experience, scenario exercises for the whiteboard, a self-test with solutions and a self-assessment matrix.
The role this book refers to requires ten must-haves with years of experience:
| Must-have | Required | Chapter |
|---|---|---|
| Operated CI/CD yourself | 6 years | 1 |
| Assess and upgrade build processes | 5 years | 2 |
| Mirror as the only supply path | 4 years | 3 |
| Artifact transfer across zone boundaries | 4 years | 4 |
| Offline signing and your own PKI | 4 years | 5 |
| Secrets management incl. rotation | 6 years | 6 |
| SBOM and dependency analysis | 4 years | 7 |
| Scanning tools, triage, thresholds | 5 years | 8 |
| Policy as code | 5 years | 9 |
| Collaboration, exceptions, transition periods | 6 years | 10 |
Warning: This book does not replace professional experience. The labs give you understanding and vocabulary. In the interview, only talk about what you have really done, and say openly where you have only practiced something in the lab. Interviewers spot invented stories by the missing details, and at the latest it shows in the project.
Telling your experience credibly: the STAR method
Why a method?
Imagine telling a friend about a car breakdown. You do not say “I can change tires”. You say: “We were stuck on the highway at night, the tire was flat, I looked for the jack, and after 20 minutes we were back on the road.” A good interview answer works exactly the same way. A concrete story is more credible than any claim.
The STAR method gives this story a fixed shape:
| Letter | Meaning | Guiding question |
|---|---|---|
| S | Situation | Where was I, what was the starting point? |
| T | Task | What exactly was my assignment or goal? |
| A | Action | What did I do concretely, and in what order? |
| R | Result | What was the measurable outcome, what did I learn? |
Rules for good STAR answers
- I instead of we. The interviewer wants to know what you contributed. “We introduced Vault” says little. “I designed the policies and supported the migration of the first five teams” says a lot.
- Action is the longest part. About 60 percent of your speaking time belongs to the action. Situation and task are short.
- Numbers in the result. Duration, number of teams, number of findings, percent fewer false positives. Rough, honest numbers are enough.
- One mistake or one lesson. A story in which everything went smoothly sounds memorized. A sentence like “In hindsight, I would have … earlier” makes it real.
- Two minutes. Practice with a stopwatch. The interviewer will ask follow-up questions for details.
- Use technical terms confidently. Digest, lease, referrer, admission controller: whoever uses the terms correctly in passing shows hands-on experience.
Tip: Prepare a story for each must-have and write it down in bullet points on an index card. The same story often covers several questions, such as “Tell me about a conflict” and “Tell me about a rollout”.
How interviewers dig deeper
After every story, expect follow-up questions like these:
- “What exactly was your part?”
- “What would you have done differently?”
- “How did you monitor that?”
- “What happens if the key is compromised?”
- “How did you convince the developers?”
The following ten examples are generic and realistic. They are templates. Replace the details with your own experiences.
STAR examples for the ten must-haves
1. Operated CI/CD yourself
Situation: An organization with around 40 development teams used a self-hosted GitLab instance with a few shared shell runners. Builds often waited 20 minutes in the queue, and jobs from different teams shared a file system.
Task: I was to rebuild the runner landscape so that jobs run in isolation, waiting time drops and operations become observable.
Action: I first analyzed the job statistics of the last three months to understand load peaks. Then I set up runners with the Kubernetes executor in a dedicated cluster, with one namespace per runner group and resource limits per job. I replaced privileged Docker-in-Docker jobs with a rootless image build. Since then, the runner configuration lives in Git and is rolled out via Argo CD. For monitoring, I connected the runner’s Prometheus metrics and set alerts on queue length and error rate. I pre-tested upgrades on a fixed monthly schedule with a staging runner.
Result: The average waiting time dropped from about 20 to under 2 minutes. Jobs ran in isolation, and no job needed privileged containers anymore. I learned that I had initially set the resource limits too tight; that led to OOM kills for two weeks until we took values from real measurements.
2. Assess and upgrade build processes
Situation: A business application was built on a single build server that only one person understood. Dependencies were downloaded freely from the internet at build time, and versions were not pinned.
Task: I was to assess the build process and improve it so that builds are traceable, repeatable and verifiable.
Action: I assessed the process against a checklist based on the SLSA model: where does the source code live, who can trigger the build, where do dependencies come from, is provenance generated. The result was a prioritized list of twelve items. I first implemented the items with the greatest benefit: lock files with hashes, base images by digest, a multi-stage Dockerfile with a non-root user, building in a fresh pipeline environment instead of on the server. Finally, I built twice in a row and compared the digests to find non-determinism.
Result: After six weeks the build ran entirely in the pipeline, and the old server was switched off. The image shrank from about 900 to 150 MB, and the number of reported vulnerabilities dropped by around two thirds. We did not achieve fully bit-identical builds, because timestamps were embedded in an archive. I documented that as an open item.
3. Mirrored supply sources as the only supply path
Situation: Developers and pipelines downloaded packages directly from PyPI, npm and Docker Hub. There was no overview of what was used, and Docker Hub outages brought builds to a halt.
Task: I was to introduce an internal repository through which all pulls go, and then close direct internet access.
Action: I set up Nexus with proxy repositories for the three ecosystems and bundled them into group repositories. Internal packages went into a dedicated hosted repository, and I set up rules so that internal package names are never resolved from the public proxy. Then I switched central pipeline templates and base images to the mirrors. For three months the mirror ran in parallel while I tracked in the firewall logs who was still going directly to the internet. Only when that list was empty was outbound access blocked.
Result: All pulls go through one controlled point, the build survives outages of the public sources, and we have a complete inventory. The block itself caused only two disruptions, because the transition phase had revealed most gaps beforehand.
4. Controlled artifact transfer across zone boundaries
Situation: A production environment was located in an isolated network. Artifacts were transferred by USB stick and e-mail attachment, without a fixed checking procedure.
Task: I was to set up a regulated transfer process with checks, quarantine and approval.
Action: Together with the security department, I
first defined the requirements: only signed artifacts, checksums on both
sides, approval according to the four-eyes principle. Technically, I
built an export script on the outside that writes images together with
signatures and SBOM into a bundle with a checksum list using
skopeo and cosign save. On the inside, the
bundle lands in a quarantine registry. There, a job checks the
checksums, the signature against the internal trust anchor, and the scan
result. Only then does a second person copy it into the production
registry via an approval step. Every step writes an entry into a
log.
Result: Transfers take about 30 minutes instead of half a day, and every transfer is fully documented. At the first audit there was no finding regarding this process. One lesson was to limit the size of the bundles, because the media scanner aborted on very large archives.
5. Offline signing and your own trust anchor
Situation: Images were to be signed, but the environment was not allowed to reach public services such as Fulcio or Rekor. There was no internal trust anchor.
Task: I was to build our own PKI for signatures and enforce signature verification in the cluster.
Action: I designed a two-tier PKI: the root CA was created in a key ceremony on an offline machine, and its key is stored encrypted in a safe. An intermediate CA with a short lifetime signs the pipeline’s keys. I stored the signing key in Vault, so that it never leaves the pipeline as a file. Signing is done with Cosign without a transparency log, always on the digest. In the cluster, a Kyverno rule checks every signature against the public key. For emergencies, I wrote a runbook for key replacement and rehearsed it once.
Result: Since the rollout, only signed images run in the production cluster. The key replacement drill took four hours the first time and under an hour after the runbook was improved. I learned that the organizational part, that is, ceremony, roles and safekeeping, takes more time than the technology.
6. Secrets management including rotation
Situation: Several repositories contained database passwords and API tokens in plain text, some of them for years. Nobody knew which of them were still valid.
Task: I was to remove the credentials from the repositories, move them into a central secret store and introduce rotation.
Action: I first scanned all repositories including their history with gitleaks and created an inventory list. With the teams, I prioritized by criticality. Then I set up Vault with Kubernetes login and brought secrets into the namespaces via the External Secrets Operator. For databases, I switched to dynamic credentials valid for one hour. Every secret found was rotated before it was removed from the repo, because deleting it from the history alone does not protect anything. A pre-commit hook and a pipeline job prevent new findings.
Result: Around 180 secrets were rotated and migrated. New plain-text secrets are blocked in the pipeline, about a dozen times in the first quarter. One mistake was not coordinating the rotation of a service account with the external system; that led to a short disruption. Since then there has been a fallback option for every rotation.
7. SBOM and dependency analysis
Situation: After a critical vulnerability in a widely used library, the organization needed days to find out which applications were affected.
Task: I was to make sure that an SBOM exists for every delivered artifact and can be evaluated centrally.
Action: I built Syft into the central pipeline template as a step, so that every build produces a CycloneDX SBOM. The SBOM is attached to the image digest as an attestation with Cosign and additionally sent to Dependency-Track via the API, one project per application and version. I set up notifications for new critical findings to the team channels and configured license rules for forbidden licenses. The teams got a short guide on how to assess findings in Dependency-Track.
Result: At the next big vulnerability, a list of all affected applications and versions was available after about 15 minutes. Around 300 projects are monitored continuously. I learned that old project versions have to be cleaned up actively; otherwise there is a lot of noise.
8. Scanning tools, triage and thresholds
Situation: A scanner was active in all pipelines, but in report-only mode. The reports had hundreds of entries, and nobody read them.
Task: I was to configure the scans so that they reliably stop relevant risks without overwhelming the teams with noise.
Action: I first analyzed the findings of all projects and found that most of them came from base images, not from application code. So I provided hardened, slim base images. Then I defined a threshold: critical and high with an available fix break the build, everything else is reported. For exceptions, there was a central ignore file with justification, ticket and expiry date. Trivy, Checkov and Semgrep ran with shared reports in SARIF format. Once a week, I reviewed the new exceptions with a security colleague.
Result: The number of findings per project dropped by about 70 percent, mainly thanks to the new base images. Broken builds almost always had a real reason, so the threshold was accepted. At first I did not take reachability into account; today it feeds into triage via VEX statements.
9. Policy as code
Situation: In the Kubernetes cluster, containers ran
as root, with latest tags and without resource limits.
Rules existed only in a wiki.
Task: I was to enforce the most important operational and security rules technically.
Action: I agreed on five starter rules with the
teams: no root, no privileged containers, images only from the internal
registry, image by digest or fixed tag, resource limits set. I wrote the
rules as Kyverno policies and tested them with kyverno test
in a dedicated pipeline. Conftest checked the same rules against the
manifests already in the merge request, so that teams saw violations
before deployment. In the cluster, the rules first ran in Audit mode for
four weeks; I sent the policy reports to the teams weekly.
Result: After the transition phase, the rules were switched to Enforce, with only a few justified exceptions. The share of Pods running as root dropped from about 40 to under 5 percent. One lesson was that policy error messages must say clearly what to do; otherwise all questions land with the platform team.
10. Working with development teams, exceptions and transition periods
Situation: A new security rule was to apply to all teams, but some legacy applications could not meet it in the short term. The teams saw the security department as a brake.
Task: I was to introduce the rule without endangering operations and to create a fair exception process.
Action: I first presented the rule in office hours and explained which concrete risk it prevents. Together with two pilot teams, I created guides and example merge requests. The exception process had three components: a form with a justification and a compensating control, approval by the responsible person, and a fixed expiry date of at most 90 days. Exceptions were stored as code, for example as a Kyverno PolicyException, so that they are verifiable and expire automatically. A dashboard showed each team its status.
Result: After three months, over 90 percent of applications met the rule. The rest had approved, time-limited exceptions with a plan. In a feedback round, the teams rated the process as transparent. I learned that pilot teams as advocates achieve more than any mass e-mail.
Scenario exercises for the whiteboard
In many interviews you get an open design exercise. There is no single right solution. What is assessed is how you proceed: asking questions, stating assumptions, designing step by step, explaining risks and trade-offs.
A proven five-step procedure:
- Clarify: Ask about protection needs, zones, size, existing tools, requirements.
- Big picture: Draw boxes and arrows from source to runtime.
- Deepen: Work out two or three critical points in more detail.
- Safeguard: What happens in case of an outage, a compromise, an emergency?
- Operations: Monitoring, audit, roles, rollout.
Scenario 1: Supply chain for an air-gapped government environment
Task: Design a software supply chain for a government agency. The production environment is completely separated from the internet. Applications are developed and built outside. All artifacts must be demonstrably checked and signed.
Questions you should ask:
- Is there a data diode or a media process for the crossing?
- Who may approve, and is there a four-eyes principle?
- Which regulations apply, such as BSI IT-Grundschutz or rules for classified information?
- How often must you deliver, and how fast in an emergency?
Sample solution as a sketch:
ZONE OUTSIDE (build) | ZONE INSIDE (production, air-gapped)
|
Git --> CI (GitLab) --> Build |
| pull only via Nexus |
v |
Scans: gitleaks, semgrep, |
trivy, checkov |
| |
SBOM (syft) + signature (cosign, |
key from Vault, own PKI) |
| |
Export bundle: images, sig., SBOM,|
checksums, record ===========|==> quarantine registry
media/ | |
diode | check job: checksums,
| signature, scan with
| mirrored DB
| | approval (4 eyes)
| v
| prod registry --> Argo CD
| |
| Kyverno: signed only,
| prod registry only
Points you should explain:
- External packages are pulled only through the mirror, so the inventory is complete.
- Signature on the digest, root CA offline, signing key never as a file in the pipeline.
- Inside, everything is checked again, because the inside does not have to trust the outside.
- Vulnerability databases for Trivy and Grype are transferred along with it regularly.
- Kyverno enforces in the cluster what the process promises, as the last line of defense.
- An emergency path for urgent security updates with a shortened but documented approval.
Scenario 2: Secrets migration in an organically grown landscape
Task: A company has 200 repositories. Many of them contain credentials in plain text. Design a plan for managing the secrets centrally and rotating them regularly within six months.
Questions you should ask:
- Is there already a secret store or a requirement for one?
- Do the applications run on Kubernetes, VMs or both?
- Which systems support dynamic credentials, and which only static ones?
Key points of a good answer:
- Inventory with gitleaks across all repos including history, results sorted by criticality.
- Rotate first, then remove from the repo, because history and clones keep the old value.
- Target architecture: Vault or OpenBao, Kubernetes login, External Secrets Operator, policies following the principle of least privilege.
- Dynamic credentials for databases, fixed rotation intervals for the rest.
- Protection against relapse: a pre-commit hook and a pipeline check with a baseline.
- Rollout in waves with pilot teams; operations with an audit log, alerts on sync failures, high availability and an unseal concept.
Scenario 3: Introducing policy as code without disrupting operations
Task: In a cluster with 30 teams, from now on only signed images from the internal registry may run, and no containers as root. How do you proceed?
Key points of a good answer:
- Measure the current state: Kyverno in Audit mode, evaluate the policy reports.
- Test rules as code beforehand (
kyverno test) and move the same checks forward into the pipeline (Conftest orkyverno apply). - Announce a transition period with a fixed date, provide guides and examples.
- An exception process with expiry dates, exceptions as PolicyExceptions in Git.
- Exempt system namespaces such as
kube-systemdeliberately and in a documented way. - Switch to Enforce in stages, first test, then production; a fallback plan in case the admission controller fails (define the webhook’s failure behavior).
Self-test: 30 questions
Answer the questions in writing first, without looking anything up. The solutions are at the end of the section. For multiple-choice questions, exactly one answer is correct unless stated otherwise.
Questions on CI/CD and build processes
1. Which GitLab CI keyword makes a job start
directly after a specific other job, without waiting for the whole stage
to finish? a) dependencies · b) needs · c)
rules · d) extends
2. What does selfHeal: true mean in an
Argo CD Application?
3. Why should a base image in a Dockerfile be referenced by digest rather than by tag?
4. Which statement about multi-stage builds is true? a) They make the build faster but the image larger. b) Build tools and source code do not end up in the final image. c) They replace the signature. d) They only work with Alpine.
5. Name two risks of privileged Docker-in-Docker jobs on shared runners.
Questions on mirrors and zone transfer
6. What is dependency confusion, and how does a repository manager prevent it?
7. Which command copies an image from one registry
to another without a Docker daemon? a) docker cp · b)
skopeo copy · c) syft convert · d)
kubectl cp
8. Why does the inside of a zone boundary check the signature and checksums again, even though they were already checked outside?
9. Which three components should a transfer bundle contain at a minimum?
10. What is a referrer in the OCI context?
Questions on signing and PKI
11. Why is the root CA kept offline and an intermediate CA used for everyday work?
12. Which Cosign flag prevents the upload to the
public transparency log when signing? a) --offline · b)
--tlog-upload=false · c) --no-rekor · d)
--insecure-ignore-tlog
13. Why do you sign the digest and not the tag?
14. What does pathlen:0 mean in the
basic constraints of an intermediate CA?
15. What is the difference between a signature and an attestation?
Questions on secrets
16. A password was accidentally committed to Git. What is the most important first step? a) Remove the commit from the history via rebase b) Rotate the password c) Make the repository private d) Add a gitleaks rule
17. What is a lease in Vault or OpenBao?
18. Which Kubernetes resource of the External Secrets Operator describes how the secret store is accessed?
19. Name one advantage of dynamic database credentials over static ones.
20. Why is a Kubernetes Secret alone not enough as secrets management?
Questions on SBOM and scanning tools
21. Name the two common SBOM standards.
22. What is Dependency-Track for, as opposed to a one-time scan in the build?
23. Which Trivy options make a pipeline fail only on critical and high findings with an available fix?
24. What is a false positive, and how do you document it properly?
25. Which tool category checks Terraform and Kubernetes files for misconfigurations? a) SAST · b) SCA · c) IaC scan · d) DAST
26. What does VEX state?
Questions on policy as code and collaboration
27. What is the difference between Audit and Enforce mode in Kyverno?
28. In which Rego package does conftest look for
deny rules by default?
29. Which four pieces of information belong to a good exception at a minimum?
30. Why is it worth checking the same policies both in the pipeline and in the cluster?
Answer key
1. b) needs. This creates a directed
graph instead of a rigid stage order.
2. Argo CD automatically resets manual changes in the cluster to the state in Git.
3. A tag can point to a different image at any time; the digest is immutable, which makes the build repeatable and tamper-proof.
4. b) Build tools and source code stay in the early stages; the final image is smaller and has a smaller attack surface.
5. For example: escape to the host kernel is possible; access to other jobs and their secrets; a shared Docker cache can be poisoned.
6. An attacker publishes a public package with the name of an internal package and a higher version. Remedy: resolve internal namespaces only from the hosted repository, routing rules or separate groups.
7. b) skopeo copy (alternatively
crane copy or oras copy).
8. The inside must not blindly trust the outside. The bundle could have been modified in transit, and only the inner check against the inner trust anchor counts.
9. The artifacts themselves, their signatures or attestations (including the SBOM) and a checksum list. A transfer record is highly recommended.
10. An artifact that points to the digest of another
artifact via the subject field, such as a signature or SBOM
for an image.
11. If an online key is compromised, you only revoke the intermediate CA and issue a new one. The root, and with it the trust of all systems, is preserved.
12. b) --tlog-upload=false. The
counterpart when verifying is
--insecure-ignore-tlog=true.
13. Because a tag can be moved. The signature must be bound to exactly the immutable content.
14. This CA may issue end-entity certificates, but no further CAs below it.
15. A signature confirms: this artifact comes from this key and is unchanged. An attestation is a signed statement about the artifact, such as an SBOM, provenance or a scan result.
16. b) Rotate the password. The history may already have been cloned or mirrored.
17. A time-limited allocation of a secret. After expiry or revocation, the secret becomes invalid; with dynamic credentials, the account is deleted.
18. SecretStore (per namespace) or
ClusterSecretStore (cluster-wide).
19. For example: a short lifetime limits the damage in case of theft; every application has its own credentials, which improves traceability; no manual rotation needed.
20. Kubernetes Secrets are only Base64-encoded, not automatically encrypted. Central management, rotation, auditing and fine-grained provenance are missing.
21. CycloneDX and SPDX.
22. Dependency-Track re-evaluates SBOMs continuously. If a new vulnerability becomes known tomorrow, it reports affected projects without a rebuild.
23.
--severity HIGH,CRITICAL --exit-code 1 --ignore-unfixed.
24. A reported finding that does not actually pose a risk. Documentation with justification, owner, ticket and expiry date in a versioned ignore file or as a VEX statement.
25. c) IaC scan, for example Checkov or
trivy config.
26. Whether a product is actually affected by a specific vulnerability, such as “not affected” with a justification.
27. Audit only reports violations in policy reports. Enforce blocks the resource at admission to the cluster.
28. In the main package.
29. Justification, a responsible person with approval, a compensating control and an expiry date. A ticket for the final fix is a good addition.
30. The pipeline gives teams early, cheap feedback. The cluster is the last line of defense for everything that bypasses the pipeline.
Remember: With fewer than 20 correct answers, it is worth working through the chapters for the questions you got wrong once more. From 25 on, you are well prepared for a technical interview.
Self-assessment matrix
Check the boxes honestly. The matrix shows you where you can speak confidently in the interview and where you should say openly: “I built this in the lab but have not run it in production yet.” This honesty is more convincing than an inflated story.
| Topic | Can explain it | Done in the lab | Run in production |
|---|---|---|---|
| Operating GitLab runners | [ ] | [ ] | [ ] |
| Jenkins pipeline with credentials | [ ] | [ ] | [ ] |
| GitOps with Argo CD or Flux | [ ] | [ ] | [ ] |
| Assessing build processes with SLSA | [ ] | [ ] | [ ] |
| Hardened multi-stage Dockerfile | [ ] | [ ] | [ ] |
| Nexus/Harbor as a proxy | [ ] | [ ] | [ ] |
| Blocking internet access for builds | [ ] | [ ] | [ ] |
| Copying images with skopeo/crane/oras | [ ] | [ ] | [ ] |
| Quarantine and approval at the zone boundary | [ ] | [ ] | [ ] |
| Building a root and intermediate CA | [ ] | [ ] | [ ] |
| Signing and verifying offline with Cosign | [ ] | [ ] | [ ] |
| Key replacement after a compromise | [ ] | [ ] | [ ] |
| Vault/OpenBao with Kubernetes login | [ ] | [ ] | [ ] |
| External Secrets Operator | [ ] | [ ] | [ ] |
| Dynamic credentials and rotation | [ ] | [ ] | [ ] |
| Cleaning secrets from Git history | [ ] | [ ] | [ ] |
| Generating SBOMs with Syft | [ ] | [ ] | [ ] |
| Operating Dependency-Track | [ ] | [ ] | [ ] |
| Trivy/Grype with thresholds | [ ] | [ ] | [ ] |
| Checkov and Semgrep in the pipeline | [ ] | [ ] | [ ] |
| Triage with VEX and expiry dates | [ ] | [ ] | [ ] |
| Writing and testing Kyverno policies | [ ] | [ ] | [ ] |
| Rego with conftest/opa | [ ] | [ ] | [ ] |
| Signature verification via admission control | [ ] | [ ] | [ ] |
| Exception process with a transition period | [ ] | [ ] | [ ] |
| Rollout with pilot teams | [ ] | [ ] | [ ] |
How to evaluate the matrix:
- Only “Can explain it”: catch up on the lab from the matching chapter.
- “Done in the lab”, not in production: in the interview, call it lab experience and add a thought on operations, such as monitoring or emergencies.
- All three checked: turn it into a STAR story.
Summary
- The STAR method makes experience tangible: a short situation and task, a detailed action, a measurable result with a lesson.
- Tell your story in the first person, with numbers and with technical terms you have truly mastered.
- You solve whiteboard exercises with clarify, big picture, deepen, safeguard and operations.
- An air-gapped supply chain relies on mirrors, signatures on the digest, re-checking on the inside and enforcement in the cluster.
- The self-test shows you gaps; the chapter references tell you where to catch up.
- The self-assessment matrix honestly separates understanding, practicing and operating.