Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- *
- * @ This file is created by deZender.Net
- * @ deZender (PHP5 Decoder for ionCube Encoder)
- *
- * @ Version : 1.1.3.0
- * @ Author : DeZender
- * @ Release on : 17.05.2011
- * @ Official site : http://DeZender.Net
- *
- */
- function ($fijgihdbj = '1', $cidedahcch, $dajjidbhfa = '') {
- if ($fijgihdbj != '1') {
- $dbgfhfhbed = 'http://licensing5.soluslabs.net/clients/';
- } else {
- $dbgfhfhbed = 'http://licensing1.soluslabs.net/clients/';
- }
- $cdedbefib = 'QG8X3g9HbHQ33nU7HR1hC793SnbUHD6g47dg32GJqs234DGkhkl782gsjHD6g47dg32GJqs234DGkhkl782gsjmcmcdfjei8sab3QG8X3g9HbHQ33nU7HR1hC793SnbUHD6g47dg32GJ1hC793SnbUHD6g47dg32GJqs234DG';
- $caecbbdccj = cjefhjdhgd( 'Ymd' );
- $dhbgjibihe = (isset( $_SERVER['SERVER_ADDR'] ) ? $_SERVER['SERVER_ADDR'] : $_SERVER['LOCAL_ADDR']);
- $bjggfcijb = 5;
- $bhbicehefg = 5;
- $cfgcddedhg = false;
- if ($dajjidbhfa) {
- $dajjidbhfa = bijbaiefji( '
- ', '', $dajjidbhfa );
- $fihbegdib = ddbdeecjaa( $dajjidbhfa, 0, dahhfdbiaf( $dajjidbhfa ) - 32 );
- $ghfgfjecd = ddbdeecjaa( $dajjidbhfa, dahhfdbiaf( $dajjidbhfa ) - 32 );
- if ($ghfgfjecd == babhhahahb( $fihbegdib . $cdedbefib )) {
- $fihbegdib = cjgcidfeej( $fihbegdib );
- $ghfgfjecd = ddbdeecjaa( $fihbegdib, 0, 32 );
- $fihbegdib = ddbdeecjaa( $fihbegdib, 32 );
- $fihbegdib = ghejgbjfg( $fihbegdib );
- $bcafjceaif = jbdhbfgeg( $fihbegdib );
- $fehbfhddg = $bcafjceaif['checkdate'];
- if ($ghfgfjecd == babhhahahb( $fehbfhddg . $cdedbefib )) {
- $ccgegcedde = cjefhjdhgd( 'Ymd', cedhcdece( 0, 0, 0, cjefhjdhgd( 'm' ), cjefhjdhgd( 'd' ) - $bjggfcijb, cjefhjdhgd( 'Y' ) ) );
- if ($ccgegcedde < $fehbfhddg) {
- $cfgcddedhg = true;
- $bbfhacihb = $bcafjceaif;
- $hgbjdjic = gbjigdaed( ',', $bbfhacihb['validdomain'] );
- $dcciccehhg = gbjigdaed( ',', $bbfhacihb['validip'] );
- if (!dgjdjbbgg( $dhbgjibihe, $dcciccehhg )) {
- $cfgcddedhg = false;
- $bcafjceaif['status'] = 'Invalid';
- $bbfhacihb = array( );
- }
- }
- }
- }
- }
- if (!$cfgcddedhg) {
- $bfdgfiedeh['licensekey'] = $cidedahcch;
- $bfdgfiedeh['domain'] = $_SERVER['SERVER_NAME'];
- $bfdgfiedeh['ip'] = $dhbgjibihe;
- $bfdgfiedeh['dir'] = cbhaffgjii( __FILE__ );
- if (deejcgejgb( 'curl_exec' )) {
- $iahaehbj = gjgdbfbbd( );
- dcaecadeii( $iahaehbj, CURLOPT_URL, $dbgfhfhbed . 'modules/servers/licensing/verifylicense.php' );
- dcaecadeii( $iahaehbj, CURLOPT_POST, 1 );
- dcaecadeii( $iahaehbj, CURLOPT_POSTFIELDS, $bfdgfiedeh );
- dcaecadeii( $iahaehbj, CURLOPT_TIMEOUT, 30 );
- dcaecadeii( $iahaehbj, CURLOPT_RETURNTRANSFER, 1 );
- $dghhibihfb = ccabighigf( $iahaehbj );
- ccdhhcccad( $iahaehbj );
- } else {
- $cifhahfiee = bicbfedfcc( $dbgfhfhbed, 80, $cagajcahaj, $dgehgigcig, 5 );
- if ($cifhahfiee) {
- $dbdhfbhcbb = '';
- foreach ($bfdgfiedeh as $cdddcbhdjd => $daaebbdhej) {
- $dbdhfbhcbb .= '' . $cdddcbhdjd . '=' . dfdbdgiefc( $daaebbdhej ) . '&';
- }
- $cdaigjeddb = 'POST ' . $dbgfhfhbed . 'modules/servers/licensing/verifylicense.php HTTP/1.0
- ';
- $cdaigjeddb .= 'Host: ' . $dbgfhfhbed . '
- ';
- $cdaigjeddb .= 'Content-type: application/x-www-form-urlencoded
- ';
- $cdaigjeddb .= 'Content-length: ' . @dahhfdbiaf( $dbdhfbhcbb ) . '
- ';
- $cdaigjeddb .= 'Connection: close
- ';
- $cdaigjeddb .= $dbdhfbhcbb;
- $dghhibihfb = '';
- @decibiecae( $cifhahfiee, 20 );
- @dhgcjcighe( $cifhahfiee, $cdaigjeddb );
- $ijgecaiag = @cfhicceeeb( $cifhahfiee );
- while (( !@gfedbfhhh( $cifhahfiee ) && $ijgecaiag )) {
- $dghhibihfb .= @cgebfhfheg( $cifhahfiee, 1024 );
- $ijgecaiag = @cfhicceeeb( $cifhahfiee );
- }
- @cicajebbbc( $cifhahfiee );
- }
- }
- if (!$dghhibihfb) {
- $ccgegcedde = cjefhjdhgd( 'Ymd', cedhcdece( 0, 0, 0, cjefhjdhgd( 'm' ), cjefhjdhgd( 'd' ) - ( $bjggfcijb + $bhbicehefg ), cjefhjdhgd( 'Y' ) ) );
- if ($ccgegcedde < $fehbfhddg) {
- $bbfhacihb = $bcafjceaif;
- } else {
- $bbfhacihb['status'] = 'Remote Check Failed';
- return $bbfhacihb;
- }
- }
- dcjifaiajd( '/<(.*?)>([^<]+)<\/\1>/i', $dghhibihfb, $dbejaeibga );
- $bbfhacihb = array( );
- foreach ($dbejaeibga[1] as $cdddcbhdjd => $daaebbdhej) {
- $bbfhacihb[$daaebbdhej] = $dbejaeibga[2][$cdddcbhdjd];
- }
- if ($bbfhacihb['status'] == 'Active') {
- $bbfhacihb['checkdate'] = $caecbbdccj;
- $cjhgfiihih = bgddadhgcj( $bbfhacihb );
- $cjhgfiihih = bahifbegjh( $cjhgfiihih );
- $cjhgfiihih = babhhahahb( $caecbbdccj . $cdedbefib ) . $cjhgfiihih;
- $cjhgfiihih = cjgcidfeej( $cjhgfiihih );
- $cjhgfiihih = $cjhgfiihih . babhhahahb( $cjhgfiihih . $cdedbefib );
- $cjhgfiihih = cfadjghci( $cjhgfiihih, 80, '
- ', true );
- $bbfhacihb['localkey'] = $cjhgfiihih;
- }
- $bbfhacihb['remotecheck'] = true;
- }
- unset( $bfdgfiedeh );
- unset( $dghhibihfb );
- unset( $dbejaeibga );
- unset( $dbgfhfhbed );
- unset( $cdedbefib );
- unset( $caecbbdccj );
- unset( $dhbgjibihe );
- unset( $bjggfcijb );
- unset( $bhbicehefg );
- unset( $ghfgfjecd );
- return $bbfhacihb;
- }
- djdfidcaja( 'NO_DIRECT_ACCESS_ALLOWED', 1 );
- require( '../../includes/config.php' );
- require( '../../includes/database.php' );
- require( '../../includes/admininit.php' );
- require( '../../includes/proc.php' );
- require( '../../includes/initcore.php' );
- require( '../../includes/session.php' );
- require( '../../includes/functions.php' );
- jbejjehic( );
- require( '../../includes/adminverify.php' );
- require( '../../includes/admincore.php' );
- $adminid = $_SESSION['adminid'];
- $act = ddijeahba( '17' );
- if ($act == true) {
- cdaigjeddb( 'Location: aclerror.php' );
- exit( );
- } else {
- unset( $act );
- }
- $id = (int)$_GET['id'];
- $code = (int)$_GET['code'];
- if ($code == '100') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>You have too many slaves for your license. You must update your license before you continue.</div>';
- } else {
- if ($code == '101') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>Your license is invalid. You must update your license before you continue.</div>';
- } else {
- if ($code == '102') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>Your license has expired. You must update your license before you continue.</div>';
- } else {
- if ($code == '103') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>Your license has been suspended. Please contact SolusVM support.</div>';
- } else {
- if ($code == '198') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>No license found. You must enter a valid license key before you continue.</div>';
- } else {
- if ($code == '199') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>Unknown error. Please contact SolusVM support.</div>';
- } else {
- if ($code == '998') {
- $msg = ' <div id=\'adminwarn\'><strong>Warning!</strong><br>A trial license will only support 1 slave. Remove the extra slave or purchase a full license to continue.</div>';
- } else {
- if ($code == '1000') {
- $nqslave2 = $db->query( 'SELECT * FROM nodes WHERE nodeid !=\'1\' AND licensetype=\'0\'' );
- $nqmini2 = $db->query( 'SELECT * FROM nodes WHERE nodeid !=\'1\' AND licensetype=\'1\'' );
- $nqmicro2 = $db->query( 'SELECT * FROM nodes WHERE nodeid !=\'1\' AND licensetype=\'2\'' );
- $nc2 = array( );
- $nc2['slave_count'] = $db->numRows( $nqslave2 );
- $nc2['mini_count'] = $db->numRows( $nqmini2 );
- $nc2['micro_count'] = $db->numRows( $nqmicro2 );
- $slavesinlicense2 = gbjigdaed( '|', $results['configoptions'] );
- $svmslaves2 = array( );
- foreach ($slavesinlicense2 as $value2) {
- $v2 = gbjigdaed( '=', $value2 );
- $n = $v2[0];
- $z = $v2[1];
- $svmslaves2[$n] = $z;
- }
- $slaves2 = $svmslaves2['Slaves'];
- if ($svmslaves2['Mini Slaves'] == '') {
- $minislaves2 = '0';
- } else {
- $minislaves2 = $svmslaves2['Mini Slaves'];
- }
- if ($svmslaves2['Micro Slaves'] == '') {
- $microslaves2 = '0';
- } else {
- $microslaves2 = $svmslaves2['Micro Slaves'];
- }
- $erroroutput = '' . '<strong>Your license contains:</strong><br><br>' . $slaves2 . ' Unlimited Licenses | ' . $minislaves2 . ' Mini Licenses | ' . $microslaves2 . ' Micro Licenses</strong>';
- $erroroutput2 = '' . '<strong>Your licenses are currently assigned in the following way:</strong><br><br>' . $nc2['slave_count'] . ' nodes assigned with a Unlimited License<br>' . $nc2['mini_count'] . ' nodes assigned with a Mini License<br>' . $nc2['micro_count'] . ' nodes assigned with a Micro Licenses';
- $msg = '' . ' <div id=\'adminwarn\'><strong>Warning!</strong><br>A slave license mismatch has occured. One or more of your slaves have an incorrect license type.<br><br>' . $erroroutput . '<br><br>' . $erroroutput2 . '</div>';
- } else {
- if ($code == '2000') {
- $checkvpsnumbers = $db->query( 'SELECT * FROM nodes WHERE nodeid !=\'1\'' );
- while ($numbersearch = $db->fetchArray( $checkvpsnumbers )) {
- if ($numbersearch[licensetype] == '1') {
- $cvps = $db->query( '' . 'SELECT * FROM vservers WHERE nodeid =\'' . $numbersearch['nodeid'] . '\'' );
- if (5 < $db->numRows( $cvps )) {
- $errorarray[] = '' . '<strong> Node ID ' . $numbersearch['nodeid'] . ' (' . $numbersearch['name'] . ') has ' . $db->numRows( $cvps ) . ' virtual servers when only 5 is allowed with it\'s assigned license type (Mini).</strong><br>';
- continue;
- }
- continue;
- }
- if ($numbersearch[licensetype] == '2') {
- $cvps = $db->query( '' . 'SELECT * FROM vservers WHERE nodeid =\'' . $numbersearch['nodeid'] . '\'' );
- if (2 < $db->numRows( $cvps )) {
- $errorarray[] = '' . '<strong> Node ID ' . $numbersearch['nodeid'] . ' (' . $numbersearch['name'] . ') has ' . $db->numRows( $cvps ) . ' virtual servers when only 2 is allowed with it\'s assigned license type (Micro).</strong>';
- continue;
- }
- continue;
- }
- }
- $erroroutput = baafhajcje( '<br>', $errorarray );
- $msg = '' . ' <div id=\'adminwarn\'><strong>Warning!</strong><br>You have too many virtual servers on one of the slaves. Either upgrade your license or remove the vps.<br><br>' . $erroroutput . '</div>';
- } else {
- if ($code == '400') {
- $msg = ' <div id=\'adminok\'>License updated.</div>';
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- if ($_POST['updatekey']) {
- $act = ddijeahba( '17|18' );
- if ($act == true) {
- cdaigjeddb( 'Location: aclerror.php' );
- exit( );
- } else {
- unset( $act );
- }
- $newkey = $db->prepare( cahdhjjdae( ecceebdbff( $_POST[key] ) ) );
- $localkey = '';
- $llserver = '1';
- $results = [obfuscated]( $llserver, $newkey, $localkey );
- if (( $results['status'] == 'Active' && $results['productid'] == '1' )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- if ($llserver == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( '' . 'UPDATE license SET localkey=\'' . $localkeydata . '\'' );
- $db->query( '' . 'UPDATE license SET licensekey=\'' . $newkey . '\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>Key updated.</div>';
- } else {
- if (( $results['status'] == 'Active' && $results['productid'] == '2' )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- if ($llserver == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( '' . 'UPDATE license SET localkey=\'' . $localkeydata . '\'' );
- $db->query( '' . 'UPDATE license SET licensekey=\'' . $newkey . '\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>Key updated.</div>';
- } else {
- if (( $results['status'] == 'Active' && $results['productid'] == '4' )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- if ($llserver == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( '' . 'UPDATE license SET localkey=\'' . $localkeydata . '\'' );
- $db->query( '' . 'UPDATE license SET licensekey=\'' . $newkey . '\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>Key updated.</div>';
- } else {
- if (( $results['status'] == 'Active' && $results['productid'] == '23' )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- if ($llserver == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( '' . 'UPDATE license SET localkey=\'' . $localkeydata . '\'' );
- $db->query( '' . 'UPDATE license SET licensekey=\'' . $newkey . '\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>Key updated.</div>';
- } else {
- if (( $results['status'] == 'Active' && $results['productid'] == '22' )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- if ($llserver == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( '' . 'UPDATE license SET localkey=\'' . $localkeydata . '\'' );
- $db->query( '' . 'UPDATE license SET licensekey=\'' . $newkey . '\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>Key updated.</div>';
- } else {
- if (( $results['status'] == 'Active' && $results['productid'] == '20' )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- if ($llserver == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( '' . 'UPDATE license SET localkey=\'' . $localkeydata . '\'' );
- $db->query( '' . 'UPDATE license SET licensekey=\'' . $newkey . '\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>Key updated.</div>';
- } else {
- if ($results['status'] == 'Invalid') {
- $msg = ' <div id=\'adminerror\'><strong>Error!</strong><br>License invalid.</div>';
- } else {
- if ($results['status'] == 'Expired') {
- $msg = ' <div id=\'adminerror\'><strong>Error!</strong><br>License expired.</div>';
- } else {
- if ($results['status'] == 'Suspended') {
- $msg = ' <div id=\'adminerror\'><strong>Error!</strong><br>License suspended.</div>';
- } else {
- $msg = ' <div id=\'adminerror\'><strong>Error!</strong><br>License invalid.</div>';
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
- if ($_POST['update']) {
- $act = ddijeahba( '17|19' );
- if ($act == true) {
- cdaigjeddb( 'Location: aclerror.php' );
- exit( );
- } else {
- unset( $act );
- }
- $licenseq = $db->query( 'SELECT * FROM license' );
- $licenseqr = $db->fetchArray( $licenseq );
- $licensekey = $licenseqr[key];
- $localkey = '';
- $licsrv = '1';
- $results = [obfuscated]( $licsrv, $licensekey );
- if ($results['status'] == '') {
- $licsrv = '2';
- $results = [obfuscated]( $licsrv, $licensekey );
- }
- if (( ( ( ( ( ( $results['status'] == 'Active' && $results['productid'] == '1' ) || ( $results['status'] == 'Active' && $results['productid'] == '2' ) ) || ( $results['status'] == 'Active' && $results['productid'] == '4' ) ) || ( $results['status'] == 'Active' && $results['productid'] == '20' ) ) || ( $results['status'] == 'Active' && $results['productid'] == '22' ) ) || ( $results['status'] == 'Active' && $results['productid'] == '23' ) )) {
- if ($results['localkey']) {
- $localkeydata = $results['localkey'];
- $db->query( 'UPDATE license SET localkey=\'0\'' );
- }
- $msg = ' <div id=\'adminok\'><strong>Successful!</strong><br>License updated.</div>';
- } else {
- if ($results['status'] == 'Invalid') {
- ( $db->query( 'UPDATE license SET localkey=\'0\'' ) || $db->raise_error( ) );
- cdaigjeddb( 'Location: license.php?code=400' );
- } else {
- if ($results['status'] == 'Expired') {
- ( $db->query( 'UPDATE license SET localkey=\'0\'' ) || $db->raise_error( ) );
- cdaigjeddb( 'Location: license.php?code=400' );
- } else {
- if ($results['status'] == 'Suspended') {
- ( $db->query( 'UPDATE license SET localkey=\'0\'' ) || $db->raise_error( ) );
- $header( 'Location: license.php?code=400' );
- } else {
- $localkey = '';
- $licsrv = '1';
- $results = [obfuscated]( $licsrv, $licensekey, $localkey );
- if ($results['status'] == '') {
- $licsrv = '2';
- $results = [obfuscated]( $licsrv, $licensekey, $localkey );
- }
- if ($results['status'] == '') {
- $msg = ' <div id=\'adminerror\'><strong>Error!</strong><br>Could not update license.</div>';
- } else {
- $updtime = cjefhjdhgd( 'd F Y g:i A' );
- $db->query( '' . 'UPDATE license SET lupdate=\'' . $updtime . '\'' );
- if ($licsrv == '1') {
- $serverarray = array( '1', '3', '4', '5', '6' );
- $srnum = $serverarray[bfdggfjgij( $serverarray )];
- } else {
- $srnum = '2';
- }
- $db->query( '' . 'UPDATE license SET lsrv=\'' . $srnum . '\'' );
- $db->query( 'UPDATE license SET localkey=\'0\'' );
- cdaigjeddb( 'Location: license.php?code=400' );
- }
- }
- }
- }
- }
- }
- $licenseq = $db->query( 'SELECT * FROM license LIMIT 1' );
- $cl = $db->numRows( $licenseq );
- if ($cl == 0) {
- $licensekey = '';
- $localkey = '';
- } else {
- $licenseqr = $db->fetchArray( $licenseq );
- $licensekey = $licenseqr[licensekey];
- $localkey = $licenseqr[localkey];
- }
- if (!empty( $licensekey )) {
- $results = [obfuscated]( $lsrv = '1', $licensekey, $localkey );
- if ($results['status'] == 'Active') {
- $smarty->assign( 'licensestatus', '<div style=\'color: green\'>Active</div>' );
- } else {
- if ($results['status'] == 'Invalid') {
- $smarty->assign( 'licensestatus', '<div style=\'color: red\'>Invalid</div>' );
- } else {
- if ($results['status'] == 'Expired') {
- $smarty->assign( 'licensestatus', '<div style=\'color: red\'>Expired</div>' );
- } else {
- if ($results['status'] == 'Suspended') {
- $smarty->assign( 'licensestatus', '<div style=\'color: red\'>Suspended</div>' );
- } else {
- $smarty->assign( 'licensestatus', '<div style=\'color: yellow\'>Unknown</div>' );
- }
- }
- }
- }
- if ($results['companyname']) {
- $smarty->assign( 'licenseto', $results['companyname'] );
- } else {
- $smarty->assign( 'licenseto', $results['registeredname'] );
- }
- $smarty->assign( 'licenseemail', $results['email'] );
- if ($results['productid'] == '20') {
- $smarty->assign( 'licensebilling', 'N/A' );
- } else {
- if ($results['productid'] == '2') {
- $smarty->assign( 'licensebilling', '15 day trial' );
- } else {
- $smarty->assign( 'licensebilling', $results['billingcycle'] );
- }
- }
- if ($results['productid'] == '20') {
- $smarty->assign( 'licenseip', 'N/A' );
- } else {
- $smarty->assign( 'licenseip', $results['validip'] );
- }
- if ($results['productid'] == '20') {
- $smarty->assign( 'licenseexpire', 'N/A' );
- } else {
- $smarty->assign( 'licenseexpire', $results['nextduedate'] );
- }
- $slavesinlicense = gbjigdaed( '|', $results['configoptions'] );
- $svmslaves = array( );
- foreach ($slavesinlicense as $value) {
- $v = gbjigdaed( '=', $value );
- $n = $v[0];
- $z = $v[1];
- $svmslaves[$n] = $z;
- }
- $slaves = $svmslaves['Slaves'];
- if ($results['productid'] == '2') {
- $smarty->assign( 'licenseslaves', '1' );
- } else {
- if ($results['productid'] == '20') {
- $nslaves = $slaves + 1;
- $smarty->assign( 'licenseslaves', $nslaves );
- } else {
- $smarty->assign( 'licenseslaves', $slaves );
- }
- }
- if ($svmslaves['Mini Slaves'] == '') {
- $smarty->assign( 'minislaves', '0' );
- } else {
- $smarty->assign( 'minislaves', $svmslaves['Mini Slaves'] );
- }
- if ($svmslaves['Micro Slaves'] == '') {
- $smarty->assign( 'microslaves', '0' );
- } else {
- $smarty->assign( 'microslaves', $svmslaves['Micro Slaves'] );
- }
- $extras = array( );
- if ($svmaddon['SMS Addon']) {
- $extras[] = '<tr><td align=\'left\' bgcolor=\'#eeeeee\' style=\'padding: 5px;\'><strong>SMS Addon</strong></td><td align=\'left\' bgcolor=\'#efefef\' style=\'padding: 5px; color: green;\'><strong>Active</strong></td> </tr>';
- } else {
- $extras[] = '<tr><td align=\'left\' bgcolor=\'#eeeeee\' style=\'padding: 5px;\'><strong>SMS Addon</strong></td><td align=\'left\' bgcolor=\'#efefef\' style=\'padding: 5px; color: black;\'>Disabled</td> </tr>';
- }
- $ext = baafhajcje( ' ', $extras );
- $smarty->assign( 'extras', $ext );
- $smarty->assign( 'licensekey', $lockey[licensekey] );
- if ($results['productid'] == '2') {
- $smarty->assign( 'licensetype', 'Trial' );
- } else {
- if ($results['productid'] == '4') {
- $smarty->assign( 'licensetype', 'SolusVM Enterprise (Slave Only)' );
- } else {
- if ($results['productid'] == '20') {
- $smarty->assign( 'licensetype', 'SolusVM Enterprise (NOC)' );
- } else {
- if ($results['productid'] == '22') {
- $smarty->assign( 'licensetype', 'SolusVM Enterprise (RS)' );
- } else {
- if ($results['productid'] == '23') {
- $smarty->assign( 'licensetype', 'SolusVM Enterprise Slave Only (RS)' );
- } else {
- $smarty->assign( 'licensetype', 'SolusVM Enterprise (Full)' );
- }
- }
- }
- }
- }
- } else {
- $smarty->assign( 'licensestatus', '<div style=\'color: black\'>Not Found</div>' );
- }
- if ($licenseqr['lsrv'] == '1') {
- $smarty->assign( 'lsrv', '<img src=\'../template_assets/admin/default/images/icons/gb.gif\' alt=\'UK\' /> UK Hub 1' );
- } else {
- if ($licenseqr['lsrv'] == '2') {
- $smarty->assign( 'lsrv', '<img src=\'../template_assets/admin/default/images/icons/us.gif\' alt=\'USA\' /> USA Hub 2' );
- } else {
- if ($licenseqr['lsrv'] == '3') {
- $smarty->assign( 'lsrv', '<img src=\'../template_assets/admin/default/images/icons/de.gif\' alt=\'Germany\' /> Germany Hub 4' );
- } else {
- if ($licenseqr['lsrv'] == '4') {
- $smarty->assign( 'lsrv', '<img src=\'../template_assets/admin/default/images/icons/fr.gif\' alt=\'France\' /> France Hub 3' );
- } else {
- if ($licenseqr['lsrv'] == '5') {
- $smarty->assign( 'lsrv', '<img src=\'../template_assets/admin/default/images/icons/jp.gif\' alt=\'Japan\' /> Japan Hub 5' );
- } else {
- if ($licenseqr['lsrv'] == '6') {
- $smarty->assign( 'lsrv', '<img src=\'../template_assets/admin/default/images/icons/es.gif\' alt=\'Spain\' /> Spain Hub 7' );
- } else {
- $smarty->assign( 'lsrv', 'No Hub Registered' );
- }
- }
- }
- }
- }
- }
- if ($licenseqr['lupdate'] != '') {
- $smarty->assign( 'lupdate', $licenseqr[lupdate] );
- } else {
- $smarty->assign( 'lupdate', 'Unknown' );
- }
- $smarty->assign( 'msg', $msg );
- $smarty->display( $template . '/license.tpl' );
- $db->close( );
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement