Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sdk/attestation/arm-attestation/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2020 Microsoft
Copyright (c) 2021 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
9 changes: 4 additions & 5 deletions sdk/attestation/arm-attestation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ npm install @azure/arm-attestation

### How to use

#### nodejs - Authentication, client creation and list operations as an example written in TypeScript.
#### nodejs - client creation and list operations as an example written in TypeScript.

##### Install @azure/ms-rest-nodeauth

Expand All @@ -26,11 +26,10 @@ npm install @azure/ms-rest-nodeauth@"^3.0.0"

##### Sample code

While the below sample uses the interactive login, other authentication options can be found in the [README.md file of @azure/ms-rest-nodeauth](https://www.npmjs.com/package/@azure/ms-rest-nodeauth) package
```typescript
import * as msRest from "@azure/ms-rest-js";
import * as msRestAzure from "@azure/ms-rest-azure-js";
import * as msRestNodeAuth from "@azure/ms-rest-nodeauth";
import { AttestationManagementClient, AttestationManagementModels, AttestationManagementMappers } from "@azure/arm-attestation";
const msRestNodeAuth = require("@azure/ms-rest-nodeauth");
const { AttestationManagementClient } = require("@azure/arm-attestation");
const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];

msRestNodeAuth.interactiveLogin().then((creds) => {
Expand Down
4 changes: 2 additions & 2 deletions sdk/attestation/arm-attestation/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ const config = {
"@azure/ms-rest-azure-js": "msRestAzure"
},
banner: `/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand All @@ -19,6 +18,7 @@ class AttestationManagementClient extends AttestationManagementClientContext {
// Operation groups
operations: operations.Operations;
attestationProviders: operations.AttestationProviders;
privateEndpointConnections: operations.PrivateEndpointConnections;

/**
* Initializes a new instance of the AttestationManagementClient class.
Expand All @@ -30,6 +30,7 @@ class AttestationManagementClient extends AttestationManagementClientContext {
super(credentials, subscriptionId, options);
this.operations = new operations.Operations(this);
this.attestationProviders = new operations.AttestationProviders(this);
this.privateEndpointConnections = new operations.PrivateEndpointConnections(this);
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand All @@ -17,6 +17,7 @@ export {
CloudError,
JSONWebKey,
JSONWebKeySet,
PrivateEndpointConnection,
ProxyResource,
Resource,
SystemData,
Expand Down
120 changes: 106 additions & 14 deletions sdk/attestation/arm-attestation/src/models/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down Expand Up @@ -38,7 +38,7 @@ export interface SystemData {
*/
lastModifiedByType?: CreatedByType;
/**
* The type of identity that last modified the resource.
* The timestamp of resource last modification (UTC)
*/
lastModifiedAt?: Date;
}
Expand Down Expand Up @@ -118,6 +118,17 @@ export interface Resource extends BaseResource {
readonly type?: string;
}

/**
* The Private Endpoint Connection resource.
*/
export interface PrivateEndpointConnection extends Resource {
/**
* Provisioning state of the private endpoint connection. Possible values include: 'Succeeded',
* 'Creating', 'Deleting', 'Failed'
*/
provisioningState?: PrivateEndpointConnectionProvisioningState;
}

/**
* The resource model definition for an Azure Resource Manager tracked top level resource which has
* 'tags' and a 'location'
Expand All @@ -144,7 +155,7 @@ export interface AttestationProvider extends TrackedResource {
*/
readonly systemData?: SystemData;
/**
* Trust model for the attestation service instance.
* Trust model for the attestation provider.
*/
trustModel?: string;
/**
Expand All @@ -155,6 +166,11 @@ export interface AttestationProvider extends TrackedResource {
* Gets the uri of attestation service
*/
attestUri?: string;
/**
* List of private endpoint connections associated with the attestation provider.
* **NOTE: This property will not be serialized. It can only be populated by the server.**
*/
readonly privateEndpointConnections?: PrivateEndpointConnection[];
}

