prancer-io / cloud-validation-framework

prancer platform is an IaC Security engine + Continuous Compliance for your cloud (Azure, AWS, GCP) and Kubernetes environment
https://www.prancer.io
Mozilla Public License 2.0
122 stars 29 forks source link

Crawl userRegistrationDetails from MS Graph API #685

Closed rezoan closed 1 year ago

rezoan commented 1 year ago

Cawal below graph API endpoint to get list of userRegistrationDetails:

Note: The API still is in beta phase. in the response under the valuearray each curly braces block is a separate user registration detail object. each object might have a property "@odata.type": "#microsoft.graph.userRegistrationDetails" or might not have in future. for our rego rules to work, normalize each user registration detail object snapshot by adding a type as microsoft.graph.userRegistrationDetails and move all other properties under a properties block.

Simply treat each user registration detail object as a sperate resource type under the value array.

Also see the permissions section for necessary permission to crawl this resource type from AAD.

master-snapshot:

                {
                    "masterSnapshotId": "AZRSNP_525",
                    "type": "microsoft.graph.userRegistrationDetails",
                    "collection": "microsoft.graph",
                    "version": "beta"
                }