1. 設定例

認証設定の例

Version:
日本語翻訳に関する免責事項

このページの翻訳はAIによって自動的に行われました。可能な限り正確な翻訳を心掛けていますが、原文と異なる表現や解釈が含まれる場合があります。正確で公式な情報については、必ず英語の原文をご参照ください。

次のコード スニペットは、Authentication 設定の構造を示しています。

警告

次の設定は、例としてのみ参照してください。値は既定値を表すものではありません。既定値を確認するには、「プロパティ」を参照してください。 ログイン画面の messages 設定に指定する翻訳キーは、T_ プレフィックスなしで指定する必要があります。たとえば、"signIn": "T_translationKey""signIn": "translationKey" にする必要があります。

次に例を示します。

{
"AttemptsBeforeLockout": 5,
"AutoCreateUsers": true,
"AutoRestrict": true,
"CookieDomain": "marketingcontenthub.com",
"CookieName": "authCookie",
"DefaultUserGroups": [
"usergroup1",
"usergroup2",
"usergroup3"
],
"EnableBasicAuthentication": true,
"EnableConfirmationMail": true,
"EnableCredentialless": true,
"EnableEmailWhiteList": true,
"EnableExternalAuthentication": false,
"EnableForgotPassword": false,
"EnableLockout": true,
"EnableRegister": false,
"ExpireTimeSpan": 30,
"ExternalAuthenticationProviders": {
"global_email_claim_type": "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress",
"global_username_claim_type": "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name",
"google": [
{
"authentication_mode": "Passive",
"client_id": "<ClientId>",
"client_secret": "<ClientSecret>",
"email_claim_type": "<ClaimTypeOverride>",
"external_user_creation_url": "https://www.registerme.com",
"is_enabled": true,
"messages": {
"signIn": "translationKey",
"signInDescription": "translationKey",
"signInTitle": "translationKey"
},
"provider_name": "Google",
"username_claim_type": "<ClaimTypeOverride>"
}
],
"microsoft": [
{
"authentication_mode": "Passive",
"client_id": "<ClientId>",
"client_secret": "<ClientSecret>",
"email_claim_type": "<ClaimTypeOverride>",
"external_user_creation_url": "https://www.registerme.com",
"is_enabled": true,
"messages": {
"signIn": "translationKey",
"signInDescription": "translationKey",
"signInTitle": "translationKey"
},
"provider_name": "Microsoft",
"username_claim_type": "<ClaimTypeOverride>"
}
],
"saml": [
{
"authentication_mode": "Passive",
"certificate": "<Certificate>",
"email_claim_type": "<ClaimTypeOverride>",
"external_user_creation_url": "https://www.registerme.com",
"idp_entity_id": "<Id>",
"is_enabled": true,
"messages": {
"signIn": "translationKey",
"signInDescription": "translationKey",
"signInTitle": "translationKey"
},
"metadata_location": "<Url>",
"module_path": "<ModulePath>",
"password": "<Password>",
"provider_name": "SAML",
"sp_entity_id": "<Id>",
"username_claim_type": "<ClaimTypeOverride>"
}
],
"sitecore": [
{
"authentication_mode": "Passive",
"client_id": "<ClientId>",
"client_secret": "<ClientSecret>",
"email_claim_type": "<ClaimTypeOverride>",
"external_user_creation_url": "https://www.registerme.com",
"identity_server_url": "<Url>",
"is_enabled": true,
"messages": {
"signIn": "translationKey",
"signInDescription": "translationKey",
"signInTitle": "translationKey"
},
"provider_name": "Sitecore,",
"username_claim_type": "<ClaimTypeOverride>"
}
],
"ws_federation": [
{
"authentication_mode": "Passive",
"email_claim_type": "<ClaimTypeOverride>",
"external_user_creation_url": "https://www.registerme.com",
"is_enabled": true,
"messages": {
"signIn": "translationKey",
"signInDescription": "translationKey",
"signInTitle": "translationKey"
},
"metadata_address": "<Url>",
"provider_name": "WsFederation",
"username_claim_type": "<ClaimTypeOverride>",
"wtrealm": "<Realm>"
}
],
"yandex": [
{
"authentication_mode": "Passive",
"client_id": "<ClientId>",
"client_secret": "<ClientSecret>",
"email_claim_type": "<ClaimTypeOverride>",
"external_user_creation_url": "https://www.registerme.com",
"is_enabled": true,
"messages": {
"signIn": "translationKey",
"signInDescription": "translationKey",
"signInTitle": "translationKey"
},
"provider_name": "Yandex,",
"username_claim_type": "<ClaimTypeOverride>"
}
]
},
"MinutesToLockout": 5,
"PasswordExpiration": 129600,
"PasswordRules": {
"RequireDigit": false,
"RequireLowercase": false,
"RequireNonLetterOrDigit": false,
"RequireUppercase": false,
"RequiredLength": 8
},
"PostSignOutRedirectUrl": "/en-us/account",
"ReCaptcha": {
"Key": "<Key>",
"Secret": "<Secret>"
},
"RegistrationLink": "https://www.registerme.com",
"ShowForgotPassword": false,
"ShowRegister": false,
"SlidingExpiration": true,
"TokenLifespan": 1440,
"WhiteListedEmailPatterns": [
"[a-zA-Z0-9._%+-][email protected]",
"[a-zA-Z0-9._%+-][email protected]"
]
}
この記事を改善するための提案がある場合は、 お知らせください!