Skip to content

Instantly share code, notes, and snippets.

View portnoy's full-sized avatar

Eugene Portnoy portnoy

View GitHub Profile
@kawsark
kawsark / Vault-ssh-ca-README.md
Created March 28, 2019 16:12
A guide for configuring Vault's SSH-CA

SSH CA use-case with Vault

In this scenario we are going to set up Vault to sign SSH keys using an internal CA. We will configure the SSH secrets engine and create a CA within Vault. We will then configure an SSH server to trust the CA key we just created. Finally we will attempt to SSH using a private key, and a public key signed by Vault SSH CA.

Prerequisites

  • This guide assumes you have already provisioned a Vault server, SSH host using OpenSSH server, and a SSH client machine.
  • The client system must be able to reach the Vault server and the OpenSSH server.
  • We will refer to these systems respectively as:
  • VAULT_SERVER
@benjamingeiger
benjamingeiger / gist:3627064
Created September 4, 2012 21:52
Cartesian product of lists in Python.
def cartesian (lists):
if lists == []: return [()]
return [x + (y,) for x in cartesian(lists[:-1]) for y in lists[-1]]
print cartesian([[1, 2, 3], [2, 4, 6], [3, 6, 9]])