/**
Expand All @@ -173,11 +189,11 @@ export interface AttestationProviderListResult {
}

/**
* Parameters for patching an attestation service instance
* Parameters for patching an attestation provider
*/
export interface AttestationServicePatchParams extends BaseResource {
/**
* The tags that will be assigned to the attestation service instance.
* The tags that will be assigned to the attestation provider.
*/
tags?: { [propertyName: string]: string };
}
Expand All @@ -193,7 +209,7 @@ export interface JSONWebKey {
* established by [JWA] or be a value that contains a Collision-
* Resistant Name.
*/
alg: string;
alg?: string;
/**
* The "crv" (curve) parameter identifies the curve type
*/
Expand Down Expand Up @@ -229,7 +245,7 @@ export interface JSONWebKey {
* equivalent alternatives by the application using them.) The "kid"
* value is a case-sensitive string.
*/
kid: string;
kid?: string;
/**
* The "kty" (key type) parameter identifies the cryptographic algorithm
* family used with the key, such as "RSA" or "EC". "kty" values should
Expand Down Expand Up @@ -260,7 +276,7 @@ export interface JSONWebKey {
* a public key is used for encrypting data or verifying the signature
* on data. Values are commonly "sig" (signature) or "enc" (encryption).
*/
use: string;
use?: string;
/**
* X coordinate for the Elliptic Curve point
*/
Expand Down Expand Up @@ -296,7 +312,7 @@ export interface JSONWebKeySet {
}

/**
* Client supplied parameters used to create a new attestation service instance.
* Client supplied parameters used to create a new attestation provider.
*/
export interface AttestationServiceCreationSpecificParams {
/**
Expand All @@ -307,19 +323,19 @@ export interface AttestationServiceCreationSpecificParams {
}

/**
* Parameters for creating an attestation service instance
* Parameters for creating an attestation provider
*/
export interface AttestationServiceCreationParams extends BaseResource {
/**
* The supported Azure location where the attestation service instance should be created.
* The supported Azure location where the attestation provider should be created.
*/
location: string;
/**
* The tags that will be assigned to the attestation service instance.
* The tags that will be assigned to the attestation provider.
*/
tags?: { [propertyName: string]: string };
/**
* Properties of the attestation service instance
* Properties of the attestation provider
*/
properties: AttestationServiceCreationSpecificParams;
}
Expand Down Expand Up @@ -351,6 +367,14 @@ export interface AttestationManagementClientOptions extends AzureServiceClientOp
baseUri?: string;
}

/**
* @interface
* List of private endpoint connection associated with the specified storage account
* @extends Array<PrivateEndpointConnection>
*/
export interface PrivateEndpointConnectionListResult extends Array<PrivateEndpointConnection> {
}

/**
* Defines values for CreatedByType.
* Possible values include: 'User', 'Application', 'ManagedIdentity', 'Key'
Expand All @@ -367,6 +391,14 @@ export type CreatedByType = 'User' | 'Application' | 'ManagedIdentity' | 'Key';
*/
export type AttestationServiceStatus = 'Ready' | 'NotReady' | 'Error';

/**
* Defines values for PrivateEndpointConnectionProvisioningState.
* Possible values include: 'Succeeded', 'Creating', 'Deleting', 'Failed'
* @readonly
* @enum {string}
*/
export type PrivateEndpointConnectionProvisioningState = 'Succeeded' | 'Creating' | 'Deleting' | 'Failed';

/**
* Contains response data for the list operation.
*/
Expand Down Expand Up @@ -526,3 +558,63 @@ export type AttestationProvidersGetDefaultByLocationResponse = AttestationProvid
parsedBody: AttestationProvider;
};
};

/**
* Contains response data for the list operation.
*/
export type PrivateEndpointConnectionsListResponse = PrivateEndpointConnectionListResult & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;

/**
* The response body as parsed JSON or XML
*/
parsedBody: PrivateEndpointConnectionListResult;
};
};

/**
* Contains response data for the get operation.
*/
export type PrivateEndpointConnectionsGetResponse = PrivateEndpointConnection & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;

/**
* The response body as parsed JSON or XML
*/
parsedBody: PrivateEndpointConnection;
};
};

/**
* Contains response data for the create operation.
*/
export type PrivateEndpointConnectionsCreateResponse = PrivateEndpointConnection & {
/**
* The underlying HTTP response.
*/
_response: msRest.HttpResponse & {
/**
* The response body as text (string format)
*/
bodyAsText: string;

/**
* The response body as parsed JSON or XML
*/
parsedBody: PrivateEndpointConnection;
};
};
Loading