exam questions

Exam AZ-500 All Questions

View all questions & answers for the AZ-500 exam

Exam AZ-500 topic 13 question 1 discussion

Actual exam question from Microsoft's AZ-500
Question #: 1
Topic #: 13
[All AZ-500 Questions]

HOTSPOT -
What is the membership of Group1 and Group2? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:

Show Suggested Answer Hide Answer
Suggested Answer:
Box 1: User1, User2, User3, User4
Contains "ON" is true for Montreal (User1), MONTREAL (User2), London (User 3), and Ontario (User4) as string and regex operations are not case sensitive.

Box 2: Only User3 -
Match "*on" is only true for London (User3) as 'London' is the only word that ends with 'on'.
Scenario:
Contoso.com contains the users shown in the following table.

Contoso.com contains the security groups shown in the following table.

References:
https://docs.microsoft.com/en-us/azure/active-directory/users-groups-roles/groups-dynamic-membership

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
AdnanEzzi
Highly Voted 5 years, 1 month ago
The answer is correct. Group 1 - U1, U2, U3 & U4 AND for Group 2 - U3.
upvoted 58 times
...
CASGTI
Highly Voted 4 years, 1 month ago
Tested in lab.. >>> -match "*on" >>> is an incorrect expression, it will not allow you to save the this, so the group will not contain any members. ... valid expression could be ".*on" (with a dot in front) ... so make sure in exam you see the dot, if no dot ... then, no members.
upvoted 30 times
ITFranz
1 year, 5 months ago
To back the CASGTI. https://learn.microsoft.com/en-us/entra/identity/users/groups-dynamic-membership Using the -match operator The -match operator is used for matching any regular expression user.displayName -match ".*vid"
upvoted 2 times
...
nExoR
10 months, 1 week ago
match and contains differs in a way that match supports regular expressions, but in this example - they work the same. both are case insensitive and saying "there is a match for 'on'' and "it contains 'on'" - are equivalent. it will be u1,2,3,4 for both
upvoted 1 times
...
Sam_997
3 years, 2 months ago
In the exam its - Match "on" no dot selected no members
upvoted 10 times
...
dorinh
4 years, 1 month ago
you're right, the syntacx is evaluated only on this format (user.displayName -match ".*as")
upvoted 2 times
...
...
mmmyo
Most Recent 1 month ago
Group 1 = U1, U2, U3, U4 -> contains use case-insesitively and find the exact substring Group 2 = U3 -> match use regex and is case-sensitive. The only one user city ending with exact match ending with "on"
upvoted 1 times
...
schpeter_091
7 months, 1 week ago
The solution looks OK, IF we assume that it says ".*on"--> Using the -match operator The -match operator is used for matching any regular expression. Example(for this question): user.displayName -match ".*vid" --> David. Therefore--".*on" --> London. In our exercise, there is just -match "on" --> the same with -contains "on" -->U1/2/3/4 for both.
upvoted 2 times
...
saira23
11 months ago
This case study was in Exam 19/07/2024 I Selected users 1234 for both groups.
upvoted 4 times
...
Drew294
11 months, 2 weeks ago
Agree with the answers users 1-4 for each answer section https://learn.microsoft.com/en-us/entra/identity/users/groups-dynamic-rule-more-efficient. The relevant section Minimize the usage of the match operator in rules as much as possible. Instead, explore if it's possible to use the startswith or -eq operators. Considering using other properties that allow you to write rules to select the users you want to be in the group without using the -match operator. For example, if you want a rule for the group for all users whose city is Lagos, then instead of using rules like: user.city -match "ago"
upvoted 1 times
...
Codelawdepp
12 months ago
Tested in Lab! correct answer: Group1: User1, User2, User3, User4 Group2: User1, User2, User3, User4 user.city -contains "ON" = and user.city -match "on" are not case sensitive and will show the same result. But looks like the -match command is more flexible. Contains: user.city -contains "ON" = ok user.city -contains ".*ON" = error1 user.city -contains ".ON" = error1 user.city -contains "*ON" = error1 user.city -contains "*.ON" = error1 Match user.city -match "on" = ok user.city -match ".*on" = ok user.city -match ".on" = ok user.city -match "*on" = error2 user.city -match"*.on" = error2 error1: Dynamic membership rule validation error: Invalid operator. Invalid operator '-contain' error2: Unable to complete due to service connection error. Please try again later. (its not a temporary error ;-)
upvoted 6 times
timHAG
11 months, 1 week ago
what was the results for ? is it only ?User 3 - London? user.city -match ".*on" = ok user.city -match ".on" = ok
upvoted 1 times
...
...
RemmyT
1 year, 1 month ago
Passed. Exam duration 100 min + 20. On the Microsoft site: https://learn.microsoft.com/en-us/credentials/certifications/azure-security-engineer/?practice-assessment-type=certification You will have 100 minutes to complete this assessment. Last Updated 04/30/2024 55 questions (46+9) contoso, 6 questions This question in exam (study case) My answer Group1: User1, User2, User3, User4 Group2: User1, User2, User3, User4 New 3 or 4 questions VM1, SQL1, VNET1, AKS in Google Cloud. What items are protected by Microsoft Defender & default period scan.
upvoted 5 times
...
RemmyT
1 year, 1 month ago
Tested in lab The two membership conditions are case insesitive and give the same result (the same memberhip for the test groups). All give the same result. (user.city -match "on") (user.city -match ".*on") (user.city -contains "ON") Group1: User1, User2, User3, User4 Group2: User1, User2, User3, User4 It's not valid expression: Failed to save group. Failed to save dynamic group. (user.city -match "*on") (user.city -match "*.on")
upvoted 2 times
...
Ivan80
1 year, 4 months ago
In exam 1/28/24
upvoted 5 times
...
husam421
1 year, 5 months ago
The answer is U1 U2 U3 and U4 four both The -match operator is used for matching any regular expression. Examples: Copy user.displayName -match "^Da.*" Da, Dav, David evaluate to true, aDa evaluates to false.
upvoted 1 times
...
wardy1983
1 year, 6 months ago
Explanation: Box 1: User1, User2, User3, User4 Contains "ON" is true for Montreal (User1), MONTREAL (User2), London (User 3), and Ontario (User4) as string and regex operations are not case sensitive. Box 2: Only User3 - Match "*on" is only true for London (User3) as 'London' is the only word that ends with 'on'.
upvoted 2 times
...
[Removed]
1 year, 7 months ago
Tested in lab. Group1 is: User1, User2, User3, User4 Group2 is: User1, User2, User3, User4 (With -macth "on" and with -match ".*on")
upvoted 3 times
Atilgen
1 year, 2 months ago
Also tested it and same result.
upvoted 1 times
...
...
_punky_
1 year, 8 months ago
both are case insesitive where one is classical substring match "contains" and 2nd is regex match(/ig). Both will give the same output
upvoted 1 times
...
TheProfessor
1 year, 8 months ago
According to the question, Group 2: No Members
upvoted 1 times
TheProfessor
1 year, 8 months ago
It should return Group2 => U1, U2,U3,U4 Only User3 will be if the expression ".*on".
upvoted 1 times
...
...
AzureAdventure
1 year, 8 months ago
I tested it with this script # Define an array of colors $colors = "RED", "Green", "Blue" # Check if "Red" exists in the array (case-sensitive) if ($colors -contains "Red") { Write-Host "The array contains 'Red'." } else { Write-Host "The array does not contain 'Red'." } # Check if "red" exists in the array (case-sensitive) if ($colors -contains "red") { Write-Host "The array contains 'red'." } else { Write-Host "The array does not contain 'red'." } if ($colors -match "red") { Write-Host "The array match 'red'." } else { Write-Host "The array does not match 'red'." } *************************** Console shows this result The array contains 'Red'. The array contains 'red'. The array match 'red'. **************************** My conclusion is Group 1 => U1,U2,U3,U4 Group2 => U1, U2,U3,U4
upvoted 3 times
AzureAdventure
1 year, 8 months ago
https://learn.microsoft.com/en-us/azure/active-directory/enterprise-users/groups-dynamic-membership#:~:text=String%20and%20regex%20operations%20aren%27t%20case%20sensitive.
upvoted 1 times
...
...
massnonn
1 year, 11 months ago
user.displayName -match "Da.*" Da, Dav, David evaluate to true, aDa evaluates to false. Therefore in this case -match "on" there are no match for group 2
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...