πDouble Protect your assets using with Pirichain Authenticator Factor
//####PIRICHAIN Smart Scenario v.1.0########
// PiriChain Smart Scenario Code Blocks Area
// All Functions must be return promise non-blocking async block or await prefix delimitier..
async function getMyToken()
{
return await Tools.getMyAuthenticatorToken();
// this code will only give secret code 30 minutes after creation the secret token for each user.
}
async function authenticatorTokenGenerate()
{
// Users can generate and system will distribute the secret token in safe
// to all of nodes.
return await Tools.generateAuthenticator();
}
async function init(token)
{
// If user is able to give the correct token then system will send 1 PIRI.
const result=await Tools.verifyAuthenticator(token);
if (result)
return await Transaction.sendPIRI(EXECUTER_ADDRESS,1);
else
return {error:1,message:'NO! Your token is not correct!'};
}PreviousAsset Management Of Share Holders using with PSceNextWhat an easy to build up your metaverse planet in Pirichain!
Last updated