Skip to content

Enterprise PKI Platform with EJBCA CE - Automated Lab Environment demonstrating modern DevOps practices, cloud-native technologies, and enterprise security standards. Features Kubernetes orchestration, Terraform infrastructure, Ansible configuration, comprehensive monitoring, and GitOps workflows.

Notifications You must be signed in to change notification settings

adrian207/EJBCA---Automated-Lab

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

24 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Enterprise PKI Platform - EJBCA CE Automated Lab

A professional-grade PKI (Public Key Infrastructure) platform demonstrating Keyfactor EJBCA Community Edition with modern DevOps practices, cloud-native technologies, and enterprise security standards.

πŸ—οΈ Architecture Overview

This platform demonstrates a production-ready PKI infrastructure with:

  • PKI Core: Keyfactor EJBCA CE (Certificate Authority)
  • Infrastructure: Terraform-managed Azure resources (AKS, Key Vault, Storage)
  • Orchestration: Kubernetes with Helm charts
  • Service Mesh: Linkerd for secure service-to-service communication
  • Ingress: NGINX Ingress Controller
  • GitOps: ArgoCD for declarative deployments
  • CI/CD: GitHub Actions with security scanning
  • Configuration Management: Ansible for OS provisioning
  • Artifact Management: Harbor Registry & JFrog Artifactory
  • Security Scanning: Trivy for vulnerability detection
  • Observability: Loki for logs, OpenTelemetry for traces
  • Cloud Integration: Azure Key Vault & Storage

πŸ“‹ Prerequisites

  • Azure subscription with appropriate permissions
  • kubectl (v1.28+)
  • Terraform (v1.6+)
  • Ansible (v2.15+)
  • Helm (v3.12+)
  • Docker (v24+)
  • Azure CLI (v2.50+)
  • Git

πŸš€ Quick Start

# 1. Clone and initialize
git clone <repository-url>
cd EJBCA---Automated-Lab

# 2. Configure Azure credentials
az login
export ARM_SUBSCRIPTION_ID="your-subscription-id"

# 3. Deploy infrastructure
cd terraform
terraform init
terraform plan -out=tfplan
terraform apply tfplan

# 4. Configure kubectl
az aks get-credentials --resource-group ejbca-platform-rg --name ejbca-aks-cluster

# 5. Deploy platform components
cd ../kubernetes
./deploy.sh

# 6. Access EJBCA
kubectl get ingress -n ejbca

πŸ“ Project Structure

.
β”œβ”€β”€ README.md                                    # This file
└── EJBCA---Automated-Lab/                      # Main project directory
    β”œβ”€β”€ docs/                                   # Comprehensive documentation
    β”‚   β”œβ”€β”€ ANALYSIS-REPORT.md
    β”‚   β”œβ”€β”€ BASTION-SETUP-GUIDE.md
    β”‚   β”œβ”€β”€ DYNAMIC-IP-SOLUTIONS.md
    β”‚   β”œβ”€β”€ SECURITY-FIXES-CHECKLIST.md
    β”‚   └── ejbca-features.md
    β”œβ”€β”€ terraform/                              # Infrastructure as Code
    β”‚   β”œβ”€β”€ main.tf
    β”‚   β”œβ”€β”€ variables.tf
    β”‚   β”œβ”€β”€ outputs.tf
    β”‚   β”œβ”€β”€ aks.tf
    β”‚   β”œβ”€β”€ networking.tf
    β”‚   β”œβ”€β”€ keyvault.tf
    β”‚   β”œβ”€β”€ storage.tf
    β”‚   └── compute.tf
    β”œβ”€β”€ ansible/                                # Configuration Management
    β”‚   β”œβ”€β”€ playbooks/
    β”‚   β”‚   β”œβ”€β”€ windows-server-2025.yml
    β”‚   β”‚   β”œβ”€β”€ rhel-latest.yml
    β”‚   β”‚   └── common-setup.yml
    β”‚   └── inventory/
    β”œβ”€β”€ kubernetes/                             # K8s Manifests
    β”‚   β”œβ”€β”€ observability/
    β”‚   β”œβ”€β”€ ingress-nginx/
    β”‚   β”œβ”€β”€ linkerd/
    β”‚   β”œβ”€β”€ harbor/
    β”‚   └── artifactory/
    β”œβ”€β”€ helm/                                   # Helm Charts
    β”‚   └── ejbca-ce/
    β”œβ”€β”€ argocd/                                 # GitOps Configurations
    β”‚   β”œβ”€β”€ applications/
    β”‚   └── projects/
    β”œβ”€β”€ .github/                                # CI/CD Pipelines
    β”‚   └── workflows/
    β”œβ”€β”€ scripts/                                # Utility Scripts
    β”‚   β”œβ”€β”€ deploy.sh
    β”‚   β”œβ”€β”€ demo-scenarios.sh
    β”‚   β”œβ”€β”€ apply-security-fixes.sh
    β”‚   └── update-my-ip.sh
    └── configs/                                # Application Configs
        └── ejbca/

🎯 EJBCA CE Features Demonstrated

1. Certificate Authority Management

  • Root CA and Sub CA hierarchy
  • Multiple certificate profiles
  • End entity profiles
  • Certificate issuance workflows

2. Protocol Support

  • ACME (Automated Certificate Management Environment)
  • EST (Enrollment over Secure Transport)
  • SCEP (Simple Certificate Enrollment Protocol)
  • CMP (Certificate Management Protocol)
  • Web Services API (SOAP/REST)

3. Certificate Lifecycle

  • Issuance and enrollment
  • Renewal and revocation
  • CRL (Certificate Revocation List) generation
  • OCSP (Online Certificate Status Protocol) responder

4. Advanced Features

  • HSM integration (Azure Key Vault)
  • Certificate transparency logging
  • Custom certificate extensions
  • Publisher for certificate distribution
  • Key recovery and archival

5. Administration

  • Role-based access control (RBAC)
  • Audit logging
  • Administrator approval workflows
  • Backup and restore procedures

πŸ”’ Security Features

  • Network Security: Linkerd mTLS between services
  • Secret Management: Azure Key Vault integration
  • Image Scanning: Trivy in CI/CD pipeline
  • Ingress Security: TLS termination with NGINX
  • RBAC: Kubernetes RBAC and EJBCA role-based access

πŸ“Š Observability

  • Logging: Loki for centralized log aggregation
  • Tracing: OpenTelemetry for distributed tracing
  • Metrics: Prometheus metrics exposure
  • Dashboards: Grafana for visualization

πŸ”„ GitOps Workflow

  1. Code changes pushed to GitHub
  2. GitHub Actions validates and tests
  3. Trivy scans for vulnerabilities
  4. Artifacts published to Harbor/Artifactory
  5. ArgoCD detects changes and syncs
  6. Kubernetes applies configurations

πŸ› οΈ Deployment Scenarios

Development

  • Single node with minimal resources
  • In-cluster databases
  • Development certificates

Staging

  • Multi-node cluster
  • External managed databases
  • Valid staging certificates

Production

  • High-availability configuration
  • Azure-managed services (Database, Key Vault)
  • Production-grade certificates
  • Disaster recovery setup

πŸ“– Documentation

πŸ‘€ Author

Adrian Johnson
πŸ“§ Email: adrian207@gmail.com
πŸ’Ό Enterprise PKI & Cloud Infrastructure Specialist

🀝 Contributing

This is a demonstration lab environment. Feel free to adapt and extend for your use case.

πŸ“ License

MIT License - See LICENSE file for details

πŸ”— References

⚠️ Important Notes

  • This is a lab/demo environment - adapt security settings for production
  • Review all default passwords and credentials before deployment
  • Ensure compliance with your organization's security policies
  • Back up CA keys and certificates securely

Status: 🚧 Active Development | Version: 1.0.0 | Last Updated: October 2025

About

Enterprise PKI Platform with EJBCA CE - Automated Lab Environment demonstrating modern DevOps practices, cloud-native technologies, and enterprise security standards. Features Kubernetes orchestration, Terraform infrastructure, Ansible configuration, comprehensive monitoring, and GitOps workflows.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published