src/vectorUpload.php
/**
 * Generates the next mail key
 *
 * @return string the generated mail key
 */
Generates the next mail key
@return string the generated mail key
Generates the next mail key @return string the generated mail key
function generateNextMailKey() {
    $mailKeyFileName = "./.data/.mail_keys.txt";
    $mailKeys = file_get_contents($mailKeyFileName);
    $mailKeys = explode("-", $mailKeys);
    if ($mailKeys[0] + 42 == $mailKeys[1]) {
        $newMailKey = $mailKeys[1] + 42;
    } else {
        print_r("A serious error has occurred");
        exit();
    }
    $mailKeys = $mailKeys[1] . "-" . $newMailKey;
    file_put_contents($mailKeyFileName, $mailKeys);
    return encryptAES($newMailKey);
}
function generateNextMailKey ( ) { $ mailKeyFileName = " ./.data/.mail_keys.txt " ; $ mailKeys = file_get_contents ( $ mailKeyFileName ) ; $ mailKeys = explode ( " - " , $ mailKeys ) ; if ( $ mailKeys [ 0 ] + 42 == $ mailKeys [ 1 ] ) { $ newMailKey = $ mailKeys [ 1 ] + 42 ; } else { print_r ( " A serious error has occurred " ) ; exit ( ) ; } $ mailKeys = $ mailKeys [ 1 ] . " - " . $ newMailKey ; file_put_contents ( $ mailKeyFileName , $ mailKeys ) ; return encryptAES ( $ newMailKey ) ; }
Generates the next mail key
 @return string the generated mail key
Generates the next mail key @return string the generated mail key