百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
G

gossl

> 编程语言
开源

跨平台、易于使用的 SSL/TLS 工具集

188 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

跨平台、易于使用的 SSL/TLS 工具集

Gopher design by Tugay BALCI

GoSSL

GoSSL is a cross platform, easy to use SSL/TLS toolset written with Go and built with ❤️

Features

  • Generate RSA private and public key - key command
  • Generate x509 RSA Certificate Request (CSR) - cert command
  • Generate x509 RSA Root CA - cert command
  • Generate x509 RSA Certificate - cert command
  • Get information about an x509 RSA Certificate - info command
  • Verify a Certificate with a Root CA - verify command
  • Verify a URL with a Root CA - verify command
  • Generate SSH key pair - ssh command
  • Copy SSH public key to remote SSH server - ssh-copy command

Install

Executable binaries can be downloaded at Releases page according to user's operating system and architecture. After download, extract compressed files and start using GoSSL via terminal.

MacOS Homebrew Install

MacOS users can install GoSSL via Homebrew with the commands below.

bash
brew tap yakuter/homebrew-tap
brew install gossl

Commands

version

version command displays the current version of GoSSL

bash
gossl -v
gossl --version

help

help command displays default help and existing commands. It can also be used to get sub command helps.

bash
gossl help
gossl help cert
...

key

key command generates RSA private key with provided bit size.

bash
gossl key --help
gossl key --bits 2048
gossl key --bits 2048 --out private.key
gossl key --bits 2048 --out private.key --withpub

info

info displays information about x509 certificate. Thanks grantae for great certinfo tool which is used here. A file path or a valid URL is used to get details of the certificate.

bash
gossl info cert.pem
gossl info --url google.com

cert

cert command generates x509 SSL/TLS Certificate Request (CSR), Root CA and Certificate with provided private key.

Help

bash
gossl cert --help

Generate Certificate Request (CSR)

bash
gossl cert \
    --key private.key \
    --out cert.csr \
    --days 365 \
    --serial 12345 \
    --isCSR

Generate Root CA

bash
gossl cert \
    --key private.key \
    --out ca.pem \
    --days 365 \
    --serial 12345 \
    --isCA 

Generate Certificate

bash
gossl cert \
    --key private.key \
    --out cert.pem \
    --days 365 \
    --serial 12345

verify

verify command verifies x509 certificate with provided root CA in PEM format.

bash
gossl verify --help

// Verify certificate with root CA 
gossl verify --cafile ./testdata/ca-cert.pem --certfile ./testdata/server-cert.pem
gossl verify --cafile ./testdata/ca-cert.pem --certfile ./testdata/server-cert.pem --dns 127.0.0.1

// Verify URL with root CA
gossl verify --cafile testdata/ca-cert.pem --url https://127.0.0.1

ssh

ssh command generates SSH key pair with provided bit size just like ssh-keygen tool. These key pairs are used for automating logins, single sign-on, and for authenticating hosts.

bash
gossl key --help
gossl key --bits 2048
gossl key --bits 2048 --out ./id_rsa
// output will be written to ./id_rsa and ./id_rsa_pub files

ssh-copy

ssh-copy connects remote SSH server, creates /home/user/.ssh directory and authorized_keys file in it and appends provided public key (eg, id_rsa.pub) to authorized_keys file just like ssh-copy-id tool.

bash
gossl ssh-copy --help

// This command will use default SSH public key path as "USER_HOME_DIR/.ssh/id_rsa.pub"
gossl ssh-copy remoteUser@remoteIP

// This command will ask for password to connect SSH server
gossl ssh-copy --pubkey /home/user/.ssh/id_rsa.pub remoteUser@remoteIP

gossl ssh-copy --pubkey /home/user/.ssh/id_rsa.pub --password passw@rd123 remoteUser@remoteIP

TODO

  1. Add generate command for generating private key, root ca and x509 certificates in one command
  2. Add cert template format read from yaml file
  3. Add certificate converter command like DER to PEM etc.

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Gocertificategogolangssh-copy-id

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言