SlideShare a Scribd company logo
1
Secret Management with
Hashicorp Vault and Consul
on Kubernetes
2
Agenda
 What’s a secret?
 Secret management
 Hashicorp Vault
 Deployment topology
 Demo
 Q&A
3
What is a secret?
 Anything is sensitive information
• Database user, password
• API keys
• SSL keys
• Encryption keys
• Cloud credentials
• Certificates
• etc..
4
Why secret management matters
 Moving fast of software development process and infrastructure
 Micro-services based architecture: service to service communication via
tokens, API keys, certificates
 DevOps processes: multiple environments for development, testing, integration,
and production
 Cloud native application and multi-cloud infrastructure: secrets for storage,
compute, analytics, logging, etc..
5
Traditional secret management (anti-patterns)
 Storing secrets:
• Hard-coding
• Clear text config files
• SCM (git, svn)
• Unencrypted file system (laptop, NFS)
 Distributed secrets:
• Email
• Slack
• Shared folder
6
Modern secret management
 Modern secret management properties:
• Secrets are encrypted at rest
• Centrally managed
• Access control to secrets
• Auditable
• Scalable
• Easy to integrate
• High automation for creating, revoking, rotating secrets
• Supported
7
Hashicorp Vault
 Modern secret management application
 Secure secret storage (in-memory, Consul, file, and more)
 Programmatic application access (automated)
 Operator access (manual)
 Leasing, renewal, revocation
 Dynamic secrets
 Rich ALCs
 Multiple client authentication methods
 Auditing
8
Vault Features
 Secure secret storage:
• Data is encrypted in transit and at rest
• TLS for clients
• No HSM required
• Support many storages: in-memory, Filesystem, Consul, DynamoDB, Etcd,
MySQL, PostgreSQL, S3, Zookeeper, etc..
9
Vault Features (cont.)
 Leasing, renewal, and revocation:
• Every secret has a lease
• Secrets are revoked at the end of the lease unless renewed
• Secret may be revoked early by operators
 Auditing:
• Pluggable audit backends
• Request and response logging
• Secrets hashed in audit log
10
Vault Features (cont.)
 Dynamic credentials:
• On-the-fly created credentials for each instance of an application or user
• Usually short to medium TTL
• Pluggable backends
o Supported databases: MySQL, MariaDB, PostgreSQL, MSSQL, Oracle,
MongoDB, Cassandra, Influxdb, etc...
o Cloud: AWS, Google Cloud, Azure
o SSH: one time password
11
Vault Features (cont.)
How does dynamic credential work?
12
Vault Features (cont.)
 Support multiple auth backends
• Token
• LDAP
• Username & password
• AppRole
• AWS
• Google Cloud
• Kubernetes
• …
13
Vault Features (cont.)
 Support multiple auth backends
• Token
• LDAP
• Username & password
• AppRole
• AWS
• Google Cloud
• Kubernetes
• …
14
Vault Enterprise Features
Feature Open source Pro Premium
Control Groups X
Multi-factor Authentication X
Read Replicas (performance standby) X
Disaster Recovery (DR replication) X X
Replication (performance replication) X
Replication Filters X
Namespace X X
Auto unseal (AWS, Google cloud, Azure) X X X
15
Vault Enterprise Features (cont.)
Performance standby node
 Handle GET requests of key/value secrets and other requests that do not
change underlying storage
16
Vault Enterprise Features (cont.)
Disaster recovery replication (DR replication)
 Replicated content, consistent across Vault
clusters
• Secret configurations
• Access control policies
• Authentication methods
• Audit configuration
• Tokens
• Leases
17
Vault Enterprise Features (cont.)
Performance replication
 Allowing Vault to scale relatively horizontally rather than vertically
 Secondaries keep track of their own tokens and leases
 If there is a request that modifiese underlying shared state, the secondary
forwards the request to the primary to be handled; this is transparent to the
client
18
Vault Enterprise Features (cont.)
Performance replication vs DR replication
Capability DR Performance
Mirrors the configuration of a primary cluster Yes Yes
Mirrors the configuration of a primary cluster’s
backends (i.e.: auth methods, secrets engines, audit
devices, etc.)
Yes Yes
Mirrors the tokens and leases for applications and
users interacting with the primary cluster
Yes No
Allows the secondary cluster to handle client requests No Yes
19
Vault Enterprise Features (cont.)
20
Understanding Seal and Unseal
 Seal state:
• When a Vault server first boots
• When a Vault server is started
• Vault servers do not know how to decrypt data
 Unsealing is a process of constructing the master key (which is constructed by
Shamir’s secret sharing algorithms) to read decryption key to decrypt data
 Unsealed state is remained until one of two thing below happens:
