예제 #1
0
							</fieldset>
							<fieldset>
								<input class="form-control" type="text" placeholder="API Key Verification Code" name="vCode" style="margin-top: 5px">
							</fieldset>
							<input class="btn btn-primary btn-lg eve-text pull-right" style="margin-top: 5px; margin-bottom: 5px; border-radius: 0px" type="submit" name="register_step_1" value="Continue">
	
							<a style="color: #65a9cc; margin-top: 15px;" href="/login/" class="pull-left">Already have an account?</a>
						</form>
					</div>

				</div>
			</div>
		<?php 
} elseif ($request['action'] == '2') {
    $key = new ApiKey($_POST['keyID'], $_POST['vCode'], 0, $db);
    if ($key->getKeyStatus() == 1) {
        if ($key->getAccessMask() & MINIMUM_API or $key->getExpiration() != 'No Expiration' or $key->getKeyType() != 'Account') {
            ?>
					<div class="col-md-offset-3 col-md-6 col-sm-offset-2 col-sm-8 mobile-reconfig" style="padding-right: 0px">
						<?php 
            showAlerts();
            ?>
						<div class="col-md-12 opaque-section" style="padding: 0px">
							<div class="row box-title-section">
								<h3 class="eve-text" style="text-align: center; font-size: 250%"><?php 
            echo SITE_NAME;
            ?>
</h3>
							</div>
							<div class="row" style="padding-left: 10px; padding-right: 10px">
								<p class="eve-text" style="font-size: 150%; text-align: center">Select the character you would like associated as your Main Character. This will be your TS3 name, Slack name, Forum name, and Auth name, so it is strongly recommended you go back and provide a key for your main character if it does not appear below.</p>
예제 #2
0
<?php

require_once 'includes/header.php';
use Pheal\Pheal;
use Pheal\Core\Config;
Config::getInstance()->cache = new \Pheal\Cache\MemcacheStorage();
Config::getInstance()->access = new \Pheal\Access\StaticCheck();
// Getting the compliance type
if ($request['action'] == 'api') {
    if ($request['value'] == 'refresh') {
        $key = new ApiKey($_POST['keyID'], $_POST['vCode'], $_POST['uid'], $db);
        if ($key->getKeyStatus() == 1 and $key->getAccessMask() & MINIMUM_API) {
            $update = $key->updateApiKey();
            if ($update) {
                foreach ($key->getCharacters() as $character) {
                    $char = new Character($character['characterID'], $key->getKeyID(), $key->getVCode(), $key->getAccessMask(), $db, $user);
                    if ($char->getExistance() or $char->getExistance() == FALSE) {
                        $char->updateCharacterInfo();
                    }
                }
                $refresh = $key->refreshAPIKey();
                setAlert('success', 'API Key Refreshed', 'The API key has been successfully refreshed.');
            }
        } elseif (!($key->getAccessMask() & MINIMUM_API) and $key->getKeyStatus() == 1) {
            setAlert('danger', 'The API Key Does Not Meet Minimum Requirements', 'The required minimum Access Mask for API keys is ' . MINIMUM_API . '. Please create a new key using the Create Key link.');
        }
    }
    // We're doing API compliance
    $compliance_type = "API";
    // Getting a full API-pulled member list
    $pheal = new Pheal($settings->getCorpUserID(), $settings->getCorpVCode(), 'corp');