function users_maintcontent_alm_users_ds_BeforeBuildUpdate(&$sender)
{
    $users_maintcontent_alm_users_ds_BeforeBuildUpdate = true;
    $Component =& $sender;
    $Container =& CCGetParentContainer($sender);
    global $users_maintcontent;
    //Compatibility
    //End users_maintcontent_alm_users_ds_BeforeBuildUpdate
    //Encrypt Password @8-A0C855A5
    if ("" != $Component->DataSource->password->GetValue()) {
        $Component->DataSource->password->SetValue(CCEncryptPasswordDB($Component->DataSource->password->GetValue()));
    } else {
        $Component->DataSource->password->SetValue(CCDecryptString($Component->DataSource->password_Shadow->GetValue(), CCS_ENCRYPTION_KEY_FOR_COOKIE));
    }
    //End Encrypt Password
    //Close users_maintcontent_alm_users_ds_BeforeBuildUpdate @3-CF5EA73C
    return $users_maintcontent_alm_users_ds_BeforeBuildUpdate;
}
Ejemplo n.º 2
0
function CCParseALCookie($cookieName)
{
    $cookieValue = CCGetCookie($cookieName);
    $decryptedCookieValue = strlen($cookieValue) ? CCDecryptString($cookieValue, CCS_ENCRYPTION_KEY_FOR_COOKIE) : "";
    $pos = strpos($decryptedCookieValue, ':');
    $parts = array();
    if ($pos) {
        $parts = explode(":", $decryptedCookieValue);
        $parts[0] = CCDecryptString($parts[0], CCS_ENCRYPTION_KEY_FOR_COOKIE);
        $parts[1] = CCDecryptString($parts[1], CCS_ENCRYPTION_KEY_FOR_COOKIE);
    }
    return $parts;
}