Просмотр исходного кода

Merge pull request #27276 from overleaf/ii-domain-capture-anaylze-saml-response

[web] Domain capture analyze saml response

GitOrigin-RevId: 5a970968bdf14ab6f52d883a390d420b00cb4d8d
ilkin-overleaf 1 год назад
Родитель
Сommit
1c5ed10bbb

+ 1 - 1
services/web/app/src/models/SSOConfig.js

@@ -6,12 +6,12 @@ const SSOConfigSchema = new Schema(
     entryPoint: { type: String, required: true },
     certificates: { type: Array, default: [''], required: true },
     userIdAttribute: { type: String, required: true },
+    userEmailAttribute: { type: String },
     userFirstNameAttribute: { type: String },
     userLastNameAttribute: { type: String },
     validated: { type: Boolean, default: false },
     enabled: { type: Boolean, default: false },
     useSettingsUKAMF: { type: Boolean, default: false },
-    emailAttribute: { type: String },
   },
 
   {

+ 1 - 0
services/web/frontend/extracted-translations.json

@@ -1646,6 +1646,7 @@
   "sso_error_idp_error": "",
   "sso_error_invalid_external_user_id": "",
   "sso_error_invalid_signature": "",
+  "sso_error_missing_email_attribute": "",
   "sso_error_missing_external_user_id": "",
   "sso_error_missing_firstname_attribute": "",
   "sso_error_missing_lastname_attribute": "",

+ 1 - 0
services/web/locales/en.json

@@ -2128,6 +2128,7 @@
   "sso_error_idp_error": "Your identity provider responded with an error.",
   "sso_error_invalid_external_user_id": "The SAML attribute provided by your IdP that uniquely identifies your user has an invalid format, a string is expected. Attribute: <0>__expecting__</0>",
   "sso_error_invalid_signature": "Sorry, the information received from your identity provider has an invalid signature.",
+  "sso_error_missing_email_attribute": "The SAML attribute that specifies the user’s email is either missing or under a different name than the one you configured. Expecting: <0>__expecting__</0>",
   "sso_error_missing_external_user_id": "The SAML attribute provided by your IdP that uniquely identifies your user is either missing or under a different name than the one you configured. Expecting: <0>__expecting__</0>",
   "sso_error_missing_firstname_attribute": "The SAML attribute that specifies the user’s first name is either missing or under a different name than the one you configured. Expecting: <0>__expecting__</0>",
   "sso_error_missing_lastname_attribute": "The SAML attribute that specifies the user’s last name is either missing or under a different name than the one you configured. Expecting: <0>__expecting__</0>",

+ 1 - 1
services/web/types/subscription/sso.ts

@@ -9,12 +9,12 @@ export type SSOConfig = {
   entryPoint?: string
   certificates: Certificate[]
   userIdAttribute?: string
+  userEmailAttribute?: string
   userFirstNameAttribute?: string
   userLastNameAttribute?: string
   validated?: boolean
   enabled?: boolean
   useSettingsUKAMF?: boolean
-  emailAttribute?: string
 }
 
 export type GroupSSOLinkingStatus = {