Skip to main content
Version: Current (v17+)

uSync.PeopleEdition

uSync.PeopleEdition adds four new handlers & serializers to uSync to manage users and member syncing between environments.

These manage:

  • Users
  • User Groups
  • Members
  • Member Groups

Dashboard​

The People Edition dashboard is now integrated into the main uSync dashboard with the Users and Members options.

tip

As of uSync v13, the user/members are now disabled by default in the uSync dashboard (but will still work in exporter). They can be turned back on via a config change in appsettings.json file.

For example:

"uSync": {
"People": {
"EnabledDefault": true
},
}

Syncing Passwords​

Passwords are stored in Umbraco in a non-reversible hash. When uSync exports these for members and users they will be stored in the .config files for those accounts.

When these values are imported to another Umbraco instance that instance has to use the same machine key values to hash passwords or they will not match when users attempt to login.

As a result you should ensure that any Umbraco instances where you wish to sync members should have the same machineKey value in their web.config files.

note

uSync.PeopleEdition will not sync the main Umbraco Admin Account. This is to stop you losing access to your Umbraco installation.

API Users​

Umbraco has two kinds of user: ordinary backoffice users, and API users that sign in with client credentials, such as client ID and secret, rather than a password.

uSync.PeopleEdition records the kind of user in the export, so an API user is created as an API user when it is imported. A user created on import also keeps the key from the source site, so anything that refers to the account by key (for example, an Umbraco Automate workspace) still finds it.

tip

Umbraco only stores a user's kind when the user is created. If a user already exists on the target site as an ordinary user, importing it won't change it into an API user. Delete the user on the target site and import it again to maintain the settings from the source site.

Syncing Client Credentials​

An API user's client credentials can be synced too. Like passwords, client secrets are stored as a non-reversible hash, and it is the hash that goes in the user's .config file. The hash doesn't depend on the site, so the original secret will keep working on the site the user is imported to.

Client credentials are not synced by default. To turn them on for every set on the site (the default set, Publisher and Exporter), add this setting to appsettings.json:

"uSync": {
"People": {
"IncludeClientCredentials": true
}
}

To turn them on (or off) for a single set, add the setting to the UserHandler in that set. A handler setting takes precedence over the site-wide one:

"uSync": {
"Sets": {
"Default": {
"Handlers": {
"UserHandler": {
"Settings": {
"IncludeClientCredentials": "true"
}
}
}
}
}
}

When credentials are included, an import makes the user's credentials on the target site match the file: client IDs that are missing are added, changed secrets are updated, and client IDs that aren't in the file are removed. If a client ID already belongs to a different user on the target site, the import reports an error for that user.

Synced Access

With client credentials synced, the same client ID and secret work on every site the user is synced to. A client that can get a token on your staging site will also be able to get one on the live site.