module Auth::Block

Overview

TODO Write documentation for Auth::Block

Included Modules

Defined in:

auth-block.cr

Constant Summary

VERSION = "0.1.0"

Constructors

Class Method Summary

Constructor Detail

def self.new(pull : MessagePack::Unpacker) #

[View source]

Class Method Detail

def self.compute_stretched_ikey(iKey) #

STEP 2 :: Stretch the key to 32 chars using scrypt IMPORTANT -- need to verify that these are correct parameters


[View source]
def self.generate_iKey #

STEP 1 :: Generate a random string 17 chars in length to use as the invitation key


[View source]
def self.generate_invitation_id(s_iKey, msg) #

STEP 3 :: Generate Invitation ID


[View source]
def self.generate_keys(seed) #

STEP 4B - Generate a signing key from the seed, and a verify key from the signing key


[View source]
def self.generate_seed(s_iKey, msg) #

STEP 4A Generate a 32-byte random seed using the s_iKey and a message


[View source]
def self.sign_message(signing_key, msg) #

STEP 5 :: Sign the invitation ID with the signing key


[View source]
def self.verify_signature(verify_key, signature, msg) #

Check the validity of a signature (for proof of concept)


[View source]