Skip to content

Latest commit

 

History

History
32 lines (27 loc) · 926 Bytes

create-and-manage-cert.MD

File metadata and controls

32 lines (27 loc) · 926 Bytes

access granting proces

image

  1. create user cert openssl genrsa -out amit.key 2048
  2. create CSR openssl req -new -key amit.key -subj "/CN=jane" -out amit.csr
  3. encode CSR cat amit.csr |base64
# amit.yaml
apiVersion: certificates.k8s.io/v1beta1
kind: CertificateSigningRequest
metadata:
  name: amit
spec:
  groups:
  - system:authenticated
  usages:
  - digital signature
  - key encipherment
  - server auth
  request:
    <certificate-goes-here>
  1. kubectl create -f amit.yaml
  2. list the csr kubectl get csr
  3. Approve the request kubectl certificate approve amit
  4. View the certificate kubectl get csr amit -o yaml
  5. Decode it echo "<certificate>" | base64 --decode

image