Constructor

SnapdAuthDatanew

since: 1.0

Declaration [src]

SnapdAuthData*
snapd_auth_data_new (
  const gchar* macaroon,
  GStrv discharges
)

Description [src]

Create some authorization data.

Available since: 1.0

Parameters

macaroon

Type: const gchar*

Serialized macaroon used to authorize access to snapd.

The data is owned by the caller of the function.
The value is a NUL terminated UTF-8 string.
discharges

Type: An array of utf8

Serialized discharges.

The array must be NULL-terminated.
Each element is a NUL terminated UTF-8 string.

Return value

Type: SnapdAuthData

A new SnapdAuthData.

The caller of the function takes ownership of the data, and is responsible for freeing it.