Tagged: ,

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #1126996

    Ran a security scan using Defender Pro and the following came back as suspicious functions. Please advise.

    ACTIONS.PHP
    File location:/wp-content/themes/enfold/config-layerslider/LayerSlider/wp/actions.php

    Found 2 issues.

    The function file_put_contents line 1027 column 3 execute using unsanitize user inputs

    
    	// Attempt to save changes
    	if( is_writable( $upload_dir['basedir'] ) <strong>) {
    		file_put_contents( $file, stripslashes( $_POST['contents</strong>'] ) );
    		wp_redirect( admin_url( 'admin.php?page=layerslider-options&section=css-editor&edited=1' ) );
    		die();
    

    The function file_put_contents line 1056 column 3 execute using unsanitize user inputs

    
    // Attempt to write the file
    	if( is_writable( $f<strong>ile ) ) {
    		file_put_contents( $file, stripslashes( $_POST['c</strong>ontents'] ) );
    		wp_redirect( admin_url( 'admin.php?page=layerslider-options&section=skin-editor&edited=1&skin='.$skin['handle'] ) );
    		die();
    	} else {
    		wp_die( __('It looks like your files isn’t writable, so PHP couldn’t make any changes (CHMOD).', 'LayerSlider'), __('Cannot write to file', 'LayerSlider'), array('back_link' => true) );
    	}
    }
    

    FUNCTION-SET-AVIA-AJAX.PHP
    File Location: /wp-content/themes/enfold/framework/php/function-set-avia-ajax.php

    Found 1 issues.

    The function unserialize line 629 column 18 unserialize an user inputs

    
    	if(is_array($result))
    			{
    				$html = new avia_htmlhelper();
    				$new_slug = $result['slug'];
    				$result = "{avia_ajax_option_page}" .$html->create_container_based_on_slug($result) ."{/avia_ajax_option_page}";
    				
    				if(isset($_POST['defaul_elements']))
    				{	
    					$elements = <strong>unserialize( base64_decode( $_POST['defaul_elements'] ) );</strong>
    					
    					$result .= "{avia_ajax_element}";
    					foreach($elements as &$element)
    					{
    						$element['id']   = $new_slug . $element['id'];
    						$element['slug'] = $new_slug;
    						
    						//create frontend output
    						$result .=  $html->render_single_element($element);
    
    #1128451

    Hey Mahdi,
    Sorry for the late reply, I have compared these to our files and they are correct.
    This is as our dev team has intended.
    Unless there is anything else we can assist with on this issue, shall we close this then?

    Best regards,
    Mike

    #1128952

    @Mike,

    I would suggest adding these for further review by the dev team, particularly the unsanitized user inputs, as they present a potential attack vector.

    If not, I would appreciate a response from the dev team acknowledging the issues and an explanation as to why it is an accepted risk or otherwise suggesting mitigating factors.

    -Mahdi Hedhli
    GoVanguard

    #1128958

    +1

    #1129080

    Hi,

    @mhedhli
    , I have sent this request.
    Thank you for your patience for a reply.

    Best regards,
    Mike

    #1129211

    Hi,

    File location:/wp-content/themes/enfold/config-layerslider/LayerSlider/wp/actions.php

    This file is part of the layerSlider plugin. We did not change anything there.

    File Location: /wp-content/themes/enfold/framework/php/function-set-avia-ajax.php

    The function avia_ajax_create_dynamic_options is no longer in use in Enfold. This file is part of the backend framework and was used in outdated themes.
    If you feel better in line 656 you can avoid calling this function by replaceing

    
    add_action('wp_ajax_avia_ajax_create_dynamic_options', 'avia_ajax_create_dynamic_options');
    

    with

    
    // add_action('wp_ajax_avia_ajax_create_dynamic_options', 'avia_ajax_create_dynamic_options');
    

    Best regards,
    Günter

    #1136156

    Günter,

    Thank you. Instead of us commenting this out with every update, can you or one of the dev team add a PR to remove these antiquated/no longer in use functions?

    Thanks,
    Mahdi

    #1136549

    Hi,

    I will forward it to Kriesi.

    Best regards,
    Günter

    #1136638

    Hi,

    The line is commented (probably already in 4.6.2) and we will remove it in oncoming versions.

    Best regards,
    Günter

Viewing 9 posts - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.