Woo Import Export

Woo Import Export v6.0.15

No permission to download

tstinfo07

New member
Jul 28, 2020
17
2
3
[QUOTE = "korvin_od, message: 229319, membre: 11880"]
J'ai résolu le problème en remplaçant le fichier
/wp-content/plugins/woo-import-export/includes/classes/class-wpie-license-manager.php
de la version précédente.
[/CITATION]
if you have this file plz give me
 

korvin_od

New member
Dec 21, 2018
8
3
3
Одесса
factorprint.art
PHP:
<?php

namespace wpie\license;

use \WP_Error;

if ( ! defined( 'ABSPATH' ) ) {
        die( __( "Can't load this file directly", 'woo-import-export' ) );
}

class WPIE_License_Manager {

        private $api_url = '';
        private $api_data = array ();
        private $name = '';
        private $slug = '';
        private $_plugin_file = '';
        private $did_check = false;
        private $version;
        private $license_db_key;
        private $transient_name;

        function __construct( $_api_url, $_plugin_file, $_api_data = null ) {

                $this->api_url = trailingslashit( $_api_url );

                $this->api_data = urlencode_deep( $_api_data );

                $this->name = plugin_basename( $_plugin_file );

                $this->slug = basename( $_plugin_file, '.php' );

                $this->version = isset( $_api_data[ 'version' ] ) ? $_api_data[ 'version' ] : 0;

                $this->_plugin_file = $_plugin_file;

                $this->license_db_key = isset( $_api_data[ 'license_db_key' ] ) ? md5( $_api_data[ 'license_db_key' ] ) : "";

                $this->transient_name = md5( 'wpie_' . sanitize_key( $this->name ) . '_plugin_updates' );
        }

        public function init() {

                add_filter( 'pre_set_site_transient_update_plugins', array ( $this, 'modify_plugins_transient' ), 10, 1 );

                add_filter( 'plugins_api', array ( $this, 'modify_plugin_details' ), 10, 3 );

                if ( is_admin() ) {

                        add_action( 'in_plugin_update_message-' . $this->name, array ( $this, 'modify_plugin_update_message' ), 10, 2 );
                }
        }

        function modify_plugin_update_message( $plugin_data, $response ) {

                if ( $this->get_license_key() ) {
                        return;
                }

                echo '<br />' . sprintf( __( 'To enable updates, please enter your license key on the <a href="%s">Updates</a> page.', 'woo-import-export' ), admin_url( 'admin.php?page=wpie-settings' ) );
        }

        public function modify_plugin_details( $result, $action = null, $args = null ) {

                if ( $action !== 'plugin_information' ) {
                        return $result;
                }

                if ( ! isset( $args->slug ) || ( $args->slug != $this->slug ) ) {

                        return $result;
                }

                $response = $this->get_plugin_transient();

                if ( ! is_object( $response ) ) {
                        return $result;
                }

                $response->sections = isset( $response->sections ) ? ( array ) $response->sections : array ();

                $response->icons = isset( $response->sections ) ? ( array ) $response->icons : array ();

                $response->banners = isset( $response->sections ) ? ( array ) $response->banners : array ();

                return $response;
        }

        public function modify_plugins_transient( $transient ) {

                if ( ! isset( $transient->response ) ) {
                        return $transient;
                }

                $force_check = ($this->did_check === false) ? ( isset( $_GET[ 'force-check' ] ) ? absint( $_GET[ 'force-check' ] ) == 1 : false) : false;

                $update = $this->get_plugin_transient( $force_check );

                if ( is_object( $update ) ) {

                        $res = new \stdClass();

                        $res->slug = $this->slug;

                        $res->plugin = $this->name;

                        $res->new_version = isset( $update->version ) ? $update->version : "";

                        $res->tested = isset( $update->tested ) ? $update->tested : "";

                        $res->url = isset( $update->homepage ) ? $update->homepage : "";

                        $res->icons = ( array ) $update->icons;

                        $res->banners = ( array ) $update->banners;

                        $res->package = "";

                        $license = $this->get_license_key();

                        if ( $license ) {
                                $res->package = $update->update_url . "?vlm_api_action=update_package&license=" . base64_encode( $license ) . "&wp_url=" . home_url() . "&plugin=" . $res->slug;
                        }

                        $res->download_link = $res->package;

                        $transient->response[ $this->name ] = $res;
                }

                $this->did_check = true;

                return $transient;
        }

