Skip to content

Commit 8007b2d

Browse files
committed
Merging changes synced from https://github.com/MicrosoftDocs/azure-docs-pr (branch live)
2 parents 90895f0 + 3d63b92 commit 8007b2d

File tree

64 files changed

+1503
-629
lines changed

Some content is hidden

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

64 files changed

+1503
-629
lines changed

articles/active-directory/develop/app-resilience-continuous-access-evaluation.md

Lines changed: 22 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -104,11 +104,20 @@ You can test your application by signing in a user to the application then using
104104
When these conditions are met, the app can extract the claims challenge from the API response header as follows:
105105

106106
```javascript
107-
const authenticateHeader = response.headers.get('www-authenticate');
108-
const claimsChallenge = parseChallenges(authenticateHeader).claims;
109-
110-
// ...
107+
try {
108+
const response = await fetch(apiEndpoint, options);
109+
110+
if (response.status === 401 && response.headers.get('www-authenticate')) {
111+
const authenticateHeader = response.headers.get('www-authenticate');
112+
const claimsChallenge = parseChallenges(authenticateHeader).claims;
113+
114+
// use the claims challenge to acquire a new access token...
115+
}
116+
} catch(error) {
117+
// ...
118+
}
111119

120+
// helper function to parse the www-authenticate header
112121
function parseChallenges(header) {
113122
const schemeSeparator = header.indexOf(' ');
114123
const challenges = header.substring(schemeSeparator + 1).split(',');
@@ -126,24 +135,20 @@ function parseChallenges(header) {
126135
Your app would then use the claims challenge to acquire a new access token for the resource.
127136

128137
```javascript
138+
const tokenRequest = {
139+
claims: window.atob(claimsChallenge), // decode the base64 string
140+
scopes: ['User.Read']
141+
account: msalInstance.getActiveAccount();
142+
};
143+
129144
let tokenResponse;
130145

131146
try {
132-
tokenResponse = await msalInstance.acquireTokenSilent({
133-
claims: window.atob(claimsChallenge), // decode the base64 string
134-
scopes: scopes, // e.g ['User.Read', 'Contacts.Read']
135-
account: account, // current active account
136-
});
137-
147+
tokenResponse = await msalInstance.acquireTokenSilent(tokenRequest);
138148
} catch (error) {
139149
if (error instanceof InteractionRequiredAuthError) {
140-
tokenResponse = await msalInstance.acquireTokenPopup({
141-
claims: window.atob(claimsChallenge), // decode the base64 string
142-
scopes: scopes, // e.g ['User.Read', 'Contacts.Read']
143-
account: account, // current active account
144-
});
150+
tokenResponse = await msalInstance.acquireTokenPopup(tokenRequest);
145151
}
146-
147152
}
148153
```
149154

@@ -154,8 +159,7 @@ const msalConfig = {
154159
auth: {
155160
clientId: 'Enter_the_Application_Id_Here',
156161
clientCapabilities: ["CP1"]
157-
// the remaining settings
158-
// ...
162+
// remaining settings...
159163
}
160164
}
161165

articles/active-directory/develop/claims-challenge.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ _clientApp = PublicClientApplicationBuilder.Create(App.ClientId)
103103
.WithDefaultRedirectUri()
104104
.WithAuthority(authority)
105105
.WithClientCapabilities(new [] {"cp1"})
106-
.Build();*
106+
.Build();
107107
```
108108

