Changeset 2615458
- Timestamp:
- 10/17/2021 08:53:13 PM (4 years ago)
- Location:
- 2fas/trunk
- Files:
-
- 1 added
- 16 edited
-
assets/js/dashboard.js (modified) (3 diffs)
-
assets/js/dashboard.min.js (modified) (1 diff)
-
assets/js/modal.js (modified) (2 diffs)
-
assets/js/modal.min.js (modified) (1 diff)
-
changelog.txt (modified) (1 diff)
-
constants.php (modified) (1 diff)
-
readme.txt (modified) (1 diff)
-
start.php (modified) (1 diff)
-
templates/dashboard/admin/admin.html.twig (modified) (1 diff)
-
templates/modals/confirmation/migrate-users-modal.html.twig (modified) (1 diff)
-
templates/modals/success-modal.html.twig (added)
-
twofas.php (modified) (1 diff)
-
vendor/autoload.php (modified) (1 diff)
-
vendor/composer/autoload_real.php (modified) (5 diffs)
-
vendor/composer/autoload_static.php (modified) (2 diffs)
-
vendor/composer/installed.json (modified) (14 diffs)
-
vendor/composer/installed.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
2fas/trunk/assets/js/dashboard.js
r2551311 r2615458 15 15 var reloadWarningModal = $( '.twofas-reload-warning-modal' ), 16 16 errorModal = $( '.twofas-error-modal' ), 17 successModal = $( '.twofas-success-modal' ), 17 18 migrateModal = $('.twofas-migrate-users-confirmation-modal'); 18 19 … … 21 22 myChart = $( '#myChart' ), 22 23 errorModalMessage = $( '#error-modal-message' ), 24 successModalMessage = $( '#success-modal-message' ), 23 25 qrImg = $( 'img.twofas-qr-code' ), 24 26 qrSpinner = $( '.twofas-spinner-container.twofas-qr-refresh' ), … … 276 278 clearInterval( migrationIntervalId ); 277 279 userBoxTitle.html( twofas.migrationCompleted ); 280 successModalMessage.html( 'Migration completed successfully. Now please turn off and uninstall 2FAS Classic plugin.' ); 281 successModal.trigger( 'display' ); 278 282 migrateUsersButton.hide(); 279 283 setTimeout(function() { -
2fas/trunk/assets/js/dashboard.min.js
r2551311 r2615458 1 !function(r){try{var e=r(".js-generate-offline-codes"), s=r(".js-open-migrate-users-modal"),t=r(".js-twofas-migrate-users"),a=r(".js-reload-qr-code"),o=r(".js-reload-qr-code-and-set-modal-status"),n=r(".js-send-sms"),i=r(".js-waiting-button"),d=r(".js-waiting-link"),c=r(".js-autofocus"),l=r(".twofas-reload-warning-modal"),f=r(".twofas-error-modal"),u=r(".twofas-migrate-users-confirmation-modal"),p=r(".twofas-trusted-device"),w=r(".twofas-offline-codes-date"),m=r("#myChart"),v=r("#error-modal-message"),h=r("img.twofas-qr-code"),g=r(".twofas-spinner-container.twofas-qr-refresh"),b=r(".twofas-admin-users-wrapper h2"),j="",C=0;function y(e){var t,a=(t=e,JSON.parse(t.responseText).error);void 0===a&&(a="Server error occurred. Please try to refresh this page."),v.html(a),f.trigger("display")}function x(e){var t=e.qrCode,a=e.totpSecret;r(".twofas-qr-code").attr("src",t),r(".twofas-totp-secret").html(a),r("#totp-secret").val(a),r(".twofas-mobile-config").attr("href",e.qrCodeMessage),h.removeClass("twofas-hidden"),g.removeClass("twofas-visible")}function k(){var e=r(".twofas-reload-qr-code-form").attr("action"),t={_wpnonce:r('.twofas-buttons-bottom > input[name="_wpnonce"]').val()};h.addClass("twofas-hidden"),g.addClass("twofas-visible"),r.ajax({url:e,type:"post",data:t,success:x,error:y})}function _(e){return twofas.months[e]}function q(){var e=r("#myChart")[0].getContext("2d"),t={datasets:[{data:[r(".js-active-users-count").val(),r(".js-inactive-users-count").val()],backgroundColor:["#202225","#eb1c23"],borderWidth:0}],labels:[twofas.activeUsers,twofas.inactiveUsers]};m=new Chart(e,{type:"doughnut",data:t,options:{responsive:!0,maintainAspectRatio:!1,legend:{display:!1},title:{display:!1},animation:{animateScale:!0,animateRotate:!0},tooltips:{enabled:!0}}}),r("#js-legend").html(m.generateLegend()),m.update()}t.length&&t.on("click",function(e){e.preventDefault(),u.trigger("close"),s.attr("disabled",!0),j=b.html();var t=r("#twofas-migration-users-form").attr("action"),a={_wpnonce:r('#twofas-migration-users-form > input[name="_wpnonce"]').val()},o=0;r.ajax({url:t,type:"post",data:a,error:function(e){y(e)}}),C=setInterval(function(){o=++o%4,b.html(twofas.migrationInProgress+Array(o+1).join("."))},500),m.data.labels[1]=twofas.migratedUsers,m.data.datasets[0].backgroundColor[1]="#10b74a",m.update(),r("#js-legend").html(m.generateLegend()),function a(){setTimeout(function(){r.ajax({url:twofas.ajaxUrl,type:"get",data:{page:twofas.submenuDashboard,"twofas-action":"migration-users-status"},success:function(e){var t=m.data;0<t.datasets.length&&(t.datasets[0].data[1]=e.migrated_users),m.update(),e.migrated_users>=e.active_users_count?(clearInterval(C),b.html(twofas.migrationCompleted),s.hide(),setTimeout(function(){q(),b.html(j)},3e3)):a()},error:function(e){y(e)}})},1e3)}()}),p.length&&(r(".twofas-trusted-device-country").each(function(e,a){r.get("https://ipapi.co/"+a.innerText+"/json/",function(e){var t=e.country;a.innerText=t||"",a.className+=" twofas-visible"})}),r(".twofas-date").each(function(e,t){var a,o=1e3*t.innerText;isNaN(o)||(t.innerText=_((a=new Date(o)).getMonth())+" "+a.getDate()+", "+a.getFullYear())}),r(".twofas-hour").each(function(e,t){var a,o,s,n,r=1e3*t.innerText;isNaN(r)||(t.innerText=(a=new Date(r),o=a.getHours(),s=a.getMinutes(),n=12<=o?"PM":"AM",12<o&&(o-=12),s<10&&(s="0"+s),o+":"+s+" "+n),t.className+=" twofas-visible")})),w.length&&function(){var e=1e3*w[0].innerText;if(!isNaN(e)){var t=new Date(e),a=_(t.getMonth()),o=t.getDate(),s=t.getFullYear();w[0].innerText=o+" "+a+" "+s}}(),m.length&&q(),c.focus(function(){this.value=this.value}),e.click(function(e){e.preventDefault();var t=r(".twofas-generate-offline-codes-form").attr("action"),a=r('.twofas-generate-offline-codes-form > input[name="_wpnonce"]').val(),n=r(this);n.addClass("twofas-wait").prop("disabled",!0);var o={_wpnonce:a};r.ajax({url:t,type:"post",data:o,success:function(e){var t=e.codes,a=encodeURIComponent(t.join("\n")),o=function(e){var t,a="<code><pre>";for(t in e)e.hasOwnProperty(t)&&(a+=e[t]+"\r\n");return a+="</pre></code>"}(t),s=function(e){var t,a="";for(t in e)e.hasOwnProperty(t)&&(a+='<input type="hidden" name="code['+t+']" value="'+e[t]+'" />');return a}(t);r(".twofas-offline-stats-generated").hide(),r(".twofas-offline-codes-data").html(o),r(".twofas-offline-codes-inputs").html(s),r(".twofas-download-codes-link").attr("href","data:text/plain;charset=utf-8,"+a),r(".twofas-offline-codes-list").show(),r(".js-backup-codes-tick").removeClass("twofas-icon-tick").addClass("twofas-icon-tick-enabled"),n.removeClass("twofas-wait").prop("disabled",!1)},error:function(e){n.removeClass("twofas-wait").prop("disabled",!1),y(e)}})}),a.submit(function(e){e.preventDefault(),k()}),r(document).on("click",".js-reload-qr-code",function(e){e.preventDefault(),k()}),o.submit(function(e){if(e.preventDefault(),r("#reload-modal-check").is(":checked")){var t=r(".js-reload-qr-code-and-set-modal-status").attr("action"),a={_wpnonce:r('.js-reload-qr-code-and-set-modal-status > input[name="_wpnonce"]').val()};r.ajax({url:t,type:"post",data:a,error:y}),r(".twofas-reload-qr-code-form").removeClass("js-open-reload-warning-modal").addClass("js-reload-qr-code")}l.trigger("close"),k()}),n.click(function(e){e.preventDefault();var t=r(this);t.addClass("twofas-wait").prop("disabled",!0);var a=r(".twofas-send-sms-form").attr("action"),o=r('.twofas-send-sms-form > input[name="_wpnonce"]').val(),s=r("#phone-number").val(),n={phone_number:s,_wpnonce:o};r.ajax({url:a,type:"post",data:n,success:function(e){r("#verified-phone-number").val(s),r("#authentication-id").val(e.authenticationId),r(".twofas-sms-sent-button-text").hide(),r(".twofas-sms-sent-message").show(),t.removeClass("twofas-wait"),r("#twofas-token").prop("disabled",!1),r(".twofas-enable-token-btn").prop("disabled",!1)},error:function(e){t.removeClass("twofas-wait").prop("disabled",!1),y(e)}})}),i.submit(function(e){e.preventDefault();var t=this;return r(this).find('*[type="submit"]').addClass("twofas-wait").prop("disabled",!0),setTimeout(function(){t.submit()},1),!0}),d.click(function(){r(this).addClass("twofas-wait").prop("disabled",!0)})}catch(e){Sentry.captureException(e),v.html("Server error occurred. Please try to refresh this page."),f.trigger("display")}}(jQuery);1 !function(r){try{var e=r(".js-generate-offline-codes"),o=r(".js-open-migrate-users-modal"),t=r(".js-twofas-migrate-users"),a=r(".js-reload-qr-code"),s=r(".js-reload-qr-code-and-set-modal-status"),n=r(".js-send-sms"),i=r(".js-waiting-button"),d=r(".js-waiting-link"),l=r(".js-autofocus"),c=r(".twofas-reload-warning-modal"),f=r(".twofas-error-modal"),u=r(".twofas-success-modal"),p=r(".twofas-migrate-users-confirmation-modal"),m=r(".twofas-trusted-device"),w=r(".twofas-offline-codes-date"),v=r("#myChart"),g=r("#error-modal-message"),h=r("#success-modal-message"),b=r("img.twofas-qr-code"),j=r(".twofas-spinner-container.twofas-qr-refresh"),y=r(".twofas-admin-users-wrapper h2"),C="",x=0;function k(e){var t,a=(t=e,JSON.parse(t.responseText).error);void 0===a&&(a="Server error occurred. Please try to refresh this page."),g.html(a),f.trigger("display")}function _(e){var t=e.qrCode,a=e.totpSecret;r(".twofas-qr-code").attr("src",t),r(".twofas-totp-secret").html(a),r("#totp-secret").val(a),r(".twofas-mobile-config").attr("href",e.qrCodeMessage),b.removeClass("twofas-hidden"),j.removeClass("twofas-visible")}function q(){var e=r(".twofas-reload-qr-code-form").attr("action"),t={_wpnonce:r('.twofas-buttons-bottom > input[name="_wpnonce"]').val()};b.addClass("twofas-hidden"),j.addClass("twofas-visible"),r.ajax({url:e,type:"post",data:t,success:_,error:k})}function D(e){return twofas.months[e]}function T(){var e=r("#myChart")[0].getContext("2d"),t={datasets:[{data:[r(".js-active-users-count").val(),r(".js-inactive-users-count").val()],backgroundColor:["#202225","#eb1c23"],borderWidth:0}],labels:[twofas.activeUsers,twofas.inactiveUsers]};v=new Chart(e,{type:"doughnut",data:t,options:{responsive:!0,maintainAspectRatio:!1,legend:{display:!1},title:{display:!1},animation:{animateScale:!0,animateRotate:!0},tooltips:{enabled:!0}}}),r("#js-legend").html(v.generateLegend()),v.update()}t.length&&t.on("click",function(e){e.preventDefault(),p.trigger("close"),o.attr("disabled",!0),C=y.html();var t=r("#twofas-migration-users-form").attr("action"),a={_wpnonce:r('#twofas-migration-users-form > input[name="_wpnonce"]').val()},s=0;r.ajax({url:t,type:"post",data:a,error:function(e){k(e)}}),x=setInterval(function(){s=++s%4,y.html(twofas.migrationInProgress+Array(s+1).join("."))},500),v.data.labels[1]=twofas.migratedUsers,v.data.datasets[0].backgroundColor[1]="#10b74a",v.update(),r("#js-legend").html(v.generateLegend()),function a(){setTimeout(function(){r.ajax({url:twofas.ajaxUrl,type:"get",data:{page:twofas.submenuDashboard,"twofas-action":"migration-users-status"},success:function(e){var t=v.data;0<t.datasets.length&&(t.datasets[0].data[1]=e.migrated_users),v.update(),e.migrated_users>=e.active_users_count?(clearInterval(x),y.html(twofas.migrationCompleted),h.html("Migration completed successfully. Now please turn off and uninstall 2FAS Classic plugin."),u.trigger("display"),o.hide(),setTimeout(function(){T(),y.html(C)},3e3)):a()},error:function(e){k(e)}})},1e3)}()}),m.length&&(r(".twofas-trusted-device-country").each(function(e,a){r.get("https://ipapi.co/"+a.innerText+"/json/",function(e){var t=e.country;a.innerText=t||"",a.className+=" twofas-visible"})}),r(".twofas-date").each(function(e,t){var a,s=1e3*t.innerText;isNaN(s)||(t.innerText=D((a=new Date(s)).getMonth())+" "+a.getDate()+", "+a.getFullYear())}),r(".twofas-hour").each(function(e,t){var a,s,o,n,r=1e3*t.innerText;isNaN(r)||(t.innerText=(a=new Date(r),s=a.getHours(),o=a.getMinutes(),n=12<=s?"PM":"AM",12<s&&(s-=12),o<10&&(o="0"+o),s+":"+o+" "+n),t.className+=" twofas-visible")})),w.length&&function(){var e=1e3*w[0].innerText;if(!isNaN(e)){var t=new Date(e),a=D(t.getMonth()),s=t.getDate(),o=t.getFullYear();w[0].innerText=s+" "+a+" "+o}}(),v.length&&T(),l.focus(function(){this.value=this.value}),e.click(function(e){e.preventDefault();var t=r(".twofas-generate-offline-codes-form").attr("action"),a=r('.twofas-generate-offline-codes-form > input[name="_wpnonce"]').val(),n=r(this);n.addClass("twofas-wait").prop("disabled",!0);var s={_wpnonce:a};r.ajax({url:t,type:"post",data:s,success:function(e){var t=e.codes,a=encodeURIComponent(t.join("\n")),s=function(e){var t,a="<code><pre>";for(t in e)e.hasOwnProperty(t)&&(a+=e[t]+"\r\n");return a+="</pre></code>"}(t),o=function(e){var t,a="";for(t in e)e.hasOwnProperty(t)&&(a+='<input type="hidden" name="code['+t+']" value="'+e[t]+'" />');return a}(t);r(".twofas-offline-stats-generated").hide(),r(".twofas-offline-codes-data").html(s),r(".twofas-offline-codes-inputs").html(o),r(".twofas-download-codes-link").attr("href","data:text/plain;charset=utf-8,"+a),r(".twofas-offline-codes-list").show(),r(".js-backup-codes-tick").removeClass("twofas-icon-tick").addClass("twofas-icon-tick-enabled"),n.removeClass("twofas-wait").prop("disabled",!1)},error:function(e){n.removeClass("twofas-wait").prop("disabled",!1),k(e)}})}),a.submit(function(e){e.preventDefault(),q()}),r(document).on("click",".js-reload-qr-code",function(e){e.preventDefault(),q()}),s.submit(function(e){if(e.preventDefault(),r("#reload-modal-check").is(":checked")){var t=r(".js-reload-qr-code-and-set-modal-status").attr("action"),a={_wpnonce:r('.js-reload-qr-code-and-set-modal-status > input[name="_wpnonce"]').val()};r.ajax({url:t,type:"post",data:a,error:k}),r(".twofas-reload-qr-code-form").removeClass("js-open-reload-warning-modal").addClass("js-reload-qr-code")}c.trigger("close"),q()}),n.click(function(e){e.preventDefault();var t=r(this);t.addClass("twofas-wait").prop("disabled",!0);var a=r(".twofas-send-sms-form").attr("action"),s=r('.twofas-send-sms-form > input[name="_wpnonce"]').val(),o=r("#phone-number").val(),n={phone_number:o,_wpnonce:s};r.ajax({url:a,type:"post",data:n,success:function(e){r("#verified-phone-number").val(o),r("#authentication-id").val(e.authenticationId),r(".twofas-sms-sent-button-text").hide(),r(".twofas-sms-sent-message").show(),t.removeClass("twofas-wait"),r("#twofas-token").prop("disabled",!1),r(".twofas-enable-token-btn").prop("disabled",!1)},error:function(e){t.removeClass("twofas-wait").prop("disabled",!1),k(e)}})}),i.submit(function(e){e.preventDefault();var t=this;return r(this).find('*[type="submit"]').addClass("twofas-wait").prop("disabled",!0),setTimeout(function(){t.submit()},1),!0}),d.click(function(){r(this).addClass("twofas-wait").prop("disabled",!0)})}catch(e){Sentry.captureException(e),g.html("Server error occurred. Please try to refresh this page."),f.trigger("display")}}(jQuery); -
2fas/trunk/assets/js/modal.js
r2551311 r2615458 12 12 creditCardModal = $( '.twofas-credit-card-modal' ), 13 13 errorModal = $( '.twofas-error-modal' ), 14 successModal = $( '.twofas-success-modal' ), 14 15 removeConfigModal = $( '.twofas-remove-config-modal' ), 15 16 disableTotpModal = $( '.twofas-disable-totp-modal' ), … … 162 163 } ); 163 164 165 successModal.on( 'display', function() { 166 openModal( successModal ); 167 } ); 168 164 169 if ( wizardModal.length ) { 165 170 openModal( wizardModal ); -
2fas/trunk/assets/js/modal.min.js
r2551311 r2615458 1 !function(e){try{var t=e(".twofas-qr-modal"),o=e(".twofas-plan-modal"),a=e(".twofas-deletion-confirmation-modal"),n=e(".twofas-delete-totp-modal"),i=e(".twofas-logout-modal"),s=e(".twofas-downgrade-modal"),l=e(".twofas-wizard-modal"),d=e(".twofas-reload-warning-modal"),c=e(".twofas-credit-card-modal"),f=e(".twofas-error-modal"),r=e(".twofas-remove-config-modal"),u=e(".twofas-disable-totp-modal"),m=e(".twofas-disable-phone-modal"),p=e(".twofas-migrate-users-confirmation-modal"),w=e(".js-close-modal"),h=e(".js-open-qr-modal"),v=e(".js-open-plan-modal"),b=e(".js-plan-redirect"),j=e(".js-confirm"),g=e(".js-close-cc-complete"),D=e(".js-open-logout-modal"),k=e(".js-open-reload-warning-modal"),y=e(".js-open-downgrade-modal"),C=e(".js-open-credit-card-modal"),q=e(".js-open-deletion-confirmation-modal"),x=e(".js-open-delete-totp-modal"),z=e(".js-open-remove-config-modal"),E=e(".js-open-disable-totp-modal"),Q=e(".js-open-disable-phone-modal"),S=e(".js-open-migrate-users-modal"),A=".twofas-modal-backdrop",B=!1,F=null;function G(t){t.css({display:"table"}).animate({opacity:1},500),B=!0}function H(t){t.animate({opacity:0},250,function(){e(this).css({display:""}),t.children().css({display:""}),B=!1})}function I(t){if(B){var o=e(".twofas-modal");if(!o.is(t.target)&&0===o.has(t.target).length)H(o.parents().find(A))}}h.click(function(){G(t)}),v.click(function(){e(".twofas-update-card-before").removeClass("twofas-hidden"),e(".twofas-update-card-after").addClass("twofas-hidden"),G(o)}),b.click(function(){e(".twofas-update-card-before").addClass("twofas-hidden"),e(".twofas-update-card-after").removeClass("twofas-hidden")}),z.click(function(t){t.preventDefault(),G(r)}),g.click(function(t){t.preventDefault(),location.reload()}),j.click(function(t){t.preventDefault(),F.trigger("submit")}),E.submit(function(t){B||(F=e(this),t.preventDefault(),G(u))}),Q.submit(function(t){B||(F=e(this),t.preventDefault(),G(m))}),q.submit(function(t){B||(F=e(this),t.preventDefault(),G(a))}),x.submit(function(t){B||(F=e(this),t.preventDefault(),G(n))}),D.submit(function(t){B||(F=e(this),t.preventDefault(),G(i))}),k.submit(function(t){t.preventDefault(),G(d)}),d.on("close",function(){H(d)}),S.click(function(t){t.preventDefault(),G(p)}),p.on("close",function(){H(p)}),f.on("display",function(){G(f)}),l.length&&G(l),y.submit(function(t){B||(F=e(this),t.preventDefault(),G(s))}),C.submit(function(t){t.preventDefault(),G(c)}),w.click(function(t){t.preventDefault(),H(e(this).parents().find(A))}),e(document).keyup(function(t){27===t.keyCode&&I(t)}),e(document).mouseup(function(t){B&&I(t)})}catch(t){Sentry.captureException(t)}}(jQuery);1 !function(e){try{var o=e(".twofas-qr-modal"),t=e(".twofas-plan-modal"),a=e(".twofas-deletion-confirmation-modal"),n=e(".twofas-delete-totp-modal"),i=e(".twofas-logout-modal"),s=e(".twofas-downgrade-modal"),l=e(".twofas-wizard-modal"),d=e(".twofas-reload-warning-modal"),c=e(".twofas-credit-card-modal"),f=e(".twofas-error-modal"),r=e(".twofas-success-modal"),u=e(".twofas-remove-config-modal"),m=e(".twofas-disable-totp-modal"),p=e(".twofas-disable-phone-modal"),w=e(".twofas-migrate-users-confirmation-modal"),h=e(".js-close-modal"),v=e(".js-open-qr-modal"),b=e(".js-open-plan-modal"),j=e(".js-plan-redirect"),g=e(".js-confirm"),D=e(".js-close-cc-complete"),y=e(".js-open-logout-modal"),k=e(".js-open-reload-warning-modal"),C=e(".js-open-downgrade-modal"),q=e(".js-open-credit-card-modal"),x=e(".js-open-deletion-confirmation-modal"),z=e(".js-open-delete-totp-modal"),E=e(".js-open-remove-config-modal"),Q=e(".js-open-disable-totp-modal"),S=e(".js-open-disable-phone-modal"),A=e(".js-open-migrate-users-modal"),B=".twofas-modal-backdrop",F=!1,G=null;function H(o){o.css({display:"table"}).animate({opacity:1},500),F=!0}function I(o){o.animate({opacity:0},250,function(){e(this).css({display:""}),o.children().css({display:""}),F=!1})}function J(o){if(F){var t=e(".twofas-modal");if(!t.is(o.target)&&0===t.has(o.target).length)I(t.parents().find(B))}}v.click(function(){H(o)}),b.click(function(){e(".twofas-update-card-before").removeClass("twofas-hidden"),e(".twofas-update-card-after").addClass("twofas-hidden"),H(t)}),j.click(function(){e(".twofas-update-card-before").addClass("twofas-hidden"),e(".twofas-update-card-after").removeClass("twofas-hidden")}),E.click(function(o){o.preventDefault(),H(u)}),D.click(function(o){o.preventDefault(),location.reload()}),g.click(function(o){o.preventDefault(),G.trigger("submit")}),Q.submit(function(o){F||(G=e(this),o.preventDefault(),H(m))}),S.submit(function(o){F||(G=e(this),o.preventDefault(),H(p))}),x.submit(function(o){F||(G=e(this),o.preventDefault(),H(a))}),z.submit(function(o){F||(G=e(this),o.preventDefault(),H(n))}),y.submit(function(o){F||(G=e(this),o.preventDefault(),H(i))}),k.submit(function(o){o.preventDefault(),H(d)}),d.on("close",function(){I(d)}),A.click(function(o){o.preventDefault(),H(w)}),w.on("close",function(){I(w)}),f.on("display",function(){H(f)}),r.on("display",function(){H(r)}),l.length&&H(l),C.submit(function(o){F||(G=e(this),o.preventDefault(),H(s))}),q.submit(function(o){o.preventDefault(),H(c)}),h.click(function(o){o.preventDefault(),I(e(this).parents().find(B))}),e(document).keyup(function(o){27===o.keyCode&&J(o)}),e(document).mouseup(function(o){F&&J(o)})}catch(o){Sentry.captureException(o)}}(jQuery); -
2fas/trunk/changelog.txt
r2594222 r2615458 1 1 == Changelog == 2 3 = 3.1.0 (Oct. 17, 2021) = 4 * Add deprecation info 2 5 3 6 = 3.0.6 (Sep. 6, 2021) = -
2fas/trunk/constants.php
r2594222 r2615458 15 15 define( 'TWOFAS_TEMPLATES_PATH', $templates_path ); 16 16 define( 'TWOFAS_WP_ADMIN_PATH', $admin_url ); 17 define( 'TWOFAS_PLUGIN_VERSION', '3. 0.6' );17 define( 'TWOFAS_PLUGIN_VERSION', '3.1.0' ); 18 18 define( 'TWOFAS_DEPRECATE_PHP_OLDER_THAN', '5.6' ); -
2fas/trunk/readme.txt
r2594222 r2615458 132 132 == Changelog == 133 133 134 = 3.1.0 (Oct. 17, 2021) = 135 * Add deprecation info 136 134 137 = 3.0.6 (Sep. 6, 2021) = 135 138 * Removed old migration -
2fas/trunk/start.php
r2551311 r2615458 47 47 } 48 48 49 if ( $is_admin ) { 50 add_action( 'admin_notices', function () { 51 echo ' 52 <div class="notice notice-info info twofas-info-notice"> 53 <p> 54 <strong>2FAS Classic plugin is obsolete!</strong><br/> 55 On the 1st of December 2021, we will turn off push notifications but logging with 2FA tokens will work. <br /> 56 From this day on 2FAS Classic plugin will not be supported anymore. <br /> 57 We recommend you to download the 2FAS Prime plugin and then migrate all your settings and tokens from 2FAS Classic to the 2FAS Prime plugin. 58 </p> 59 </div>'; 60 } ); 61 } 62 49 63 /** @var Listener_Provider $listener */ 50 64 $listener = $twofas_container->get( Listener_Provider::class ); -
2fas/trunk/templates/dashboard/admin/admin.html.twig
r2551311 r2615458 361 361 {% include 'modals/confirmation/downgrade-modal.html.twig' %} 362 362 {% include 'modals/confirmation/migrate-users-modal.html.twig' %} 363 {% include 'modals/success-modal.html.twig' %} 363 364 {% include 'modals/plan-modal.html.twig' %} 364 365 {% include 'modals/credit-card-modal.html.twig' %} -
2fas/trunk/templates/modals/confirmation/migrate-users-modal.html.twig
r2551311 r2615458 6 6 <div class="twofas-text-content"> 7 7 <p> 8 {{ esc_html__('You are going to migrate your data from 2FAS Classic to 2FAS Prime. Remember that only 2FA settings will be migrated. Trusted devices and backup codes will not be transferred. Are you sure you want to proceed?', '2fas') }} 8 You are going to migrate your data from 2FAS Classic to 2FAS Prime.<br /> 9 Remember that only 2FAS Classic settings and tokens (secret/service keys) will be migrated. <br /> 10 <strong>Trusted devices and backup codes will not be transferred.</strong><br /> 11 Are you sure you want to proceed? 9 12 </p> 10 13 </div> -
2fas/trunk/twofas.php
r2594222 r2615458 4 4 * Plugin URI: https://wordpress.org/plugins/2fas/ 5 5 * Description: 2FAS strengthens WordPress admin security by requiring an additional verification code on untrusted devices. 6 * Version: 3. 0.66 * Version: 3.1.0 7 7 * Author: Two Factor Authentication Service Inc. 8 8 * Author URI: https://2fas.com -
2fas/trunk/vendor/autoload.php
r2343404 r2615458 5 5 require_once __DIR__ . '/composer/autoload_real.php'; 6 6 7 return ComposerAutoloaderInit 66cf7295c106ae5a08d97a7953e2c171::getLoader();7 return ComposerAutoloaderInit30d7a7d42f7ac83137b3d236ae23e084::getLoader(); -
2fas/trunk/vendor/composer/autoload_real.php
r2594222 r2615458 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit 66cf7295c106ae5a08d97a7953e2c1715 class ComposerAutoloaderInit30d7a7d42f7ac83137b3d236ae23e084 6 6 { 7 7 private static $loader; … … 23 23 } 24 24 25 spl_autoload_register(array('ComposerAutoloaderInit 66cf7295c106ae5a08d97a7953e2c171', 'loadClassLoader'), true, true);25 spl_autoload_register(array('ComposerAutoloaderInit30d7a7d42f7ac83137b3d236ae23e084', 'loadClassLoader'), true, true); 26 26 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__))); 27 spl_autoload_unregister(array('ComposerAutoloaderInit 66cf7295c106ae5a08d97a7953e2c171', 'loadClassLoader'));27 spl_autoload_unregister(array('ComposerAutoloaderInit30d7a7d42f7ac83137b3d236ae23e084', 'loadClassLoader')); 28 28 29 29 $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); … … 31 31 require __DIR__ . '/autoload_static.php'; 32 32 33 call_user_func(\Composer\Autoload\ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c171::getInitializer($loader));33 call_user_func(\Composer\Autoload\ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084::getInitializer($loader)); 34 34 } else { 35 35 $map = require __DIR__ . '/autoload_namespaces.php'; … … 52 52 53 53 if ($useStaticLoader) { 54 $includeFiles = Composer\Autoload\ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c171::$files;54 $includeFiles = Composer\Autoload\ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084::$files; 55 55 } else { 56 56 $includeFiles = require __DIR__ . '/autoload_files.php'; 57 57 } 58 58 foreach ($includeFiles as $fileIdentifier => $file) { 59 composerRequire 66cf7295c106ae5a08d97a7953e2c171($fileIdentifier, $file);59 composerRequire30d7a7d42f7ac83137b3d236ae23e084($fileIdentifier, $file); 60 60 } 61 61 … … 64 64 } 65 65 66 function composerRequire 66cf7295c106ae5a08d97a7953e2c171($fileIdentifier, $file)66 function composerRequire30d7a7d42f7ac83137b3d236ae23e084($fileIdentifier, $file) 67 67 { 68 68 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { -
2fas/trunk/vendor/composer/autoload_static.php
r2551311 r2615458 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c1717 class ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084 8 8 { 9 9 public static $files = array ( … … 1007 1007 { 1008 1008 return \Closure::bind(function () use ($loader) { 1009 $loader->prefixLengthsPsr4 = ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c171::$prefixLengthsPsr4;1010 $loader->prefixDirsPsr4 = ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c171::$prefixDirsPsr4;1011 $loader->prefixesPsr0 = ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c171::$prefixesPsr0;1012 $loader->classMap = ComposerStaticInit 66cf7295c106ae5a08d97a7953e2c171::$classMap;1009 $loader->prefixLengthsPsr4 = ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084::$prefixLengthsPsr4; 1010 $loader->prefixDirsPsr4 = ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084::$prefixDirsPsr4; 1011 $loader->prefixesPsr0 = ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084::$prefixesPsr0; 1012 $loader->classMap = ComposerStaticInit30d7a7d42f7ac83137b3d236ae23e084::$classMap; 1013 1013 1014 1014 }, null, ClassLoader::class); -
2fas/trunk/vendor/composer/installed.json
r2594222 r2615458 33 33 "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", 34 34 "homepage": "https://github.com/container-interop/container-interop", 35 "support": { 36 "issues": "https://github.com/container-interop/container-interop/issues", 37 "source": "https://github.com/container-interop/container-interop/tree/master" 38 }, 35 39 "abandoned": "psr/container", 36 40 "install-path": "../container-interop/container-interop" … … 87 91 "qrcode" 88 92 ], 93 "support": { 94 "issues": "https://github.com/endroid/qr-code/issues", 95 "source": "https://github.com/endroid/qr-code/tree/1.6.6" 96 }, 89 97 "install-path": "../endroid/qr-code" 90 98 }, … … 133 141 "invoker" 134 142 ], 143 "support": { 144 "issues": "https://github.com/PHP-DI/Invoker/issues", 145 "source": "https://github.com/PHP-DI/Invoker/tree/master" 146 }, 135 147 "install-path": "../php-di/invoker" 136 148 }, … … 199 211 "di" 200 212 ], 213 "support": { 214 "issues": "https://github.com/PHP-DI/PHP-DI/issues", 215 "source": "https://github.com/PHP-DI/PHP-DI/tree/5.4" 216 }, 201 217 "install-path": "../php-di/php-di" 202 218 }, … … 239 255 "reflection" 240 256 ], 257 "support": { 258 "issues": "https://github.com/PHP-DI/PhpDocReader/issues", 259 "source": "https://github.com/PHP-DI/PhpDocReader/tree/master" 260 }, 241 261 "install-path": "../php-di/phpdoc-reader" 242 262 }, … … 288 308 "psr-6" 289 309 ], 310 "support": { 311 "source": "https://github.com/php-fig/cache/tree/master" 312 }, 290 313 "install-path": "../psr/cache" 291 314 }, … … 340 363 "psr" 341 364 ], 365 "support": { 366 "issues": "https://github.com/php-fig/container/issues", 367 "source": "https://github.com/php-fig/container/tree/master" 368 }, 342 369 "install-path": "../psr/container" 343 370 }, … … 407 434 "logging" 408 435 ], 436 "support": { 437 "issues": "https://github.com/getsentry/sentry-php/issues", 438 "source": "https://github.com/getsentry/sentry-php/tree/1.11.0" 439 }, 409 440 "install-path": "../sentry/sentry" 410 441 }, … … 472 503 "portable" 473 504 ], 505 "support": { 506 "source": "https://github.com/symfony/polyfill-ctype/tree/v1.19.0" 507 }, 474 508 "funding": [ 475 509 { … … 553 587 "templating" 554 588 ], 589 "support": { 590 "issues": "https://github.com/twigphp/Twig/issues", 591 "source": "https://github.com/twigphp/Twig/tree/1.x" 592 }, 555 593 "install-path": "../twig/twig" 556 594 }, … … 661 699 ], 662 700 "description": "Encryption for TwoFAS data.", 701 "support": { 702 "issues": "https://github.com/twofas/encryption/issues", 703 "source": "https://github.com/twofas/encryption/tree/master" 704 }, 663 705 "install-path": "../twofas/encryption" 664 706 }, … … 714 756 ], 715 757 "description": "SDK for 2fas.com API", 758 "support": { 759 "issues": "https://github.com/twofas/sdk/issues", 760 "source": "https://github.com/twofas/sdk/tree/v7.2.0" 761 }, 716 762 "install-path": "../twofas/sdk" 717 763 }, … … 756 802 ], 757 803 "description": "Validation rules for SDK", 804 "support": { 805 "issues": "https://github.com/twofas/validation-rules/issues", 806 "source": "https://github.com/twofas/validation-rules/tree/master" 807 }, 758 808 "install-path": "../twofas/validation-rules" 759 809 }, … … 861 911 "useragent" 862 912 ], 913 "support": { 914 "issues": "https://github.com/WhichBrowser/Parser-PHP/issues", 915 "source": "https://github.com/WhichBrowser/Parser-PHP/tree/v2.1.2" 916 }, 863 917 "install-path": "../whichbrowser/parser" 864 918 } -
2fas/trunk/vendor/composer/installed.php
r2594222 r2615458 6 6 'install_path' => __DIR__ . '/../../', 7 7 'aliases' => array(), 8 'reference' => '1 6ab34c38e56f41eb9fa650f0b439d5a0ebdee7b',8 'reference' => '17280cee06f939f62f07096cacf0a8c383eaf79a', 9 9 'name' => 'twofas/twofas-wp-plugin', 10 10 'dev' => false, … … 152 152 'install_path' => __DIR__ . '/../../', 153 153 'aliases' => array(), 154 'reference' => '1 6ab34c38e56f41eb9fa650f0b439d5a0ebdee7b',154 'reference' => '17280cee06f939f62f07096cacf0a8c383eaf79a', 155 155 'dev_requirement' => false, 156 156 ),
Note: See TracChangeset
for help on using the changeset viewer.