Skip to content
This repository was archived by the owner on May 5, 2023. It is now read-only.
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
42 changes: 21 additions & 21 deletions lib/services/postgresqlManagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
The MIT License (MIT)

Copyright (c) 2018 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
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
The MIT License (MIT)
Copyright (c) 2018 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
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
33 changes: 33 additions & 0 deletions lib/services/postgresqlManagement/lib/models/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -493,6 +493,39 @@ export interface NameAvailability {
reason?: string;
}

/**
* @class
* Initializes a new instance of the ServerSecurityAlertPolicy class.
* @constructor
* A server security alert policy.
*
* @member {string} state Specifies the state of the policy, whether it is
* enabled or disabled. Possible values include: 'Enabled', 'Disabled'
* @member {array} [disabledAlerts] Specifies an array of alerts that are
* disabled. Allowed values are: Sql_Injection, Sql_Injection_Vulnerability,
* Access_Anomaly
* @member {array} [emailAddresses] Specifies an array of e-mail addresses to
* which the alert is sent.
* @member {boolean} [emailAccountAdmins] Specifies that the alert is sent to
* the account administrators.
* @member {string} [storageEndpoint] Specifies the blob storage endpoint (e.g.
* https://MyAccount.blob.core.windows.net). This blob storage will hold all
* Threat Detection audit logs.
* @member {string} [storageAccountAccessKey] Specifies the identifier key of
* the Threat Detection audit storage account.
* @member {number} [retentionDays] Specifies the number of days to keep in the
* Threat Detection audit logs.
*/
export interface ServerSecurityAlertPolicy extends ProxyResource {
state: string;
disabledAlerts?: string[];
emailAddresses?: string[];
emailAccountAdmins?: boolean;
storageEndpoint?: string;
storageAccountAccessKey?: string;
retentionDays?: number;
}


/**
* @class
Expand Down
1 change: 1 addition & 0 deletions lib/services/postgresqlManagement/lib/models/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ exports.PerformanceTierServiceLevelObjectives = require('./performanceTierServic
exports.PerformanceTierProperties = require('./performanceTierProperties');
exports.NameAvailabilityRequest = require('./nameAvailabilityRequest');
exports.NameAvailability = require('./nameAvailability');
exports.ServerSecurityAlertPolicy = require('./serverSecurityAlertPolicy');
exports.ServerListResult = require('./serverListResult');
exports.FirewallRuleListResult = require('./firewallRuleListResult');
exports.DatabaseListResult = require('./databaseListResult');
Expand Down
75 changes: 75 additions & 0 deletions lib/services/postgresqlManagement/lib/models/resource.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

const models = require('./index');

/**
* ARM resource.
*
* @extends models['BaseResource']
*/
class Resource extends models['BaseResource'] {
/**
* Create a Resource.
* @member {string} [id] Resource ID.
* @member {string} [name] Resource name.
* @member {string} [type] Resource type.
*/
constructor() {
super();
}

/**
* Defines the metadata of Resource
*
* @returns {object} metadata of Resource
*
*/
mapper() {
return {
required: false,
serializedName: 'Resource',
type: {
name: 'Composite',
className: 'Resource',
modelProperties: {
id: {
required: false,
readOnly: true,
serializedName: 'id',
type: {
name: 'String'
}
},
name: {
required: false,
readOnly: true,
serializedName: 'name',
type: {
name: 'String'
}
},
type: {
required: false,
readOnly: true,
serializedName: 'type',
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = Resource;
Original file line number Diff line number Diff line change
@@ -0,0 +1,152 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

const models = require('./index');

/**
* A server security alert policy.
*
* @extends models['ProxyResource']
*/
class ServerSecurityAlertPolicy extends models['ProxyResource'] {
/**
* Create a ServerSecurityAlertPolicy.
* @member {string} state Specifies the state of the policy, whether it is
* enabled or disabled. Possible values include: 'Enabled', 'Disabled'
* @member {array} [disabledAlerts] Specifies an array of alerts that are
* disabled. Allowed values are: Sql_Injection, Sql_Injection_Vulnerability,
* Access_Anomaly
* @member {array} [emailAddresses] Specifies an array of e-mail addresses to
* which the alert is sent.
* @member {boolean} [emailAccountAdmins] Specifies that the alert is sent to
* the account administrators.
* @member {string} [storageEndpoint] Specifies the blob storage endpoint
* (e.g. https://MyAccount.blob.core.windows.net). This blob storage will
* hold all Threat Detection audit logs.
* @member {string} [storageAccountAccessKey] Specifies the identifier key of
* the Threat Detection audit storage account.
* @member {number} [retentionDays] Specifies the number of days to keep in
* the Threat Detection audit logs.
*/
constructor() {
super();
}

/**
* Defines the metadata of ServerSecurityAlertPolicy
*
* @returns {object} metadata of ServerSecurityAlertPolicy
*
*/
mapper() {
return {
required: false,
serializedName: 'ServerSecurityAlertPolicy',
type: {
name: 'Composite',
className: 'ServerSecurityAlertPolicy',
modelProperties: {
id: {
required: false,
readOnly: true,
serializedName: 'id',
type: {
name: 'String'
}
},
name: {
required: false,
readOnly: true,
serializedName: 'name',
type: {
name: 'String'
}
},
type: {
required: false,
readOnly: true,
serializedName: 'type',
type: {
name: 'String'
}
},
state: {
required: true,
serializedName: 'properties.state',
type: {
name: 'Enum',
allowedValues: [ 'Enabled', 'Disabled' ]
}
},
disabledAlerts: {
required: false,
serializedName: 'properties.disabledAlerts',
type: {
name: 'Sequence',
element: {
required: false,
serializedName: 'StringElementType',
type: {
name: 'String'
}
}
}
},
emailAddresses: {
required: false,
serializedName: 'properties.emailAddresses',
type: {
name: 'Sequence',
element: {
required: false,
serializedName: 'StringElementType',
type: {
name: 'String'
}
}
}
},
emailAccountAdmins: {
required: false,
serializedName: 'properties.emailAccountAdmins',
type: {
name: 'Boolean'
}
},
storageEndpoint: {
required: false,
serializedName: 'properties.storageEndpoint',
type: {
name: 'String'
}
},
storageAccountAccessKey: {
required: false,
serializedName: 'properties.storageAccountAccessKey',
type: {
name: 'String'
}
},
retentionDays: {
required: false,
serializedName: 'properties.retentionDays',
type: {
name: 'Number'
}
}
}
}
};
}
}

module.exports = ServerSecurityAlertPolicy;
Loading