pub fn create_multi_party_token(
subject: String,
resource: String,
operation: String,
key: KeyPair,
multi_party_nodes: &Vec<ServiceNode>,
) -> Result<String, Box<dyn Error>>Expand description
Creates a new multi-party biscuit token with default time configuration.
This function creates a token that grants access to the specified resource for the given subject, includes attestations for each multi-party node, and uses the default time configuration (5 minutes).
The key difference between a multi-party biscuit and a service chain biscuit is that a multi-party biscuit is not valid until it has been attested by all the parties.
§Arguments
subject- The subject (user) identifierresource- The resource identifier to grant access tooperation- The operation to grant access tokey- The key pair used to sign the tokenmulti_party_nodes- Vector of multi-party nodes that will attest to the token
§Returns
Ok(String)- The base64-encoded token if successfulErr(Box<dyn Error>)- If token creation fails