Skip to content

Commit d57b008

Browse files
authored
Merge pull request #294117 from MicrosoftDocs/main
Publish to live, Wednesday 4AM PST, 2/5
2 parents 295a723 + 9445267 commit d57b008

31 files changed

+321
-42
lines changed
44.8 KB
Loading

articles/azure-signalr/signalr-howto-configure-application-firewall.md

Lines changed: 49 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ The Application Firewall provides sophisticated control over client connections
1717

1818
## What Does the Application Firewall Do?
1919

20-
The Application Firewall consists of various rule lists. Currently, there is a rule list called *Client Connection Count Rules*. Future updates will support more rule lists to control aspects like connection lifetime and message throughput.
20+
The Application Firewall consists of various rule lists. Currently, there are two rule lists called *Client Connection Count Rules* and *Client Traffic Control Rules*. Future updates will support more rule lists to control aspects such as connection lifetime.
2121

2222
This guideline is divided into three parts:
2323
1. Introduction to different application firewall rules.
@@ -56,7 +56,18 @@ Client Connection Count Rules restrict concurrent client connections. When a cli
5656
> [!WARNING]
5757
> * **Avoid using too aggressive maxCount**. Client connections may close without completing the TCP handshake. SignalR service can't detect those "half-closed" connections immediately. The connection is taken as active until the heartbeat failure. Therefore, aggressive throttling strategies might unexpectedly throttle clients. A smoother approach is to **leave some buffer** for the connection count, for example: double the *maxCount*.
5858
59+
## Client Traffic Control Rules
60+
Client Traffic Control Rules restrict the inbound throughput of client connections. When a client attempts to send a message, the rules are checked **sequentially**. Within each *aggregation window*, the message size will be aggregated to check against *max inbound message*. If any rule is violated, the connection is disconnected.
5961

62+
#### TrafficThrottleByUserIdRule
63+
This rule limits the inbound throughput of a user.
64+
65+
#### TrafficThrottleByJwtSignatureRule
66+
This rule limits the inbound throughput of each token.
67+
68+
#### TrafficThrottleByJwtCustomClaimRule
69+
This rule limits the inbound throughput of the same claim.
70+
6071

6172
## Set up Application Firewall
6273

@@ -73,7 +84,7 @@ Use Visual Studio Code or your favorite editor to create a file with the followi
7384
@description('The name for your SignalR service')
7485
param resourceName string = 'contoso'
7586
76-
resource signalr 'Microsoft.SignalRService/signalr@2024-04-01-preview' = {
87+
resource signalr 'Microsoft.SignalRService/signalr@2024-10-01-preview' = {
7788
name: resourceName
7889
properties: {
7990
applicationFirewall:{
@@ -101,6 +112,42 @@ resource signalr 'Microsoft.SignalRService/signalr@2024-04-01-preview' = {
101112
claimName: 'paidUser'
102113
}
103114
]
115+
clientTrafficControlRules:[
116+
// Add or remove rules as needed
117+
{
118+
// This rule will be skipped if no userId is set
119+
type: 'TrafficThrottleByUserIdRule'
120+
// Every minute
121+
aggregationWindowInSeconds: 60
122+
// 10MB
123+
maxInboundMessageBytes: 10485760
124+
}
125+
{
126+
type: 'TrafficThrottleByJwtSignatureRule'
127+
// Every 30 seconds
128+
aggregationWindowInSeconds: 30
129+
// 5MB
130+
maxInboundMessageBytes: 5242880
131+
}
132+
{
133+
// This rule will be skipped if no freeUser claim is set
134+
type: 'TrafficThrottleByJwtCustomClaimRule'
135+
// Every 10 minutes
136+
aggregationWindowInSeconds: 600
137+
// 1MB
138+
maxInboundMessageBytes: 1048576
139+
claimName: 'freeUser'
140+
}
141+
{
142+
// This rule will be skipped if no paidUser claim is set
143+
type: 'TrafficThrottleByJwtCustomClaimRule'
144+
// Every 30 seconds
145+
aggregationWindowInSeconds: 30
146+
// 1MB
147+
maxInboundMessageBytes: 1048576
148+
claimName: 'paidUser'
149+
}
150+
]
104151
}
105152
}
106153
}

articles/azure-web-pubsub/howto-configure-application-firewall.md

Lines changed: 42 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ ms.author: biqian
1212

1313
The Application Firewall provides sophisticated control over client connections in a distributed system. Before diving into its functionality and setup, let's clarify what the Application Firewall does not do:
1414

15-
1. It does not replace authentication. The firewall operates behind the client connection authentication layer.
16-
2. It is not related to network layer access control.
15+
1. It doesn't replace authentication. The firewall operates behind the client connection authentication layer.
16+
2. It isn't related to network layer access control.
1717

1818
## What Does the Application Firewall Do?
1919

20-
The Application Firewall consists of various rule lists. Currently, there is a rule list called *Client Connection Count Rules*. Future updates will support more rule lists to control aspects like connection lifetime and message throughput.
20+
The Application Firewall consists of various rule lists. Currently, there are two rule lists called *Client Connection Count Rules* and *Client Traffic Control Rules*. Future updates will support more rule lists to control aspects such as connection lifetime.
2121

2222
This guideline is divided into three parts:
2323
1. Introduction to different application firewall rules.
@@ -48,6 +48,14 @@ Client Connection Count Rules restrict concurrent client connections. When a cli
4848
> * **Avoid using too aggressive maxCount**. Client connections may close without completing the TCP handshake. SignalR service can't detect those "half-closed" connections immediately. The connection is taken as active until the heartbeat failure. Therefore, aggressive throttling strategies might unexpectedly throttle clients. A smoother approach is to **leave some buffer** for the connection count, for example: double the *maxCount*.
4949
5050

51+
## Client Traffic Control Rules
52+
Client Traffic Control Rules restrict the inbound throughput of client connections. When a client attempts to send a message, the rules are checked **sequentially**. Within each *aggregation window*, the message size will be aggregated to check against *max inbound message*. If any rule is violated, the connection is disconnected.
53+
54+
#### TrafficThrottleByUserIdRule
55+
This rule limits the inbound throughput of a user.
56+
57+
#### TrafficThrottleByJwtSignatureRule
58+
This rule limits the inbound throughput of each token.
5159

5260
## Set up Application Firewall
5361

@@ -64,22 +72,40 @@ Use Visual Studio Code or your favorite editor to create a file with the followi
6472
@description('The name for your Web PubSub service')
6573
param resourceName string = 'contoso'
6674
67-
resource webpubsub 'Microsoft.SignalRService/webpubsub@2024-04-01-preview' = {
75+
resource webpubsub 'Microsoft.SignalRService/webpubsub@2024-10-01-preview' = {
6876
name: resourceName
6977
properties: {
7078
applicationFirewall:{
71-
clientConnectionCountRules:[
72-
// Add or remove rules as needed
73-
{
74-
// This rule will be skipped if no userId is set
75-
type: 'ThrottleByUserIdRule'
76-
maxCount: 5
77-
}
78-
{
79-
type: 'ThrottleByJwtSignatureRule'
80-
maxCount: 10
81-
}
82-
]
79+
clientConnectionCountRules: [
80+
// Add or remove rules as needed
81+
{
82+
// This rule will be skipped if no userId is set
83+
type: 'ThrottleByUserIdRule'
84+
maxCount: 5
85+
}
86+
{
87+
type: 'ThrottleByJwtSignatureRule'
88+
maxCount: 10
89+
}
90+
]
91+
clientTrafficControlRules: [
92+
// Add or remove rules as needed
93+
{
94+
// This rule will be skipped if no userId is set
95+
type: 'TrafficThrottleByUserIdRule'
96+
// Every minute
97+
aggregationWindowInSeconds: 60
98+
// 10MB
99+
maxInboundMessageBytes: 10485760
100+
}
101+
{
102+
type: 'TrafficThrottleByJwtSignatureRule'
103+
// Every 30 seconds
104+
aggregationWindowInSeconds: 30
105+
// 5MB
106+
maxInboundMessageBytes: 5242880
107+
}
108+
]
83109
}
84110
}
85111
}
48.9 KB
Loading

articles/sentinel/TOC.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -752,8 +752,6 @@
752752
href: configure-connector-login-detection.md
753753
- name: Create a custom connector
754754
href: create-custom-connector.md
755-
- name: Create a codeless connector
756-
href: create-codeless-connector.md
757755
- name: Normalize data
758756
items:
759757
- name: ASIM overview
@@ -766,8 +764,6 @@
766764
href: normalization-ingest-time.md
767765
- name: Use ASIM
768766
href: normalization-about-parsers.md
769-
- name: Develop ASIM parsers
770-
href: normalization-develop-parsers.md
771767
- name: Manage ASIM parsers
772768
href: normalization-manage-parsers.md
773769
- name: Modify content to use ASIM
@@ -1147,10 +1143,16 @@
11471143
href: sentinel-integration-guide.md
11481144
- name: Partner integrations best practices
11491145
href: partner-integrations.md
1146+
- name: Creating codeless data connectors (CCP)
1147+
href: create-codeless-connector.md
1148+
- name: Creating analytics rules
1149+
href: sentinel-analytic-rules-creation.md
11501150
- name: Creating workbooks
11511151
href: sentinel-workbook-creation.md
11521152
- name: Creating playbooks
11531153
href: sentinel-playbook-creation.md
1154+
- name: Creating ASIM parsers
1155+
href: normalization-develop-parsers.md
11541156
- name: Publish solutions
11551157
href: publish-sentinel-solutions.md
11561158
- name: Solution lifecycle post publish

0 commit comments

Comments
 (0)