Giter Site home page Giter Site logo

sai546488 / samples Goto Github PK

View Code? Open in Web Editor NEW

This project forked from azure-ad-b2c/samples

0.0 0.0 0.0 44.17 MB

Azure AD B2C Identity Experience Framework samples

JavaScript 7.80% Python 0.22% Java 0.16% Ruby 0.01% Objective-C 0.50% HTML 32.80% C# 36.57% CSS 1.18% ASP 0.04% PowerShell 6.30% Pascal 11.63% Puppet 2.79%

samples's Introduction

Azure Active Directory B2C: Custom CIAM User Journeys

In this repo, you will find samples for several enhanced Azure AD B2C Custom CIAM User Journeys.

Prerequisites

  • You will require to create an Azure AD B2C directory, see the guidance here.

  • To use the sample policies in this repo, follow the instructions here to setup your AAD B2C environment for Custom Policies here.

  • For any custom policy sample which makes use of Extension attributes, follow the guidance here and here. The AAD-Common Technical profile will always need to be modified to use your ApplicationId and ObjectId.

Local account policy enhancements

  • Delete my account - Demonstrate how to delete a local or social account from the directory

  • Local account change sign-in name email address - During sign-in with a local account, a user may want to change the sign-in name (email address). This sample policy demonstrates how to allow a user to provide and validate a new email address, and store the new email address to the Azure Active Directory user account. After the user changes their email address, subsequent logins require the use of the new email address.

  • Password-less sign-in with email verification - Passwordless authentication is a type of authentication where user doesn't need to sign-in with their password. This is commonly used in B2C scenarios where users use your application infrequently and tend to forget their password. This sample policy demonstrates how to allow user to sign-in, simply by providing and verifying the sign-in email address using OTP code (one time password).

  • Custom email verification - Allows you to send your own custom email verification email during sign-up or password reset user journey's. The solution requires using Azure AD B2C custom policy and a REST API endpoint that sends and verifies the TOTP.

  • Force password reset first logon - Demonstrates how to force a user to reset their password on the first logon.

  • Sign-up and sign-in with embedded password reset - This policy demostrates how to embed the password reset flow a part of the sign-up or sign-in policy without the AADB2C90118 error message.

  • Force password after 90 days - Demonstrates how to force a user to reset their password after 90 days from the last time user set their password.

  • Password reset only - This example policy prevents issuing an access token to the user after resetting their password.

  • Username discovery - This example shows how to discover a username by email address. It's useful when a user forgot their username and remembers only their email address.

  • Azure AD B2C Invitation This sample console app demonstrates how to send a sign-up email invitation. After you sent the invention, the user clicks on the Confirm account link, which opens the sign-up page (without the need to validate the email again). Use this approach when you need to create the users account by beforehand, while letting the user to choose the password on initial sign in. This approach is better than creating an account via Graph API and sending the password to the user via some communication means.

  • Email Verification at Sign In - For scenarios where you would like users to validate their email via TOTP on every sign in.

  • Google Captcha on Sign In - An example set of policies which integrate Google Captcha into the sign in journey.

  • Login with Phone Number - An example set of policies to for passwordless login via Phone Number (SMS or Phone Call).

  • Password reset without the ability to use the last password - For scenarios where you need to implement a password reset/change flow where the user cannot use their currently set password.

  • Disable and lockout an account after a time period - For scenarios where you need to prevent users logging into the application after a set number of days. The account will also be disabled at the time of the users login attempt in the case the user logs in after the time period.

  • Sign-in with email - This sample demonstrates how to sign-in to a web application by sending a sign-in link. The web application sends an email to the end user with a link to sign-in policy. When user clicks on the link, Azure AD B2C issues an access token, without prompting for a password.

  • Sign-in with a magic link - This sample demonstrates how to sign-in to a web application by sending a sign-in link.

  • Banned password list - For scenarios where you need to implement a sign up and password reset/change flow where the user cannot use a new password that is part of a banned password list. This sample does not use an API.

  • Impersonation Flow - For scenarios where you require one user to impersonate another user. This is common for support desk or delegated administration of a user in an application or service. It is recommended to always issue the token of the original authenticated user and append additional information about the targeted impersonated user as part of the auth flow

  • Sign-in with FIDO - Demonstrates how to sign-in with FIDO authenticator (as a first factor authentication.) This policy use the WebAuthn standard to register new credential and sign-in with FIDO credential.

Social account policy enhancements

  • Social identity provider force email verification - When a users signs in with a social account, in some scenarios, the identity provider doesn't share the email address. This sample demonstrates how to force the user to provide and validate an email address.

  • Dynamic identity provider selection Demonstrates how to dynamically filter the list of social identity providers rendered to the user based on application ID. In the following screenshot user can select from the list of identity providers, such as Facebook, Google+ and Amazon. With Azure AD B2C custom policies, you can configure the technical profiles to be displayed based a claim's value. The claim value contains the list of identity providers to be rendered.

  • Home Realm Discovery page - Demonstrates how to create a home realm discovery page. On the sign-in page, the user provides their sign-in email address and clicks continue. B2C checks the domain portion of the sign-in email address. If the domain name is contoso.com the user is redirected to Contoso.com Azure AD to complete the sign-in. Otherwise the user continues the sign-in with username and password. In both cases (AAD B2C local account and AAD account), the user does not need to retype the user name.

  • Sign-in with social identity provider and force email uniqueness - Demonstrates how to force a social account user to provide and validate their email address, and also checks that there is no other account with the same email address.

  • Link a local account to federated account - Demonstrates how to link a user who logged in via a federated provider to a pre-created AAD B2C Local Account.

  • Preventing logon for Social or External IdP Accounts when Disabled in AAD B2C - For scenarios where you would like to prevent logons via Social or External IdPs when the account has been disabled in Azure AD B2C.

  • Sign in with Apple as a Custom OpenID Connect identity provider - Demonstrates how to gather the correct configuration information to setup Sign in with Apple as an OpenID Connect identity provider.

Multi factor authentication enhancements

  • Edit MFA phone number - Demonstrates how to allow user to provide and validate a new MFA phone number. After the user changes their MFA phone number, on the next login, the user needs to provide the new phone number instead of the old one.

  • TOTP multi-factor authentication - Custom MFA solution, based on TOTP code. Allowing users to sign-in with Microsoft or Google authenticator apps.

  • Authy App multi-factor authentication - Custom MFA solution, based on Authy App (push notification). Allowing users to sign-in with Twilio Auth App (authenticator apps).

  • MFA with either Phone (Call/SMS) or Email verification - Allow the user to do MFA by either Phone (Call/SMS) or Email verification, with the ability to change this preference via Profile Edit.

Generic enhancements

App migration

  • Angular5 This guide shows how to migrate an exiting Angular SPA application to be protected with Azure AD B2C authentication.

samples's People

Contributors

yoelhor avatar jassuri avatar vi-nu avatar chadhasbrook avatar adamstoffel avatar jasjeetsuri avatar marcelodiiorio avatar whippsp avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.