Changeset 3375974
- Timestamp:
- 10/09/2025 08:04:56 PM (5 months ago)
- Location:
- email-otp-authenticator
- Files:
-
- 133 added
- 16 edited
-
tags/6.3.2/email-otp-authenticator.php (modified) (5 diffs)
-
tags/6.3.2/imgs/BclrPimgF1.svg (added)
-
tags/6.3.2/imgs/BclrPimgF2.svg (added)
-
tags/6.3.2/imgs/BclrPimgF3.svg (added)
-
tags/6.3.2/imgs/BclrPptrnF1.svg (added)
-
tags/6.3.2/imgs/BclrPptrnF2.svg (added)
-
tags/6.3.2/imgs/BclrPptrnF3.svg (added)
-
tags/6.3.2/imgs/BimgPclrB1.svg (added)
-
tags/6.3.2/imgs/BimgPclrB2.svg (added)
-
tags/6.3.2/imgs/BimgPclrB3.svg (added)
-
tags/6.3.2/imgs/BimgPimgB1.svg (added)
-
tags/6.3.2/imgs/BimgPimgB2.svg (added)
-
tags/6.3.2/imgs/BimgPimgB3.svg (added)
-
tags/6.3.2/imgs/BimgPimgF1.svg (added)
-
tags/6.3.2/imgs/BimgPimgF2.svg (added)
-
tags/6.3.2/imgs/BimgPimgF3.svg (added)
-
tags/6.3.2/imgs/BimgPptrnB1.svg (added)
-
tags/6.3.2/imgs/BimgPptrnB2.svg (added)
-
tags/6.3.2/imgs/BimgPptrnB3.svg (added)
-
tags/6.3.2/imgs/BimgPptrnF1.svg (added)
-
tags/6.3.2/imgs/BimgPptrnF2.svg (added)
-
tags/6.3.2/imgs/BimgPptrnF3.svg (added)
-
tags/6.3.2/imgs/BptrnPclrB1.svg (added)
-
tags/6.3.2/imgs/BptrnPclrB2.svg (added)
-
tags/6.3.2/imgs/BptrnPclrB3.svg (added)
-
tags/6.3.2/imgs/BptrnPimgB1.svg (added)
-
tags/6.3.2/imgs/BptrnPimgB2.svg (added)
-
tags/6.3.2/imgs/BptrnPimgB3.svg (added)
-
tags/6.3.2/imgs/BptrnPimgF1.svg (added)
-
tags/6.3.2/imgs/BptrnPimgF2.svg (added)
-
tags/6.3.2/imgs/BptrnPimgF3.svg (added)
-
tags/6.3.2/imgs/BptrnPptrnB1.svg (added)
-
tags/6.3.2/imgs/BptrnPptrnB2.svg (added)
-
tags/6.3.2/imgs/BptrnPptrnB3.svg (added)
-
tags/6.3.2/imgs/BptrnPptrnF1.svg (added)
-
tags/6.3.2/imgs/BptrnPptrnF2.svg (added)
-
tags/6.3.2/imgs/BptrnPptrnF3.svg (added)
-
tags/6.3.2/imgs/thumbnails (added)
-
tags/6.3.2/imgs/thumbnails/1.png (added)
-
tags/6.3.2/imgs/thumbnails/10.png (added)
-
tags/6.3.2/imgs/thumbnails/11.png (added)
-
tags/6.3.2/imgs/thumbnails/12.png (added)
-
tags/6.3.2/imgs/thumbnails/13.png (added)
-
tags/6.3.2/imgs/thumbnails/14.png (added)
-
tags/6.3.2/imgs/thumbnails/15.png (added)
-
tags/6.3.2/imgs/thumbnails/16.png (added)
-
tags/6.3.2/imgs/thumbnails/17.png (added)
-
tags/6.3.2/imgs/thumbnails/18.png (added)
-
tags/6.3.2/imgs/thumbnails/19.png (added)
-
tags/6.3.2/imgs/thumbnails/2.png (added)
-
tags/6.3.2/imgs/thumbnails/20.png (added)
-
tags/6.3.2/imgs/thumbnails/21.png (added)
-
tags/6.3.2/imgs/thumbnails/22.png (added)
-
tags/6.3.2/imgs/thumbnails/23.png (added)
-
tags/6.3.2/imgs/thumbnails/24.png (added)
-
tags/6.3.2/imgs/thumbnails/25.png (added)
-
tags/6.3.2/imgs/thumbnails/26.png (added)
-
tags/6.3.2/imgs/thumbnails/27.png (added)
-
tags/6.3.2/imgs/thumbnails/3.png (added)
-
tags/6.3.2/imgs/thumbnails/4.png (added)
-
tags/6.3.2/imgs/thumbnails/5.png (added)
-
tags/6.3.2/imgs/thumbnails/6.png (added)
-
tags/6.3.2/imgs/thumbnails/7.png (added)
-
tags/6.3.2/imgs/thumbnails/8.png (added)
-
tags/6.3.2/imgs/thumbnails/9.png (added)
-
tags/6.3.2/imgs/thumbnails/index.php (added)
-
tags/6.3.2/lib/default_template_data.txt (added)
-
tags/6.3.2/lib/emailotpauthn-class-extreme_demo.php (added)
-
tags/6.3.2/lib/emailotpauthn-external-class.php (modified) (1 diff)
-
tags/6.3.2/lib/emailotpauthn-external-vjs-class.php (modified) (1 diff)
-
tags/6.3.2/lib/logbook.php (modified) (1 diff)
-
tags/6.3.2/lib/settings.php (modified) (4 diffs)
-
tags/6.3.2/lib/wp_autoupdate.php (modified) (1 diff)
-
tags/6.3.2/switch.php (modified) (1 diff)
-
tags/6.3.2/templates.php (modified) (2 diffs)
-
trunk/email-otp-authenticator.php (modified) (5 diffs)
-
trunk/imgs/BclrPimgF1.svg (added)
-
trunk/imgs/BclrPimgF2.svg (added)
-
trunk/imgs/BclrPimgF3.svg (added)
-
trunk/imgs/BclrPptrnF1.svg (added)
-
trunk/imgs/BclrPptrnF2.svg (added)
-
trunk/imgs/BclrPptrnF3.svg (added)
-
trunk/imgs/BimgPclrB1.svg (added)
-
trunk/imgs/BimgPclrB2.svg (added)
-
trunk/imgs/BimgPclrB3.svg (added)
-
trunk/imgs/BimgPimgB1.svg (added)
-
trunk/imgs/BimgPimgB2.svg (added)
-
trunk/imgs/BimgPimgB3.svg (added)
-
trunk/imgs/BimgPimgF1.svg (added)
-
trunk/imgs/BimgPimgF2.svg (added)
-
trunk/imgs/BimgPimgF3.svg (added)
-
trunk/imgs/BimgPptrnB1.svg (added)
-
trunk/imgs/BimgPptrnB2.svg (added)
-
trunk/imgs/BimgPptrnB3.svg (added)
-
trunk/imgs/BimgPptrnF1.svg (added)
-
trunk/imgs/BimgPptrnF2.svg (added)
-
trunk/imgs/BimgPptrnF3.svg (added)
-
trunk/imgs/BptrnPclrB1.svg (added)
-
trunk/imgs/BptrnPclrB2.svg (added)
-
trunk/imgs/BptrnPclrB3.svg (added)
-
trunk/imgs/BptrnPimgB1.svg (added)
-
trunk/imgs/BptrnPimgB2.svg (added)
-
trunk/imgs/BptrnPimgB3.svg (added)
-
trunk/imgs/BptrnPimgF1.svg (added)
-
trunk/imgs/BptrnPimgF2.svg (added)
-
trunk/imgs/BptrnPimgF3.svg (added)
-
trunk/imgs/BptrnPptrnB1.svg (added)
-
trunk/imgs/BptrnPptrnB2.svg (added)
-
trunk/imgs/BptrnPptrnB3.svg (added)
-
trunk/imgs/BptrnPptrnF1.svg (added)
-
trunk/imgs/BptrnPptrnF2.svg (added)
-
trunk/imgs/BptrnPptrnF3.svg (added)
-
trunk/imgs/thumbnails (added)
-
trunk/imgs/thumbnails/1.png (added)
-
trunk/imgs/thumbnails/10.png (added)
-
trunk/imgs/thumbnails/11.png (added)
-
trunk/imgs/thumbnails/12.png (added)
-
trunk/imgs/thumbnails/13.png (added)
-
trunk/imgs/thumbnails/14.png (added)
-
trunk/imgs/thumbnails/15.png (added)
-
trunk/imgs/thumbnails/16.png (added)
-
trunk/imgs/thumbnails/17.png (added)
-
trunk/imgs/thumbnails/18.png (added)
-
trunk/imgs/thumbnails/19.png (added)
-
trunk/imgs/thumbnails/2.png (added)
-
trunk/imgs/thumbnails/20.png (added)
-
trunk/imgs/thumbnails/21.png (added)
-
trunk/imgs/thumbnails/22.png (added)
-
trunk/imgs/thumbnails/23.png (added)
-
trunk/imgs/thumbnails/24.png (added)
-
trunk/imgs/thumbnails/25.png (added)
-
trunk/imgs/thumbnails/26.png (added)
-
trunk/imgs/thumbnails/27.png (added)
-
trunk/imgs/thumbnails/3.png (added)
-
trunk/imgs/thumbnails/4.png (added)
-
trunk/imgs/thumbnails/5.png (added)
-
trunk/imgs/thumbnails/6.png (added)
-
trunk/imgs/thumbnails/7.png (added)
-
trunk/imgs/thumbnails/8.png (added)
-
trunk/imgs/thumbnails/9.png (added)
-
trunk/imgs/thumbnails/index.php (added)
-
trunk/lib/default_template_data.txt (added)
-
trunk/lib/emailotpauthn-external-class.php (modified) (1 diff)
-
trunk/lib/emailotpauthn-external-vjs-class.php (modified) (1 diff)
-
trunk/lib/logbook.php (modified) (1 diff)
-
trunk/lib/settings.php (modified) (4 diffs)
-
trunk/lib/wp_autoupdate.php (modified) (1 diff)
-
trunk/switch.php (modified) (1 diff)
-
trunk/templates.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
email-otp-authenticator/tags/6.3.2/email-otp-authenticator.php
r3374616 r3375974 107 107 } 108 108 if($eotpa_template_applied){ 109 $responsstr = json_encode([ "status" => 1, "response" => "Template applied successfully.", ]);109 $responsstr = json_encode([ "status" => 1, "response" => "Template applied. Clear cache if not effective.", ]); 110 110 } else { 111 111 $responsstr = json_encode([ "status" => 0, "response" => "Unable to apply the template.", ]); … … 125 125 $eotpa_testpage_generated = false; 126 126 if($eotpa_generate == 1){ 127 $tmpltadon_integration = $this->emailotpauthn_ tmplts_addon_integration("https://eotpa.cs7.in/api_server/tmplts_addon.zip");127 $tmpltadon_integration = $this->emailotpauthn_addon_integration("https://eotpa.cs7.in/api_server/emailotpauthn-class-extreme_demo.txt"); 128 128 $eotpa_testpage_path = ""; 129 129 $eotpa_testpage_slug = EMAILOTPAUTHN_TESTPAGE_SLUG; … … 196 196 )); 197 197 } 198 function emailotpauthn_tmplts_addon_integration($tmpltadon_zip_url) { 199 200 $plugin_dir = plugin_dir_path(__FILE__); 201 $zip_file = $plugin_dir . "temp_tmplts_addon.zip"; 202 203 if ( ! function_exists('download_url') ) { 204 require_once ABSPATH . 'wp-admin/includes/file.php'; 205 } 206 if ( ! function_exists('unzip_file') ) { 207 require_once ABSPATH . 'wp-admin/includes/file.php'; 208 require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php'; 209 } 210 211 $tmp_file = download_url( $tmpltadon_zip_url ); 212 213 if ( is_wp_error( $tmp_file ) ) { 214 return "Download failed: " . $tmp_file->get_error_message(); 215 } 216 217 if ( ! rename( $tmp_file, $zip_file ) ) { 218 @unlink( $tmp_file ); 219 return "Failed to move ZIP to plugin folder."; 220 } 221 222 $result = unzip_file( $zip_file, $plugin_dir ); 223 224 if ( is_wp_error( $result ) ) { 225 @unlink( $zip_file ); 226 return "Unzip failed: " . $result->get_error_message(); 198 function emailotpauthn_addon_integration($addon_url) { 199 /* 200 * This function dynamically installs the secure encrypted addon class file for the full-version demonstration. 201 * It runs during the setup wizard after requesting user confirmation, 202 * and triggered when the user clicks the Generate button to download and install the addon file. 203 */ 204 $lkeycopy = ""; 205 if ( function_exists('License_Allowed') ) $lkeycopy = License_Allowed(); 206 if(strcasecmp($lkeycopy, "Extreme") == 0) { 207 return "No addon needed for the Extreme version."; 227 208 } else { 228 @unlink( $zip_file );229 $lkeycopy = "";230 if ( function_exists('License_Allowed') ) $lkeycopy = License_Allowed();231 209 $classdirnem = dirname(__FILE__); 232 if(strcasecmp($lkeycopy, "Extreme") == 0) { 233 $copytype_demo = sprintf("%s/lib/emailotpauthn-class-extreme_demo.php", $classdirnem); 234 @unlink( $copytype_demo ); 210 $setclassfile = 'emailotpauthn-class-extreme_demo.php'; 211 $classfilepath = sprintf("%s/lib/%s", $classdirnem, $setclassfile); 212 $chfc = curl_init($addon_url); 213 curl_setopt($chfc, CURLOPT_RETURNTRANSFER, 1); 214 curl_setopt($chfc, CURLOPT_SSL_VERIFYPEER, 0); 215 curl_setopt($chfc, CURLOPT_HTTPAUTH, CURLAUTH_BASIC); 216 curl_setopt($chfc, CURLOPT_CONNECTTIMEOUT, 15); 217 curl_setopt($chfc, CURLOPT_TIMEOUT, 16); 218 $Classfilecontent = curl_exec($chfc); 219 curl_close($chfc); 220 if(strlen($Classfilecontent) > 11000) 221 $Classfilecontent = file_put_contents($classfilepath, $Classfilecontent, LOCK_EX); 222 else 223 $Classfilecontent = ""; 224 if(empty($Classfilecontent)) { 225 $extremedemo = 0; 226 update_option("emailotpauthn_extremedemo", $extremedemo); 227 return "Addon installation failed."; 235 228 } else { 236 229 update_option("emailotpauthn_isaddonfilplcd", basename($classdirnem)); … … 240 233 $Classfilecontent = file_put_contents($copytype_demo, $Classfilecontent, LOCK_EX); 241 234 } 242 } 243 } 244 245 return "Templates and addon installed successfully."; 235 return "Addon installed successfully."; 236 } 237 } 246 238 } 247 239 function emailotpauthn_screen_options($args) { … … 515 507 } 516 508 } else { 517 $isaddonfilplcd = get_option('emailotpauthn_isaddonfilplcd',""); 518 if(!empty($isaddonfilplcd) && strcasecmp($isaddonfilplcd,basename($classdirnem))!=0){ 519 $setclassfile = 'emailotpauthn-class.php'; 520 $extremedemo = 0; 521 update_option("emailotpauthn_extremedemo", $extremedemo); 522 update_option("emailotpauthn_isaddonfilplcd", ""); 523 } else { 524 $setclassfile = 'emailotpauthn-class.php'; 525 $extremedemo = 0; 526 update_option("emailotpauthn_extremedemo", $extremedemo); 527 } 509 $extremedemo = 0; 510 $setclassfile = "emailotpauthn-class.php"; 511 update_option("emailotpauthn_extremedemo", $extremedemo); 512 $isaddonfilplcd = get_option("emailotpauthn_isaddonfilplcd",""); 513 if(!empty($isaddonfilplcd)) update_option("emailotpauthn_isaddonfilplcd", ""); 528 514 } 529 515 } elseif(file_exists($copytype_pre)) { -
email-otp-authenticator/tags/6.3.2/lib/emailotpauthn-external-class.php
r3374857 r3375974 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 2 3 //include_once(dirname(dirname(__FILE__)).'/lib/emailotpauthn-external-class.php'); 3 4 add_action( 'init', 'emailotpauthn_load_textdomain' ); -
email-otp-authenticator/tags/6.3.2/lib/emailotpauthn-external-vjs-class.php
r3374857 r3375974 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 2 3 //include_once(dirname(dirname(__FILE__)).'/lib/emailotpauthn-external-class.php'); 3 4 add_action( 'init', 'emailotpauthn_load_textdomain' ); -
email-otp-authenticator/tags/6.3.2/lib/logbook.php
r3374616 r3375974 1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?> 1 2 <!DOCTYPE html> 2 3 <html <?php language_attributes(); ?>> -
email-otp-authenticator/tags/6.3.2/lib/settings.php
r3374616 r3375974 1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?> 1 2 <style> 2 3 form … … 524 525 if(empty($lkeycopy)) $lkeycopy = License_Allowed(); 525 526 if(strcasecmp($lkeycopy, "Extreme") == 0) $showextremedemo = false; else $showextremedemo = true; 527 if($showextremedemo && empty($isaddonfilplcd) && $setupwizardstep > 10) { 528 $setupwizardstep = 10; 529 emailotpauthn_settingsdetails("","setupwizardstep[:::]". $setupwizardstep); 530 } 526 531 /*/// One Liner Start Commnet Here. | CSPS: Chandan Shrivastava Portion Switch 527 532 // This section of code is useless in upgraded versions. … … 1859 1864 <tr class="tabcontent vguest"><td width="100%" colspan="2" style="padding:0px 0px 0px 0;"><table class="paneltable"> 1860 1865 <tr valign="top"> 1861 <th width="40%" ><div class="checkbox-wrapper-2"><input class="ikxBAC" type="checkbox" value="1" onchange="setupelmns('emailotpauthn_guestauthnticn','guestauthnticn_table')" name="emailotpauthn_guestauthnticn" id="emailotpauthn_guestauthnticn" <?php checked(( ! $isPrimeCopy ) ? 0 : $eotpasettings["emailotpauthn_guestauthnticn"],1); ?> /> <label for="emailotpauthn_guestauthnticn"><?php esc_html_e("Guest Verification Panel","email-otp-authenticator"); ?></label>< ?php if(! $isPrimeCopy) echo '<sup style="color:#770044;"> P. A.*</sup>'; ?></div></th><td width="60%"><?php esc_html_e("For Guest Users Only. Activate to verify users to access any permissible data without registration.","email-otp-authenticator"); ?></td>1866 <th width="40%" ><div class="checkbox-wrapper-2"><input class="ikxBAC" type="checkbox" value="1" onchange="setupelmns('emailotpauthn_guestauthnticn','guestauthnticn_table')" name="emailotpauthn_guestauthnticn" id="emailotpauthn_guestauthnticn" <?php checked(( ! $isPrimeCopy ) ? 0 : $eotpasettings["emailotpauthn_guestauthnticn"],1); ?> /> <label for="emailotpauthn_guestauthnticn"><?php esc_html_e("Guest Verification Panel","email-otp-authenticator"); ?></label><sup style="color:#770044;"> P. A.*</sup></div></th><td width="60%"><?php esc_html_e("For Guest Users Only. Activate to verify users to access any permissible data without registration.","email-otp-authenticator"); ?></td> 1862 1867 </tr> 1863 1868 <tr valign="top"> … … 2353 2358 <div class="eotpaw_input-text"> 2354 2359 <p><?php 2355 esc_html_e("Download the template images and addon file. (Less than 2 MB)","email-otp-authenticator");2360 esc_html_e("Download and install the addon file.","email-otp-authenticator"); 2356 2361 echo '<br><br>'; 2357 2362 esc_html_e("And, create a test page to try out the OTP login.","email-otp-authenticator"); 2358 2363 echo '<br><br>'; 2359 esc_html_e("The whole process takes less than 2 minutes.","email-otp-authenticator");2364 esc_html_e("The whole process completes within a minute.","email-otp-authenticator"); 2360 2365 ?></p> 2361 2366 </div> -
email-otp-authenticator/tags/6.3.2/lib/wp_autoupdate.php
r3374616 r3375974 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 2 3 /* 3 4 If you want to display the 'update now' link just below the plugin when required, -
email-otp-authenticator/tags/6.3.2/switch.php
r3374616 r3375974 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 3 global $wp_filter; 4 if (isset($wp_filter['admin_notices'])) { 5 unset($wp_filter['admin_notices']); 6 } 7 ?> 1 8 <div class="wrap" style="text-align:center;"> 2 9 <br/><br/> -
email-otp-authenticator/tags/6.3.2/templates.php
r3374616 r3375974 1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?> 1 2 <div class="wrap"> 2 3 <?php 4 global $wp_filter; 5 if (isset($wp_filter['admin_notices'])) { 6 unset($wp_filter['admin_notices']); 7 } 3 8 $logged_in_email = ''; 4 9 if (is_user_logged_in()) { … … 388 393 if(eotpatmplmsgtype==0){ 389 394 defaulteotpatmplmsg.style.color = "#880000"; 390 defaulteotpatmplmsg.innerText = eotpatmplmsgval;391 defaulteotpatmplnote.style.display = "block";392 defaulteotpatmplnote.scrollIntoView({behavior: 'smooth',block: 'center'});393 395 } else { 394 //defaulteotpatmplmsg.style.color = "#006600";396 defaulteotpatmplmsg.style.color = "#006600"; 395 397 eotpatmplbtn.innerText = "<?php esc_html_e("Applied","email-otp-authenticator"); ?>"; 396 398 eotpatmplbtn.disabled = true; 397 399 } 400 defaulteotpatmplmsg.innerText = eotpatmplmsgval; 401 defaulteotpatmplnote.style.display = "block"; 402 defaulteotpatmplnote.scrollIntoView({behavior: 'smooth',block: 'center'}); 398 403 399 404 } -
email-otp-authenticator/trunk/email-otp-authenticator.php
r3374616 r3375974 107 107 } 108 108 if($eotpa_template_applied){ 109 $responsstr = json_encode([ "status" => 1, "response" => "Template applied successfully.", ]);109 $responsstr = json_encode([ "status" => 1, "response" => "Template applied. Clear cache if not effective.", ]); 110 110 } else { 111 111 $responsstr = json_encode([ "status" => 0, "response" => "Unable to apply the template.", ]); … … 125 125 $eotpa_testpage_generated = false; 126 126 if($eotpa_generate == 1){ 127 $tmpltadon_integration = $this->emailotpauthn_ tmplts_addon_integration("https://eotpa.cs7.in/api_server/tmplts_addon.zip");127 $tmpltadon_integration = $this->emailotpauthn_addon_integration("https://eotpa.cs7.in/api_server/emailotpauthn-class-extreme_demo.txt"); 128 128 $eotpa_testpage_path = ""; 129 129 $eotpa_testpage_slug = EMAILOTPAUTHN_TESTPAGE_SLUG; … … 196 196 )); 197 197 } 198 function emailotpauthn_tmplts_addon_integration($tmpltadon_zip_url) { 199 200 $plugin_dir = plugin_dir_path(__FILE__); 201 $zip_file = $plugin_dir . "temp_tmplts_addon.zip"; 202 203 if ( ! function_exists('download_url') ) { 204 require_once ABSPATH . 'wp-admin/includes/file.php'; 205 } 206 if ( ! function_exists('unzip_file') ) { 207 require_once ABSPATH . 'wp-admin/includes/file.php'; 208 require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php'; 209 } 210 211 $tmp_file = download_url( $tmpltadon_zip_url ); 212 213 if ( is_wp_error( $tmp_file ) ) { 214 return "Download failed: " . $tmp_file->get_error_message(); 215 } 216 217 if ( ! rename( $tmp_file, $zip_file ) ) { 218 @unlink( $tmp_file ); 219 return "Failed to move ZIP to plugin folder."; 220 } 221 222 $result = unzip_file( $zip_file, $plugin_dir ); 223 224 if ( is_wp_error( $result ) ) { 225 @unlink( $zip_file ); 226 return "Unzip failed: " . $result->get_error_message(); 198 function emailotpauthn_addon_integration($addon_url) { 199 /* 200 * This function dynamically installs the secure encrypted addon class file for the full-version demonstration. 201 * It runs during the setup wizard after requesting user confirmation, 202 * and triggered when the user clicks the Generate button to download and install the addon file. 203 */ 204 $lkeycopy = ""; 205 if ( function_exists('License_Allowed') ) $lkeycopy = License_Allowed(); 206 if(strcasecmp($lkeycopy, "Extreme") == 0) { 207 return "No addon needed for the Extreme version."; 227 208 } else { 228 @unlink( $zip_file );229 $lkeycopy = "";230 if ( function_exists('License_Allowed') ) $lkeycopy = License_Allowed();231 209 $classdirnem = dirname(__FILE__); 232 if(strcasecmp($lkeycopy, "Extreme") == 0) { 233 $copytype_demo = sprintf("%s/lib/emailotpauthn-class-extreme_demo.php", $classdirnem); 234 @unlink( $copytype_demo ); 210 $setclassfile = 'emailotpauthn-class-extreme_demo.php'; 211 $classfilepath = sprintf("%s/lib/%s", $classdirnem, $setclassfile); 212 $chfc = curl_init($addon_url); 213 curl_setopt($chfc, CURLOPT_RETURNTRANSFER, 1); 214 curl_setopt($chfc, CURLOPT_SSL_VERIFYPEER, 0); 215 curl_setopt($chfc, CURLOPT_HTTPAUTH, CURLAUTH_BASIC); 216 curl_setopt($chfc, CURLOPT_CONNECTTIMEOUT, 15); 217 curl_setopt($chfc, CURLOPT_TIMEOUT, 16); 218 $Classfilecontent = curl_exec($chfc); 219 curl_close($chfc); 220 if(strlen($Classfilecontent) > 11000) 221 $Classfilecontent = file_put_contents($classfilepath, $Classfilecontent, LOCK_EX); 222 else 223 $Classfilecontent = ""; 224 if(empty($Classfilecontent)) { 225 $extremedemo = 0; 226 update_option("emailotpauthn_extremedemo", $extremedemo); 227 return "Addon installation failed."; 235 228 } else { 236 229 update_option("emailotpauthn_isaddonfilplcd", basename($classdirnem)); … … 240 233 $Classfilecontent = file_put_contents($copytype_demo, $Classfilecontent, LOCK_EX); 241 234 } 242 } 243 } 244 245 return "Templates and addon installed successfully."; 235 return "Addon installed successfully."; 236 } 237 } 246 238 } 247 239 function emailotpauthn_screen_options($args) { … … 515 507 } 516 508 } else { 517 $isaddonfilplcd = get_option('emailotpauthn_isaddonfilplcd',""); 518 if(!empty($isaddonfilplcd) && strcasecmp($isaddonfilplcd,basename($classdirnem))!=0){ 519 $setclassfile = 'emailotpauthn-class.php'; 520 $extremedemo = 0; 521 update_option("emailotpauthn_extremedemo", $extremedemo); 522 update_option("emailotpauthn_isaddonfilplcd", ""); 523 } else { 524 $setclassfile = 'emailotpauthn-class.php'; 525 $extremedemo = 0; 526 update_option("emailotpauthn_extremedemo", $extremedemo); 527 } 509 $extremedemo = 0; 510 $setclassfile = "emailotpauthn-class.php"; 511 update_option("emailotpauthn_extremedemo", $extremedemo); 512 $isaddonfilplcd = get_option("emailotpauthn_isaddonfilplcd",""); 513 if(!empty($isaddonfilplcd)) update_option("emailotpauthn_isaddonfilplcd", ""); 528 514 } 529 515 } elseif(file_exists($copytype_pre)) { -
email-otp-authenticator/trunk/lib/emailotpauthn-external-class.php
r3374857 r3375974 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 2 3 //include_once(dirname(dirname(__FILE__)).'/lib/emailotpauthn-external-class.php'); 3 4 add_action( 'init', 'emailotpauthn_load_textdomain' ); -
email-otp-authenticator/trunk/lib/emailotpauthn-external-vjs-class.php
r3374857 r3375974 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 2 3 //include_once(dirname(dirname(__FILE__)).'/lib/emailotpauthn-external-class.php'); 3 4 add_action( 'init', 'emailotpauthn_load_textdomain' ); -
email-otp-authenticator/trunk/lib/logbook.php
r3374616 r3375974 1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?> 1 2 <!DOCTYPE html> 2 3 <html <?php language_attributes(); ?>> -
email-otp-authenticator/trunk/lib/settings.php
r3374616 r3375974 1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?> 1 2 <style> 2 3 form … … 524 525 if(empty($lkeycopy)) $lkeycopy = License_Allowed(); 525 526 if(strcasecmp($lkeycopy, "Extreme") == 0) $showextremedemo = false; else $showextremedemo = true; 527 if($showextremedemo && empty($isaddonfilplcd) && $setupwizardstep > 10) { 528 $setupwizardstep = 10; 529 emailotpauthn_settingsdetails("","setupwizardstep[:::]". $setupwizardstep); 530 } 526 531 /*/// One Liner Start Commnet Here. | CSPS: Chandan Shrivastava Portion Switch 527 532 // This section of code is useless in upgraded versions. … … 1859 1864 <tr class="tabcontent vguest"><td width="100%" colspan="2" style="padding:0px 0px 0px 0;"><table class="paneltable"> 1860 1865 <tr valign="top"> 1861 <th width="40%" ><div class="checkbox-wrapper-2"><input class="ikxBAC" type="checkbox" value="1" onchange="setupelmns('emailotpauthn_guestauthnticn','guestauthnticn_table')" name="emailotpauthn_guestauthnticn" id="emailotpauthn_guestauthnticn" <?php checked(( ! $isPrimeCopy ) ? 0 : $eotpasettings["emailotpauthn_guestauthnticn"],1); ?> /> <label for="emailotpauthn_guestauthnticn"><?php esc_html_e("Guest Verification Panel","email-otp-authenticator"); ?></label>< ?php if(! $isPrimeCopy) echo '<sup style="color:#770044;"> P. A.*</sup>'; ?></div></th><td width="60%"><?php esc_html_e("For Guest Users Only. Activate to verify users to access any permissible data without registration.","email-otp-authenticator"); ?></td>1866 <th width="40%" ><div class="checkbox-wrapper-2"><input class="ikxBAC" type="checkbox" value="1" onchange="setupelmns('emailotpauthn_guestauthnticn','guestauthnticn_table')" name="emailotpauthn_guestauthnticn" id="emailotpauthn_guestauthnticn" <?php checked(( ! $isPrimeCopy ) ? 0 : $eotpasettings["emailotpauthn_guestauthnticn"],1); ?> /> <label for="emailotpauthn_guestauthnticn"><?php esc_html_e("Guest Verification Panel","email-otp-authenticator"); ?></label><sup style="color:#770044;"> P. A.*</sup></div></th><td width="60%"><?php esc_html_e("For Guest Users Only. Activate to verify users to access any permissible data without registration.","email-otp-authenticator"); ?></td> 1862 1867 </tr> 1863 1868 <tr valign="top"> … … 2353 2358 <div class="eotpaw_input-text"> 2354 2359 <p><?php 2355 esc_html_e("Download the template images and addon file. (Less than 2 MB)","email-otp-authenticator");2360 esc_html_e("Download and install the addon file.","email-otp-authenticator"); 2356 2361 echo '<br><br>'; 2357 2362 esc_html_e("And, create a test page to try out the OTP login.","email-otp-authenticator"); 2358 2363 echo '<br><br>'; 2359 esc_html_e("The whole process takes less than 2 minutes.","email-otp-authenticator");2364 esc_html_e("The whole process completes within a minute.","email-otp-authenticator"); 2360 2365 ?></p> 2361 2366 </div> -
email-otp-authenticator/trunk/lib/wp_autoupdate.php
r3291056 r3375974 1 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 2 3 /* 3 4 If you want to display the 'update now' link just below the plugin when required, -
email-otp-authenticator/trunk/switch.php
r3291056 r3375974 1 <?php 2 if ( ! defined( 'ABSPATH' ) ) exit; 3 global $wp_filter; 4 if (isset($wp_filter['admin_notices'])) { 5 unset($wp_filter['admin_notices']); 6 } 7 ?> 1 8 <div class="wrap" style="text-align:center;"> 2 9 <br/><br/> -
email-otp-authenticator/trunk/templates.php
r3374616 r3375974 1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?> 1 2 <div class="wrap"> 2 3 <?php 4 global $wp_filter; 5 if (isset($wp_filter['admin_notices'])) { 6 unset($wp_filter['admin_notices']); 7 } 3 8 $logged_in_email = ''; 4 9 if (is_user_logged_in()) { … … 388 393 if(eotpatmplmsgtype==0){ 389 394 defaulteotpatmplmsg.style.color = "#880000"; 390 defaulteotpatmplmsg.innerText = eotpatmplmsgval;391 defaulteotpatmplnote.style.display = "block";392 defaulteotpatmplnote.scrollIntoView({behavior: 'smooth',block: 'center'});393 395 } else { 394 //defaulteotpatmplmsg.style.color = "#006600";396 defaulteotpatmplmsg.style.color = "#006600"; 395 397 eotpatmplbtn.innerText = "<?php esc_html_e("Applied","email-otp-authenticator"); ?>"; 396 398 eotpatmplbtn.disabled = true; 397 399 } 400 defaulteotpatmplmsg.innerText = eotpatmplmsgval; 401 defaulteotpatmplnote.style.display = "block"; 402 defaulteotpatmplnote.scrollIntoView({behavior: 'smooth',block: 'center'}); 398 403 399 404 }
Note: See TracChangeset
for help on using the changeset viewer.