Gcr.SecretExchange.prototype.get_secret
function get_secret(): [return_value: Array(String), secret_len: Number(gsize)] { // Gjs wrapper for gcr_secret_exchange_get_secret() }
Returns the last secret received. If no secret has yet been received this will return null. The string is owned by the Gcr.SecretExchange object and will be valid until the next time that Gcr.SecretExchange.prototype.receive is called on this object, or the object is destroyed.
Depending on the secret passed into the other side of the secret exchange, the result may be a binary string. It does however have a null terminator, so if you're certain that it is does not contain arbitrary binary data, it can be used as a string.
- return_value
the last secret received
- secret_len
optionally, a location to store the length of returned secret