Skip to content

Instantly share code, notes, and snippets.

@vikramacharya
Created September 10, 2022 15:17
Show Gist options
  • Select an option

  • Save vikramacharya/bfb6cfe42061f8596b8cdec0e5d3296e to your computer and use it in GitHub Desktop.

Select an option

Save vikramacharya/bfb6cfe42061f8596b8cdec0e5d3296e to your computer and use it in GitHub Desktop.

Revisions

  1. vikramacharya created this gist Sep 10, 2022.
    2 changes: 2 additions & 0 deletions sign_payload.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,2 @@
    const signedMessage = sodium.crypto_sign_detached(signing_string, sodium.from_base64(privateKey, base64_variants.ORIGINAL));
    const signedMessage_ = sodium.to_base64(signedMessage, base64_variants.ORIGINAL);