Skip to main content

ssh-sse-gateway

Provide authorized SSH access through an HTTPS endpoint. Run the gateway on a host that can reach your approved SSH destinations.

Install

Requires Python 3.12 or newer and OpenSSH's ssh-keygen.

With uv:

uv tool install --python 3.12 ssh-over-sse-gateway

Or with pip:

pip install 'ssh-over-sse[gateway]'

Use ssh-over-sse[all] with pip to install the client command too.

Configure

Save your configuration as ~/.config/ssh-over-sse/gateway.yaml. Use your public HTTPS root URL and allow each SSH destination and login username:

server:
  audience: https://gateway.example.com
  listen: 0.0.0.0:7010
  ingress_network_restricted: true
targets:
  - host: 192.0.2.20
    ports: [22]
    ssh_users: [alice]

Replace the example values and restrict the file to its owner. Limit backend access to your trusted network before setting ingress_network_restricted: true; this setting acknowledges your network restrictions and does not create them.

The default listener is 127.0.0.1:7010. With OCI providing HTTPS, the gateway runs plain HTTP on port 7010 and needs no backend certificate. The example above accepts ingress on all interfaces.

Authorize users

The gateway reads public keys from its account's ~/.ssh/authorized_keys by default. Set server.authorized_keys_file if the file is elsewhere.

Supported entries are unrestricted Ed25519, RSA (2048–8192 bits), and ECDSA (P-256, P-384, P-521) public keys. Entries with SSH restrictions such as from= or command= are skipped. Use only keys intended to have gateway access.

All eligible keys authenticate to the gateway account. The requested destination and SSH username must also be allowed in your configuration. The destination server separately authorizes the user's SSH login. Private user keys stay on users' computers.

Removing a key denies new access and ends its active connections. Restart the gateway after changing destination permissions; restarting ends active sessions.

Start

Validate the configuration, then start:

ssh-sse-gateway --check-config
ssh-sse-gateway

To use another configuration file:

ssh-sse-gateway --config /path/to/gateway.yaml --check-config
ssh-sse-gateway --config /path/to/gateway.yaml

Configure HTTPS ingress to forward requests to the gateway. It must pass authorization headers and support streaming without buffering or compression. The root URL shows a landing page in a browser. Users pass that same root URL to ssh-sse-cli.

For direct HTTPS without an ingress, set server.tls_mode: direct and provide --tls-cert /path/to/cert.pem and --tls-key /path/to/key.pem when starting. Restrict the server's private certificate key to its owner.

Check access

From a user's computer:

ssh-sse-cli --url https://gateway.example.com -i ~/.ssh/id_ecdsa check

Success confirms gateway key access. Users still need destination permission and an authorized SSH login. A landing page alone does not confirm SSH access.

Troubleshooting

If startup fails, run --check-config and check required values, file ownership, and permissions. If users cannot connect, check the HTTPS route, public-key access, destination permissions, and network reachability.

ssh-sse-gateway --help

Metadata

Release files for ssh-over-sse-gateway 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for ssh-over-sse-gateway 0.1.0
File Interpreter ABI Platform Actions
ssh_over_sse_gateway-0.1.0-py3-none-any.whl Python 3 none any Details for ssh_over_sse_gateway-0.1.0-py3-none-any.whl

Release files / ssh_over_sse_gateway-0.1.0-py3-none-any.whl

Download URL ssh_over_sse_gateway-0.1.0-py3-none-any.whl
Size 19.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5aac65a5dcffe6c069b907ae48fd1cdb43f814a0555caaf6c02b528d0f816e8e
BLAKE2b-256 checksum
How to use checksums
b560569871f1fdb9fed9b19f2be65f6406b6c8ceb3c9caa1f76c8f5d941bd41c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"22.04","id":"jammy","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for ssh-over-sse-gateway 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page