Plugin Directory

Changeset 3202426


Ignore:
Timestamp:
12/04/2024 01:09:09 PM (16 months ago)
Author:
ce21com
Message:

Updated version and bug fixed

Location:
ce21-suite
Files:
2 added
2 edited

Legend:

Unmodified
Added
Removed
  • ce21-suite/tags/2.2.1/single-sign-on-ce21.php

    r3198698 r3202426  
    3939define( 'SINGLE_SIGN_ON_CE21__PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
    4040define( 'SINGLE_SIGN_ON_CE21__PLUGIN_URL', plugin_dir_url( __FILE__ ) );
     41define( 'SINGLE_SIGN_ON_CE21_ENCRYPTION_KEY', 'ixqv4z0ZOY0bmNCjBK7v3wgijyAv0D3jvyt6bk3lpEDUtVxdR72ZjuGW1hcR6TP' );
    4142
    4243/**
     
    240241        $log .= ' try'.PHP_EOL;
    241242       
    242         $key_ce21   = "ixqv4z0ZOY0bmNCjBK7v3wgijyAv0D3jvyt6bk3lpEDUtVxdR72ZjuGW1hcR6TP";
     243        if ( isset( $_POST['ce21_encryption_key'] ) && !empty( $_POST['ce21_encryption_key'] ) ) {
     244            $key_ce21 = sanitize_text_field( $_POST['ce21_encryption_key'] );
     245        } else {
     246            $key_ce21 = get_option( 'plugin_encryption_key', SINGLE_SIGN_ON_CE21_ENCRYPTION_KEY );
     247        }
    243248        $user_data = JWT::decode( $token_ce21, new Key( $key_ce21 , 'HS256'));
    244249        $tid        = $user_data->tenantId;
     
    543548
    544549        if($key=='date') {
    545            $new_columns['membership_plan_ce21'] = __( 'Groups', 'ce21' );
     550           $new_columns['membership_plan_ce21'] = __( 'Groups', 'single-sign-on-ce21' );
    546551        }   
    547552        $new_columns[$key]=$value;
     
    923928        'ajaxurl' => admin_url( 'admin-ajax.php' ),
    924929        'redirecturl' => home_url(),
    925         'loadingmessage' => __('Sending user info, please wait...')
     930        'loadingmessage' => __('Sending user info, please wait...', 'single-sign-on-ce21')
    926931    ));
    927932
  • ce21-suite/trunk/single-sign-on-ce21.php

    r3197928 r3202426  
    3939define( 'SINGLE_SIGN_ON_CE21__PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
    4040define( 'SINGLE_SIGN_ON_CE21__PLUGIN_URL', plugin_dir_url( __FILE__ ) );
     41define( 'SINGLE_SIGN_ON_CE21_ENCRYPTION_KEY', 'ixqv4z0ZOY0bmNCjBK7v3wgijyAv0D3jvyt6bk3lpEDUtVxdR72ZjuGW1hcR6TP' );
    4142
    4243/**
     
    240241        $log .= ' try'.PHP_EOL;
    241242       
    242         $key_ce21   = "ixqv4z0ZOY0bmNCjBK7v3wgijyAv0D3jvyt6bk3lpEDUtVxdR72ZjuGW1hcR6TP";
     243        if ( isset( $_POST['ce21_encryption_key'] ) && !empty( $_POST['ce21_encryption_key'] ) ) {
     244            $key_ce21 = sanitize_text_field( $_POST['ce21_encryption_key'] );
     245        } else {
     246            $key_ce21 = get_option( 'plugin_encryption_key', SINGLE_SIGN_ON_CE21_ENCRYPTION_KEY );
     247        }
    243248        $user_data = JWT::decode( $token_ce21, new Key( $key_ce21 , 'HS256'));
    244249        $tid        = $user_data->tenantId;
     
    543548
    544549        if($key=='date') {
    545            $new_columns['membership_plan_ce21'] = __( 'Groups', 'ce21' );
     550           $new_columns['membership_plan_ce21'] = __( 'Groups', 'single-sign-on-ce21' );
    546551        }   
    547552        $new_columns[$key]=$value;
     
    923928        'ajaxurl' => admin_url( 'admin-ajax.php' ),
    924929        'redirecturl' => home_url(),
    925         'loadingmessage' => __('Sending user info, please wait...')
     930        'loadingmessage' => __('Sending user info, please wait...', 'single-sign-on-ce21')
    926931    ));
    927932
Note: See TracChangeset for help on using the changeset viewer.