# 金玉FLASH滚动展示上传系统的无限制上传漏洞

**URL:** <https://forum.90sec.com/t/topic/3195>\
**Category:** 代码审计\
**Created:** [2012 年2 月 5 日 16:52 UTC](https://forum.90sec.com/t/topic/3195 "2012-02-05T16:52:12Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

作者： ![user35](https://forum.90sec.com/user_avatar/forum.90sec.com/user35/32/11382_2.png) [@user35](https://forum.90sec.com/u/user35)\
发布日期： [2012 年2 月 5 日 16:52 UTC](https://forum.90sec.com/t/topic/3195/1 "2012-02-05T16:52:12Z")

</div>

因为90说要清理ID，诚惶诚恐的来了  
因为最近在上学，所以没有时间  
小菜我就发个垃圾的漏洞，算是给比我还菜的菜鸟分析一下代码{:4\_67:} （虽然我是最菜的...呜呜）  
金玉FLASH滚动展示上传系统的无限制上传漏洞  
金玉FLASH滚动展示上传系统一般镶嵌在一些企业管理的系统中  
有后台登陆啊神马的  
废话不多说了，看代码

\<!--#include file="upload\_5xsoft.inc" --\>  
\<style type="text/css"\>  
\<!--  
a { font-family: "宋体"; font-size: 9pt; font-style: normal; line-height: 13pt; font-weight: normal; font-variant: normal; text-transform: none; color: \<%=fontcolor%\>; text-decoration: none}  
a:hover { font-family: "宋体"; font-size: 9pt; font-style: normal; line-height: 13pt; font-weight: normal; font-variant: normal; text-transform: none; color: \<%=fontcolor%\>; text-decoration: underline}  
td { font-family: "宋体"; font-size: 9pt; font-style: normal; line-height: 13pt; font-weight: normal; font-variant: normal; text-transform: none; color: \<%=fontcolor%\>}  
br { font-family: "宋体"; font-size: 9pt; font-style: normal; line-height: 13pt; font-weight: normal; font-variant: normal; text-transform: none; color: \<%=fontcolor%\>}  
.bk { font-size: 9pt; border: 1px \<%=xcolor%\> solid}  
body { font-family: "宋体"; font-size: 9pt; font-style: normal; line-height: 13pt; font-weight: normal; font-variant: normal; text-transform: none}  
.an { font-family: "宋体"; font-size: 9pt; background-color: \<%=bgcolor%\>; border: 1px \<%=xcolor%\> solid; color: \<%=fontcolor%\>}  
.xzy { border: \<%=xcolor%\> solid; border-width: 0px 1px 1px}  
.zx { border: \<%=xcolor%\> solid; border-width: 0px 0px 1px 1px}  
.sxz { border: \<%=xcolor%\> solid; border-width: 1px 0px 1px 1px}  
.s { border: \<%=xcolor%\>; border-style: solid; border-top-width: 1px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px}  
.y { border: \<%=xcolor%\>; border-style: solid; border-top-width: 0px; border-right-width: 1px; border-bottom-width: 0px; border-left-width: 0px}  
.font { font-family: "Arial Black"; font-size: 14pt; color: \<%=fontcolor%\>}  
.x { border: \<%=xcolor%\>; border-style: solid; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 1px; border-left-width: 0px}  
.z { border: \<%=xcolor%\>; border-style: solid; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 1px}  
.sx { border: \<%=xcolor%\>; border-style: solid; border-top-width: 1px; border-right-width: 0px; border-bottom-width: 1px; border-left-width: 0px}  
--\>  
\</style\>  
\<body bgcolor="ffffff" leftmargin="0" topmargin="0"\>  
\<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0"\>  
\<tr\>  
\<td align="center"\>

```xml
<script language="Javascript">
function eimage(smileface)
{
	window.opener.document.form.eimage.value=smileface;
}

</script>

```

```
  &lt;%

```

set upload=new upload\_5xSoft  
set file=upload.file("file1")  
formPath="../flash\_images/"  
if file.filesize\>100 then  
fileExt=lcase(right(file.filename,3))  
if fileExt="asp" then  
Response.Write"文件类型非法"  
end if  
end if  
randomize  
ranNum=int(90000\*rnd)+10000  
filename=formPath&year(now)&month(now)&day(now)&hour(now)&minute(now)&second(now)&ranNum&"."&fileExt  
picname="flash\_images/"&year(now)&month(now)&day(now)&hour(now)&minute(now)&second(now)&ranNum&"."&fileExt  
if file.FileSize\>0 then  
file.SaveAs Server.mappath(FileName)  
end ifresponse.write "\<img src=../pic/chenggong.gif\>\</img\> \<br\>\<a href=Javascript:eimage('"&picname&"');window.close();\>我决定用这张图片\</a\> "%\>  
\</td\>  
\</tr\>  
\</table\>  
\</body\>  
大家可以看到，只是在上传asp的时候会提示文件非法  
但是文件都给上传了  
很低级的漏洞...  
希望各位大牛不要喷~

---

<div class="post-metadata">

作者： ![jjf012](https://forum.90sec.com/letter_avatar_proxy/v4/letter/j/b5a626/32.png) [@jjf012](https://forum.90sec.com/u/jjf012)\
发布日期： [2012 年2 月 5 日 17:50 UTC](https://forum.90sec.com/t/topic/3195/2 "2012-02-05T17:50:12Z")

</div>

楼主你看到源码之后是不是直奔上传页面？

---

<div class="post-metadata">

作者： ![user35](https://forum.90sec.com/user_avatar/forum.90sec.com/user35/32/11382_2.png) [@user35](https://forum.90sec.com/u/user35)\
发布日期： [2012 年2 月 6 日 11:36 UTC](https://forum.90sec.com/t/topic/3195/3 "2012-02-06T11:36:44Z")

</div>

\*\*回复 [3#](http://www.90sec.org/redirect.php?goto=findpost&pid=14481&ptid=1441) _enki_ \*\*

```
不需要的，只要找到路径就可，路径默认为admin2

```

---

<div class="post-metadata">

作者： ![user21](https://forum.90sec.com/letter_avatar_proxy/v4/letter/u/6bbea6/32.png) [@user21](https://forum.90sec.com/u/user21)\
发布日期： [2012 年2 月 8 日 07:59 UTC](https://forum.90sec.com/t/topic/3195/4 "2012-02-08T07:59:29Z")

</div>

原来你也是学生娃。。。

---

<div class="post-metadata">

作者： ![user28](https://forum.90sec.com/user_avatar/forum.90sec.com/user28/32/11371_2.png) [@user28](https://forum.90sec.com/u/user28)\
发布日期： [2012 年2 月 9 日 09:44 UTC](https://forum.90sec.com/t/topic/3195/5 "2012-02-09T09:44:18Z")

</div>

呵呵试着弄了一个，还挺靠谱

---

<div class="post-metadata">

作者： ![wefgod](https://forum.90sec.com/letter_avatar_proxy/v4/letter/w/a587f6/32.png) [@wefgod](https://forum.90sec.com/u/wefgod)\
发布日期： [2012 年2 月 12 日 13:31 UTC](https://forum.90sec.com/t/topic/3195/6 "2012-02-12T13:31:24Z")

</div>

用黑名单来防文件上传是很不好的方法

---

<div class="post-metadata">

作者： ![kerling3389](https://forum.90sec.com/letter_avatar_proxy/v4/letter/k/dfb087/32.png) [@kerling3389](https://forum.90sec.com/u/kerling3389)\
发布日期： [2012 年2 月 16 日 08:29 UTC](https://forum.90sec.com/t/topic/3195/7 "2012-02-16T08:29:41Z")

</div>

我晕倒....不用全部都打上来吧...

---

<div class="post-metadata">

作者： ![347574754](https://forum.90sec.com/letter_avatar_proxy/v4/letter/3/ce73a5/32.png) [@347574754](https://forum.90sec.com/u/347574754)\
发布日期： [2012 年2 月 16 日 09:14 UTC](https://forum.90sec.com/t/topic/3195/8 "2012-02-16T09:14:22Z")

</div>

感谢分享，留着用

---

<div class="post-metadata">

作者： ![649334222](https://forum.90sec.com/letter_avatar_proxy/v4/letter/6/6bbea6/32.png) [@649334222](https://forum.90sec.com/u/649334222)\
发布日期： [2012 年2 月 17 日 06:09 UTC](https://forum.90sec.com/t/topic/3195/9 "2012-02-17T06:09:53Z")

</div>

哇咔咔，真好，截图都不用

---

<div class="post-metadata">

作者： ![user33](https://forum.90sec.com/user_avatar/forum.90sec.com/user33/32/11379_2.png) [@user33](https://forum.90sec.com/u/user33)\
发布日期： [2012 年2 月 27 日 16:58 UTC](https://forum.90sec.com/t/topic/3195/10 "2012-02-27T16:58:42Z")

</div>

狗哥写得好，狗哥是大学狗?
