Skip to content
This repository has been archived by the owner on May 17, 2024. It is now read-only.

Generate password with Bulk Create option #24

Open
Bgany opened this issue Dec 27, 2021 · 1 comment
Open

Generate password with Bulk Create option #24

Bgany opened this issue Dec 27, 2021 · 1 comment

Comments

@Bgany
Copy link

Bgany commented Dec 27, 2021

Hi,

I am using the code in this project to bulk create users in Azure B2C and let this run everyday.

This works perfect but right now I put the password in plain text in the users.json file that is the source for the input. I would like to change this and let the code generate a password (different one for every user).

I also found that there is a passwordHelper.cs file that is used for single user creation. How do I change the code (in either the project code or the users.json file) so that the Bulk Create option also uses this feature to generate a password.

Currently my users.json file looks like this:

{ "users": [ { "extension_***********_TestId": "12345678.1", "displayName": "Test 1234", "givenName": "Test", "surname": "1234", "identities": [{ "signInType": "emailAddress", "issuerAssignedId": "test.1234@test.com" }], "Password": "Test1234" }] }

@melkorCBA
Copy link

This makes sense. Currently "bulk create" uses's the given password for each user from the file JSON file.

This is a useful feature to have especially when migrating users between tenants where importing users won't retrieve any passwords. So in that case it'll be good to have some kind of flag to perform password generation.

I'd like to try implementing this feature as my first contribution to the project.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants