< Back

New-OTSSecret

Sat Jan 18, 2020 6:07 pm

NAME New-OTSSecret



SYNOPSIS

Generate a short, unique secret. This is useful for temporary passwords, one-time pads, salts, etc.





SYNTAX

New-OTSSecret [[-Passphrase] <String>] [[-Ttl] <String>] [[-Recipient] <String>] [-WhatIf] [-Confirm]

[<CommonParameters>]





DESCRIPTION

Generate a short, unique secret. This is useful for temporary passwords, one-time pads, salts, etc.





PARAMETERS

-Passphrase <String>

A string that the recipient must know to view the secret. This value is also used to encrypt the secret and is

bcrypted before being stored so we only have this value in transit.



Required? false

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Ttl <String>

The maximum amount of time, in seconds, that the secret should survive (i.e. time-to-live). Once this time

expires, the secret will be deleted and not recoverable.



Required? false

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Recipient <String>

An email address. We will send a friendly email containing the secret link (NOT the secret itself).



Required? false

Position? 5

Default value

Accept pipeline input? false

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Confirm [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

System.String





OUTPUTS

System.Management.Automation.PSObject





-------------------------- EXAMPLE 1 --------------------------



PS C:\\>New-OTSSecret -Passphrase 1234 -Recipient user@mail.com













-------------------------- EXAMPLE 2 --------------------------



PS C:\\>New-OTSSecret -Passphrase 1234 -Ttl 90000 -MetadataTtl 90000 -SecretTtil 90000 -Recipient user@mail.com















RELATED LINKS