# Confidential Computing v1alpha1 API - Class Challenge (1.0.0-alpha06)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [1.0.0-alpha06 (latest)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge)
- [1.0.0-alpha05](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/1.0.0-alpha05/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge)

    public sealed class Challenge : IMessage<Challenge>, IEquatable<Challenge>, IDeepCloneable<Challenge>, IBufferMessage, IMessage

Reference documentation and code samples for the Confidential Computing v1alpha1 API class Challenge.

A Challenge from the server used to guarantee freshness of attestations

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> Challenge

## Implements

[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[Challenge](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[Challenge](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[Challenge](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html)

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.ConfidentialComputing.V1Alpha1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1)

## Assembly

Google.Cloud.ConfidentialComputing.V1Alpha1.dll

## Constructors

### Challenge()

    public Challenge()

### Challenge(Challenge)

    public Challenge(Challenge other)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `other` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge` |

## Properties

### ChallengeName

    public ChallengeName ChallengeName { get; set; }

[ChallengeName](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.ChallengeName)-typed view over the [Name](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.Challenge#Google_Cloud_ConfidentialComputing_V1Alpha1_Challenge_Name) resource name property.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.ConfidentialComputing.V1Alpha1/latest/Google.Cloud.ConfidentialComputing.V1Alpha1.ChallengeName` |   |

### CreateTime

    public Timestamp CreateTime { get; set; }

Output only. The time at which this Challenge was created

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Timestamp.html` |   |

### ExpireTime

    public Timestamp ExpireTime { get; set; }

Output only. The time at which this Challenge will no longer be usable. It
is also the expiration time for any tokens generated from this Challenge.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Timestamp.html` |   |

### Name

    public string Name { get; set; }

Output only. The resource name for this Challenge in the format
`projects/*/locations/*/challenges/*`

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### Nonce

    public ByteString Nonce { get; set; }

## Output only. Random data which should be used when calling TPM2_Quote.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.ByteString.html` |   |

### Used

    public bool Used { get; set; }

Output only. Indicates if this challenge has been used to generate a token.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.boolean` |   |