        private function get_plugin_transient( $force_check = false ) {

                if ( ! $force_check ) {

                        $transient = get_transient( $this->transient_name );

                        if ( is_object( $transient ) ) {

                                if ( version_compare( $this->version, $transient->version, '=' ) ) {

                                        $transient = false;
                                }
                        }

                        if ( $transient !== false ) {
                                return $transient;
                        }
                }

                $response = $this->json_request( $this->api_url . 'items/woo-import-export/woo-import-export.json' );

                if ( is_object( $response ) && isset( $response->version ) ) {

                        if ( version_compare( $this->version, $response->version, '<' ) ) {

                                set_transient( $this->transient_name, $response, 43200 );

                                return $response;
                        } else {
                                $this->refresh_plugins_transient();
                        }
                }

                return false;
        }

        private function json_request( $url = "" ) {

                if ( empty( $url ) ) {
                        return false;
                }

                $response = wp_remote_get( $url, array (
                        'timeout' => 10,
                        'headers' => array (
                                'Accept' => 'application/json'
                        ) )
                );

                if ( is_wp_error( $response ) ) {
                        return $response;
                } elseif ( wp_remote_retrieve_response_code( $response ) != 200 ) {
                        return new \WP_Error( 'server_error', wp_remote_retrieve_response_message( $response ) );
                }

                $json = json_decode( wp_remote_retrieve_body( $response ) );

                if ( $json === null ) {
                        return wp_remote_retrieve_body( $response );
                }

                return $json;
        }

        private function request( $url = '', $body = array (), $method = "post" ) {

                if ( $method == "get" ) {

                        $response = wp_remote_get( $url, array (
                                'timeout' => 30,
                                'body'    => $body
                                ) );
                } else {

                        $response = wp_remote_post( $url, array (
                                'timeout' => 30,
                                'body'    => $body
                                ) );
                }

                if ( is_wp_error( $response ) ) {
                        return $response;
                } elseif ( wp_remote_retrieve_response_code( $response ) != 200 ) {
                        return new \WP_Error( 'server_error', wp_remote_retrieve_response_message( $response ) );
                }

                $json = json_decode( wp_remote_retrieve_body( $response ), true );

                if ( $json === null ) {
                        return wp_remote_retrieve_body( $response );
                }
                return $json;
        }

        private function update_license( $key = "", $expire = "" ) {

                $value = '';

              

                        $data = array (
                                'key'    => 'nullmasterinbabiato',
                                'url'    => home_url(),
                                'expire' => '01/01/2099'
                        );

                        $value = base64_encode( maybe_serialize( $data ) );
              

                update_option( $this->license_db_key, $value );
        }

        public function is_license_active() {

                
                        return true;
                
        }

        public function get_plugin_data() {

                
        }

        private function get_license_key() {

              
                $home_url = home_url();

                if ( $this->strip_protocol( $license[ 'url' ] ) !== $this->strip_protocol( $home_url ) ) {
                        return false;
                }

                return 'nullmasterinbabiato';
        }

        function strip_protocol( $url ) {

                return str_replace( array ( 'http://', 'https://' ), '', $url );
        }

        private function get_license() {
                $license = 'nullmasterinbabiato';
                $license = maybe_unserialize( base64_decode( $license ) );
                return $license;
        }

        public function wpie_change_license_status() {

                $status =  "activate";

                $license = "nullmasterinbabiato";

                if ( $status == "activate" ) {

                      
                        $is_active = $this->activate_license( $license );

                      
                         wp_send_json_success( __( 'License Successfully Activated', 'woo-import-export' ) );
                        
                } else {

                        $is_deactive = $this->deactivate_license();

                        
                         wp_send_json_success( __( 'License Successfully Deactivated', 'woo-import-export' ) );
                      
                }
        }