• It is resealed via API
• The server is restarted
21
Deploy Vault on Kubernetes
 Consul cluster is to serve as the
storage backend for Vault since it
supports HA mode
 Only active pod replies to requests.
Standby pods will redirect requests to
the active one
 Leader election is done in storage
backend
 Refer here for details
22
Demo
 Scenario 1: Legacy applications that don’t run on Kubernetes
 Scenario 2: Legacy applications that run on Kubernetes
 Scenario 3: New applications that use static credentials
 Scenario 4: New applications that use dynamic credentials
23
Scenario 1: Legacy applications that don’t run on k8s
24
Scenario 1: Legacy applications that don’t run on k8s
25
Scenario 1: Legacy applications that don’t run on k8s
1. Jenkins master triggers a new build
2. Jenkins slave pulls source code from SCM, does necessary steps to
build software packages and push to Artifactory if needed
3. The slave authenticates to Vault and gets required secrets that need for
deployment steps
4. Deployment server gets software packages from Jenkins master or
Artifactory and secrets. Doing necessary steps to deploy application
26
Scenario 2: Legacy applications that run on Kubernetes
27
Scenario 3: New applications that use static credentials
28
Scenario 4: New applications that use dynamic creds
29
Q&A
Ad

More Related Content

What's hot (20)

Open shift 4 infra deep dive
Open shift 4    infra deep diveOpen shift 4    infra deep dive
Open shift 4 infra deep dive
Winton Winton
 
Vault
VaultVault
Vault
Jean-Philippe Bélanger
 
Docker Container Introduction
Docker Container IntroductionDocker Container Introduction
Docker Container Introduction
Innfinision Cloud and BigData Solutions
 
2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...
2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...
2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...
Andrey Devyatkin
 
Microservices Docker Kubernetes Istio Kanban DevOps SRE
Microservices Docker Kubernetes Istio Kanban DevOps SREMicroservices Docker Kubernetes Istio Kanban DevOps SRE
Microservices Docker Kubernetes Istio Kanban DevOps SRE
Araf Karsh Hamid
 
OPENSHIFT CONTAINER PLATFORM CI/CD Build & Deploy
OPENSHIFT CONTAINER PLATFORM CI/CD Build & DeployOPENSHIFT CONTAINER PLATFORM CI/CD Build & Deploy
OPENSHIFT CONTAINER PLATFORM CI/CD Build & Deploy
Natale Vinto
 
Cloud Native Bern 05.2023 — Zero Trust Visibility
Cloud Native Bern 05.2023 — Zero Trust VisibilityCloud Native Bern 05.2023 — Zero Trust Visibility
Cloud Native Bern 05.2023 — Zero Trust Visibility
Raphaël PINSON
 
Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라
Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라
Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라
MinKyu Kim
 
Kubernetes Secrets Management on Production with Demo
Kubernetes Secrets Management on Production with DemoKubernetes Secrets Management on Production with Demo
Kubernetes Secrets Management on Production with Demo
Opsta
 
Gitlab, GitOps & ArgoCD
Gitlab, GitOps & ArgoCDGitlab, GitOps & ArgoCD
Gitlab, GitOps & ArgoCD
Haggai Philip Zagury
 
Vault Open Source vs Enterprise v2
Vault Open Source vs Enterprise v2Vault Open Source vs Enterprise v2
Vault Open Source vs Enterprise v2
Stenio Ferreira
 
Securing Kubernetes Applications with HashiCorp Vault
Securing Kubernetes Applications with HashiCorp VaultSecuring Kubernetes Applications with HashiCorp Vault
Securing Kubernetes Applications with HashiCorp Vault
DevOps.com
 
Terraform
TerraformTerraform
Terraform
Phil Wilkins
 
Container Security
Container SecurityContainer Security
Container Security
Salman Baset
 
HashiCorp's Vault - The Examples
HashiCorp's Vault - The ExamplesHashiCorp's Vault - The Examples
HashiCorp's Vault - The Examples
Michał Czeraszkiewicz
 
Deploy Application on Kubernetes
Deploy Application on KubernetesDeploy Application on Kubernetes
Deploy Application on Kubernetes
Opsta
 
DevOps with Kubernetes
DevOps with KubernetesDevOps with Kubernetes
DevOps with Kubernetes
EastBanc Tachnologies
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentation
Suresh Kumar
 
Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...
Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...
Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...
Vietnam Open Infrastructure User Group
 
Kubernetes in Docker
Kubernetes in DockerKubernetes in Docker
Kubernetes in Docker
Docker, Inc.
 
Open shift 4 infra deep dive
Open shift 4    infra deep diveOpen shift 4    infra deep dive
Open shift 4 infra deep dive
Winton Winton
 
2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...
2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...
2020-02-20 - HashiCorpUserGroup Madring - Integrating HashiCorp Vault and Kub...
Andrey Devyatkin
 
Microservices Docker Kubernetes Istio Kanban DevOps SRE
Microservices Docker Kubernetes Istio Kanban DevOps SREMicroservices Docker Kubernetes Istio Kanban DevOps SRE
Microservices Docker Kubernetes Istio Kanban DevOps SRE
Araf Karsh Hamid
 
OPENSHIFT CONTAINER PLATFORM CI/CD Build & Deploy
OPENSHIFT CONTAINER PLATFORM CI/CD Build & DeployOPENSHIFT CONTAINER PLATFORM CI/CD Build & Deploy
OPENSHIFT CONTAINER PLATFORM CI/CD Build & Deploy
Natale Vinto
 
Cloud Native Bern 05.2023 — Zero Trust Visibility
Cloud Native Bern 05.2023 — Zero Trust VisibilityCloud Native Bern 05.2023 — Zero Trust Visibility
Cloud Native Bern 05.2023 — Zero Trust Visibility
Raphaël PINSON
 
Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라
Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라
Packer, Terraform, Vault를 이용해 만드는 
재현 가능한 게임 인프라
MinKyu Kim
 
Kubernetes Secrets Management on Production with Demo
Kubernetes Secrets Management on Production with DemoKubernetes Secrets Management on Production with Demo
Kubernetes Secrets Management on Production with Demo
Opsta
 
Vault Open Source vs Enterprise v2
Vault Open Source vs Enterprise v2Vault Open Source vs Enterprise v2
Vault Open Source vs Enterprise v2
Stenio Ferreira
 
Securing Kubernetes Applications with HashiCorp Vault
Securing Kubernetes Applications with HashiCorp VaultSecuring Kubernetes Applications with HashiCorp Vault
Securing Kubernetes Applications with HashiCorp Vault
DevOps.com
 
Container Security
Container SecurityContainer Security
Container Security
Salman Baset
 
Deploy Application on Kubernetes
Deploy Application on KubernetesDeploy Application on Kubernetes
Deploy Application on Kubernetes
Opsta
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentation
Suresh Kumar
 
Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...
Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...
Room 2 - 3 - Nguyễn Hoài Nam & Nguyễn Việt Hùng - Terraform & Pulumi Comparin...
Vietnam Open Infrastructure User Group
 
Kubernetes in Docker
Kubernetes in DockerKubernetes in Docker
Kubernetes in Docker
Docker, Inc.
 

Similar to Secret Management with Hashicorp Vault and Consul on Kubernetes (20)

Managing your secrets in a cloud environment
Managing your secrets in a cloud environmentManaging your secrets in a cloud environment
Managing your secrets in a cloud environment
Taswar Bhatti
 
DCSF19 Container Security: Theory & Practice at Netflix
DCSF19 Container Security: Theory & Practice at NetflixDCSF19 Container Security: Theory & Practice at Netflix
DCSF19 Container Security: Theory & Practice at Netflix
Docker, Inc.
 
Vault
VaultVault
Vault
dawnlua
 
TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...
TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...
TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...
Trivadis
 
Architecting for Microservices Part 2
Architecting for Microservices Part 2Architecting for Microservices Part 2
Architecting for Microservices Part 2
Elana Krasner
 
Centralizing Kubernetes and Container Operations
Centralizing Kubernetes and Container OperationsCentralizing Kubernetes and Container Operations
Centralizing Kubernetes and Container Operations
Kublr
 
Vault Digital Transformation
Vault Digital TransformationVault Digital Transformation
Vault Digital Transformation
Stenio Ferreira
 
ServerTemplates - The Next Generation
ServerTemplates - The Next GenerationServerTemplates - The Next Generation
ServerTemplates - The Next Generation
RightScale
 
Chickens & Eggs: Managing secrets in AWS with Hashicorp Vault
Chickens & Eggs: Managing secrets in AWS with Hashicorp VaultChickens & Eggs: Managing secrets in AWS with Hashicorp Vault
Chickens & Eggs: Managing secrets in AWS with Hashicorp Vault
Jeff Horwitz
 
OpenStack and Windows
OpenStack and WindowsOpenStack and Windows
OpenStack and Windows
Alessandro Pilotti
 
Why Kubernetes as a container orchestrator is a right choice for running spar...
Why Kubernetes as a container orchestrator is a right choice for running spar...Why Kubernetes as a container orchestrator is a right choice for running spar...
Why Kubernetes as a container orchestrator is a right choice for running spar...
DataWorks Summit
 
Intelligent Cloud Conference 2018 - Building secure cloud applications with A...
Intelligent Cloud Conference 2018 - Building secure cloud applications with A...Intelligent Cloud Conference 2018 - Building secure cloud applications with A...
Intelligent Cloud Conference 2018 - Building secure cloud applications with A...
Tom Kerkhove
 
Elastic Kubernetes Services (EKS)
Elastic Kubernetes Services (EKS)Elastic Kubernetes Services (EKS)
Elastic Kubernetes Services (EKS)
sriram_rajan
 
Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020
Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020
Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020
AVIO Consulting
 
Techdays Finland 2018 - Building secure cloud applications with Azure Key Vault
Techdays Finland 2018 - Building secure cloud applications with Azure Key VaultTechdays Finland 2018 - Building secure cloud applications with Azure Key Vault
Techdays Finland 2018 - Building secure cloud applications with Azure Key Vault
Tom Kerkhove
 
Hacking apache cloud stack
Hacking apache cloud stackHacking apache cloud stack
Hacking apache cloud stack
Nitin Mehta
 
AWS Lambda at JUST EAT
AWS Lambda at JUST EATAWS Lambda at JUST EAT
AWS Lambda at JUST EAT
Andrew Brown
 
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
NETWAYS
 
Demystifying Kubernetes for Enterprise DevOps
Demystifying Kubernetes for Enterprise DevOpsDemystifying Kubernetes for Enterprise DevOps
Demystifying Kubernetes for Enterprise DevOps
Jim Bugwadia
 
Vault - Enhancement for K8S secret security
Vault - Enhancement for K8S secret securityVault - Enhancement for K8S secret security
Vault - Enhancement for K8S secret security
Huynh Thai Bao
 
Managing your secrets in a cloud environment
Managing your secrets in a cloud environmentManaging your secrets in a cloud environment
Managing your secrets in a cloud environment
Taswar Bhatti
 
DCSF19 Container Security: Theory & Practice at Netflix
DCSF19 Container Security: Theory & Practice at NetflixDCSF19 Container Security: Theory & Practice at Netflix
DCSF19 Container Security: Theory & Practice at Netflix
Docker, Inc.
 
TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...
TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...
TechEvent 2019: Oracle Databases as Managed Service at AWS, Yes it works!; Al...
Trivadis
 
Architecting for Microservices Part 2
Architecting for Microservices Part 2Architecting for Microservices Part 2
Architecting for Microservices Part 2
Elana Krasner
 
Centralizing Kubernetes and Container Operations
Centralizing Kubernetes and Container OperationsCentralizing Kubernetes and Container Operations
Centralizing Kubernetes and Container Operations
Kublr
 
Vault Digital Transformation
Vault Digital TransformationVault Digital Transformation
Vault Digital Transformation
Stenio Ferreira
 
ServerTemplates - The Next Generation
ServerTemplates - The Next GenerationServerTemplates - The Next Generation
ServerTemplates - The Next Generation
RightScale
 
Chickens & Eggs: Managing secrets in AWS with Hashicorp Vault
Chickens & Eggs: Managing secrets in AWS with Hashicorp VaultChickens & Eggs: Managing secrets in AWS with Hashicorp Vault
Chickens & Eggs: Managing secrets in AWS with Hashicorp Vault
Jeff Horwitz
 
Why Kubernetes as a container orchestrator is a right choice for running spar...
Why Kubernetes as a container orchestrator is a right choice for running spar...Why Kubernetes as a container orchestrator is a right choice for running spar...
Why Kubernetes as a container orchestrator is a right choice for running spar...
DataWorks Summit
 
Intelligent Cloud Conference 2018 - Building secure cloud applications with A...
Intelligent Cloud Conference 2018 - Building secure cloud applications with A...Intelligent Cloud Conference 2018 - Building secure cloud applications with A...
Intelligent Cloud Conference 2018 - Building secure cloud applications with A...
Tom Kerkhove
 
Elastic Kubernetes Services (EKS)
Elastic Kubernetes Services (EKS)Elastic Kubernetes Services (EKS)
Elastic Kubernetes Services (EKS)
sriram_rajan
 
Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020
Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020
Hashicorp Vault Connector - Dallas MuleSoft Meetup - May 6, 2020
AVIO Consulting
 
Techdays Finland 2018 - Building secure cloud applications with Azure Key Vault
Techdays Finland 2018 - Building secure cloud applications with Azure Key VaultTechdays Finland 2018 - Building secure cloud applications with Azure Key Vault
Techdays Finland 2018 - Building secure cloud applications with Azure Key Vault
Tom Kerkhove
 
Hacking apache cloud stack
Hacking apache cloud stackHacking apache cloud stack
Hacking apache cloud stack
Nitin Mehta
 
AWS Lambda at JUST EAT
AWS Lambda at JUST EATAWS Lambda at JUST EAT
AWS Lambda at JUST EAT
Andrew Brown
 
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
NETWAYS
 
Demystifying Kubernetes for Enterprise DevOps
Demystifying Kubernetes for Enterprise DevOpsDemystifying Kubernetes for Enterprise DevOps
Demystifying Kubernetes for Enterprise DevOps
Jim Bugwadia
 
Vault - Enhancement for K8S secret security
Vault - Enhancement for K8S secret securityVault - Enhancement for K8S secret security
Vault - Enhancement for K8S secret security
Huynh Thai Bao
 
Ad

More from An Nguyen (17)

Terraform
TerraformTerraform
Terraform
An Nguyen
 
Introduce to Git and Jenkins
Introduce to Git and JenkinsIntroduce to Git and Jenkins
Introduce to Git and Jenkins
An Nguyen
 
CI/CD Overview
CI/CD OverviewCI/CD Overview
CI/CD Overview
An Nguyen
 
Introduce to Credstash
Introduce to CredstashIntroduce to Credstash
Introduce to Credstash
An Nguyen
 
Introduction To AWS & AWS Lambda
Introduction To AWS & AWS LambdaIntroduction To AWS & AWS Lambda
Introduction To AWS & AWS Lambda
An Nguyen
 
Introduction To Docker, Docker Compose, Docker Swarm
Introduction To Docker, Docker Compose, Docker SwarmIntroduction To Docker, Docker Compose, Docker Swarm
Introduction To Docker, Docker Compose, Docker Swarm
An Nguyen
 
Spring framework
Spring frameworkSpring framework
Spring framework
An Nguyen
 
Luận văn tìm hiểu Spring
Luận văn tìm hiểu SpringLuận văn tìm hiểu Spring
Luận văn tìm hiểu Spring
An Nguyen
 
Terminal Services and VPN
Terminal Services and VPNTerminal Services and VPN
Terminal Services and VPN
An Nguyen
 
Tân sinh viên TECH - AGU 2014
Tân sinh viên TECH - AGU 2014Tân sinh viên TECH - AGU 2014
Tân sinh viên TECH - AGU 2014
An Nguyen
 
Quy tắc thiết kế giao diện và viết code C#
Quy tắc thiết kế giao diện và viết code C#Quy tắc thiết kế giao diện và viết code C#
Quy tắc thiết kế giao diện và viết code C#
An Nguyen
 
Nêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làm
Nêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làmNêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làm
Nêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làm
An Nguyen
 
Hướng dẫn lập trình quản lý c#
Hướng dẫn lập trình quản lý c#Hướng dẫn lập trình quản lý c#
Hướng dẫn lập trình quản lý c#
An Nguyen
 
Quản lý quan hệ khách hàng
Quản lý quan hệ khách hàngQuản lý quan hệ khách hàng
Quản lý quan hệ khách hàng
An Nguyen
 
Quản lý quan hệ khách hàng
Quản lý quan hệ khách hàngQuản lý quan hệ khách hàng
Quản lý quan hệ khách hàng
An Nguyen
 
RichTetxtBox control
RichTetxtBox controlRichTetxtBox control
RichTetxtBox control
An Nguyen
 
Hội nghị học tốt CNTT 2013 - An Giang University
Hội nghị học tốt CNTT 2013 - An Giang UniversityHội nghị học tốt CNTT 2013 - An Giang University
Hội nghị học tốt CNTT 2013 - An Giang University
An Nguyen
 
Introduce to Git and Jenkins
Introduce to Git and JenkinsIntroduce to Git and Jenkins
Introduce to Git and Jenkins
An Nguyen
 
CI/CD Overview
CI/CD OverviewCI/CD Overview
CI/CD Overview
An Nguyen
 
Introduce to Credstash
Introduce to CredstashIntroduce to Credstash
Introduce to Credstash
An Nguyen
 
Introduction To AWS & AWS Lambda
Introduction To AWS & AWS LambdaIntroduction To AWS & AWS Lambda
Introduction To AWS & AWS Lambda
An Nguyen
 
Introduction To Docker, Docker Compose, Docker Swarm
Introduction To Docker, Docker Compose, Docker SwarmIntroduction To Docker, Docker Compose, Docker Swarm
Introduction To Docker, Docker Compose, Docker Swarm
An Nguyen
 
Spring framework
Spring frameworkSpring framework
Spring framework
An Nguyen
 
Luận văn tìm hiểu Spring
Luận văn tìm hiểu SpringLuận văn tìm hiểu Spring
Luận văn tìm hiểu Spring
An Nguyen
 
Terminal Services and VPN
Terminal Services and VPNTerminal Services and VPN
Terminal Services and VPN
An Nguyen
 
Tân sinh viên TECH - AGU 2014
Tân sinh viên TECH - AGU 2014Tân sinh viên TECH - AGU 2014
Tân sinh viên TECH - AGU 2014
An Nguyen
 
Quy tắc thiết kế giao diện và viết code C#
Quy tắc thiết kế giao diện và viết code C#Quy tắc thiết kế giao diện và viết code C#
Quy tắc thiết kế giao diện và viết code C#
An Nguyen
 
Nêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làm
Nêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làmNêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làm
Nêu cao tinh thần trách nhiệm, chống chủ nghĩa cá nhân, nói đi đôi với làm
An Nguyen
 
Hướng dẫn lập trình quản lý c#
Hướng dẫn lập trình quản lý c#Hướng dẫn lập trình quản lý c#
Hướng dẫn lập trình quản lý c#
An Nguyen
 
Quản lý quan hệ khách hàng
Quản lý quan hệ khách hàngQuản lý quan hệ khách hàng
Quản lý quan hệ khách hàng
An Nguyen
 
Quản lý quan hệ khách hàng
Quản lý quan hệ khách hàngQuản lý quan hệ khách hàng
Quản lý quan hệ khách hàng
An Nguyen
 
RichTetxtBox control
RichTetxtBox controlRichTetxtBox control
RichTetxtBox control
An Nguyen
 
Hội nghị học tốt CNTT 2013 - An Giang University
Hội nghị học tốt CNTT 2013 - An Giang UniversityHội nghị học tốt CNTT 2013 - An Giang University
Hội nghị học tốt CNTT 2013 - An Giang University
An Nguyen
 
Ad

Recently uploaded (20)

Who Watches the Watchmen (SciFiDevCon 2025)
Who Watches the Watchmen (SciFiDevCon 2025)Who Watches the Watchmen (SciFiDevCon 2025)
Who Watches the Watchmen (SciFiDevCon 2025)
Allon Mureinik
 
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
ssuserb14185
 
Expand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchangeExpand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchange
Fexle Services Pvt. Ltd.
 
EASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License CodeEASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License Code
aneelaramzan63
 
Revolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptxRevolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptx
nidhisingh691197
 
F-Secure Freedome VPN 2025 Crack Plus Activation New Version
F-Secure Freedome VPN 2025 Crack Plus Activation  New VersionF-Secure Freedome VPN 2025 Crack Plus Activation  New Version
F-Secure Freedome VPN 2025 Crack Plus Activation New Version
saimabibi60507
 
Download Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With LatestDownload Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With Latest
tahirabibi60507
 
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& ConsiderationsDesigning AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Dinusha Kumarasiri
 
How to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud PerformanceHow to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud Performance
ThousandEyes
 
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Andre Hora
 
Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025
mu394968
 
Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...
Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...
Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...
Ranjan Baisak
 
Landscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature ReviewLandscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature Review
Hironori Washizaki
 
Automation Techniques in RPA - UiPath Certificate
Automation Techniques in RPA - UiPath CertificateAutomation Techniques in RPA - UiPath Certificate
Automation Techniques in RPA - UiPath Certificate
VICTOR MAESTRE RAMIREZ
 
Get & Download Wondershare Filmora Crack Latest [2025]
Get & Download Wondershare Filmora Crack Latest [2025]Get & Download Wondershare Filmora Crack Latest [2025]
Get & Download Wondershare Filmora Crack Latest [2025]
saniaaftab72555
 
How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?
How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?
How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?
steaveroggers
 
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Orangescrum
 
TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...
TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...
TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...
Andre Hora
 
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AIScaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
danshalev
 
Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...
Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...
Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...
Lionel Briand
 
Who Watches the Watchmen (SciFiDevCon 2025)
Who Watches the Watchmen (SciFiDevCon 2025)Who Watches the Watchmen (SciFiDevCon 2025)
Who Watches the Watchmen (SciFiDevCon 2025)
Allon Mureinik
 
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
ssuserb14185
 
Expand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchangeExpand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchange
Fexle Services Pvt. Ltd.
 
EASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License CodeEASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License Code
aneelaramzan63
 
Revolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptxRevolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptx
nidhisingh691197
 
F-Secure Freedome VPN 2025 Crack Plus Activation New Version
F-Secure Freedome VPN 2025 Crack Plus Activation  New VersionF-Secure Freedome VPN 2025 Crack Plus Activation  New Version
F-Secure Freedome VPN 2025 Crack Plus Activation New Version
saimabibi60507
 
Download Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With LatestDownload Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With Latest
tahirabibi60507
 
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& ConsiderationsDesigning AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Dinusha Kumarasiri
 
How to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud PerformanceHow to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud Performance
ThousandEyes
 
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Andre Hora
 
Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025
mu394968
 
Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...
Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...
Proactive Vulnerability Detection in Source Code Using Graph Neural Networks:...
Ranjan Baisak
 
Landscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature ReviewLandscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature Review
Hironori Washizaki
 
Automation Techniques in RPA - UiPath Certificate
Automation Techniques in RPA - UiPath CertificateAutomation Techniques in RPA - UiPath Certificate
Automation Techniques in RPA - UiPath Certificate
VICTOR MAESTRE RAMIREZ
 
Get & Download Wondershare Filmora Crack Latest [2025]
Get & Download Wondershare Filmora Crack Latest [2025]Get & Download Wondershare Filmora Crack Latest [2025]
Get & Download Wondershare Filmora Crack Latest [2025]
saniaaftab72555
 
How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?
How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?
How to Batch Export Lotus Notes NSF Emails to Outlook PST Easily?
steaveroggers
 
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Orangescrum
 
TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...
TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...
TestMigrationsInPy: A Dataset of Test Migrations from Unittest to Pytest (MSR...
Andre Hora
 
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AIScaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
danshalev
 
Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...
Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...
Requirements in Engineering AI- Enabled Systems: Open Problems and Safe AI Sy...
Lionel Briand
 

Secret Management with Hashicorp Vault and Consul on Kubernetes

  • 1. 1 Secret Management with Hashicorp Vault and Consul on Kubernetes
  • 2. 2 Agenda  What’s a secret?  Secret management  Hashicorp Vault  Deployment topology  Demo  Q&A
  • 3. 3 What is a secret?  Anything is sensitive information • Database user, password • API keys • SSL keys • Encryption keys • Cloud credentials • Certificates • etc..
  • 4. 4 Why secret management matters  Moving fast of software development process and infrastructure  Micro-services based architecture: service to service communication via tokens, API keys, certificates  DevOps processes: multiple environments for development, testing, integration, and production  Cloud native application and multi-cloud infrastructure: secrets for storage, compute, analytics, logging, etc..
  • 5. 5 Traditional secret management (anti-patterns)  Storing secrets: • Hard-coding • Clear text config files • SCM (git, svn) • Unencrypted file system (laptop, NFS)  Distributed secrets: • Email • Slack • Shared folder
  • 6. 6 Modern secret management  Modern secret management properties: • Secrets are encrypted at rest • Centrally managed • Access control to secrets • Auditable • Scalable • Easy to integrate • High automation for creating, revoking, rotating secrets • Supported
  • 7. 7 Hashicorp Vault  Modern secret management application  Secure secret storage (in-memory, Consul, file, and more)  Programmatic application access (automated)  Operator access (manual)  Leasing, renewal, revocation  Dynamic secrets  Rich ALCs  Multiple client authentication methods  Auditing
  • 8. 8 Vault Features  Secure secret storage: • Data is encrypted in transit and at rest • TLS for clients • No HSM required • Support many storages: in-memory, Filesystem, Consul, DynamoDB, Etcd, MySQL, PostgreSQL, S3, Zookeeper, etc..
  • 9. 9 Vault Features (cont.)  Leasing, renewal, and revocation: • Every secret has a lease • Secrets are revoked at the end of the lease unless renewed • Secret may be revoked early by operators  Auditing: • Pluggable audit backends • Request and response logging • Secrets hashed in audit log
  • 10. 10 Vault Features (cont.)  Dynamic credentials: • On-the-fly created credentials for each instance of an application or user • Usually short to medium TTL • Pluggable backends o Supported databases: MySQL, MariaDB, PostgreSQL, MSSQL, Oracle, MongoDB, Cassandra, Influxdb, etc... o Cloud: AWS, Google Cloud, Azure o SSH: one time password
  • 11. 11 Vault Features (cont.) How does dynamic credential work?
  • 12. 12 Vault Features (cont.)  Support multiple auth backends • Token • LDAP • Username & password • AppRole • AWS • Google Cloud • Kubernetes • …
  • 13. 13 Vault Features (cont.)  Support multiple auth backends • Token • LDAP • Username & password • AppRole • AWS • Google Cloud • Kubernetes • …
  • 14. 14 Vault Enterprise Features Feature Open source Pro Premium Control Groups X Multi-factor Authentication X Read Replicas (performance standby) X Disaster Recovery (DR replication) X X Replication (performance replication) X Replication Filters X Namespace X X Auto unseal (AWS, Google cloud, Azure) X X X
  • 15. 15 Vault Enterprise Features (cont.) Performance standby node  Handle GET requests of key/value secrets and other requests that do not change underlying storage
  • 16. 16 Vault Enterprise Features (cont.) Disaster recovery replication (DR replication)  Replicated content, consistent across Vault clusters • Secret configurations • Access control policies • Authentication methods • Audit configuration • Tokens • Leases
  • 17. 17 Vault Enterprise Features (cont.) Performance replication  Allowing Vault to scale relatively horizontally rather than vertically  Secondaries keep track of their own tokens and leases  If there is a request that modifiese underlying shared state, the secondary forwards the request to the primary to be handled; this is transparent to the client
  • 18. 18 Vault Enterprise Features (cont.) Performance replication vs DR replication Capability DR Performance Mirrors the configuration of a primary cluster Yes Yes Mirrors the configuration of a primary cluster’s backends (i.e.: auth methods, secrets engines, audit devices, etc.) Yes Yes Mirrors the tokens and leases for applications and users interacting with the primary cluster Yes No Allows the secondary cluster to handle client requests No Yes
  • 20. 20 Understanding Seal and Unseal  Seal state: • When a Vault server first boots • When a Vault server is started • Vault servers do not know how to decrypt data  Unsealing is a process of constructing the master key (which is constructed by Shamir’s secret sharing algorithms) to read decryption key to decrypt data  Unsealed state is remained until one of two thing below happens: • It is resealed via API • The server is restarted
  • 21. 21 Deploy Vault on Kubernetes  Consul cluster is to serve as the storage backend for Vault since it supports HA mode  Only active pod replies to requests. Standby pods will redirect requests to the active one  Leader election is done in storage backend  Refer here for details
  • 22. 22 Demo  Scenario 1: Legacy applications that don’t run on Kubernetes  Scenario 2: Legacy applications that run on Kubernetes  Scenario 3: New applications that use static credentials  Scenario 4: New applications that use dynamic credentials
  • 23. 23 Scenario 1: Legacy applications that don’t run on k8s
  • 24. 24 Scenario 1: Legacy applications that don’t run on k8s
  • 25. 25 Scenario 1: Legacy applications that don’t run on k8s 1. Jenkins master triggers a new build 2. Jenkins slave pulls source code from SCM, does necessary steps to build software packages and push to Artifactory if needed 3. The slave authenticates to Vault and gets required secrets that need for deployment steps 4. Deployment server gets software packages from Jenkins master or Artifactory and secrets. Doing necessary steps to deploy application
  • 26. 26 Scenario 2: Legacy applications that run on Kubernetes
  • 27. 27 Scenario 3: New applications that use static credentials
  • 28. 28 Scenario 4: New applications that use dynamic creds

Editor's Notes

  • #8: Audit: who requested secrets for which system at what points of time
  • #11: Dynamic passwords provide a bunch of benefits: - No need to write down, store, or share passwords - Enables very short lived passwords, less exposure if compromised - For distributed applications, every instance gets unique credentials - Constantly changing and expiring usernames/passwords are much harder to brute force - Automatic password rotation/expiration - Better audit trail
  • #12: 1. Provide Vault credentials for an user that has permissions to create users or tokens in a remote system (e.g. database) 2. Configure Vault with setting on how to create credentials 3. Configure Vault with setting on how to invalid credentials in the remote system
  • #15: https://www.hashicorp.com/products/vault/enterprise
  • #17: https://www.vaultproject.io/docs/enterprise/replication/ https://learn.hashicorp.com/vault/day-one/ops-disaster-recovery
  • #18: https://learn.hashicorp.com/vault/day-one/ops-replication
  • #21: https://www.vaultproject.io/docs/concepts/seal.html
  • #22: https://github.com/nthienan/vault-consul-k8s
  • #25: AppRole is a secure introduction method to establish machine identity. In AppRole, in order for the application to get a token, it would need to login using a Role ID (which is static, and associated with a policy), and a Secret ID (which is dynamic, one time use, and can only be requested by a previously authenticated user/system.