Provisioning with SCIM - azure-active-directory

I am very new to SCIM and want to use it Provisioning or a user registered in Azure AD and want to update some other system with user registrations. What if the other system is having issues or is in maintenance. How can you guarantee the delivery of the information to the other system. What is the best practices to handle situation like this?

Errors and retries
If an individual user can't be added, updated, or deleted in the target system due to an error in the target system, then the operation will be retried in the next sync cycle. If the user continues to fail, then the retries will begin to occur at a reduced frequency, gradually scaling back to just one attempt per day. To resolve the failure, administrators will need to check the audit logs for "process escrow" events to determine the root cause and take the appropriate action. Common failures can include:
Users not having an attribute populated in the source system that is required in the target system
Users having an attribute value in the source system for which there is a unique constraint in the target system, and the same value is present in another user record
These failures can be resolved by adjusting the attribute values for the affected user in the source system, or by adjusting the attribute mappings to not cause conflicts.
Quarantine
If most or all of the calls made against the target system consistently fail due to an error (such as in the case of invalid admin credentials), then the provisioning job goes into a "quarantine" state. This is indicated in the provisioning summary report, and via email if email notifications were configured in the Azure portal.
When in quarantine, the frequency of incremental syncs is gradually reduced to once per day.
The provisioning job will be removed from quarantine after all of the offending errors being fixed, and the next sync cycle starts. If the provisioning job stays in quarantine for more than four weeks, the provisioning job is disabled.
Reference: Automate user provisioning and deprovisioning to SaaS applications with Azure Active Directory

Related

Azure AD Access Reviews

I am wondering what the criteria are for Azure PIM Access Reviews recommendations? In the documentation it gives an example of an interactive user not signing in for the last 30 days. Do the PIM Access Reviews look at who hasn't activated their eligible role(s)? Is there a corresponding report that could be pulled to view anyone who has not requested to elevate their privileges in the last x days?
You can configure Security alerts for azure ad PIM if the user goes over specified number of days without activating the role. When an alert is triggered, it shows up on the Privileged Identity Management dashboard. Select the alert to see a report that lists the users or roles that triggered the alert. We have three levels of severity in security alerts.
High: Requires immediate action because of a policy violation.
Medium: Does not require immediate action but signals a potential policy violation.
Low: Does not require immediate action but suggests a preferable policy change.
We have a default rule called Administrators aren't using their privileged roles you may configure this alert to get the list.
Why do I get this alert?
Users that have been assigned privileged roles they don't need increases the chance of an attack.
Trigger: Triggered if a user goes over a specified number of days without activating a role.
Number of days: This setting specifies the maximum number of days, from 0 to 100, that a user can go without activating a role.
Prevention Assign privileged roles only to users who have a business justification.Schedule regular access reviews to verify that users still need their access.
How to fix? Review the users in the list and remove them from privileged roles that they do not need.
Security alerts for Azure AD roles in PIM - Azure AD | Microsoft Docs
You can also retrieve the group membership information and users who are activated by using power shell commands or scripts
Here are some references to use power shell commands
https://learn.microsoft.com/en-us/azure/active-directory/privileged-identity-management/powershell-for-azure-ad-roles
https://practical365.com/powershell-script-to-report-rbac-role-group-membership/

Azure AD Enterprise application role change doesn't trigger provisioning update for Zoom or DocuSign

I've set up Zoom and DocuSign with SSO and Automatic provisioning in Azure AD Enterprise Applications. Just in Time provisioning works as expected after ensuring roles are correctly mapped. Automatic provisioning however only appears to add users the first time it runs. If I add an application user, change a user's Application Role, or Remove the user from the application nothing happens on the next provisioning run. I would expect the user to be added, the user's permissions to be updated at Zoom or DocuSign, or for the user to be disabled.
Documentation seems to show that updates and deletes should be handled through provisioning. What am I missing?
Second question is whether the timing of how often provisioning job runs can be changed. It is time consuming to test when I have to wait 40 minutes between tests.
updates and deletes are handled if they are configured to. https://learn.microsoft.com/en-us/azure/active-directory/app-provisioning/configure-automatic-user-provisioning-portal#configuring-automatic-user-account-provisioning
in the screenshot, you'll see there is actions that it can target, create, update, delete. if those are all selected, As a test, you should make sure the target actions are selected and try to change a different attribute, say add some characters to a name or something. it should trigger and update to the provider.
I believe changes of the User itself will trigger the provisioning changes,
The issue here is likely because app roles are specific to applications, they are not user or group attributes, nothing has actually changed on that user object. so it wouldn't detect any changes.
as per: https://learn.microsoft.com/en-us/azure/active-directory/app-provisioning/how-provisioning-works#incremental-cycles
it will "Query the source system for any users and groups that were updated since the last watermark was stored."
if I take that literally, then changing the app role isn't a change to a user or a group, so it won't trigger a delta sync change
Deletes however should occur, if you unassign the user from the application. as per here: https://learn.microsoft.com/en-us/azure/active-directory/app-provisioning/how-provisioning-works#de-provisioning
as for your second question, the interval I don't believe you can change that for the incremental schedules.

Notification when display name of existing AD record is changed

