Skip to content

Commit 8223f4f

Browse files
committed
Adding schema to data masking rule and refactoring
1 parent d39247d commit 8223f4f

File tree

43 files changed

+160
-126
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+160
-126
lines changed

src/ResourceManager/Automation/Commands.Automation.Test/Commands.ResourceManagement.Automation.Test.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<ProductVersion>
77
</ProductVersion>
88
<SchemaVersion>2.0</SchemaVersion>
9-
<ProjectGuid>{127D0D51-FDEA-4E1A-8CD8-34DEB5C2F7F6}</ProjectGuid>
9+
<ProjectGuid>{59D1B5DC-9175-43EC-90C6-CBA601B3565F}</ProjectGuid>
1010
<OutputType>Library</OutputType>
1111
<AppDesignerFolder>Properties</AppDesignerFolder>
1212
<RootNamespace>Microsoft.Azure.Commands.ResourceManager.Automation.Test</RootNamespace>

src/ResourceManager/Sql/Commands.Sql.Test/packages.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<package id="Microsoft.Azure.Gallery" version="2.6.2-preview" targetFramework="net45" />
88
<package id="Microsoft.Azure.Management.Authorization" version="0.19.2-preview" targetFramework="net45" />
99
<package id="Microsoft.Azure.Management.Resources" version="2.18.1-preview" targetFramework="net45" />
10-
<package id="Microsoft.Azure.Management.Sql" version="0.29.0-prerelease" targetFramework="net45" />
10+
<package id="Microsoft.Azure.Management.Sql" version="0.31.0-prerelease" targetFramework="net45" />
1111
<package id="Microsoft.Azure.Management.Storage" version="2.4.0-preview" targetFramework="net45" />
1212
<package id="Microsoft.Azure.Test.Framework" version="1.0.5571.32271-prerelease" targetFramework="net45" />
1313
<package id="Microsoft.Azure.Test.HttpRecorder" version="1.0.5571.32271-prerelease" targetFramework="net45" />
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
using Microsoft.Azure.Commands.Sql.Security.Model;
15+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
1616
using System.Management.Automation;
1717

