Skip to content

Trust what an identity provider says

When a person signs in through an identity provider your organization runs, such as Microsoft Entra ID, Okta, or Google Workspace, Authwise checks the provider’s signature. That proves the provider sent the response. It doesn’t prove what the response says: that the person used a second factor, or that the email address is theirs.

By default, Authwise counts none of those statements. A sign-in through the provider counts as one factor, and its email address is kept as stated, not verified. Four settings on the provider change that, each for that provider alone. This page explains what each one does, what turning it on costs, and how to set them for Microsoft Entra ID over SAML.

  • Identity server 1.98.0 or later, awctl 0.48.0 or later, and Terraform provider 0.38.0 or later, for a SAML provider and for Trusted email domains on any provider. See Earlier versions.
  • A tenant administrator seat, or a service account holding tenant.admin.
  • A federated provider on a realm: SAML, OpenID Connect, or one of the named types such as Microsoft or Google. See Sign in through a SAML identity provider. The settings don’t apply to the password, magic link, and passkey providers, where Authwise checks the evidence itself.

In the console, open the realm, go to Providers, open the provider, and under Advanced open Trust in the upstream.

ConsoleAPI, awctl, and TerraformWhat it doesDefault
Trust the upstream’s authentication methodstrust_upstream_amrThe provider’s statement of how the person signed in counts toward the realm’s authentication rule.Off
Upstream level mappingupstream_acr_mapMaps a statement the provider makes to one of the realm’s assurance levels. Read only while the methods are trusted.Empty
Trusted email domainstrusted_email_domainsThe email domains the provider is the directory of record for.Empty
Count the upstream’s email as verifiedtrust_upstream_email_verifiedAn address the provider states verified becomes a verified address of the account.Off
Offer to connect an existing account by verified emaillink_by_verified_emailAt a first sign-in, offers to connect the provider to an existing account that holds the same address.Off

Turn on Trust the upstream’s authentication methods when the realm’s authentication rules ask for a second factor and the provider already enforces one. Without it, a person who completed multifactor authentication at the provider is asked for a second factor again in Authwise.

With the setting on, Authwise reads two things:

  • The provider’s amr values. mfa counts as two factors, and hwk and swk count as phishing-resistant.
  • The entries of Upstream level mapping. Each entry maps something the provider says to the name of one of the realm’s assurance levels, such as urn:authwise:acr:2. A matching entry counts as that level met.

A mapping key takes one of two forms. Both match exactly, including case.

KeyMatches
A bare value, such as urn:oasis:names:tc:SAML:2.0:ac:classes:TimeSyncTokenThe ID token’s acr on OpenID Connect, or the assertion’s AuthnContextClassRef on SAML.
attribute:NAME=VALUEA SAML attribute or an ID token claim named NAME that carries VALUE among its values. The name runs to the first =.

When several entries match, the strongest level counts. A key that is empty or malformed, or an entry with no level, is refused when you save.

What it costs. Authwise can’t check the statement. A provider that says mfa without enforcing it satisfies the realm’s rule. Turn the setting on only for a provider whose multifactor policy you rely on.

The amr claim in the tokens Authwise issues relays what the provider said whether the setting is on or off. The setting decides only whether the statement counts toward the realm’s rule and the token’s acr.

Count the provider’s email addresses as verified

Section titled “Count the provider’s email addresses as verified”

An OpenID Connect provider says an address is verified with the email_verified claim. A SAML assertion has no way to say it. Trusted email domains closes that gap: on a SAML provider, an address counts as stated verified when its domain is in the list, and no other address does.

List only the domains the directory owns. A directory also holds accounts whose addresses belong to someone else, such as guest accounts in a Microsoft Entra ID tenant, and the list is what keeps those out.

  • Each entry is a lowercase domain name with at least two labels, such as contoso.com.
  • An address matches when its domain equals an entry. contoso.com doesn’t cover eu.contoso.com; list each domain.
  • A wildcard, an @, upper case, a trailing dot, or a repeated entry is refused when you save.

On a SAML provider, Count the upstream’s email as verified and Offer to connect an existing account by verified email each need at least one listed domain, and the console keeps them off until one is listed. On the other federated types the list is optional: when set, the provider’s email_verified counts only for addresses in those domains.

The two settings read the same statement and are independent. Neither needs the other.

With the setting on, each sign-in that states the address verified records it as a verified address of the account. The tokens then carry email_verified: true, and the person isn’t asked to prove the address again.

What it costs. A verified address is a recovery route. Whoever controls that address at the provider can recover the account, and sign in to it where the realm offers a magic link. Turn it on only for the directory of record for its people’s addresses, such as your workforce identity provider. Don’t turn it on for a social provider or for a partner’s directory.

