this Idea is to MASK a Passphrase Filed and encode / Decode a password
a. User enters a PassPhrase
b. I use Formula to Convert the "Passphrase" into a Masked Random Charter and Update in filed "maskedPassphrase"
achieved using this:
maskedPassphrase=string\upperCase(
string\concatenate(
string\substring(passphrase, 0, number\randomInt(1, 3)),
string\substring("##########", -3, number\randomInt(2, 10)),
string\substring(passphrase, -3, number\randomInt(2, 4)),
string\substring(password\generate(), -3, number\randomInt(2, 6)),"X",
string\substring("##########", -3, number\randomInt(2, 10))));
c. Convert the Passphrase to a Encoded String and Store ina Field "EncodedPassword "
Tried using this:
$EncodedPassword=password\hash(passphrase);
d. When ever requried, I want to Decode the Field "EncodedPassword " back to Filed "Passphrase"
Tried using this:
util\base64Decode($EncodedPassword));
got ERROR :
Function util\base64Encode; Bad argument type on position 1, must be string.
Request you to guide me to achieve
a. Mask a Passphrase
b. Encrypt a Password
c. Decrypt when requried
a. User enters a PassPhrase
b. I use Formula to Convert the "Passphrase" into a Masked Random Charter and Update in filed "maskedPassphrase"
achieved using this:
maskedPassphrase=string\upperCase(
string\concatenate(
string\substring(passphrase, 0, number\randomInt(1, 3)),
string\substring("##########", -3, number\randomInt(2, 10)),
string\substring(passphrase, -3, number\randomInt(2, 4)),
string\substring(password\generate(), -3, number\randomInt(2, 6)),"X",
string\substring("##########", -3, number\randomInt(2, 10))));
c. Convert the Passphrase to a Encoded String and Store ina Field "EncodedPassword "
Tried using this:
$EncodedPassword=password\hash(passphrase);
d. When ever requried, I want to Decode the Field "EncodedPassword " back to Filed "Passphrase"
Tried using this:
util\base64Decode($EncodedPassword));
got ERROR :
Function util\base64Encode; Bad argument type on position 1, must be string.
Request you to guide me to achieve
a. Mask a Passphrase
b. Encrypt a Password
c. Decrypt when requried
Comment