Skip to content

Instantly share code, notes, and snippets.

View NHAS's full-sized avatar

NHAS

View GitHub Profile
@NHAS
NHAS / LICENSE
Created February 20, 2024 20:23 — forked from shaneutt/LICENSE
Golang: Demonstrate creating a CA Certificate, and Creating and Signing Certs with the CA
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
@NHAS
NHAS / cert.go
Last active February 27, 2022 08:44
Golang generate SSH certificate
package main
import (
"crypto/ed25519"
"crypto/rand"
"crypto/x509"
"encoding/base64"
"encoding/pem"
"fmt"
"log"
@NHAS
NHAS / sshKeygen.go
Last active May 2, 2023 12:47
Generate SSH private key (Ed25519)
package main
import (
"crypto/ed25519"
"crypto/rand"
"crypto/x509"
"encoding/pem"
"golang.org/x/crypto/ssh"
)