Advertisement
Guest User

Untitled

a guest
Apr 6th, 2019
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.90 KB | None | 0 0
  1. <?php
  2. /*
  3. *
  4. * @ This file is created by http://DeZender.Net
  5. * @ deZender (PHP5 Decoder for ionCube Encoder)
  6. *
  7. * @ Version : 3.5.0.0
  8. * @ Author : DeZender
  9. * @ Release on : 22.06.2018
  10. * @ Official site : http://DeZender.Net
  11. *
  12. */
  13.  
  14. if (!function_exists('utf8_uri_encode')) {
  15. }
  16.  
  17. if (!function_exists('_')) {
  18. function _($text)
  19. {
  20. return __($text);
  21. }
  22. }
  23.  
  24. if (!function_exists('seems_utf8')) {
  25. }
  26.  
  27. if (!function_exists('to_case')) {
  28. }
  29.  
  30. if (!function_exists('seo_string')) {
  31. }
  32.  
  33. if (!function_exists('is_ajax')) {
  34. }
  35.  
  36. if (!function_exists('json')) {
  37. }
  38.  
  39. if (!function_exists('cms_version')) {
  40. }
  41.  
  42. if (!function_exists('in_file')) {
  43. function in_file()
  44. {
  45. if (defined('DMNCMS')) {
  46. if (!DMNCMS) {
  47. exit('Your not allowed to access this file!');
  48. }
  49.  
  50. return true;
  51. }
  52.  
  53. exit('Your not allowed to access this file!');
  54. }
  55. }
  56.  
  57. if (!function_exists('ip')) {
  58. }
  59.  
  60. if (!function_exists('use_funcs')) {
  61. }
  62.  
  63. if (!function_exists('check_ip_white_list')) {
  64. }
  65.  
  66. if (!function_exists('pre')) {
  67. }
  68.  
  69. if (!function_exists('writelog')) {
  70. }
  71.  
  72. if (!function_exists('server_list')) {
  73. }
  74.  
  75. if (!function_exists('get_country_code')) {
  76. }
  77.  
  78. if (!function_exists('collect_country')) {
  79. }
  80.  
  81. if (!function_exists('find_country_code')) {
  82. }
  83.  
  84. if (!function_exists('findCountryCodeRemotely')) {
  85. }
  86.  
  87. if (!function_exists('arithmetic')) {
  88. }
  89.  
  90. if (!function_exists('load_class')) {
  91. }
  92.  
  93. if (!function_exists('is_loaded')) {
  94. }
  95.  
  96. if (!function_exists('array_save')) {
  97. }
  98.  
  99. if (!function_exists('array_load')) {
  100. }
  101.  
  102. if (!function_exists('print_exception')) {
  103. }
  104.  
  105. class license
  106. {
  107. public $errors = array();
  108. private $api_url = 'https://dmncms.net/applications/nexus/interface/licenses/new.php?';
  109. private $endpoint = 'activate';
  110. private $host = 'dmncms.net';
  111. private $debug = 0;
  112. private $request_value = array();
  113. public $response = false;
  114. public $validation_error = null;
  115. private $license_key_file = 'license.txt';
  116. private $license_data = array();
  117. private $new_license_data = null;
  118. private $iv_size = null;
  119. private $securekey = null;
  120. private $local_license_data = array();
  121. public $secret = null;
  122. public $access_details = array();
  123. public $activation_faults = array('101' => 'The key or email provided does not exist.', '102' => 'The key provided is has been deactivated.', '103' => 'The purchase the key is associated with has been cancelled.', '104' => 'The purchase the key is associated with has expired.', '201' => 'The key has already been activated the maximum number of times and cannot be activated again. Please contact support <a href="http://dmncms.net/support/create/" target="_blank">here</a>.', '202' => 'setEmail was TRUE, but the key already has an email.', '203' => 'The email provided was incorrect.');
  124. private $check_faults = array('Bad request.', '101' => 'The key or email provided does not exist.', '301' => 'The email provided was incorrect.', '302' => 'You did not provide a usage ID.', '303' => 'The usage ID provided was invalid.', '304' => 'The request was received by a different IP address to the IP address that sent the "activate" API call.', '305' => 'The local license key is invalid for this domain.', '306' => 'The local license key is invalid for this directory');
  125. private $user_agent = 'ApiQuery-Bot v1.0';
  126.  
  127. public function __construct()
  128. {
  129. $this->user_agent = 'ApiQuery-Bot v1.0';
  130. }
  131.  
  132. public function check_license()
  133. {
  134. $this->check_license_file();
  135.  
  136. if ($this->license_data[0]['activated'] == 0) {
  137. $this->activation_form();
  138. } else {
  139. if (empty($this->license_data[0]['license'])) {
  140. if (!isset($_POST['submit_license'])) {
  141. $this->errors[] = 'The local license data is empty please contact DmNMuCMS Support.';
  142. }
  143.  
  144. $this->activation_form();
  145. } else {
  146. $this->license_data[5] = explode('[DmN]', $this->decrypt());
  147.  
  148. if (1 < count($this->license_data[5])) {
  149. if ($this->license_data[5][3] != 'ACTIVE') {
  150. $this->check_license_data($this->license_data[5][0], $this->license_data[5][1], $this->license_data[5][2]);
  151.  
  152. if ($this->check_response()) {
  153. $this->generate_license_data();
  154.  
  155. if ($this->write_license() == true) {
  156. return 'okdmn';
  157. }
  158.  
  159. $this->validation_error = $this->errors[0];
  160. writelog($this->validation_error, 'license');
  161. }
  162. } else {
  163. return 'okdmn';
  164. }
  165. } else {
  166. if ('1.1.4.1' < $this->license_data[0]['version'] || $this->license_data[0]['version'] < '1.1.5') {
  167. @unlink(BASEDIR . $this->license_key_file);
  168. $this->check_license_file('1.1.4.1');
  169. $this->activation_form();
  170. }
  171. }
  172. }
  173. }
  174.  
  175. return false;
  176. }
  177.  
  178. public function validate()
  179. {
  180. $this->check_license_file();
  181. $this->license_data[5] = explode('[DmN]', $this->decrypt());
  182.  
  183. if (1 < count($this->license_data[5])) {
  184. .........................................................
  185. ..............................
  186. ...........
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement