From 699943365bda05c7775b2ed735fba8261274e2cd Mon Sep 17 00:00:00 2001 From: Maxime Besson Date: Tue, 15 Jun 2021 15:50:52 +0200 Subject: [PATCH] Improve messages on TOTP registration (#2541) --- lemonldap-ng-portal/site/coffee/totpregistration.coffee | 3 ++- .../site/htdocs/static/common/js/totpregistration.js | 3 ++- .../site/htdocs/static/common/js/totpregistration.min.js | 2 +- .../site/htdocs/static/common/js/totpregistration.min.js.map | 2 +- lemonldap-ng-portal/site/htdocs/static/languages/ar.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/de.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/en.json | 3 ++- lemonldap-ng-portal/site/htdocs/static/languages/es.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/fi.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/fr.json | 3 ++- lemonldap-ng-portal/site/htdocs/static/languages/it.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/nl.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/pl.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/pt.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/ro.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/tr.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/vi.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/zh.json | 5 +++-- lemonldap-ng-portal/site/htdocs/static/languages/zh_TW.json | 5 +++-- .../site/templates/bootstrap/totp2fregister.tpl | 3 ++- 20 files changed, 51 insertions(+), 33 deletions(-) diff --git a/lemonldap-ng-portal/site/coffee/totpregistration.coffee b/lemonldap-ng-portal/site/coffee/totpregistration.coffee index 68189b685..a6574833a 100644 --- a/lemonldap-ng-portal/site/coffee/totpregistration.coffee +++ b/lemonldap-ng-portal/site/coffee/totpregistration.coffee @@ -61,7 +61,8 @@ getKey = () -> verify = -> val = $('#code').val() unless val - setMsg 'fillTheForm', 'warning' + setMsg 'totpMissingCode', 'warning' + $("#code").focus() else $.ajax type: "POST", diff --git a/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.js b/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.js index d8a435112..c0be4bbb7 100644 --- a/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.js +++ b/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.js @@ -78,7 +78,8 @@ LemonLDAP::NG TOTP registration script var val; val = $('#code').val(); if (!val) { - return setMsg('fillTheForm', 'warning'); + setMsg('totpMissingCode', 'warning'); + return $("#code").focus(); } else { return $.ajax({ type: "POST", diff --git a/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js b/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js index 466f113ec..c097b3b79 100644 --- a/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js +++ b/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js @@ -1 +1 @@ -(function(){var r,e,s,o,t;s=function(e,r){return $("#msg").attr("trspan",e),$("#msg").html(window.translate(e)),$("#color").removeClass("message-positive message-warning message-danger alert-success alert-warning alert-danger"),$("#color").addClass("message-"+r),"positive"===r&&(r="success"),$("#color").addClass("alert-"+r)},r=function(e,r,t){var o;if(console.log("Error",t),(o=JSON.parse(e.responseText))&&o.error)return o=o.error.replace(/.* /,""),console.log("Returned error",o),s(o,"warning")},o="",e=function(){return s("yourTotpKey","warning"),$.ajax({type:"POST",url:portal+"/2fregisters/totp/getkey",dataType:"json",error:r,success:function(e){var r,t;return e.error?(e.error.match(/totpExistingKey/)&&$("#divToHide").hide(),s(e.error,"warning")):e.portal&&e.user&&e.secret?($("#divToHide").show(),r="otpauth://totp/"+escape(e.portal)+":"+escape(e.user)+"?secret="+e.secret+"&issuer="+escape(e.portal),6!==e.digits&&(r+="&digits="+e.digits),30!==e.interval&&(r+="&period="+e.interval),new QRious({element:document.getElementById("qr"),value:r,size:150}),t=e.secret||"",$("#secret").text(t.toUpperCase().replace(/(.{4})/g,"$1 ").trim()),e.newkey?s("yourNewTotpKey","warning"):s("yourTotpKey","success"),o=e.token):s("PE24","danger")}})},t=function(){var e;return(e=$("#code").val())?$.ajax({type:"POST",url:portal+"/2fregisters/totp/verify",dataType:"json",data:{token:o,code:e,TOTPName:$("#TOTPName").val()},error:r,success:function(e){return e.error?e.error.match(/bad(Code|Name)/)?s(e.error,"warning"):s(e.error,"danger"):s("yourKeyIsRegistered","success")}}):s("fillTheForm","warning")},$(document).ready(function(){return e(),$("#verify").on("click",function(){return t()})})}).call(this); \ No newline at end of file +(function(){var r,e,s,o,t;s=function(e,r){return $("#msg").attr("trspan",e),$("#msg").html(window.translate(e)),$("#color").removeClass("message-positive message-warning message-danger alert-success alert-warning alert-danger"),$("#color").addClass("message-"+r),"positive"===r&&(r="success"),$("#color").addClass("alert-"+r)},r=function(e,r,t){var o;if(console.log("Error",t),(o=JSON.parse(e.responseText))&&o.error)return o=o.error.replace(/.* /,""),console.log("Returned error",o),s(o,"warning")},o="",e=function(){return s("yourTotpKey","warning"),$.ajax({type:"POST",url:portal+"/2fregisters/totp/getkey",dataType:"json",error:r,success:function(e){var r,t;return e.error?(e.error.match(/totpExistingKey/)&&$("#divToHide").hide(),s(e.error,"warning")):e.portal&&e.user&&e.secret?($("#divToHide").show(),r="otpauth://totp/"+escape(e.portal)+":"+escape(e.user)+"?secret="+e.secret+"&issuer="+escape(e.portal),6!==e.digits&&(r+="&digits="+e.digits),30!==e.interval&&(r+="&period="+e.interval),new QRious({element:document.getElementById("qr"),value:r,size:150}),t=e.secret||"",$("#secret").text(t.toUpperCase().replace(/(.{4})/g,"$1 ").trim()),e.newkey?s("yourNewTotpKey","warning"):s("yourTotpKey","success"),o=e.token):s("PE24","danger")}})},t=function(){var e;return(e=$("#code").val())?$.ajax({type:"POST",url:portal+"/2fregisters/totp/verify",dataType:"json",data:{token:o,code:e,TOTPName:$("#TOTPName").val()},error:r,success:function(e){return e.error?e.error.match(/bad(Code|Name)/)?s(e.error,"warning"):s(e.error,"danger"):s("yourKeyIsRegistered","success")}}):(s("totpMissingCode","warning"),$("#code").focus())},$(document).ready(function(){return e(),$("#verify").on("click",function(){return t()})})}).call(this); \ No newline at end of file diff --git a/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js.map b/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js.map index ede635042..a377a6b35 100644 --- a/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js.map +++ b/lemonldap-ng-portal/site/htdocs/static/common/js/totpregistration.min.js.map @@ -1 +1 @@ -{"version":3,"sources":["totpregistration.js"],"names":["displayError","getKey","setMsg","token","verify","msg","level","$","attr","html","window","translate","removeClass","addClass","j","status","err","res","console","log","JSON","parse","responseText","error","replace","ajax","type","url","portal","dataType","success","data","s","secret","match","hide","user","show","escape","digits","interval","QRious","element","document","getElementById","value","size","text","toUpperCase","trim","newkey","val","code","TOTPName","ready","on","call","this"],"mappings":"CAMA,WACE,IAAIA,EAAcC,EAAQC,EAAQC,EAAOC,EAEzCF,EAAS,SAASG,EAAKC,GAQrB,OAPAC,EAAE,QAAQC,KAAK,SAAUH,GACzBE,EAAE,QAAQE,KAAKC,OAAOC,UAAUN,IAChCE,EAAE,UAAUK,YAAY,4FACxBL,EAAE,UAAUM,SAAS,WAAaP,GACpB,aAAVA,IACFA,EAAQ,WAEHC,EAAE,UAAUM,SAAS,SAAWP,IAGzCN,EAAe,SAASc,EAAGC,EAAQC,GACjC,IAAIC,EAGJ,GAFAC,QAAQC,IAAI,QAASH,IACrBC,EAAMG,KAAKC,MAAMP,EAAEQ,gBACRL,EAAIM,MAGb,OAFAN,EAAMA,EAAIM,MAAMC,QAAQ,MAAO,IAC/BN,QAAQC,IAAI,iBAAkBF,GACvBf,EAAOe,EAAK,YAIvBd,EAAQ,GAERF,EAAS,WAEP,OADAC,EAAO,cAAe,WACfK,EAAEkB,KAAK,CACZC,KAAM,OACNC,IAAKC,OAAS,2BACdC,SAAU,OACVN,MAAOvB,EACP8B,QAAS,SAASC,GAChB,IAAQC,EAAGC,EACX,OAAIF,EAAKR,OACHQ,EAAKR,MAAMW,MAAM,oBACnB3B,EAAE,cAAc4B,OAEXjC,EAAO6B,EAAKR,MAAO,YAEtBQ,EAAKH,QAAUG,EAAKK,MAAQL,EAAKE,QAGvC1B,EAAE,cAAc8B,OAChBL,EAAI,kBAAqBM,OAAOP,EAAKH,QAAW,IAAOU,OAAOP,EAAKK,MAAS,WAAaL,EAAKE,OAAS,WAAcK,OAAOP,EAAKH,QAC7G,IAAhBG,EAAKQ,SACPP,GAAK,WAAaD,EAAKQ,QAEH,KAAlBR,EAAKS,WACPR,GAAK,WAAaD,EAAKS,UAEpB,IAAIC,OAAO,CACdC,QAASC,SAASC,eAAe,MACjCC,MAAOb,EACPc,KAAM,MAERb,EAASF,EAAKE,QAAU,GACxB1B,EAAE,WAAWwC,KAAKd,EAAOe,cAAcxB,QAAQ,UAAW,OAAOyB,QAC7DlB,EAAKmB,OACPhD,EAAO,iBAAkB,WAEzBA,EAAO,cAAe,WAEjBC,EAAQ4B,EAAK5B,OAtBXD,EAAO,OAAQ,cA2B9BE,EAAS,WACP,IAAI+C,EAEJ,OADAA,EAAM5C,EAAE,SAAS4C,OAIR5C,EAAEkB,KAAK,CACZC,KAAM,OACNC,IAAKC,OAAS,2BACdC,SAAU,OACVE,KAAM,CACJ5B,MAAOA,EACPiD,KAAMD,EACNE,SAAU9C,EAAE,aAAa4C,OAE3B5B,MAAOvB,EACP8B,QAAS,SAASC,GAChB,OAAIA,EAAKR,MACHQ,EAAKR,MAAMW,MAAM,kBACZhC,EAAO6B,EAAKR,MAAO,WAEnBrB,EAAO6B,EAAKR,MAAO,UAGrBrB,EAAO,sBAAuB,cApBpCA,EAAO,cAAe,YA2BjCK,EAAEoC,UAAUW,MAAM,WAEhB,OADArD,IACOM,EAAE,WAAWgD,GAAG,QAAS,WAC9B,OAAOnD,UAIVoD,KAAKC"} \ No newline at end of file +{"version":3,"sources":["totpregistration.js"],"names":["displayError","getKey","setMsg","token","verify","msg","level","$","attr","html","window","translate","removeClass","addClass","j","status","err","res","console","log","JSON","parse","responseText","error","replace","ajax","type","url","portal","dataType","success","data","s","secret","match","hide","user","show","escape","digits","interval","QRious","element","document","getElementById","value","size","text","toUpperCase","trim","newkey","val","code","TOTPName","focus","ready","on","call","this"],"mappings":"CAMA,WACE,IAAIA,EAAcC,EAAQC,EAAQC,EAAOC,EAEzCF,EAAS,SAASG,EAAKC,GAQrB,OAPAC,EAAE,QAAQC,KAAK,SAAUH,GACzBE,EAAE,QAAQE,KAAKC,OAAOC,UAAUN,IAChCE,EAAE,UAAUK,YAAY,4FACxBL,EAAE,UAAUM,SAAS,WAAaP,GACpB,aAAVA,IACFA,EAAQ,WAEHC,EAAE,UAAUM,SAAS,SAAWP,IAGzCN,EAAe,SAASc,EAAGC,EAAQC,GACjC,IAAIC,EAGJ,GAFAC,QAAQC,IAAI,QAASH,IACrBC,EAAMG,KAAKC,MAAMP,EAAEQ,gBACRL,EAAIM,MAGb,OAFAN,EAAMA,EAAIM,MAAMC,QAAQ,MAAO,IAC/BN,QAAQC,IAAI,iBAAkBF,GACvBf,EAAOe,EAAK,YAIvBd,EAAQ,GAERF,EAAS,WAEP,OADAC,EAAO,cAAe,WACfK,EAAEkB,KAAK,CACZC,KAAM,OACNC,IAAKC,OAAS,2BACdC,SAAU,OACVN,MAAOvB,EACP8B,QAAS,SAASC,GAChB,IAAQC,EAAGC,EACX,OAAIF,EAAKR,OACHQ,EAAKR,MAAMW,MAAM,oBACnB3B,EAAE,cAAc4B,OAEXjC,EAAO6B,EAAKR,MAAO,YAEtBQ,EAAKH,QAAUG,EAAKK,MAAQL,EAAKE,QAGvC1B,EAAE,cAAc8B,OAChBL,EAAI,kBAAqBM,OAAOP,EAAKH,QAAW,IAAOU,OAAOP,EAAKK,MAAS,WAAaL,EAAKE,OAAS,WAAcK,OAAOP,EAAKH,QAC7G,IAAhBG,EAAKQ,SACPP,GAAK,WAAaD,EAAKQ,QAEH,KAAlBR,EAAKS,WACPR,GAAK,WAAaD,EAAKS,UAEpB,IAAIC,OAAO,CACdC,QAASC,SAASC,eAAe,MACjCC,MAAOb,EACPc,KAAM,MAERb,EAASF,EAAKE,QAAU,GACxB1B,EAAE,WAAWwC,KAAKd,EAAOe,cAAcxB,QAAQ,UAAW,OAAOyB,QAC7DlB,EAAKmB,OACPhD,EAAO,iBAAkB,WAEzBA,EAAO,cAAe,WAEjBC,EAAQ4B,EAAK5B,OAtBXD,EAAO,OAAQ,cA2B9BE,EAAS,WACP,IAAI+C,EAEJ,OADAA,EAAM5C,EAAE,SAAS4C,OAKR5C,EAAEkB,KAAK,CACZC,KAAM,OACNC,IAAKC,OAAS,2BACdC,SAAU,OACVE,KAAM,CACJ5B,MAAOA,EACPiD,KAAMD,EACNE,SAAU9C,EAAE,aAAa4C,OAE3B5B,MAAOvB,EACP8B,QAAS,SAASC,GAChB,OAAIA,EAAKR,MACHQ,EAAKR,MAAMW,MAAM,kBACZhC,EAAO6B,EAAKR,MAAO,WAEnBrB,EAAO6B,EAAKR,MAAO,UAGrBrB,EAAO,sBAAuB,eArB3CA,EAAO,kBAAmB,WACnBK,EAAE,SAAS+C,UA2BtB/C,EAAEoC,UAAUY,MAAM,WAEhB,OADAtD,IACOM,EAAE,WAAWiD,GAAG,QAAS,WAC9B,OAAOpD,UAIVqD,KAAKC"} \ No newline at end of file diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/ar.json b/lemonldap-ng-portal/site/htdocs/static/languages/ar.json index 24c06064b..8d353cad9 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/ar.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/ar.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"الاسم الاول", "forbidden":"Access FORBIDDEN", "forgotPwd":"نسيت كلمة المرور؟", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"يرجى لمس جهاز U2F وامض الآن.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"نوع", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/de.json b/lemonldap-ng-portal/site/htdocs/static/languages/de.json index 89f851c7e..3a6d0a6cc 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/de.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/de.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fülle das Formular aus", "firstName":"Vorname", "forbidden":"Access FORBIDDEN", "forgotPwd":"Passwort vergessen ?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"Es existiert bereits ein TOTP-Secret", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/en.json b/lemonldap-ng-portal/site/htdocs/static/languages/en.json index 38749be39..6e28d248f 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/en.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/en.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"First name", "forbidden":"Access FORBIDDEN", "forgotPwd":"Forgot your password?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/es.json b/lemonldap-ng-portal/site/htdocs/static/languages/es.json index 4580c64e3..fd05e973e 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/es.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/es.json @@ -168,7 +168,6 @@ "expired2Fremoved":"¡%s dispositivos 2F caducados han sido suprimidos!", "explorer":"Explorer", "ext2f":"Código de verificación", -"fillTheForm":"Llene el formulario", "firstName":"Nombre", "forbidden":"Acceso DENEGADO", "forgotPwd":"Contraseña olvidada?", @@ -293,6 +292,8 @@ "switchContext":"Cambiar contexto", "totp2f":"Aplicación OTP", "totpExistingKey":"Un secreto TOTP ya existe", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Por favor toque el dispositivo U2F centelleante ahora.", "touchU2fDeviceOrEnterTotp":"Por favor toque el dispositivo U2F centelleante o ingrese el código TOTP.", "type":"Tipo", @@ -332,4 +333,4 @@ "yourProfile":"Conozca su perfil", "yourTotpKey":"Su llave TOTP", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/fi.json b/lemonldap-ng-portal/site/htdocs/static/languages/fi.json index c3a9f3fcf..747cd88db 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/fi.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/fi.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"Etunimi", "forbidden":"Access FORBIDDEN", "forgotPwd":"Unohditko salasanasi?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/fr.json b/lemonldap-ng-portal/site/htdocs/static/languages/fr.json index 10f4492b7..6e8031968 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/fr.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/fr.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s seconds facteurs expirés ont été supprimés !", "explorer":"Explorateur", "ext2f":"Code de vérification", -"fillTheForm":"Remplissez le formulaire", "firstName":"Prénom", "forbidden":"Accès INTERDIT", "forgotPwd":"Mot de passe oublié ?", @@ -293,6 +292,8 @@ "switchContext":"Changer de contexte", "totp2f":"Application OTP", "totpExistingKey":"Un périphérique TOTP est déja enregistré, vous devez le supprimer pour pouvoir en ajouter un nouveau", +"totpMissingCode":"Veuillez entrer le code fourni par votre application TOTP", +"totpSecretKey":"Si votre application n'accepte pas les QR codes, saisissez la clé suivante:", "touchU2fDevice":"Posez votre doigt sur le périphérique U2F", "touchU2fDeviceOrEnterTotp":"Posez votre doigt sur le périphérique U2F ou entrez le code TOTP", "type":"Type", diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/it.json b/lemonldap-ng-portal/site/htdocs/static/languages/it.json index fca600b20..393477784 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/it.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/it.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Compila il modulo", "firstName":"Nome", "forbidden":"Accesso VIETATO", "forgotPwd":"Password dimenticata?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"Un segreto TOTP esiste già", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Adesso tocca il dispositivo U2F lampeggiante.", "touchU2fDeviceOrEnterTotp":"Tocca il dispositivo U2F lampeggiante o inserisci il codice TOTP.", "type":"Tipo", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"La tua chiave TOTP", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/nl.json b/lemonldap-ng-portal/site/htdocs/static/languages/nl.json index 19c71d7b6..cbd8cc01d 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/nl.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/nl.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"First name", "forbidden":"Access FORBIDDEN", "forgotPwd":"Forgot your password?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/pl.json b/lemonldap-ng-portal/site/htdocs/static/languages/pl.json index f10976bdd..37cdc341f 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/pl.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/pl.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s przeterminowane urządzenia 2F zostały usunięte!", "explorer":"Eksplorator", "ext2f":"Kod weryfikacyjny", -"fillTheForm":"Wypełnij formularz", "firstName":"Imię", "forbidden":"Dostęp ZABRONIONY", "forgotPwd":"Zapomniałeś hasła?", @@ -293,6 +292,8 @@ "switchContext":"Przełącz kontekst", "totp2f":"Aplikacja OTP", "totpExistingKey":"Sekret TOTP już istnieje", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Dotknij teraz migającego urządzenia U2F.", "touchU2fDeviceOrEnterTotp":"Dotknij migającego urządzenia U2F lub wprowadź kod TOTP.", "type":"Rodzaj", @@ -332,4 +333,4 @@ "yourProfile":"Twój profil", "yourTotpKey":"Twój klucz TOTP", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/pt.json b/lemonldap-ng-portal/site/htdocs/static/languages/pt.json index 38273a2ab..fb0b7dfb6 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/pt.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/pt.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"First name", "forbidden":"Access FORBIDDEN", "forgotPwd":"Forgot your password?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/ro.json b/lemonldap-ng-portal/site/htdocs/static/languages/ro.json index f325f9128..6797951e0 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/ro.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/ro.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"First name", "forbidden":"Access FORBIDDEN", "forgotPwd":"Forgot your password?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/tr.json b/lemonldap-ng-portal/site/htdocs/static/languages/tr.json index ed4b62277..8b4b3f6ba 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/tr.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/tr.json @@ -168,7 +168,6 @@ "expired2Fremoved":"Kullanım süresi dolan %s2F cihazı kaldırıldı!", "explorer":"Explorer", "ext2f":"Doğrulama kodu", -"fillTheForm":"Formu doldur", "firstName":"Ad", "forbidden":"Erişim YASAKLI", "forgotPwd":"Parolanızı mı unuttunuz?", @@ -293,6 +292,8 @@ "switchContext":"Bağlam değiştir", "totp2f":"OTP Uygulaması", "totpExistingKey":"Bir TOTP sırrı zaten mevcut", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Lütfen şimdi yanıp sönen U2F cihazına dokunun.", "touchU2fDeviceOrEnterTotp":"Lütfen şimdi yanıp sönen U2F cihazına dokunun veya TOTP kodunu girin.", "type":"Tür", @@ -332,4 +333,4 @@ "yourProfile":"Profilini bil", "yourTotpKey":"TOTP anahtarınız", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/vi.json b/lemonldap-ng-portal/site/htdocs/static/languages/vi.json index bff188d9a..8d9c8fd91 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/vi.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/vi.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"Tên", "forbidden":"Access FORBIDDEN", "forgotPwd":"Quên mật khẩu của bạn?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Vui lòng chạm vào thiết bị U2F nhấp nháy ngay bây giờ.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Loại", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/zh.json b/lemonldap-ng-portal/site/htdocs/static/languages/zh.json index 07e53e5e3..6165cc0be 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/zh.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/zh.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s expired 2F devices have been removed!", "explorer":"Explorer", "ext2f":"Verification code", -"fillTheForm":"Fill the form", "firstName":"名", "forbidden":"Access FORBIDDEN", "forgotPwd":"忘记密码?", @@ -293,6 +292,8 @@ "switchContext":"Switch context", "totp2f":"OTP App", "totpExistingKey":"A TOTP device is already registered, you must remove it before adding a new TOTP device", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"Please touch the flashing U2F device now.", "touchU2fDeviceOrEnterTotp":"Please touch the flashing U2F device or enter TOTP code.", "type":"Type", @@ -332,4 +333,4 @@ "yourProfile":"Know your profile", "yourTotpKey":"Your TOTP key", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/htdocs/static/languages/zh_TW.json b/lemonldap-ng-portal/site/htdocs/static/languages/zh_TW.json index cb97ca773..f3d421e5b 100644 --- a/lemonldap-ng-portal/site/htdocs/static/languages/zh_TW.json +++ b/lemonldap-ng-portal/site/htdocs/static/languages/zh_TW.json @@ -168,7 +168,6 @@ "expired2Fremoved":"%s 個過期的雙因素驗證已被移除!", "explorer":"探索者", "ext2f":"驗證代碼", -"fillTheForm":"填表單", "firstName":"名", "forbidden":"禁止存取", "forgotPwd":"忘記您的密碼?", @@ -293,6 +292,8 @@ "switchContext":"切換內容", "totp2f":"OTP 應用程式", "totpExistingKey":"TOTP 祕密已存在", +"totpMissingCode":"Please enter the code supplied by your TOTP application", +"totpSecretKey":"If your TOTP application does not support QR codes, enter the following key instead:", "touchU2fDevice":"請立刻碰觸閃爍中的 U2F 裝置。", "touchU2fDeviceOrEnterTotp":"請立刻碰觸閃爍中的 U2F 裝置或輸入 TOTP 代碼。", "type":"類型", @@ -332,4 +333,4 @@ "yourProfile":"知道您的個人檔案", "yourTotpKey":"您的 TOTP 金鑰", "yubikey2f":"Yubikey" -} \ No newline at end of file +} diff --git a/lemonldap-ng-portal/site/templates/bootstrap/totp2fregister.tpl b/lemonldap-ng-portal/site/templates/bootstrap/totp2fregister.tpl index 8f5e3a99b..63268e34b 100644 --- a/lemonldap-ng-portal/site/templates/bootstrap/totp2fregister.tpl +++ b/lemonldap-ng-portal/site/templates/bootstrap/totp2fregister.tpl @@ -11,6 +11,7 @@
+

@@ -22,7 +23,7 @@
- +