基于vue-cli与thinkphp的简单登录注册系统
本项目后台用到的控制器只有user和admin,其他可以作参考
yicenburan / manage Goto Github PK
View Code? Open in Web Editor NEW基于vue-cli与thinkphp的简单登录注册系统
基于vue-cli与thinkphp的简单登录注册系统
文件解压时出错,都是dhparams下的dhp文件出错 分别是128,1536,160,192,2048,256
Hello,
I would like to report to XSS vulnerability.
The path of the vulnerability.
In file Application/Home/Controller/GoodsController.class.php, line 21
public function postGoods(){
$postData = $_POST;
$add=true;
$this->upload($postData,$add);
}
line 53
public function upload($postData,$isAdd){
//...
$add['title']=$postData['title'];
$add['price']=$postData['price'];
$add['img']=$info['picture']['savepath'].$info['picture']['savename'];
if($isAdd){
$this->addGoods($add);
}
//...
}
}
line 77
public function addGoods($addGoods){
// ...
if($result >= 0){
$data=array(
code=>'0',
msg=>'添加成功',
data=>$addGoods
);
$this->ajaxReturn($data);
}
// ...
}
In file ThinkPHP/Mode/Api/Controller.class.php
line 55
protected function ajaxReturn($data,$type='') {
if(empty($type)) $type = C('DEFAULT_AJAX_RETURN');
switch (strtoupper($type)){
case 'JSON' :
// 返回JSON数据格式到客户端 包含状态信息
header('Content-Type:application/json; charset=utf-8');
exit(json_encode($data));
case 'XML' :
// 返回xml格式数据
header('Content-Type:text/xml; charset=utf-8');
exit(xml_encode($data));
case 'JSONP':
// 返回JSON数据格式到客户端 包含状态信息
header('Content-Type:application/json; charset=utf-8');
$handler = isset($_GET[C('VAR_JSONP_HANDLER')]) ? $_GET[C('VAR_JSONP_HANDLER')] : C('DEFAULT_JSONP_HANDLER');
exit($handler.'('.json_encode($data).');');
case 'EVAL' :
// 返回可执行的js脚本
header('Content-Type:text/html; charset=utf-8');
exit($data);
}
}
exit function will terminate the script and print a message to the user. Then there is XSS vulnerability because it contains values from $_POST.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.