-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathForward11.php
94 lines (84 loc) · 2.2 KB
/
Forward11.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<?php
include('func.php');
$title="SMS Controlled Robot";
#include('head.php');
set_time_limit(0);
$ser="http://site24.way2sms.com/";
$ckfile = tempnam ("/tmp", "CURLCOOKIE");
$login=$ser."Login1.action";
$uid="";
$pwd="";
$to="";
$msg="#F";
/*if(!$to)
{ $to=$uid; }
if(!$msg)
{ $msg=rword(5).rword(5).rword(5).rword(5).rword(5); }
*/
//$captcha=input($_REQUEST['captcha']);
//echo '<div class="head">'.$title.'</div>';
flush();
if($uid && $pwd)
{
$ibal="0";
$sbal="0";
$lhtml="0";
$shtml="0";
$khtml="0";
$qhtml="0";
$fhtml="0";
$te="0";
//echo '<div class="content">User: <span class="number"><b>'.$uid.'</b></span><br>';
flush();
$loginpost="gval=&username=".$uid."&password=".$pwd."&Login=Login";
$ch = curl_init();
$lhtml=post($login,$loginpost,$ch,$ckfile);
//curl_close($ch);
if(stristr($lhtml,'Location: '.$ser.'vem.action') || stristr($lhtml,'Location: '.$ser.'MainView.action') || stristr($lhtml,'Location: '.$ser.'ebrdg.action'))
{
preg_match("/~(.*?);/i",$lhtml,$id);
$id=$id['1'];
if(!$id)
{
show('Login Failed. We Didnot Get Session Value.','darkred');
goto end;
}
//show('Login Successfull.','darkgreen');
goto bal;
}
elseif(stristr($lhtml,'Location: http://site2.way2sms.com/entry'))
{
show('Login Failed. Invalid Login Details.','darkred');
goto end;
}
else
{
show('Login Failed. Unknown Error Occured.','darkred');
goto end;
}
bal:
//$ch = curl_init();
$proxy="";
$msg=urlencode($msg);
$main=$ser."smstoss.action";
$ref=$ser."sendSMS?Token=".$id;
$conf=$ser."smscofirm.action?SentMessage=".$msg."&Token=".$id."&status=0";
$post="ssaction=ss&Token=".$id."&mobile=".$to."&message=".$msg."&Send=Send Sms&msgLen=".strlen($msg);
$mhtml=post($main,$post,$ch,$ckfile,$proxy,$ref);
if(stristr($mhtml,'smscofirm.action?SentMessage='))
{
//echo '<meta http-equiv="refresh" content="0; url=Main.html">';
//show('SmS Sent Successfully To '.$to.'.','darkgreen');
}
else
{ show('Error in Sending SmS.','darkred');}
curl_close($ch);
end:
//echo "</div>";
flush();
}
//echo '<button type="button" onclick="location.href = 'First.html';">Back
//</button>';
echo '<center><p>Sent:Forward Successfully</p></center>';
//include('foot.php');
?>