New-AzureSBAuthorizationRule

[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

New-AzureSBAuthorizationRule

Creates a new Service Bus authorization rule.

Parameter Set: EntitySAS
New-AzureSBAuthorizationRule [-Name] <String> [[-Permission] <AccessRights[]> ] [-Namespace] <String> [-EntityName] <String> [-EntityType] <ServiceBusEntityType> [[-PrimaryKey] <String> ] [[-SecondaryKey] <String> ] [ <CommonParameters>]

Parameter Set: NamespaceSAS
New-AzureSBAuthorizationRule [-Name] <String> [[-Permission] <AccessRights[]> ] [-Namespace] <String> [[-PrimaryKey] <String> ] [[-SecondaryKey] <String> ] [ <CommonParameters>]

This topic describes the cmdlet in the .6.19 version of the Windows Azure PowerShell module. To find out the version of the module you're using, from the Windows Azure PowerShell console, type (get-module azure).version.

-EntityName<String>

The entity name on which to apply the rule.

Aliases

none

Required?

true

Position?

4

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-EntityType<ServiceBusEntityType>

Aliases

none

Required?

true

Position?

5

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Name<String>

The unique authorization rule name.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Namespace<String>

The namespace name to apply the authorization rule. If no EntityName is provided, the rule will be on the namespace level.

Aliases

none

Required?

true

Position?

3

Default Value

none

Accept Pipeline Input?

True (ByPropertyName)

Accept Wildcard Characters?

false

-Permission<AccessRights[]>

The authorization permissions (Send, Manage, Listen).

Aliases

none

Required?

false

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PrimaryKey<String>

Specifies the Shared Access Signature primary key. Generated automatically if not provided.

Aliases

none

Required?

false

Position?

6

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SecondaryKey<String>

Specifies the Shared Access Signature secondary key.

Aliases

none

Required?

false

Position?

7

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see  about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

Create a new authorization rule with a generated primary key

Creates new authorization rule on namespace level with Send permission.

PS C:\> New-AzureSBAuthorizationRule -Name MyRule -Namespace MyNamespace -Permission $("Send")

Creates a new authorization rule with a specified primary key

PS C:\> New-AzureSBAuthorizationRule -Name MyRule -Namespace MyNamespace -Permission $("Manage", "Listen", "Send") -EntityName MyEntity -EntityType Queue -PrimaryKey P+lL/Mnd2Z9sj5hwMrRyAxQDdX8RHfbdqU2eIAqs1rc=

Get-AzureSBAuthorizationRule

Remove-AzureSBAuthorizationRule

Set-AzureSBAuthorizationRule