Skip to content

Expose the ed25519 API#61

Open
hanssv wants to merge 11 commits intojlouis:masterfrom
aeternity:add_ed25519_api
Open

Expose the ed25519 API#61
hanssv wants to merge 11 commits intojlouis:masterfrom
aeternity:add_ed25519_api

Conversation

@hanssv
Copy link
Contributor

@hanssv hanssv commented Oct 1, 2021

This adds a low-level APIs to perform computations over the edwards25519
curve, only useful to implement custom constructions.

Exposed functions:
crypto_ed25519_scalarmult/2,
crypto_ed25519_scalarmult_base/1,
crypto_ed25519_scalarmult_noclamp/2,
crypto_ed25519_scalarmult_base_noclamp/1,
crypto_ed25519_add/2,
crypto_ed25519_sub/2,
crypto_ed25519_is_valid_point/1,
crypto_ed25519_scalar_reduce/1,
crypto_ed25519_scalar_negate/1,
crypto_ed25519_scalar_add/2,
crypto_ed25519_scalar_sub/2,
crypto_ed25519_scalar_mul/2

Bryan Paxton and others added 4 commits January 6, 2021 13:08
sodium_init() will return 0 on success, -1 on failure, and 1 if sodium is
already loaded and initialized (which is not an error). In the case
where libsodium is already initialized and the system is restarted we
may return 1 from onload nif function resulting in a crash.

- change the call to sodium_init() to check for an error return (-1) and
  return -1 explicitly in this case, otherwise always return zero at the
  end of our onload function.
Fix NIF-load issue on init:restart
hanssv and others added 5 commits August 19, 2022 13:23
They are just a simplification of the secretbox API, thus it does
not provide any new functionality. But it helps mapping function
names to libsodium documentation.
Add access to secretbox_easy/easy_open functions
* .envrc is not for git

* Fix c code - avoid warnings

* Bump Erlang versions in Github workflows
This adds a low-level APIs to perform computations over the edwards25519
curve, only useful to implement custom constructions.

Exposed functions:
  crypto_ed25519_scalarmult/2,
  crypto_ed25519_scalarmult_base/1,
  crypto_ed25519_scalarmult_noclamp/2,
  crypto_ed25519_scalarmult_base_noclamp/1,
  crypto_ed25519_add/2,
  crypto_ed25519_sub/2,
  crypto_ed25519_is_valid_point/1,
  crypto_ed25519_scalar_reduce/1,
  crypto_ed25519_scalar_negate/1,
  crypto_ed25519_scalar_add/2,
  crypto_ed25519_scalar_sub/2,
  crypto_ed25519_scalar_mul/2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants