SSH protocol implementation in Ada
  • Ada 62.4%
  • C++ 36%
  • C 1.5%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-11-24 04:30:34 +00:00
.githooks fix pre-commit hook 2026-06-08 23:35:24 +08:00
backends transport: fix AES-CTR keystream and length decryption 2026-11-18 20:35:57 +08:00
doc doc: record stage 5 completion 2026-11-21 13:45:00 +08:00
examples transport: fix framing boundaries and dropped-packet sequencing 2026-11-18 23:37:18 +08:00
src client: add non-blocking version exchange helper 2026-11-21 11:15:11 +08:00
tests test: cover non-blocking version exchange 2026-11-21 11:15:22 +08:00
util add util/check_ascii.py 2026-06-06 11:25:20 +08:00
.gitignore add AGENTS.md 2026-05-23 17:39:11 +08:00
.gitmodules add docs 2026-05-23 18:13:54 +08:00
AGENTS.md update AGENTS.md 2026-06-13 22:50:56 +08:00
alire.toml alire.toml: change website to code.wehack.space 2026-08-07 18:08:16 +08:00
LICENSE use Apache 2.0 license 2026-07-11 10:26:22 +08:00
README.md update README and alire.toml 2026-07-15 11:03:34 +08:00
run_tests.sh client: add non-blocking RX accumulator 2026-11-19 20:15:56 +08:00
ssh_protocol.gpr client: add non-blocking RX accumulator 2026-11-19 20:15:56 +08:00

ssh_protocol-ada

SSH protocol implementation in Ada. It's a core library without I/O, cryptography, or RNG.

Backends

To use this library in an SSH application, developers need to use a cryptography backend to provide cryptography primitives and RNG support.

This project has implemented two backends:

  • libsodium: use libsodium to provide Curve25519 KEX, Ed25519 signing and Chacha20-Poly1305 AEAD cipher, which is compatible to most SSH servers
  • openssh-libcrypto: use cryptography primitives from OpenSSH and OpenSSL libcrypto, which supports a safe subset of the cipher suite from OpenSSH, compatible to all the SSH servers I have seen

Examples

A client example is implemented in ssh_apps.

SPARK

The code is written in the SPARK subset. The source code can now pass the stone level.

Disclaimer

Most of the code is generated by DeepSeek V4 models.

The code in the main branch is reviewed by a human, and the code in the dev branch is not fully reviewed.

License

The core library uses Apache 2.0 license. The backends may use different licenses.