From 7a219e17106d8df90ca0a95f8cb3d6cbec991b5c Mon Sep 17 00:00:00 2001 From: BaiJiangjie Date: Fri, 20 Apr 2018 11:23:31 +0800 Subject: [PATCH] =?UTF-8?q?[Update]=20OTP=E6=96=87=E6=A1=88=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E4=B8=BAMFA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../_asset_group_bulk_update_modal.html | 2 +- apps/i18n/zh/LC_MESSAGES/django.mo | Bin 31742 -> 31755 bytes apps/i18n/zh/LC_MESSAGES/django.po | 105 +++++++++--------- apps/users/forms.py | 2 +- apps/users/templates/users/_base_otp.html | 2 +- apps/users/templates/users/login_otp.html | 2 +- apps/users/templates/users/user_detail.html | 6 +- apps/users/templates/users/user_profile.html | 27 ++--- apps/users/views/login.py | 2 +- apps/users/views/user.py | 12 +- 10 files changed, 80 insertions(+), 80 deletions(-) diff --git a/apps/assets/templates/assets/_asset_group_bulk_update_modal.html b/apps/assets/templates/assets/_asset_group_bulk_update_modal.html index 0e76ff923..61ac04fa6 100644 --- a/apps/assets/templates/assets/_asset_group_bulk_update_modal.html +++ b/apps/assets/templates/assets/_asset_group_bulk_update_modal.html @@ -31,7 +31,7 @@
- +
diff --git a/apps/i18n/zh/LC_MESSAGES/django.mo b/apps/i18n/zh/LC_MESSAGES/django.mo index 19dcb5e7a0e0021ed5ac8ad0dfe0acd5f461acfd..535471a1cd132a830a27b0ef5edbc686f4e6cf77 100644 GIT binary patch delta 8841 zcmZYD4Sde^{>Sm(#l~hcx3gH-%*^Jl5stAkbGMA#cjR`qVZ$5@Bb}>A89BwzQ94JI zyXb_BkQ~Rtp_EiekxCej#BsAq&j0nkexDwX9*_U^czk<)KcDaY_xHQ5Ip^LT-@ zume)Vz@wgJz?*MAT6R4A(L2c*~>Rq~q zI=~&&e3d(UHyMq(sdx-yeJ6>EPSg(7kdC_Yo~RS`N9Bj2PC5#;(0J6#H5s*`xmXXE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33KjGnjgxHB^y5|-n((DZ}Nh`{{fgPec1p2 diff --git a/apps/i18n/zh/LC_MESSAGES/django.po b/apps/i18n/zh/LC_MESSAGES/django.po index c8de1947a..41f83403a 100644 --- a/apps/i18n/zh/LC_MESSAGES/django.po +++ b/apps/i18n/zh/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Jumpserver 0.3.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-19 17:48+0800\n" +"POT-Creation-Date: 2018-04-20 11:17+0800\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: ibuler \n" "Language-Team: Jumpserver team\n" @@ -346,7 +346,7 @@ msgstr "创建日期" #: users/models/user.py:52 users/templates/users/user_detail.html:119 #: users/templates/users/user_group_detail.html:67 #: users/templates/users/user_group_list.html:14 -#: users/templates/users/user_profile.html:122 +#: users/templates/users/user_profile.html:123 msgid "Comment" msgstr "备注" @@ -561,8 +561,9 @@ msgid "Select System Users" msgstr "选择系统用户" #: assets/templates/assets/_asset_group_bulk_update_modal.html:34 -msgid "Enable-OTP" -msgstr "二次验证" +#, fuzzy +msgid "Enable-MFA" +msgstr "启用MFA" #: assets/templates/assets/_asset_import_modal.html:4 msgid "Import asset" @@ -639,7 +640,7 @@ msgstr "其它" #: users/templates/users/_user.html:43 #: users/templates/users/user_bulk_update.html:23 #: users/templates/users/user_password_update.html:58 -#: users/templates/users/user_profile.html:180 +#: users/templates/users/user_profile.html:181 #: users/templates/users/user_profile_update.html:63 #: users/templates/users/user_pubkey_update.html:70 #: users/templates/users/user_pubkey_update.html:76 @@ -745,8 +746,8 @@ msgstr "测试" #: users/templates/users/user_group_detail.html:28 #: users/templates/users/user_group_list.html:43 #: users/templates/users/user_list.html:76 -#: users/templates/users/user_profile.html:143 -#: users/templates/users/user_profile.html:172 +#: users/templates/users/user_profile.html:144 +#: users/templates/users/user_profile.html:173 msgid "Update" msgstr "更新" @@ -794,7 +795,7 @@ msgstr "选择节点" #: users/templates/users/user_group_create_update.html:32 #: users/templates/users/user_group_list.html:86 #: users/templates/users/user_list.html:196 -#: users/templates/users/user_profile.html:214 +#: users/templates/users/user_profile.html:215 msgid "Confirm" msgstr "确认" @@ -845,14 +846,14 @@ msgstr "硬盘" #: assets/templates/assets/asset_detail.html:121 #: users/templates/users/user_detail.html:111 -#: users/templates/users/user_profile.html:96 +#: users/templates/users/user_profile.html:97 msgid "Date joined" msgstr "创建日期" #: assets/templates/assets/asset_detail.html:137 #: terminal/templates/terminal/session_detail.html:81 #: users/templates/users/user_detail.html:130 -#: users/templates/users/user_profile.html:134 +#: users/templates/users/user_profile.html:135 msgid "Quick modify" msgstr "快速修改" @@ -1730,7 +1731,7 @@ msgstr "" #: perms/models.py:27 perms/models.py:71 #: perms/templates/perms/asset_permission_detail.html:90 #: users/models/user.py:54 users/templates/users/user_detail.html:103 -#: users/templates/users/user_profile.html:104 +#: users/templates/users/user_profile.html:105 msgid "Date expired" msgstr "失效日期" @@ -2229,7 +2230,7 @@ msgid "Invalid token or cache refreshed." msgstr "" #: users/forms.py:30 -msgid "Otp_code" +msgid "MFA_code" msgstr "" #: users/forms.py:39 users/models/user.py:43 @@ -2290,7 +2291,7 @@ msgstr "复制你的公钥到这里" #: users/forms.py:181 users/models/user.py:51 #: users/templates/users/user_password_update.html:43 -#: users/templates/users/user_profile.html:79 +#: users/templates/users/user_profile.html:68 #: users/templates/users/user_profile_update.html:43 #: users/templates/users/user_pubkey_update.html:43 msgid "Public key" @@ -2328,18 +2329,18 @@ msgstr "管理员" msgid "Application" msgstr "应用程序" -#: users/models/user.py:34 users/templates/users/user_profile.html:74 -#: users/templates/users/user_profile.html:155 -#: users/templates/users/user_profile.html:158 +#: users/models/user.py:34 users/templates/users/user_profile.html:92 +#: users/templates/users/user_profile.html:156 +#: users/templates/users/user_profile.html:159 msgid "Disable" msgstr "禁用" -#: users/models/user.py:35 users/templates/users/user_profile.html:72 -#: users/templates/users/user_profile.html:162 +#: users/models/user.py:35 users/templates/users/user_profile.html:90 +#: users/templates/users/user_profile.html:163 msgid "Enable" msgstr "启用" -#: users/models/user.py:36 users/templates/users/user_profile.html:70 +#: users/models/user.py:36 users/templates/users/user_profile.html:88 msgid "Force enable" msgstr "强制启用" @@ -2356,7 +2357,7 @@ msgstr "头像" msgid "Wechat" msgstr "微信" -#: users/models/user.py:47 users/templates/users/user_detail.html:91 +#: users/models/user.py:47 msgid "Enable OTP" msgstr "二次验证" @@ -2457,8 +2458,10 @@ msgid "City" msgstr "城市" #: users/templates/users/login_otp.html:45 -msgid "二次认证" -msgstr "" +#: users/templates/users/user_detail.html:91 +#: users/templates/users/user_profile.html:85 +msgid "MFA certification" +msgstr "MFA认证" #: users/templates/users/login_otp.html:64 #: users/templates/users/user_otp_authentication.html:19 @@ -2468,7 +2471,7 @@ msgstr "6位数字" #: users/templates/users/login_otp.html:69 msgid "Can't provide security? Please contact the administrator!" -msgstr "如果不能提供OTP验证码,请联系管理员!" +msgstr "如果不能提供MFA验证码,请联系管理员!" #: users/templates/users/reset_password.html:45 #: users/templates/users/user_detail.html:348 users/utils.py:73 @@ -2514,13 +2517,13 @@ msgid "Disabled" msgstr "禁用" #: users/templates/users/user_detail.html:115 -#: users/templates/users/user_profile.html:100 +#: users/templates/users/user_profile.html:101 msgid "Last login" msgstr "最后登录" #: users/templates/users/user_detail.html:151 -msgid "Force enabled OTP" -msgstr "强制启用OTP" +msgid "Force enabled MFA" +msgstr "强制启用MFA" #: users/templates/users/user_detail.html:166 msgid "Send reset password mail" @@ -2536,8 +2539,8 @@ msgid "Send reset ssh key mail" msgstr "发送重置密钥邮件" #: users/templates/users/user_detail.html:291 -msgid "Goto profile page enable otp" -msgstr "请去个人信息页面启用自己的OTP" +msgid "Goto profile page enable MFA" +msgstr "请去个人信息页面启用自己的MFA" #: users/templates/users/user_detail.html:347 msgid "An e-mail has been sent to the user`s mailbox." @@ -2562,14 +2565,14 @@ msgid "This will reset the user public key and send a reset mail" msgstr "将会失效用户当前密钥,并发送重置邮件到用户邮箱" #: users/templates/users/user_detail.html:400 -#: users/templates/users/user_profile.html:203 +#: users/templates/users/user_profile.html:204 msgid "Successfully updated the SSH public key." msgstr "更新ssh密钥成功" #: users/templates/users/user_detail.html:401 #: users/templates/users/user_detail.html:405 -#: users/templates/users/user_profile.html:204 -#: users/templates/users/user_profile.html:209 +#: users/templates/users/user_profile.html:205 +#: users/templates/users/user_profile.html:210 msgid "User SSH public key update" msgstr "ssh密钥" @@ -2625,32 +2628,28 @@ msgstr "删除" msgid "User Deleting failed." msgstr "用户删除失败" -#: users/templates/users/user_profile.html:67 -msgid "OTP" -msgstr "" - -#: users/templates/users/user_profile.html:108 users/views/user.py:185 +#: users/templates/users/user_profile.html:109 users/views/user.py:185 #: users/views/user.py:239 msgid "User groups" msgstr "用户组" -#: users/templates/users/user_profile.html:140 +#: users/templates/users/user_profile.html:141 msgid "Update password" msgstr "更改密码" -#: users/templates/users/user_profile.html:148 -msgid "Update otp" -msgstr "更改OTP设置" +#: users/templates/users/user_profile.html:149 +msgid "Update MFA settings" +msgstr "更改MFA设置" -#: users/templates/users/user_profile.html:169 +#: users/templates/users/user_profile.html:170 msgid "Update SSH public key" msgstr "更改SSH密钥" -#: users/templates/users/user_profile.html:177 +#: users/templates/users/user_profile.html:178 msgid "Reset public key and download" msgstr "重置并下载SSH密钥" -#: users/templates/users/user_profile.html:207 +#: users/templates/users/user_profile.html:208 msgid "Failed to update SSH public key." msgstr "更新密钥失败" @@ -2821,8 +2820,8 @@ msgid "Please enable cookies and try again." msgstr "设置你的浏览器支持cookie" #: users/views/login.py:107 users/views/user.py:464 users/views/user.py:489 -msgid "Otp code invalid" -msgstr "otp码认证失败" +msgid "MFA code invalid" +msgstr "MFA码认证失败" #: users/views/login.py:133 msgid "Logout success" @@ -2898,20 +2897,20 @@ msgid "Password invalid" msgstr "用户名或密码无效" #: users/views/user.py:515 -msgid "OTP enable success" -msgstr "OTP 绑定成功" +msgid "MFA enable success" +msgstr "MFA 绑定成功" #: users/views/user.py:516 -msgid "OTP enable success, return login page" -msgstr "OTP 绑定成功,返回到登录页面" +msgid "MFA enable success, return login page" +msgstr "MFA 绑定成功,返回到登录页面" #: users/views/user.py:518 -msgid "OTP disable success" -msgstr "OTP 解绑成功" +msgid "MFA disable success" +msgstr "MFA 解绑成功" #: users/views/user.py:519 -msgid "OTP disable success, return login page" -msgstr "OTP 解绑成功,返回登录页面" +msgid "MFA disable success, return login page" +msgstr "MFA 解绑成功,返回登录页面" #~ msgid "Add asset" #~ msgstr "添加资产到节点" diff --git a/apps/users/forms.py b/apps/users/forms.py index 03b1e21cb..5af28756b 100644 --- a/apps/users/forms.py +++ b/apps/users/forms.py @@ -27,7 +27,7 @@ class UserCheckPasswordForm(forms.Form): class UserCheckOtpCodeForm(forms.Form): - otp_code = forms.CharField(label=_('Otp_code'), max_length=6) + otp_code = forms.CharField(label=_('MFA_code'), max_length=6) class UserCreateUpdateForm(forms.ModelForm): diff --git a/apps/users/templates/users/_base_otp.html b/apps/users/templates/users/_base_otp.html index cd9c43edc..a6eca32d9 100644 --- a/apps/users/templates/users/_base_otp.html +++ b/apps/users/templates/users/_base_otp.html @@ -54,7 +54,7 @@ -
绑定TOTP
+
绑定MFA
  • diff --git a/apps/users/templates/users/login_otp.html b/apps/users/templates/users/login_otp.html index de201ce8c..1edde0b59 100644 --- a/apps/users/templates/users/login_otp.html +++ b/apps/users/templates/users/login_otp.html @@ -42,7 +42,7 @@
    - {% trans '二次认证' %} + {% trans 'MFA certification' %}
    diff --git a/apps/users/templates/users/user_detail.html b/apps/users/templates/users/user_detail.html index d062a0a3c..66bfa61e0 100644 --- a/apps/users/templates/users/user_detail.html +++ b/apps/users/templates/users/user_detail.html @@ -88,7 +88,7 @@ {{ user_object.get_role_display }} - {% trans 'Enable OTP' %}: + {% trans 'MFA certification' %}: {% if user_object.otp_force_enabled %} {% trans 'Force enabled' %} @@ -148,7 +148,7 @@ - {% trans 'Force enabled OTP' %}: + {% trans 'Force enabled MFA' %}:
    @@ -288,7 +288,7 @@ $(document).ready(function() { }) .on('click', '#force_enable_otp', function() { {% if request.user == user_object %} - toastr.error("{% trans 'Goto profile page enable otp' %}"); + toastr.error("{% trans 'Goto profile page enable MFA' %}"); return {% endif %} diff --git a/apps/users/templates/users/user_profile.html b/apps/users/templates/users/user_profile.html index 6cda70eb9..3efc193c9 100644 --- a/apps/users/templates/users/user_profile.html +++ b/apps/users/templates/users/user_profile.html @@ -63,18 +63,7 @@ {% trans 'Active' %} {{ user.is_active|yesno:"Yes,No,Unkown" }} - - {% trans 'OTP' %} - - {% if user.otp_force_enabled %} - {% trans 'Force enable' %} - {% elif user.otp_enabled%} - {% trans 'Enable' %} - {% else %} - {% trans 'Disable' %} - {% endif %} - - + {% trans 'Public key' %} @@ -92,6 +81,18 @@ + + {% trans 'MFA certification' %} + + {% if user.otp_force_enabled %} + {% trans 'Force enable' %} + {% elif user.otp_enabled%} + {% trans 'Enable' %} + {% else %} + {% trans 'Disable' %} + {% endif %} + + {% trans 'Date joined' %} {{ user.date_joined|date:"Y-m-d H:i:s" }} @@ -145,7 +146,7 @@ - {% trans 'Update otp' %}: + {% trans 'Update MFA settings' %}: