Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/WillFantom/sshare
Quickly share curlable links to your SSH pub keys (from agent,github,file,raw) π
https://github.com/WillFantom/sshare
authorized-keys ssh-agent ssh-keys transfer-sh transfersh
Last synced: 3 months ago
JSON representation
Quickly share curlable links to your SSH pub keys (from agent,github,file,raw) π
- Host: GitHub
- URL: https://github.com/WillFantom/sshare
- Owner: WillFantom
- License: mit
- Created: 2022-12-11T09:45:52.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-16T12:06:41.000Z (5 months ago)
- Last Synced: 2024-01-18T00:47:04.578Z (5 months ago)
- Topics: authorized-keys, ssh-agent, ssh-keys, transfer-sh, transfersh
- Language: Go
- Homepage:
- Size: 134 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Lists
- awesome-stars - WillFantom/sshare - Quickly share curlable links to your SSH pub keys (from agent,github,file,raw) π (Go)
README
# SSHareΒ Β Β Β ![GitHub release (latest SemVer)](https://img.shields.io/github/v/tag/willfantom/sshare?display_name=tag&label=%20&sort=semver)Β Β ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/willfantom/sshare/release.yml?label=%20&logo=github)
Quickly share SSH keys from your agent as `curl`able links! Use the `sshare` TUI to easily select keys from an SSH agent and automatically generate a [`transfer.sh`](https://transfer.sh) upload that can easily be added to an authorized key file via `curl`.
---
## Install
- **Linux**
- Download the appropriate version for your system from the [GitHub release page](https://github.com/WillFantom/sshare/releases)
- Move the `sshare` binary to a directory in your `PATH`
- **MacOS**
- Download and install via Homebrew:
```
brew install willfantom/tap/sshare
```## Usage
Simply run: `sshare`
Sensible defaults are used, such as connecting to the SSH agent as defined by the `SSH_AUTH_SOCK` environment variable.
- To include keys that are not found in your agent, you can specify a file containing the public key with the `-f` flag (and can be specified multiple times):
```
sshare -f ~/.ssh/id_rsa.pub
```- An SSH agent socket path other than the one found in `SSH_AUTH_SOCK` can be provided using the `-a` flag:
```
sshare -a /tmp/ssh-XXXXXXanCbmG/agent.8
```- Add keys from a generated link to an `authorized_keys` file:
```
curl --fail-with-body >> ~/.ssh/authorized_keys
```- Uploads can be deleted by either:
- Opening the downloaded link in a browser and deleting the key using the given deletion code
- By running the `delete` command of `sshare`:
```
sshare delete
```
- Or by running:
```
curl -X DELETE /
```- Also provide your GitHub SSH keys as options for keys to share:
```
sshare -g ""
```---
```
Share your public SSH keys found in your agent via curl-able transfer.sh links.Usage:
sshare [flags]
sshare [command]Available Commands:
completion Generate the autocompletion script for the specified shell
delete Delete an uploaded authorized_keys file
help Help about any commandFlags:
-a, --agent string path to the target ssh agent socket ($SSH_AUTH_SOCK) (default "~/.1password/agent.sock")
-g, --github-token string github token with permission to read ssh keys
-h, --help help for sshare
-k, --key stringArray additional keys to include in the generated authorized_keys
-f, --key-file stringArray additional key file(s) to include in the generated authorized_keys
-d, --max-days int number of days that the content will remain available via transfer.sh (default 2)
-m, --max-downloads int maximum number of times any content shared can be downloaded (default 10)
-p, --passphrase string passphrase for the ssh agentUse "sshare [command] --help" for more information about a command.
```