SecretNET.Token Namespace

Snip20Tx..::..CreateViewingKey Method (MsgCreateViewingKey, Nullable<(Of <(<'TxOptions>)>)>)

This function generates a new viewing key for the Cosmos message sender, which is used in ALL account specific queries. This key is used to validate the identity of the caller, since in queries in Cosmos there is no way to cryptographically authenticate the querier's identity. The Viewing Key MUST be stored in such a way that lookup takes a significant amount to time to perform, in order to be resistant to brute-force attacks. The viewing key MUST NOT control any functions which actively affect the balance of the user. The entropy field of the request should be a client supplied string used for entropy for generation of the viewing key.Secure implementation is left to the client, but it is recommended to use base-64 encoded random bytes and not predictable inputs.

Namespace:  SecretNET.Token
Assembly:  SecretNET.Token (in SecretNET.Token.dll)

Syntax


public Task<SingleSecretTx<CreateViewingKeyResponse>> CreateViewingKey(
	MsgCreateViewingKey msg,
	Nullable<TxOptions> txOptions
)
Public Function CreateViewingKey ( _
	msg As MsgCreateViewingKey, _
	txOptions As Nullable(Of TxOptions) _
) As Task(Of SingleSecretTx(Of CreateViewingKeyResponse))
public:
Task<SingleSecretTx<CreateViewingKeyResponse^>^>^ CreateViewingKey(
	MsgCreateViewingKey^ msg, 
	Nullable<TxOptions^> txOptions
)

Parameters

msg
Type: SecretNET.Token..::..MsgCreateViewingKey
txOptions
Type: Nullable<(Of <(<'TxOptions>)>)>

Return Value