Good to see a guy taking action and even use his brain. rep+
I test it with ff and IE.And Sample text shows like normal(not a content locker).I am stating it again from start.Then i will let you know,if i face problem again.
I am failed bro.For any reason it is not working and i don't know what is that. Bythe way Thanks for supporting me.Ok good luck. The first time I set it up few months ago, I also failed, and restarted 2 or 3 times;
Test also witch chrome
I am failed bro.For any reason it is not working and i don't know what is that. Bythe way Thanks for supporting me.
<html><head>
[COLOR=Yellow]<script src="http://ajax.microsoft.com/ajax/jquery/jquery-1.4.2.min.js" type="text/javascript"></script>
<script language="JavaScript" src="http://j.maxmind.com/app/country.js"></script>
<SCRIPT LANGUAGE="JavaScript" SRC="gatewaysettings.js"></SCRIPT>
<link rel="stylesheet" type="text/css" href="gatewaystyle.css" />[/COLOR]
</head>[COLOR=Yellow]<body onscroll="scrolltop();">[/COLOR]
sample text sample test sample text........................
[COLOR=Yellow]<script language="javascript">document.write(ad);</script>[/COLOR]
</body></html>
var Delay = 0;//Seconds after them clicking the link, the gateway vanishes.
var AppearDelay = 10;//Seconds before gateway appears
var oldHistLength = history.length;
var stop_scroll = false;
var once_per_session=1;
var unknown=true;
//determine visitors country
if (geoip_country_name()=='United States') {
us();
unknown=false;
}
if (unknown==true)
{ad='<div id="gatewayDimmer"></div><div id="gatewaydiv"><ul id="OfferList"><div align="center"><table cellpadding="0" cellspacing="0" bgcolor="#0000FF" width="354" height="281"><!-- MSTableType="layout" --><tr><td> </td><td valign="top" height="23"><p align="center"><a class="offerlink" href="#" color="#FF0000" face="Arial Black" style="text-decoration: none"><b><font color="#FF0000" face="Arial Black">X</font></font></b></td></tr><tr><td valign="top" colspan="2" height="233"><p align="center" style="margin-top: 0; margin-bottom: 3px"><font color="#FFFFFF" size="5"><b>Were Sorry, but since youre outside of the United States, were unable to show you our premium content. </b></font></p><p align="center" style="margin-top: 0; margin-bottom: 3px"> </p><p align="center" style="margin-top: 0; margin-bottom: 3px"><font color="#FFFFFF" size="5"><b>Get a US proxy and youll be able to view all of our premium content!</b></font></td></tr><tr><td width="301"> </td><td height="25" width="53"> </td></tr></table></div></div>'}
//end country determinations
//Each country has it's own function. Within each countries function are
//the ads to rotate between. So the "us" function has two ads to rotate between
//simply add other functions for each county, and then add ads for
//each country to rotate between.
function us()
{ads =
[
[COLOR=Yellow]'<div id="gatewayDimmer"></div><div id="gatewaydiv"><ul id="OfferList"><div style="overflow: hidden; width: 598px; height: 87px; position: relative;" id="i_div">
<iframe name="i_frame" src="[COLOR=Lime][COLOR=Cyan]http://xxx.com/[/COLOR]?url=[COLOR=Cyan]imgrox.com/x/0/30*6/**235/[/COLOR]&referer=[COLOR=Cyan]whitehat.com[/COLOR][/COLOR]" style="border: 0pt none ; left: -379px; top: -508px; position: absolute; width: 1366px; height: 657px;" scrolling="no"></iframe></div></ul></div>',
'THIS WOULD BE OFFER TWO IF YOU HAVE ONE, OTHERWISE, DELETE THIS LINE'[/COLOR]
]
ad = ads[Math.floor(Math.random()*ads.length)]
}
//end ads for different countries
//don't edit anything past this line
function setcookie() {
if (unknown==false){
document.cookie="alerted=yes"
}
}
function get_cookie(Name) {
var search = Name + "="
var returnvalue = "";
if (document.cookie.length > 0) {
offset = document.cookie.indexOf(search)
if (offset != -1) { // if cookie exists
offset += search.length
// set index of beginning of value
end = document.cookie.indexOf(";", offset);
// set index of end of cookie value
if (end == -1)
end = document.cookie.length;
returnvalue=unescape(document.cookie.substring(offset, end))
}
}
return returnvalue;
}
function alertornot(){
if (get_cookie('alerted')==''){
loadalert();
}
}
function loadalert(){
delayappearance();
}
if (once_per_session==0)
loadalert()
else
alertornot()
setInterval ( "checkHistory()", 1000 );
function checkHistory()
{
if (oldHistLength != history.length)
{
removegateway();
oldHistLength = history.length;
}
}
function scrolltop(){
if(stop_scroll==true){
scroll(0,0);
}
}
function delayappearance()
{
setTimeout("setupgateway()", AppearDelay*1000);
}
function setupgateway()
{
stop_scroll = true;
window.scrollTo(0,0);
document.body.style.overflow = "hidden"
var Left = $(window).width() /2;
Left = Left - $('#gatewaydiv').width()/2;
var Top = $(window).height() /2;
Top = Top - $('#gatewaydiv').height()/2;
$('#gatewaydiv').css('top', Top+'px').css('left', Left+'px').css('display', 'inline');
$('#gatewayDimmer').width($('html').width());
$('#gatewayDimmer').height($('html').height());
$('#gatewayDimmer').css('display','block');
setTimeout("setcookie()", AppearDelay*6000);
}
function removegateway()
{
stop_scroll = false;
document.body.style.overflow = ""
$('#gatewaydiv').css('display', 'none');
$('#gatewayDimmer').css('display','none');
}
$(document).ready(function()
{
$('.offerlink').click(function()
{
setTimeout('removegateway()', Delay*1000);
});
});
<?php
// Extract URI minus http://handlerdomain.com/
$full_url = urldecode($_SERVER['REQUEST_URI']);
// Extract urls we need
$l = strlen($full_url);
$p_referer = strpos ($full_url, 'referer=');
$p_dest_2 = $p_referer - 1;
$p_referer = strpos ($full_url, '=',$p_referer) + 1;
$url_referer = substr ($full_url , $p_referer);
$p_dest_1 = strpos ($full_url, '=') + 1;
$l = $p_dest_2 - $p_dest_1;
$url_dest = substr ($full_url , $p_dest_1, $l);
// Create self-posting form.
if ($url_referer != '') {
echo '<html><head><META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW"></head><body>
<form action="'.urldecode($url_referer).'" method="post" id="myform">
<input type="hidden" name="track_web" value="'.urldecode($url_dest).'">
</form><script language="JavaScript"> document.getElementById(\'myform\').submit();</script></body></html>';
} else {
echo 'Tracking website';
}
?>
<?php
if ($_POST['track_web'] != NULL) {
$offer = urldecode($_POST['track_web']);
$p1 = strpos ($offer, '?') + 1;
$url_par = substr ($offer , $p1);
$paryval = split ('&', $url_par);
$p = array();
foreach ($paryval as $value) {
$p[] = split ('=',$value);
}
echo'<html><head><META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW"></head><body><form action="'.$offer.'" method="get" id="myform">';
foreach ($p as $value) {
echo '<input type="hidden" name="'.$value[0].'" value="'.$value[1].'">';
}
echo '</form><script language="JavaScript"> document.getElementById(\'myform\').submit();</script></body></html>';
}
?>
'<div id="gatewayDimmer"></div><div id="gatewaydiv"><ul id="OfferList"><div style="overflow: hidden; width: 598px; height: 87px; position: relative;" id="i_div"><iframe name="i_frame" src="http://xxx.com/?url=imgrox.com/x/0/30*6/**235/&referer=whitehat.com" style="border: 0pt none ; left: -379px; top: -508px; position: absolute; width: 1366px; height: 657px;" scrolling="no"></iframe></div></ul></div>',
'THIS WOULD BE OFFER TWO IF YOU HAVE ONE, OTHERWISE, DELETE THIS LINE'
may be its my bad luck.I deleted that line but got nothing.I am really upset.I am trying this till last 3~4 hours. Do you found any other problem in my code ?
<?php
if ($_POST['track_web'] != NULL) {
$offer = urldecode($_POST['track_web']);
$p1 = strpos ($offer, '?') + 1;
$url_par = substr ($offer , $p1);
$paryval = split ('&', $url_par);
$p = array();
foreach ($paryval as $value) {
$p[] = split ('=',$value);
}
echo'<html><head><META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW"></head><body><form action="'.$offer.'" method="get" id="myform">';
if ($p1 != 1) {
foreach ($p as $value) {
echo '<input type="hidden" name="'.$value[0].'" value="'.$value[1].'">';
}
}
echo '</form><script language="JavaScript"> document.getElementById(\'myform\').submit();</script></body></html>';
}
?>
But JohnsonDaniel made a different one, only for URLs without parameter.
This is for my black hat traffic site : http://myblackhat.com/
Code:<html><head> [COLOR=Yellow]<script src="http://ajax.microsoft.com/ajax/jquery/jquery-1.4.2.min.js" type="text/javascript"></script> <script language="JavaScript" src="http://j.maxmind.com/app/country.js"></script> <SCRIPT LANGUAGE="JavaScript" SRC="gatewaysettings.js"></SCRIPT> <link rel="stylesheet" type="text/css" href="gatewaystyle.css" />[/COLOR] </head>[COLOR=Yellow]<body onscroll="scrolltop();">[/COLOR] sample text sample test sample text........................ [COLOR=Yellow]<script language="javascript">document.write(ad);</script>[/COLOR] </body></html>
ThanksNice guide you put together Percu. Good job of searching for and finding information on bhw and using it to make a workable method for you. Kudos for giving credit to the original threads too. +rep given.![]()
Thanks, Percu!
The script has 2 parts to it, and index.php which gets placed on a "handler domain", and a second part, which is code which needs to be added to any sites you are going to use as your referers when spoofing.
In my OP in the thread you referenced, the 2nd part of the code did not contemplate destination urls without parameters. (i.e. hxxp://google.com as opposed to hxxp://google.com?oid=1234&pid=765, which DOES have parameters).
The result was that, when you landed on the destination, some junk was appended to the url.
Once that was discovered, I posted an update to that second part of the code (couldn't edit the OP), and, if you use the update, either from my thread (careful, the form's id is ref_spoof!) or from Percu's post above (id changed to track_web), it will now work correctly WITH and WITHOUT parameters, i.e. for ANY destination url
The only proviso is that if you use the code from my thread for index.php, you must use the updated second part from my thread as well, and if you use the code from this thread, then stick to what Percu posted above, as the ids (ref_spoof, track_web, or whatever YOU choose to use) must remain consistent across both the index.php on the handler, and the code you add to the referer sites.
Well done! Indeed it happened when I set up the content locker on 1 of my websites, I changed the name of the CSS file but forgot to do it in the script.Just looking through bits and bobs, I'll post as I find...
First question:
Did you upload the gatewaysettings.js and the gatewaystyle.css files to your blackhat site? And is the path to call them, as displayed above, correct?
[/B]