We have several external systems that work of the Display Name value in Active Directory. When a new account in AD is created, corresponding accounts in other applications are automatically created. When someone changes the display name of an existing user, the login for that user is no longer valid in other systems.
Is there a way to get an email notification or similar whenever the display name for an existing record is changed in AD?
If you have access to your domain controllers
Active Directory has certain "audit policies" that describes what it generates events for (in the Windows Event Viewer on each domain controller). Each can be turned on or off. The "Account Management" audit policy would generate events for changes to accounts. I believe the event contains the attributes changed. You can read more about those policies here.
If that policy is enabled in your environment, and you have access to the domain controllers, you could setup scheduled tasks on each domain controller with event-based triggers that fires when event ID 4738 happens (event IDs are listed here).
The scheduled task can then run a script that can do whatever you want it to. There are instructions here on how to run a PowerShell script on an event and to get the event that triggered it in the script.
If you don't have access to your DCs
Otherwise, you would need to keep a separate database mapping a unique identifier of each account (like the objectGuid) to the display name, and have a scheduled job that updates that and notices changes. You can read here about how to search AD for accounts changed after a certain date, which you can use to only find accounts that have been changed since the last time the job ran.

How can I have 2 users logged in at the same time in a Laravel App

Please help me architect the following case in Laravel:
Every instance of the Laravel app (ex. a company) will have a single username (super-user) who can control the sub-users. The super-user will log into the app once to allow the sub-users to log in and out many times throughout the day. The sub-users won't be able to access the app at all without the super-user logging in.
Example: A POS system that the manager logs into once a day. It doesn't log itself out all throughout the day. The cashiers simply tap in their password to gain access and it auto-logs out after 5 mins. There's a single system in the store so the cashiers have to keep switching on and off. The cashier wont be able to use the POS at all if the manager does not log in.
Im new to Laravel. I know I need multiple guards but how do I access auth so that it doesn't keep directing me to the super-user? Im thinking of using the default laravel authentication for the superuser. But what about the other users?
Any help or pointers in the right direction is highly appreciated!
Thanks!
Laravel cannot persist multiple authenticated users at once but you don't necessarily need that for this system, in fact you may be able to design a more robust system without it.
Defining the problem (rather than a solution) we'd say something like, "The system must allow for a manager to enable and disable the POS for cashiers so that they are only able to access it when authorised".
A system that achieves that goal can be built with a single Laravel authentication system, using different roles (manager, cashier) and the associated permissions. This is (fortunately) very straightforward with Laravel.
The user flow would be along the lines of:
A cashier visits the POS terminal
The cashier clicks "log in"
The cashier enters their identifying details
The system finds the user, identifies that they're a cashier, then checks if cashiers are allowed to log in
If yes, the cashier is logged in and able to access the POS functionality
If no, the cashier log in is rejected with an error
The manager flow would be along the lines of:
A manager visits the POS terminal
The manager clicks "log in"
The manager enters their identifying details
The system accepts their log in and sends them to the management dashboard
The management dashboard would be where the manager could control other users (create and manage cashiers (edit, delete, audit)) and set the system status as activated for cashiers, this would be protected with policies.
At the start of business the manager would log in to the POS and activate it for cashiers by setting the "active" flag to true, then the manager would log out. Through the day any cashier could log in and use it. At the end of the day the manager would log in and deactivate the POS for cashiers.
An added benefit of this system is that you could allow managers to also be cashiers so if they needed to use the POS during the day they would not need a separate account. A users manager status could be a simple is_manager database column. You could additionally implement programmatic scheduled POS availability, i.e: "allow log in from cashiers between 9am and 5pm".
Laravel is a great choice for this project as it provides everything you need out of the box, let me know if you have any other questions about your implementation :-)

How to get a trigger when a Google app is deleted by a domain

This query is related to Google Apps. Is there a way we can get a trigger or a callback or force the user to visit a page from my app when user deletes my app from his domain?
I want to perform some operations when a user deletes the app from his domain.
Please help.
No. Mappings are completely independent of the app - they just 'point' at it. You can't get notifications when a user adds or deletes them.
The license notifications API allows you to retrieve a list of license-related events that have occurred for customers of your application. These events may be of four types:
provisions — A new license of the application has been provisioned.
expiries — A license of the application has expired.
deletions — An application has been deleted from a domain.
reassignments — An administrator has assigned or revoked a seat license for the application on the provided domain.
The license notification API allows several optional parameters:
timestamp — The time, measured in milliseconds since the UNIX epoch, to begin querying for notifications. The API will return results that occurred approximately after this time, but occasionally may return results that occurred prior to the timestamp. If you must have a list of notifications that only contains results after the timestamp, it is recommended that you apply a second filter in your code. The timestamp may not be used simultaneously with a start-token.
start-token — A continuation token, returned from a previous query, that may be used to continue retrieving notifications after the previous result set stopped. The start-token may not be used simultaneously with a timestamp.
max-results — The maximum number of notifications to return.
For a complete description of all response fields and possible values for those fields, see the reference.
For more : http://code.google.com/googleapps/marketplace/v2/developers_guide.html#license_notifications

Resources