109109
Those using Microsoft.Identity.Web can add the following code to the configuration file:
@@ -112,22 +112,21 @@ Those using Microsoft.Identity.Web can add the following code to the configurati
112112
{
113113
"AzureAd": {
114114
"Instance": "https://login.microsoftonline.com/",
115-
// the remaining settings
116-
// ...
117-
"ClientCapabilities": [ "cp1" ]
115+
"ClientId": 'Enter_the_Application_Id_Here'
116+
"ClientCapabilities": [ "cp1" ],
117+
// remaining settings...
118118
},
119119
```
120120
#### [JavaScript](#tab/JavaScript)
121121

122-
Those using MSAL.js can add `clientCapabilities` property to the configuration object.
122+
Those using MSAL.js or MSAL Node can add `clientCapabilities` property to the configuration object. Note: this option is available to both public and confidential cient applications.
123123

124124
```javascript
125125
const msalConfig = {
126126
auth: {
127127
clientId: 'Enter_the_Application_Id_Here',
128128
clientCapabilities: ["CP1"]
129-
// the remaining settings
130-
// ...
129+
// remaining settings...
131130
}
132131
}
133132

@@ -222,14 +221,15 @@ else
222221

223222
### [JavaScript](#tab/JavaScript)
224223

224+
The following snippet illustrates a custom Express.js middleware:
225+
225226
```javascript
226227
const checkIsClientCapableOfClaimsChallenge = (req, res, next) => {
227228
// req.authInfo contains the decoded access token payload
228229
if (req.authInfo['xms_cc'] && req.authInfo['xms_cc'].includes('CP1')) {
229230
// Return formatted claims challenge as this client understands this
230-
231231
} else {
232-
return res.status(403).json({ error: 'Client is not capable' });
232+
return res.status(403).json({ error: 'Client is not capable' });
233233
}
234234
}
235235

articles/active-directory/develop/mark-app-as-publisher-verified.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ If you are already enrolled in the Microsoft Partner Network (MPN) and have met
3131

3232
For more details on specific benefits, requirements, and frequently asked questions see the [overview](publisher-verification-overview.md).
3333

34-
3534
## Mark your app as publisher verified
3635
Make sure you have met the [pre-requisites](publisher-verification-overview.md#requirements), then follow these steps to mark your app(s) as Publisher Verified.
3736

articles/active-directory/managed-identities-azure-resources/how-to-use-vm-token.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ GET 'http://169.254.169.254/metadata/identity/oauth2/token?api-version=2018-02-0
7676
| `Metadata` | An HTTP request header field required by managed identities. This information is used as a mitigation against server side request forgery (SSRF) attacks. This value must be set to "true", in all lower case. |
7777
| `object_id` | (Optional) A query string parameter, indicating the object_id of the managed identity you would like the token for. Required, if your VM has multiple user-assigned managed identities.|
7878
| `client_id` | (Optional) A query string parameter, indicating the client_id of the managed identity you would like the token for. Required, if your VM has multiple user-assigned managed identities.|
79-
| `mi_res_id` | (Optional) A query string parameter, indicating the mi_res_id (Azure Resource ID) of the managed identity you would like the token for. Required, if your VM has multiple user-assigned managed identities. |
79+
| `msi_res_id` | (Optional) A query string parameter, indicating the msi_res_id (Azure Resource ID) of the managed identity you would like the token for. Required, if your VM has multiple user-assigned managed identities. |
8080

8181
Sample response:
8282

articles/aks/TOC.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,8 @@
186186
href: custom-node-configuration.md
187187
- name: Integrate ACR with an AKS cluster
188188
href: cluster-container-registry-integration.md
189+
- name: Use Vertical Pod Autoscaler (preview)
190+
href: vertical-pod-autoscaler.md
189191
- name: Scale an AKS cluster
190192
href: scale-cluster.md
191193
- name: Stop/Deallocate nodes with Scale-down Mode

articles/aks/operator-best-practices-cluster-security.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,8 @@ spec:
7373
```
7474
7575
> [!NOTE]
76-
> We recommend you review [Azure AD workload identity][workload-identity-overview] (preview).
77-
> This authentication method replaces pod-managed identity (preview), which integrates with the
78-
> Kubernetes native capabilities to federate with any external identity providers on behalf of the
79-
> application.
76+
> Alternatively you can use [Pod Identity](./use-azure-ad-pod-identity.md) though this is in Public Preview. It has a pod (NMI) that runs as a DaemonSet on each node in the AKS cluster. NMI intercepts security token requests to the Azure Instance Metadata Service on each node, redirect them to itself and validates if the pod has access to the identity it's requesting a token for and fetch the token from the Azure AD tenant on behalf of the application.
77+
>
8078
8179
## Secure container access to resources
8280

articles/aks/supported-kubernetes-versions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ For the past release history, see [Kubernetes](https://en.wikipedia.org/wiki/Kub
192192
| 1.22 | Aug-04-21 | Sept 2021 | Dec 2021 | 1.25 GA |
193193
| 1.23 | Dec 2021 | Jan 2022 | Apr 2022 | 1.26 GA |
194194
| 1.24 | Apr-22-22 | May 2022 | Jul 2022 | 1.27 GA
195-
| 1.25 | Aug 2022 | Sept 2022 | Nov 2022 | 1.28 GA
195+
| 1.25 | Aug 2022 | Oct 2022 | Nov 2022 | 1.28 GA
196196

197197
## FAQ
198198

0 commit comments

Comments
 (0)