Someone told me the following script could be used to run harmful
commands on the server, by passing commands into the script. What the
script does is encode an affiliate URL, create two frames, with the
affiliate URL decoded and placed in the bottom URL. The top frame
contains http://www.domain.com/selectanothercard.html for navigation
back to the originating site.
The script is accessed with a link like this:
<a href="sendcard. php?url=<? echo
base64_encode(" http://affiliateurl.co m/ecards/fourthjuly11107/index.php?en=1& aid=12345");
?>" target=_top>Sen d Card</a>
The affiliate URL is first encoded, because otherwise it breaks (the
ampersands cause problems). I tried another frame re-directing script,
but it wouldn't carry through the affiliate info properly, so someone
created this php script to encode/decode and create the frames.
Could this script be used to send harmful commands to the server? If
so, is there any way of modifying the script to fix that? Perhaps there
are other alternatives to passing an affiliate URL into a frame like
this script does?
Jason
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
</head>
<frameset rows="50,*" cols="*" framespacing="0 " frameborder="NO "
border="0">
<frame src="http://www.domain.com/selectanotherca rd.html"
name="topFrame" scrolling="NO" noresize >
<frame src="<? echo base64_decode($ url); ?>" name="mainFrame ">
</frameset>
<noframes>
<body>
Your browser does not support frames.
</body>
</noframes>
</html>
<?
//////////////////////////////////////////////////////////////////////////////
// NOTES
//////////////////////////////////////////////////////////////////////////////
/*
HOW TO LINK TO THIS FRAMESET
----------------------------
* Your document that contains the links, must have the file extension
..php
EXAMPLE LINK:
<a href="sendcard. php?url=<? echo
base64_encode(" http://affiliateurl.co m/ecards/fourthjuly11107/index.php?en=1& aid=12345");
?>" target=_top>Sen d Card</a>
*/
//////////////////////////////////////////////////////////////////////////////
// END NOTES
//////////////////////////////////////////////////////////////////////////////
?>
commands on the server, by passing commands into the script. What the
script does is encode an affiliate URL, create two frames, with the
affiliate URL decoded and placed in the bottom URL. The top frame
contains http://www.domain.com/selectanothercard.html for navigation
back to the originating site.
The script is accessed with a link like this:
<a href="sendcard. php?url=<? echo
base64_encode(" http://affiliateurl.co m/ecards/fourthjuly11107/index.php?en=1& aid=12345");
?>" target=_top>Sen d Card</a>
The affiliate URL is first encoded, because otherwise it breaks (the
ampersands cause problems). I tried another frame re-directing script,
but it wouldn't carry through the affiliate info properly, so someone
created this php script to encode/decode and create the frames.
Could this script be used to send harmful commands to the server? If
so, is there any way of modifying the script to fix that? Perhaps there
are other alternatives to passing an affiliate URL into a frame like
this script does?
Jason
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
</head>
<frameset rows="50,*" cols="*" framespacing="0 " frameborder="NO "
border="0">
<frame src="http://www.domain.com/selectanotherca rd.html"
name="topFrame" scrolling="NO" noresize >
<frame src="<? echo base64_decode($ url); ?>" name="mainFrame ">
</frameset>
<noframes>
<body>
Your browser does not support frames.
</body>
</noframes>
</html>
<?
//////////////////////////////////////////////////////////////////////////////
// NOTES
//////////////////////////////////////////////////////////////////////////////
/*
HOW TO LINK TO THIS FRAMESET
----------------------------
* Your document that contains the links, must have the file extension
..php
EXAMPLE LINK:
<a href="sendcard. php?url=<? echo
base64_encode(" http://affiliateurl.co m/ecards/fourthjuly11107/index.php?en=1& aid=12345");
?>" target=_top>Sen d Card</a>
*/
//////////////////////////////////////////////////////////////////////////////
// END NOTES
//////////////////////////////////////////////////////////////////////////////
?>
Comment