Skip to content

How to configure if we have multiple SignIn Policy? #17

@ashishmundrajll

Description

@ashishmundrajll

We see that initialize is called in index.js which forms UserAgentApplication using signInPolicy.

We have different signinPolicy per user domain, so if user is from xyz organization with email ashish@xyz.com then we want them to go through b2c_1_xyzsigninpolicy and if user is from abc organization with email ashish@abc.com then we want them to go through b2c_1_abcsigninpolicy.

We have not used one policy as we do not want to show "SignIn to ABC" and "SignIn to XYZ" buttons on B2C Custom login UI.

Instead, what we want to do is have a Login UI in our App which will have only Email TextBox. When user will enter ashish@xyz.com then based on email domain, we want them to redirect to xyzsigninpolicy login screen.

How can we dynamically change the Authority in this codebase? When redirectUrl will be sent back from this policy, will the code in index.js execute again?

Also, we are using scheme instead of wrapping show App in authentication HOC as we want to allow /login /logout /404 /403 and /home page to be accessed without authentication.

Please advise if this is possible using this library. Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions