vere/pkg/urcrypt
2023-01-09 13:46:53 -05:00
..
argon2 Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
ge-additions Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
.gitignore build: gitignore urcrypt build results 2021-08-19 20:31:13 -04:00
aes_cbc.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
aes_ecb.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
aes_siv.c Build with bazel on darwin-arm64 (#13) 2023-01-09 13:46:53 -05:00
argon.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
BUILD.bazel Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
ed25519.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
ge_additions.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
keccak.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
README.md Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
ripemd.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
scrypt.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
secp256k1.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
sha.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
urcrypt.h Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
util.c Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00
util.h Build with bazel on linux-x86_64 (#10) 2023-01-09 13:46:48 -05:00

What is urcrypt?

urcrypt is a library of cryptography routines used by urbit jets.

Why is urcrypt?

Urbit's C runtime (long the only urbit runtime) has accumulated a collection of cryptography dependencies, some with custom additions or patches. These libraries have different conventions and have been managed by u3 in an ad-hoc manner. Reproducing that arrangement in other runtimes is tricky and error-prone. The (sometimes inconsistent) logic must be reproduced and suitable cryptography primitives must be found (or worse, written) for the new environment.

To ease these burdens, urcrypt isolates the quirks behind a consistent calling convention. Everything is a little-endian byte array, and each jetted operation has a corresponding function in the library. Jets simply unpack their nouns, call urcrypt, and pack the results.

What is a cryptography routine?

This is more of a subjective question than it might appear. Any of the following conditions are sufficient, but not necessary, for a function to be included in urcrypt:

  • The routine is sensitive to side-channel attacks (encryption, etc)
  • Some property of the routine is cryptographically useful (SHA, RIPE, etc)
  • The routine typically lives in a crypto library, for whatever reason.

A word on OpenSSL

It is the library user's responsibility to initialize openssl, set custom memory functions, etc.