18-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
18+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
1919
{
2020
/// <summary>
2121
/// Returns the auditing policy of a specific database.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
using Microsoft.Azure.Commands.Sql.Security.Model;
15+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
1616
using System.Management.Automation;
1717

18-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
18+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
1919
{
2020
/// <summary>
2121
/// Returns the auditing policy of a specific database server.

src/ResourceManager/Sql/Commands.Sql/Security/Cmdlet/Auditing/RemoveSqlDatabaseAuditing.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Cmdlet/RemoveSqlDatabaseAuditing.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
using Microsoft.Azure.Commands.Sql.Security.Model;
15+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
1616
using System.Management.Automation;
1717

18-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
18+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
1919
{
2020
/// <summary>
2121
/// Disables auditing on a specific database.

src/ResourceManager/Sql/Commands.Sql/Security/Cmdlet/Auditing/RemoveSqlServerAuditing.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Cmdlet/RemoveSqlServerAuditing.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
using Microsoft.Azure.Commands.Sql.Security.Model;
15+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
1616
using System.Management.Automation;
1717

18-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
18+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
1919
{
2020
/// <summary>
2121
/// Disables auditing on a specific database server.
Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,16 @@
1313
// ----------------------------------------------------------------------------------
1414

1515
using Microsoft.Azure.Commands.Sql.Properties;
16-
using Microsoft.Azure.Commands.Sql.Security.Model;
17-
using Microsoft.Azure.Commands.Sql.Security.Services;
16+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
17+
using Microsoft.Azure.Commands.Sql.Auditing.Services;
1818
using System;
1919
using System.Collections.Generic;
2020
using System.Linq;
2121
using System.Management.Automation;
2222
using Microsoft.Azure.Commands.Sql.Services;
23+
using Microsoft.Azure.Commands.Sql.Common;
2324

24-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
25+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
2526
{
2627
/// <summary>
2728
/// Sets the auditing policy properties for a specific database.
Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,16 @@
1313
// ----------------------------------------------------------------------------------
1414

1515
using Microsoft.Azure.Commands.Sql.Properties;
16-
using Microsoft.Azure.Commands.Sql.Security.Model;
17-
using Microsoft.Azure.Commands.Sql.Security.Services;
16+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
17+
using Microsoft.Azure.Commands.Sql.Auditing.Services;
1818
using System;
1919
using System.Collections.Generic;
2020
using System.Linq;
2121
using System.Management.Automation;
2222
using Microsoft.Azure.Commands.Sql.Services;
23+
using Microsoft.Azure.Commands.Sql.Common;
2324

24-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
25+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
2526
{
2627
/// <summary>
2728
/// Sets the auditing policy properties for a specific database server.
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@
1313
// ----------------------------------------------------------------------------------
1414

1515
using Microsoft.Azure.Commands.Sql.Common;
16-
using Microsoft.Azure.Commands.Sql.Security.Model;
17-
using Microsoft.Azure.Commands.Sql.Security.Services;
16+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
17+
using Microsoft.Azure.Commands.Sql.Auditing.Services;
1818
using Microsoft.Azure.Common.Authentication.Models;
1919

20-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
20+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
2121
{
2222
/// <summary>
2323
/// The base class for all Azure Sql Database security Management Cmdlets
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@
1414

1515
using System.Management.Automation;
1616
using Microsoft.Azure.Commands.Sql.Common;
17-
using Microsoft.Azure.Commands.Sql.Security.Model;
18-
using Microsoft.Azure.Commands.Sql.Security.Services;
17+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
18+
using Microsoft.Azure.Commands.Sql.Auditing.Services;
1919
using Microsoft.Azure.Common.Authentication.Models;
2020

21-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
21+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
2222
{
2323
/// <summary>
2424
/// The base class for all SQL server auditing Management Cmdlets
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@
1313
// ----------------------------------------------------------------------------------
1414

1515
using Microsoft.Azure.Commands.Sql.Properties;
16-
using Microsoft.Azure.Commands.Sql.Security.Model;
16+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
1717
using System;
1818
using System.Management.Automation;
1919

20-
namespace Microsoft.Azure.Commands.Sql.Security.Cmdlet.Auditing
20+
namespace Microsoft.Azure.Commands.Sql.Auditing.Cmdlet
2121
{
2222
/// <summary>
2323
/// Marks the given database as using its server's default policy instead of its own policy.

src/ResourceManager/Sql/Commands.Sql/Security/Model/BaseAuditingPolicyModel.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Model/BaseAuditingPolicyModel.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
namespace Microsoft.Azure.Commands.Sql.Security.Model
15+
namespace Microsoft.Azure.Commands.Sql.Auditing.Model
1616
{
1717
/// <summary>
1818
/// types of storage keys
@@ -22,7 +22,7 @@ public enum StorageKeyKind { Primary, Secondary };
2222
/// <summary>
2323
/// The possible audit event types
2424
/// </summary>
25-
public enum AuditEventType { DataAccess, DataChanges, RevokePermissions, SchemaChanges, SecurityExceptions, PlainSQL_Success, PlainSQL_Failure, ParameterizedSQL_Success, ParameterizedSQL_Failure, StoredProcedure_Success, StoredProcedure_Failure, Login_Success, Login_Failure, TransactionManagement_Success, TransactionManagement_Failure };
25+
public enum AuditEventType { PlainSQL_Success, PlainSQL_Failure, ParameterizedSQL_Success, ParameterizedSQL_Failure, StoredProcedure_Success, StoredProcedure_Failure, Login_Success, Login_Failure, TransactionManagement_Success, TransactionManagement_Failure };
2626

2727
/// <summary>
2828
/// The possible states in which an auditing policy may be in

src/ResourceManager/Sql/Commands.Sql/Security/Model/DatabaseAuditingPolicyModel.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Model/DatabaseAuditingPolicyModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
namespace Microsoft.Azure.Commands.Sql.Security.Model
15+
namespace Microsoft.Azure.Commands.Sql.Auditing.Model
1616
{
1717
/// <summary>
1818
/// The possible states in which the user server's policy property may be in

src/ResourceManager/Sql/Commands.Sql/Security/Model/ServerAuditingPolicyModel.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Model/ServerAuditingPolicyModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// limitations under the License.
1313
// ----------------------------------------------------------------------------------
1414

15-
namespace Microsoft.Azure.Commands.Sql.Security.Model
15+
namespace Microsoft.Azure.Commands.Sql.Auditing.Model
1616
{
1717
/// <summary>
1818
/// A class representing A server's auditing policy

src/ResourceManager/Sql/Commands.Sql/Security/Services/AuditingEndpointsCommunicator.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Services/AuditingEndpointsCommunicator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
using System;
2020
using Microsoft.Azure.Commands.Sql.Common;
2121

22-
namespace Microsoft.Azure.Commands.Sql.Security.Services
22+
namespace Microsoft.Azure.Commands.Sql.Auditing.Services
2323
{
2424
/// <summary>
2525
/// This class is responsible for all the REST communication with the audit REST endpoints

src/ResourceManager/Sql/Commands.Sql/Security/Services/SqlAuditAdapter.cs renamed to src/ResourceManager/Sql/Commands.Sql/Auditing/Services/SqlAuditAdapter.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
// ----------------------------------------------------------------------------------
1414

1515
using Microsoft.Azure.Commands.Sql.Properties;
16-
using Microsoft.Azure.Commands.Sql.Security.Model;
16+
using Microsoft.Azure.Commands.Sql.Auditing.Model;
1717
using Microsoft.Azure.Common.Authentication.Models;
1818
using Microsoft.Azure.Management.Sql.Models;
1919
using System;
@@ -24,7 +24,7 @@
2424
using Microsoft.Azure.Commands.Sql.Database.Services;
2525
using Microsoft.Azure.Commands.Sql.Database.Model;
2626

27-
namespace Microsoft.Azure.Commands.Sql.Security.Services
27+
namespace Microsoft.Azure.Commands.Sql.Auditing.Services
2828
{
2929
/// <summary>
3030
/// The SqlAuditClient class is responsible for transforming the data that was received form the endpoints to the cmdlets model of auditing policy and vice versa

0 commit comments

Comments
 (0)