Offer to connect an existing account by verified email

Section titled “Offer to connect an existing account by verified email”

With the setting on, a first sign-in through the provider checks whether exactly one active account in the realm holds the same address as verified and has a password. If so, Authwise offers to connect the two. The person signs in to the existing account with its password first. Nothing is connected without that step.

With the setting off, a first sign-in is treated as a new person, even when the address matches an existing account.

What it costs. It trusts the provider’s statement that the person controls the address. A provider that marks addresses verified without proving them lets someone start the offer for an account that isn’t theirs, though they still need its password.

Microsoft Entra ID doesn’t state multifactor authentication in the assertion’s AuthnContextClassRef, which stays urn:oasis:names:tc:SAML:2.0:ac:classes:Password after a multifactor sign-in. It states it as a value of the attribute http://schemas.microsoft.com/claims/authnmethodsreferences. The mapping key is the attribute: form with that name and the value http://schemas.microsoft.com/claims/multipleauthn.

In the console, on the provider’s Trust in the upstream row:

  1. Turn on Trust the upstream’s authentication methods.
  2. Under Upstream level mapping, click Add the Entra ID MFA key, and in the value enter the realm’s two-factor level, such as urn:authwise:acr:2.
  3. Under Trusted email domains, click Add a domain and enter each domain your Entra tenant owns, such as contoso.com.
  4. Turn on Count the upstream’s email as verified, Offer to connect an existing account by verified email, or both, as you need.
  5. Click Save.

With awctl, in the realm’s context:

Terminal window
awctl identity providers update PROVIDER_ID \
--trust-upstream-amr \
--upstream-acr-map 'attribute:http://schemas.microsoft.com/claims/authnmethodsreferences=http://schemas.microsoft.com/claims/multipleauthn=urn:authwise:acr:2' \
--trusted-email-domains contoso.com \
--trust-upstream-email-verified
awctl identity providers describe PROVIDER_ID --yaml
Updated tenants/t-g3wq78hbfjls/realms/r-g50tkucfpjxo/providers/p-g50tmbajq3p2
display_name: Contoso Entra ID
labels: {}
link_by_verified_email: false
name: tenants/t-g3wq78hbfjls/realms/r-g50tkucfpjxo/providers/p-g50tmbajq3p2
provider_type: saml
status: active
trust_upstream_amr: true
trust_upstream_email_verified: true
trusted_email_domains:
- contoso.com
upstream_acr_map:
attribute:http://schemas.microsoft.com/claims/authnmethodsreferences=http://schemas.microsoft.com/claims/multipleauthn: urn:authwise:acr:2

Replace PROVIDER_ID with the provider’s ID (p-…). awctl splits each mapping pair on its last =, so the level name follows the final =.

With Terraform:

resource "authwise_provider" "entra" {
realm_id = authwise_realm.employees.realm_id
display_name = "Sign in with Entra ID"
provider_type = "saml"
config = data.authwise_provider_saml.entra.any
trust_upstream_amr = true
upstream_acr_map = {
"attribute:http://schemas.microsoft.com/claims/authnmethodsreferences=http://schemas.microsoft.com/claims/multipleauthn" = "urn:authwise:acr:2"
}
trusted_email_domains = ["contoso.com"]
trust_upstream_email_verified = true
}

Terraform checks these settings at plan: an email setting on a saml provider without trusted_email_domains, a malformed domain, or a malformed mapping key fails terraform plan.

  1. Sign in through the provider with an account that completes multifactor authentication there.

    Authwise doesn’t ask for a second factor. The tokens carry the level the sign-in met in acr, such as urn:authwise:acr:2, and, with Count the upstream’s email as verified on and the address in a listed domain, email_verified: true.

  2. In the console, open the tenant’s Events and find the sign-in.

    When the provider’s statement counted, the authn.login event records upstream_amr_trusted, and upstream_acr_level with the level a mapping entry met.

If Authwise still asks for a second factor, the provider’s statement didn’t match. Check that the person completed multifactor authentication at the provider in that sign-in, and that the mapping key matches the attribute name and value exactly.

Through identity server 1.97, the settings behave differently:

  • On a SAML provider, none of the four settings has an effect. A SAML sign-in counts as one factor, and no address from an assertion is verified.
  • Upstream level mapping is stored and read by nothing, on every provider type.
  • Trusted email domains doesn’t exist. awctl and the Terraform provider refuse to set it on an identity server that can’t store it.

A SAML provider that already has an email setting on and no listed domain keeps signing people in after the upgrade to 1.98.0, stating no address verified. The identity server refuses it the next time the provider is saved. List the domains, or turn the setting off.