| | |
| | | '连接数据库
|
| | | Set objConn = Server.CreateObject("ADODB.Connection")
|
| | | 'objConn.ConnectionString="Provider=SQLOLEDB.1;Password=1382929319;Persist Security Info=True;User ID=sa;Initial Catalog=CAME;Data Source=120.24.159.70;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=CAME;Data Source=localhost;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=CAME;Data Source=120.25.98.119,1432;Connect Timeout=60"
|
| | | objConn.Open
|
| | |
|
| | | '防护XSS,sql注射,代码执行,文件包含等多种高危漏洞
|
| | |
| | | session_start();
|
| | | //echo phpinfo();
|
| | | //exit;
|
| | | $serverName = "localhost";//服务器的名字,本地localhost
|
| | | $serverName = "120.25.98.119,1432";//服务器的名字,本地localhost
|
| | | $connectionInfo = array( "Database"=>"CAME", "UID"=>"camesa", "PWD"=>"camesa", "CharacterSet"=>"UTF-8");
|
| | | $conn = sqlsrv_connect( $serverName, $connectionInfo);
|
| | | if( $conn ) {
|
| | |
| | | '连接数据库
|
| | | Set objConn = Server.CreateObject("ADODB.Connection")
|
| | | 'objConn.ConnectionString="Provider=SQLOLEDB.1;Password=1382929319;Persist Security Info=True;User ID=sa;Initial Catalog=CAME;Data Source=120.24.159.70;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=came_demo;Data Source=localhost;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=came_demo;Data Source=120.25.98.119,1432;Connect Timeout=60"
|
| | | objConn.Open
|
| | |
|
| | | '防护XSS,sql注射,代码执行,文件包含等多种高危漏洞
|
| | |
| | | }
|
| | |
|
| | | }
|
| | |
|
| | | function sendPayUrl($phone,$name,$payurl){
|
| | | $content='【医疗快线】移动支付指引:'.$name.'您好!请点击以下链接进入信息确认和支付界面。核对您的出车信息无误后,可选择支付宝或者微信支付:' .$payurl;
|
| | | require './sms/SmsSend.php';
|
| | | $sms = new SmsSend('LTAIySpe19H0jIwE', 'eH9JQEZZCgFguaDfcCLUcpK6746tgT');
|
| | | $result = $sms->sendSmsOne([['phone' => $phone, 'content' => $content]], '');
|
| | | return $result;
|
| | | }
|
| | | // 调用示例:
|
| | | set_time_limit(0);
|
| | | header('Content-Type: text/plain; charset=utf-8');
|
| | |
| | | $name=empty($_REQUEST['name'])!=false ? "" : addslashes($_REQUEST['name']); //内容--姓名
|
| | | $payurl=empty($_REQUEST['payurl'])!=false ? "" : addslashes($_REQUEST['payurl']); //内容--短链接验证码
|
| | | $codejson=json_encode(array("name"=>$name,"payurl"=>$payurl), JSON_UNESCAPED_UNICODE);
|
| | | sendPayUrl($Phone,$name,$payurl);
|
| | | return;
|
| | | }elseif ($lateCode=="SMS_172011256" or $lateCode=="SMS_219742082") {
|
| | | //出车短信
|
| | | $UserName=empty($_REQUEST['UserName'])!=false ? "" : addslashes($_REQUEST['UserName']); //内容--负责人
|
New file |
| | |
| | | <?php |
| | | require "SmsUtils.php"; |
| | | |
| | | class SmsSend{ |
| | | private $userName = ""; |
| | | private $password = ""; |
| | | private $address = ""; |
| | | |
| | | public function __construct($userName, $password, $address="http://sms.izjun.com:8001/sms") { |
| | | $this->userName = $userName; |
| | | $this->password = $password; |
| | | $this->address = $address; |
| | | } |
| | | |
| | | public function sendSmsMass($phoneList, $content, $sendTime, $extcode, $callData) { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/sendMessageMass"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "content" => $content, |
| | | "phoneList" => $phoneList, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign, |
| | | "sendTime" => $sendTime, |
| | | "extCode" => $extcode, |
| | | "callData" => $callData |
| | | ); |
| | | |
| | | // 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | public function sendSmsOne($messageList, $sendTime) { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/sendMessageOne"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign, |
| | | "messageList" => $messageList, |
| | | "sendTime" => $sendTime, |
| | | ); |
| | | |
| | | // 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | public function getReport() { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/getReport"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign, |
| | | ); |
| | | |
| | | // 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | public function getUpstream() { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/getUpstream"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign, |
| | | ); |
| | | |
| | | // 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | public function getBalance() { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/getBalance"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign, |
| | | ); |
| | | |
| | | // 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | public function createTemplate($content) { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/createTemplate"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign, |
| | | "content" => $content |
| | | ); |
| | | |
| | | // 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | public function queryTemplate() { |
| | | // 获取时间戳 |
| | | $timestamp = SmsUtils::getTimestamp(); |
| | | // 获取sign |
| | | $sign = SmsUtils::generateSign($this->userName, $this->password, $timestamp); |
| | | // 获取url |
| | | $url = "http://" . $this->address . "/sms/api/queryTemplates"; |
| | | // 请求数据 |
| | | $data = array( |
| | | "userName" => $this->userName, |
| | | "timestamp" => $timestamp, |
| | | "sign" => $sign |
| | | ); |
| | | |
| | | # 发送请求 |
| | | return SmsUtils::send($url, $data); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | ?> |
New file |
| | |
| | | <?php |
| | | // 短信发送工具类 |
| | | class SmsUtils{ |
| | | // 获取时间戳 |
| | | public static function getTimestamp() { |
| | | return time() * 1000; |
| | | } |
| | | |
| | | // 生成sign |
| | | public static function generateSign($account, $password, $timestamp) { |
| | | $value = $account . $timestamp . md5($password); |
| | | return md5($value); |
| | | } |
| | | |
| | | // post请求 |
| | | public static function send($url, $data) { |
| | | // 定义请求选项 |
| | | $options = [ |
| | | 'http' => [ |
| | | 'header' => "Content-Type: application/json;charset=utf-8\r\nAccept: application/json\r\n", |
| | | 'method' => 'POST', |
| | | 'content' => json_encode($data) |
| | | ] |
| | | ]; |
| | | // 发送 HTTP 请求 |
| | | $context = stream_context_create($options); |
| | | $result = file_get_contents($url, false, $context); |
| | | return $result; |
| | | } |
| | | } |
| | | ?> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <configuration> |
| | | <system.webServer> |
| | | <defaultDocument> |
| | | <files> |
| | | <remove value="default.aspx" /> |
| | | <remove value="Default.htm" /> |
| | | <remove value="Default.asp" /> |
| | | <remove value="index.htm" /> |
| | | <remove value="index.html" /> |
| | | <remove value="iisstart.htm" /> |
| | | <add value="index.gds" /> |
| | | </files> |
| | | </defaultDocument> |
| | | <handlers> |
| | | <remove name="php" /> |
| | | <remove name="FastCGI" /> |
| | | <add name="gds" path="*.gds" verb="*" modules="IsapiModule" scriptProcessor="C:\Windows\System32\inetsrv\asp.dll" resourceType="File" preCondition="bitness64" /> |
| | | <add name="FastCGI" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="D:\project\急救转运\code\php\php-cgi.exe" resourceType="File" requireAccess="Script" /> |
| | | <add name="php" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="C:\php\php-cgi.exe" resourceType="File" requireAccess="Script" /> |
| | | </handlers> |
| | | <httpErrors errorMode="DetailedLocalOnly" /> |
| | | |
| | | |
| | | </system.webServer> |
| | | </configuration> |
| | |
| | | session_start();
|
| | | //echo phpinfo();
|
| | | //exit;
|
| | | $serverName = "localhost";//服务器的名字,本地localhost
|
| | | $serverName = "120.25.98.119,1432";//服务器的名字,本地localhost
|
| | | $connectionInfo = array( "Database"=>"Welcab", "UID"=>"camesa", "PWD"=>"camesa", "CharacterSet"=>"UTF-8");
|
| | | $conn = sqlsrv_connect( $serverName, $connectionInfo);
|
| | | if( $conn ) {
|
| | |
| | | Response.Cookies("CAMEName").Expires=Date+30
|
| | | Set adminrs = Server.CreateObject("ADODB.Recordset")
|
| | | If Len(admin)=11 And IsNumeric(admin) Then SqlPhone=" or OA_mobile='"&admin&"'"
|
| | | If admin="vicgame" And loginAuthorize="123" Then '测试账号
|
| | | If admin="13602220409" or admin="13710299733" And loginAuthorize="123" Then '测试账号
|
| | | sql="select * from OA_User where (OA_User='"&admin&"'"&SqlPhone&") and OA_execLevel>=0"
|
| | | ElseIf Cookieslogin="YES" Then 'Cookies登陆
|
| | | sql="select * from OA_User where (OA_User='"&admin&"') and OA_execLevel>=0"
|
| | |
| | | '连接数据库
|
| | | Set objConn = Server.CreateObject("ADODB.Connection")
|
| | | 'objConn.ConnectionString="Provider=SQLOLEDB.1;Password=1382929319;Persist Security Info=True;User ID=sa;Initial Catalog=CAME;Data Source=120.24.159.70;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=CAME;Data Source=localhost;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=CAME;Data Source=120.25.98.119,1432;Connect Timeout=60"
|
| | | objConn.Open
|
| | |
|
| | | '防护XSS,sql注射,代码执行,文件包含等多种高危漏洞
|
| | |
| | | session_start();
|
| | | //echo phpinfo();
|
| | | //exit;
|
| | | $serverName = "localhost";//服务器的名字,本地localhost
|
| | | $serverName = "120.25.98.119,1432";//服务器的名字,本地localhost
|
| | | $connectionInfo = array( "Database"=>"CAME", "UID"=>"camesa", "PWD"=>"camesa", "CharacterSet"=>"UTF-8");
|
| | | $conn = sqlsrv_connect( $serverName, $connectionInfo);
|
| | | if( $conn ) {
|
| | |
| | | '连接数据库
|
| | | Set objConn = Server.CreateObject("ADODB.Connection")
|
| | | 'objConn.ConnectionString="Provider=SQLOLEDB.1;Password=1382929319;Persist Security Info=True;User ID=sa;Initial Catalog=CAME;Data Source=120.24.159.70;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=CAME;Data Source=localhost;Connect Timeout=60"
|
| | | objConn.ConnectionString="Provider=SQLOLEDB.1;Password=camesa;Persist Security Info=True;User ID=camesa;Initial Catalog=CAME;Data Source=120.25.98.119,1432;Connect Timeout=60"
|
| | | objConn.Open
|
| | |
|
| | | '防护XSS,sql注射,代码执行,文件包含等多种高危漏洞
|
| | |
| | | </files>
|
| | | </defaultDocument>
|
| | | <handlers>
|
| | | <remove name="php" />
|
| | | <remove name="FastCGI" />
|
| | | <add name="gds" path="*.gds" verb="*" modules="IsapiModule" scriptProcessor="C:\Windows\System32\inetsrv\asp.dll" resourceType="File" preCondition="bitness64" />
|
| | | <add name="FastCGI" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="C:\php\php-cgi.exe" resourceType="File" requireAccess="Script" />
|
| | | <add name="FastCGI" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="D:\project\急救转运\code\php\php-cgi.exe" resourceType="File" requireAccess="Script" />
|
| | | <add name="php" path="*.php" verb="*" modules="FastCgiModule" scriptProcessor="C:\php\php-cgi.exe" resourceType="File" requireAccess="Script" />
|
| | | </handlers>
|
| | | <staticContent>
|
| | | <mimeMap fileExtension=".wasm" mimeType="video/x-ms-wmv" />
|
| | | </staticContent>
|
| | | <rewrite>
|
| | | <rules>
|
| | | <rule name="sys" stopProcessing="true">
|
| | | <match url="(.*)" />
|
| | | <conditions>
|
| | | <add input="{HTTPS}" pattern="^OFF$" />
|
| | | <add input="{HTTPS_HOST}" pattern="^(localhst)" negate="true" />
|
| | | </conditions>
|
| | | <action type="Redirect" url="https://{HTTP_HOST}/{R:1}" />
|
| | | </rule>
|
| | | </rules>
|
| | | </rewrite>
|
| | | <httpErrors errorMode="DetailedLocalOnly" />
|
| | | |
| | | |
| | | </system.webServer>
|
| | | </configuration>
|
| | |
| | | <directoryBrowse enabled="false" />
|
| | | </system.webServer>
|
| | | </configuration>
|
| | | ion>
|
| | |
| | | <!--#include virtual="/inc/odbc1.asp"-->
|
| | | <script language="jscript" runat="server">
|
| | | Array.prototype.get = function(i)
|
| | | {
|
| | | return this[i]; |
| | | };
|
| | | function getjson(str){
|
| | | try{
|
| | | eval("var jsonStr = (" + str + ")");
|
| | | }catch(ex){
|
| | | var jsonStr = null;
|
| | | }
|
| | | return jsonStr;
|
| | | }
|
| | | </script>
|
| | | <%
|
| | | '接口信息
|
| | | corpid="wx248505bfbab6d0c1"
|
| | |
| | | url="https://qyapi.weixin.qq.com/cgi-bin/gettoken" '//定义要获取源代码的网址,一般是通过变量传递过来
|
| | | Origin="corpid="&corpid&"&corpsecret="&corpsecret
|
| | | HTMLCODE= GetBody(url,Origin)
|
| | | 'Response.Write url&"?"&Origin
|
| | | str="["&HTMLCODE&"]"
|
| | | 'Response.Write url&"?"&Origin
|
| | | Response.write str
|
| | | set obj = getjson(str)
|
| | | access_token = obj.get(0).access_token
|
| | | expires_in = obj.get(0).expires_in
|