        private function activate_license( $license = "" ) {

                
                
                $this->update_license( $license, '01/01/2099' );
                $this->refresh_plugins_transient();
                return true;
              


               $post = array (
                        'vlm_api_action' => "license_activate",
                        'plugin'         => "woo-import-export",
                        'license'        => base64_encode( $license ),
                        'version'        => WPIE_PLUGIN_VERSION,
                        'wp_name'        => get_bloginfo( 'name' ),
                        'wp_url'         => home_url(),
                        'wp_version'     => get_bloginfo( 'version' ),
                        'wp_language'    => get_bloginfo( 'language' ),
                        'wp_timezone'    => get_option( 'timezone_string' ),
                );

                $response = $this->request( $this->api_url, $post );

                $is_error = true;

                if ( is_wp_error( $response ) ) {
                        return $response;
                } elseif ( is_array( $response ) && isset( $response[ 'success' ] ) ) {

                        if ( empty( $response[ 'success' ] ) ) {

                                if ( isset( $response[ 'data' ] ) ) {

                                        return new \WP_Error( 'server_error', esc_html( $response[ 'data' ] ) );
                                }
                        } else {
                                $is_error = false;
                        }
                }

                if ( $is_error ) {
                        return new \WP_Error( 'server_error', __( 'unexpected error occurred while activation of license', 'woo-import-export' ) );
                }

                $expire = isset( $response[ 'expire' ] ) ? $response[ 'expire' ] : "";

                $this->update_license( $license, $expire );

                $this->refresh_plugins_transient();

                return true;
        }

        private function deactivate_license() {
            $this->update_license();
            $this->refresh_plugins_transient();
            return true;
                $license = $this->get_license_key();

                if ( ! $license ) {
                        return;
                }

                $post = array (
                        'vlm_api_action' => "license_deactivate",
                        'license'        => base64_encode( $license ),
                        'wp_url'         => home_url(),
                );

                $response = $this->request( $this->api_url, $post );

                $is_error = true;

                if ( isset( $response[ 'success' ] ) ) {

                        if ( empty( $response[ 'success' ] ) ) {

                                if ( isset( $response[ 'data' ] ) ) {

                                        return new \WP_Error( 'server_error', esc_html( $response[ 'data' ] ) );
                                }
                        } else {
                                $is_error = false;
                        }
                }

                if ( $is_error ) {
                        return new \WP_Error( 'server_error', __( 'unexpected error occurred while activation of license', 'woo-import-export' ) );
                }

                $this->update_license();

                $this->refresh_plugins_transient();

                return true;
        }

        function refresh_plugins_transient() {

                delete_site_transient( 'update_plugins' );

                delete_transient( $this->transient_name );
        }

}
 

NullMaster

Well-known member
Null Master
Trusted Uploader
Jul 25, 2018
12,058
22,063
120
wpie-general-admin.min.js
decompress..
jQuery.ajax({
url: wpiePluginSettings.wpieAjaxURL,
type: "POST",
data: "action=wpie_change_license_status&status=" + e + "&license=" + i,
dataType: "json",
async: !0,
success: function (i) {
if (!1 === i.success) return wpieSetErrorMsg(i.data), !1;
"activate" == e
? (jQuery(".wpie_license_activation_wrapper").hide(), jQuery(".wpie_license_deactivation_wrapper").show())
: (jQuery(".wpie_license_activation_wrapper").show(), jQuery(".wpie_license_deactivation_wrapper").hide()),
wpieSetSuccessMsg(i.data),
wpieHideLoader();
},
error: function (e, i) {
wpieHandleAjaxError(e, i);
},
});
 
  • Like
Reactions: tanierlyons
F

felipe-rolim

Guest
Thank you!

The new version now doesn't show anymore the licence message, but when I finish import customers, all the data is skipped and nothing is imported after all.

Is something in my end?
 

pedrothelion

Member
May 20, 2019
135
17
18
LOL You posted just before me. Now they have two to try! :)

Hello! What is the use if when click 'update now' I get Update failed: The package could not be installed. PCLZIP_ERR_BAD_FORMAT (-10) : Unable to find End of Central Dir Record signature ?
 

tanierlyons

Well-known member
Staff member
Administrative
Moderator
May 24, 2018
75,058
111,714
120

wazzz

New member
Mar 17, 2020
25
12
3
When I try to download it:
The file you are trying to download is no longer available.
The account that created this link has been terminated due to multiple violations of our Terms and Cond
 

tanierlyons

Well-known member
Staff member
Administrative
Moderator
May 24, 2018
75,058
111,714
120
  • Like
Reactions: JRGWxRxZ

tanierlyons

Well-known member
Staff member
Administrative
Moderator
May 24, 2018
75,058
111,714
120
  • Like
Reactions: JRGWxRxZ

About us

  • Our community has been around for many years and pride ourselves on offering unbiased, critical discussion among people of all different backgrounds. We are working every day to make sure our community is one of the best.

Quick Navigation

User Menu