[GH-6366] Add functionality to disable Authentication when connecting to SMTP (#6639)
* Issue #6366: Add feature to disable auth for Encrypted connections to SMTP settings. * Clean PLAIN AUTH Option * Reorder SMTP server setup and change helptext * remove unneeded setting and modify logic * text description change
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
cf32b59e64
Коммит
6f4e38d129
@@ -32,6 +32,7 @@ export default class EmailSettings extends AdminSettings {
|
||||
config.EmailSettings.FeedbackName = this.state.feedbackName;
|
||||
config.EmailSettings.FeedbackEmail = this.state.feedbackEmail;
|
||||
config.EmailSettings.FeedbackOrganization = this.state.feedbackOrganization;
|
||||
config.EmailSettings.EnableSMTPAuth = this.state.enableSMTPAuth;
|
||||
config.EmailSettings.SMTPUsername = this.state.smtpUsername;
|
||||
config.EmailSettings.SMTPPassword = this.state.smtpPassword;
|
||||
config.EmailSettings.SMTPServer = this.state.smtpServer;
|
||||
@@ -56,6 +57,7 @@ export default class EmailSettings extends AdminSettings {
|
||||
feedbackName: config.EmailSettings.FeedbackName,
|
||||
feedbackEmail: config.EmailSettings.FeedbackEmail,
|
||||
feedbackOrganization: config.EmailSettings.FeedbackOrganization,
|
||||
enableSMTPAuth: config.EmailSettings.EnableSMTPAuth,
|
||||
smtpUsername: config.EmailSettings.SMTPUsername,
|
||||
smtpPassword: config.EmailSettings.SMTPPassword,
|
||||
smtpServer: config.EmailSettings.SMTPServer,
|
||||
@@ -201,44 +203,6 @@ export default class EmailSettings extends AdminSettings {
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications}
|
||||
/>
|
||||
<TextSetting
|
||||
id='smtpUsername'
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpUsernameTitle'
|
||||
defaultMessage='SMTP Server Username:'
|
||||
/>
|
||||
}
|
||||
placeholder={Utils.localizeMessage('admin.email.smtpUsernameExample', 'Ex: "admin@yourcompany.com", "AKIADTOVBGERKLCBV"')}
|
||||
helpText={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpUsernameDescription'
|
||||
defaultMessage=' Obtain this credential from administrator setting up your email server.'
|
||||
/>
|
||||
}
|
||||
value={this.state.smtpUsername}
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications}
|
||||
/>
|
||||
<TextSetting
|
||||
id='smtpPassword'
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpPasswordTitle'
|
||||
defaultMessage='SMTP Server Password:'
|
||||
/>
|
||||
}
|
||||
placeholder={Utils.localizeMessage('admin.email.smtpPasswordExample', 'Ex: "yourpassword", "jcuS8PuvcpGhpgHhlcpT1Mx42pnqMxQY"')}
|
||||
helpText={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpPasswordDescription'
|
||||
defaultMessage=' Obtain this credential from administrator setting up your email server.'
|
||||
/>
|
||||
}
|
||||
value={this.state.smtpPassword}
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications}
|
||||
/>
|
||||
<TextSetting
|
||||
id='smtpServer'
|
||||
label={
|
||||
@@ -277,6 +241,63 @@ export default class EmailSettings extends AdminSettings {
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications}
|
||||
/>
|
||||
<BooleanSetting
|
||||
id='enableSMTPAuth'
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.email.enableSMTPAuthTitle'
|
||||
defaultMessage='Enable SMTP Authentication: '
|
||||
/>
|
||||
}
|
||||
helpText={[
|
||||
<FormattedHTMLMessage
|
||||
key='admin.email.enableSMTPAuthDesc'
|
||||
id='admin.email.enableSMTPAuthDesc'
|
||||
defaultMessage='When true, SMTP Authentication is enabled.'
|
||||
/>
|
||||
]}
|
||||
value={this.state.enableSMTPAuth}
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications}
|
||||
/>
|
||||
<TextSetting
|
||||
id='smtpUsername'
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpUsernameTitle'
|
||||
defaultMessage='SMTP Server Username:'
|
||||
/>
|
||||
}
|
||||
placeholder={Utils.localizeMessage('admin.email.smtpUsernameExample', 'Ex: "admin@yourcompany.com", "AKIADTOVBGERKLCBV"')}
|
||||
helpText={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpUsernameDescription'
|
||||
defaultMessage=' Obtain this credential from administrator setting up your email server.'
|
||||
/>
|
||||
}
|
||||
value={this.state.smtpUsername}
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications || !this.state.enableSMTPAuth}
|
||||
/>
|
||||
<TextSetting
|
||||
id='smtpPassword'
|
||||
label={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpPasswordTitle'
|
||||
defaultMessage='SMTP Server Password:'
|
||||
/>
|
||||
}
|
||||
placeholder={Utils.localizeMessage('admin.email.smtpPasswordExample', 'Ex: "yourpassword", "jcuS8PuvcpGhpgHhlcpT1Mx42pnqMxQY"')}
|
||||
helpText={
|
||||
<FormattedMessage
|
||||
id='admin.email.smtpPasswordDescription'
|
||||
defaultMessage=' Obtain this credential from administrator setting up your email server.'
|
||||
/>
|
||||
}
|
||||
value={this.state.smtpPassword}
|
||||
onChange={this.handleChange}
|
||||
disabled={!this.state.sendEmailNotifications || !this.state.enableSMTPAuth}
|
||||
/>
|
||||
<ConnectionSecurityDropdownSettingEmail
|
||||
value={this.state.connectionSecurity}
|
||||
onChange={this.handleChange}
|
||||
|
||||
Ссылка в новой задаче
Block a user