authen
.public
Tables
(current)
Columns
Constraints
Relationships
Orphan Tables
Anomalies
Routines
fn_gen_password_reset_token
Parameters
Name
Type
Mode
grant_type
text
IN
user_id
integer
IN
prop_ids
int4[]
IN
Definition
declare reset_data json; begin reset_data := json_build_object( 'grant_type', grant_type, 'user_id', user_id, 'properties', prop_ids, 'expire', NOW() + INTERVAL '24 hours' ); raise notice 'Key: %', sys.get_secret(grant_type); raise notice 'Reset data: %', reset_data::text; return sys.encrypt_text(reset_data::text, sys.get_secret(grant_type)); end