Initial commit
This commit is contained in:
parent
71d28a05c6
commit
074806cf7d
|
@ -0,0 +1,91 @@
|
|||
<html>
|
||||
<head>
|
||||
<title>
|
||||
RAWeb - Remote Applications
|
||||
</title>
|
||||
<style type="text/css">
|
||||
a:link {color:#444444;text-decoration:none;}
|
||||
a:visited {color:#444444;text-decoration:none;}
|
||||
a:hover{color:#000000;text-decoration:underline;}
|
||||
a:active {color:#000000;text-decoration:underline;}
|
||||
#apptile
|
||||
{
|
||||
width:150px;
|
||||
height:135px;
|
||||
text-align:center;
|
||||
vertical-align:bottom;
|
||||
border-style:solid;
|
||||
border-width:0px;
|
||||
float:left;
|
||||
font-size:14px;
|
||||
font-weight:bold;
|
||||
}
|
||||
h1 {
|
||||
font-family:Arial, Helvetica, sans-serif;
|
||||
font-size: 30px;
|
||||
font-style: italic;
|
||||
color:rgb(0,0,0)
|
||||
}
|
||||
body
|
||||
{
|
||||
font-family:Arial,sans-serif;
|
||||
}
|
||||
</style>
|
||||
<link rel="shortcut icon" href="favicon.ico">
|
||||
</head>
|
||||
<body>
|
||||
<div style='text-align:left;'><h1>Remote<font style='color:rgb(100,100,100)'>Apps</font></h1></div><br>
|
||||
<%
|
||||
Whichfolder=server.mappath("rdp\") &"/"
|
||||
Dim fs, f, f1, fc
|
||||
set fs = CreateObject("Scripting.FileSystemObject")
|
||||
set f = fs.GetFolder(Whichfolder)
|
||||
set fc = f.files
|
||||
|
||||
For Each f1 in fc
|
||||
if (LCase(Right(f1.name,4)) = ".rdp") then
|
||||
if not GetRDPvalue(f1,"full address:s:") = "" then
|
||||
appname = GetRDPvalue(f1,"remoteapplicationname:s:")
|
||||
basefilename = Left(f1.name,Len(f1.name) - 4)
|
||||
|
||||
if appname = "" then appname = basefilename
|
||||
|
||||
pngname = basefilename & ".png"
|
||||
set pngfs = CreateObject("Scripting.FileSystemObject")
|
||||
If pngfs.FileExists(server.mappath("png\" & pngname)) Then
|
||||
pngpath = "png/" & pngname
|
||||
Else
|
||||
pngpath = "rdpicon.png"
|
||||
End If
|
||||
Response.write "<div id=apptile>"
|
||||
Response.write "<a href=""" & "rdp/" & f1.name & """><img border=0 height=64 width=64 src=""" & pngpath & """><br>" & appname & "</a>"
|
||||
Response.write "</div>"
|
||||
end if
|
||||
end if
|
||||
Next
|
||||
|
||||
function GetRDPvalue(f1,valuename)
|
||||
Err.Clear
|
||||
on error resume next
|
||||
Dim ts
|
||||
valuenamelen = Len(valuename)
|
||||
set ts = f1.OpenAsTextStream(1,-2)
|
||||
if Err.Number = 0 then
|
||||
Do While Not ts.AtEndOfStream
|
||||
Dim Line
|
||||
Line = ts.readline
|
||||
if (Lcase(Left(Line,valuenamelen)) = valuename) then
|
||||
theName = Right(Line,Len(Line)-valuenamelen)
|
||||
end if
|
||||
Loop
|
||||
theName = Replace(theName,"|","")
|
||||
GetRDPvalue = theName
|
||||
Else
|
||||
GetRDPvalue = ""
|
||||
end if
|
||||
on error goto 0
|
||||
end function
|
||||
|
||||
%>
|
||||
</body>
|
||||
</html>
|
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
After Width: | Height: | Size: 25 KiB |
Binary file not shown.
After Width: | Height: | Size: 1.9 KiB |
Binary file not shown.
After Width: | Height: | Size: 6.9 KiB |
|
@ -0,0 +1,50 @@
|
|||
redirectclipboard:i:1
|
||||
redirectposdevices:i:0
|
||||
redirectprinters:i:1
|
||||
redirectcomports:i:1
|
||||
redirectsmartcards:i:1
|
||||
devicestoredirect:s:*
|
||||
drivestoredirect:s:*
|
||||
redirectdrives:i:1
|
||||
session bpp:i:32
|
||||
prompt for credentials on client:i:1
|
||||
span monitors:i:1
|
||||
use multimon:i:1
|
||||
remoteapplicationmode:i:1
|
||||
server port:i:3389
|
||||
allow font smoothing:i:1
|
||||
promptcredentialonce:i:0
|
||||
authentication level:i:2
|
||||
full address:s:win7testbox
|
||||
remoteapplicationprogram:s:||testapp
|
||||
remoteapplicationname:s:Test Application
|
||||
remoteapplicationcmdline:s:
|
||||
alternate full address:s:win7testbox
|
||||
disableremoteappcapscheck:i:1
|
||||
alternate shell:s:rdpinit.exe
|
||||
screen mode id:i:2
|
||||
winposstr:s:0,3,0,0,800,600
|
||||
compression:i:1
|
||||
keyboardhook:i:2
|
||||
audiocapturemode:i:0
|
||||
videoplaybackmode:i:1
|
||||
connection type:i:2
|
||||
disable wallpaper:i:1
|
||||
allow desktop composition:i:1
|
||||
disable full window drag:i:1
|
||||
disable menu anims:i:1
|
||||
disable themes:i:0
|
||||
disable cursor setting:i:0
|
||||
bitmapcachepersistenable:i:1
|
||||
audiomode:i:0
|
||||
redirectdirectx:i:1
|
||||
autoreconnection enabled:i:1
|
||||
prompt for credentials:i:0
|
||||
negotiate security layer:i:1
|
||||
remoteapplicationicon:s:
|
||||
shell working directory:s:
|
||||
gatewayhostname:s:
|
||||
gatewayusagemethod:i:4
|
||||
gatewaycredentialssource:i:4
|
||||
gatewayprofileusagemethod:i:0
|
||||
use redirection server name:i:0
|
Binary file not shown.
After Width: | Height: | Size: 9.6 KiB |
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration>
|
||||
<system.webServer>
|
||||
<staticContent>
|
||||
<mimeMap fileExtension=".rdp" mimeType="application/rdp" />
|
||||
</staticContent>
|
||||
</system.webServer>
|
||||
</configuration>
|
|
@ -0,0 +1,109 @@
|
|||
<%
|
||||
Set objWSHNetwork = Server.CreateObject("WScript.Network")
|
||||
ServerName = objWSHNetwork.ComputerName
|
||||
|
||||
datetime = Year(now()) & "-" & Right(Cstr(Month(now()) + 100),2) & "-" & Right(Cstr(Day(now()) + 100),2) & "T" & Right(Cstr(Hour(now()) + 100),2) & ":" & Right(Cstr(Minute(now()) + 100),2) & ":" & Right(Cstr(Second(now()) + 100),2) & ".0Z"
|
||||
|
||||
Response.write "<ResourceCollection PubDate=""" & datetime & """ SchemaVersion=""1.1"" xmlns=""http://schemas.microsoft.com/ts/2007/05/tswf"">" & vbCRLF
|
||||
Response.write "<Publisher LastUpdated=""" & datetime & """ Name=""" & ServerName & """ ID=""" & ServerName & """ Description="""">" & vbCRLF
|
||||
Response.write "<Resources>" & vbCRLF
|
||||
|
||||
Whichfolder=server.mappath("rdp\") & "/"
|
||||
Dim fs, f, f1, fc
|
||||
set fs = CreateObject("Scripting.FileSystemObject")
|
||||
set f = fs.GetFolder(Whichfolder)
|
||||
set fc = f.files
|
||||
|
||||
For Each f1 in fc
|
||||
if (LCase(Right(f1.name,4)) = ".rdp") then
|
||||
if not GetRDPvalue(f1,"full address:s:") = "" then
|
||||
basefilename = Left(f1.name,Len(f1.name) - 4)
|
||||
appalias = GetRDPvalue(f1,"remoteapplicationprogram:s:")
|
||||
apptitle = GetRDPvalue(f1,"remoteapplicationname:s:")
|
||||
appicon = basefilename & ".ico"
|
||||
appicon32 = basefilename & ".png"
|
||||
apprdpfile = f1.name
|
||||
appresourceid = appalias
|
||||
appftastring = GetRDPvalue(f1,"remoteapplicationfileextensions:s:")
|
||||
appfulladdress = GetRDPvalue(f1,"full address:s:")
|
||||
rdptype = "RemoteApp"
|
||||
|
||||
if appalias = "" then
|
||||
rdptype = "Desktop"
|
||||
appalias = basefilename
|
||||
apptitle = basefilename
|
||||
appresourceid = basefilename
|
||||
else
|
||||
rdptype = "RemoteApp"
|
||||
end if
|
||||
|
||||
filedatetimeraw = f1.DateLastModified
|
||||
filedatetime = Year(now()) & "-" & Right(Cstr(Month(filedatetimeraw) + 100),2) & "-" & Right(Cstr(Day(filedatetimeraw) + 100),2) & "T" & Right(Cstr(Hour(filedatetimeraw) + 100),2) & ":" & Right(Cstr(Minute(filedatetimeraw) + 100),2) & ":" & Right(Cstr(Second(filedatetimeraw) + 100),2) & ".0Z"
|
||||
|
||||
Response.write "<Resource ID=""" & appresourceid & """ Alias=""" & appalias & """ Title=""" & apptitle & """ LastUpdated=""" & filedatetime & """ Type=""" & rdptype & """>" & vbCRLF
|
||||
Response.write "<Icons>" & vbCRLF
|
||||
Response.write "<IconRaw FileType=""Ico"" FileURL=""" & Root & "icon/" & appicon & """ />" & vbCRLF
|
||||
if fs.FileExists(server.mappath("icon32/" & appicon32)) then Response.write "<Icon32 Dimensions=""32x32"" FileType=""Png"" FileURL=""" & Root & "icon32/" & appicon32 & """ />" & vbCRLF
|
||||
Response.write "</Icons>" & vbCRLF
|
||||
if appftastring <> "" then
|
||||
Response.write "<FileExtensions>" & vbCRLF
|
||||
appftaarray = Split(appftastring,",")
|
||||
for each filetype in appftaarray
|
||||
docicon = basefilename & "." & filetype & ".ico"
|
||||
Response.write "<FileExtension Name=""" & filetype & """ PrimaryHandler=""True"">" & vbCRLF
|
||||
Response.write "<FileAssociationIcons>" & vbCRLF
|
||||
Response.write "<IconRaw FileType=""Ico"" FileURL=""" & Root & "icon/" & docicon & """ />" & vbCRLF
|
||||
Response.write "</FileAssociationIcons>" & vbCRLF
|
||||
Response.write "</FileExtension>" & vbCRLF
|
||||
next
|
||||
Response.write "</FileExtensions>" & vbCRLF
|
||||
Else
|
||||
Response.write "<FileExtensions />" & vbCRLF
|
||||
end if
|
||||
Response.write "<HostingTerminalServers>" & vbCRLF
|
||||
Response.write "<HostingTerminalServer>" & vbCRLF
|
||||
Response.write "<ResourceFile FileExtension="".rdp"" URL=""" & Root & "rdp/" & apprdpfile & """ />" & vbCRLF
|
||||
Response.write "<TerminalServerRef Ref=""" & ServerName & """ />" & vbCRLF
|
||||
Response.write "</HostingTerminalServer>" & vbCRLF
|
||||
Response.write "</HostingTerminalServers>" & vbCRLF
|
||||
Response.write "</Resource>" & vbCRLF
|
||||
end if
|
||||
end if
|
||||
Next
|
||||
|
||||
Response.write "</Resources>" & vbCRLF
|
||||
Response.write "<TerminalServers>" & vbCRLF
|
||||
Response.write "<TerminalServer ID=""" & ServerName & """ Name=""" & ServerName & """ LastUpdated=""" & datetime & """ />" & vbCRLF
|
||||
Response.write "</TerminalServers>" & vbCRLF
|
||||
Response.write "</Publisher>" & vbCRLF
|
||||
Response.write "</ResourceCollection>" & vbCRLF
|
||||
|
||||
function GetRDPvalue(f1,valuename)
|
||||
Err.Clear
|
||||
on error resume next
|
||||
Dim ts
|
||||
valuenamelen = Len(valuename)
|
||||
set ts = f1.OpenAsTextStream(1,-2)
|
||||
if Err.Number = 0 then
|
||||
Do While Not ts.AtEndOfStream
|
||||
Dim Line
|
||||
Line = ts.readline
|
||||
if (Lcase(Left(Line,valuenamelen)) = valuename) then
|
||||
theName = Right(Line,Len(Line)-valuenamelen)
|
||||
end if
|
||||
Loop
|
||||
theName = Replace(theName,"|","")
|
||||
GetRDPvalue = theName
|
||||
Else
|
||||
GetRDPvalue = ""
|
||||
end if
|
||||
on error goto 0
|
||||
end function
|
||||
|
||||
Function Root()
|
||||
DocPath = Request.ServerVariables("PATH_INFO")
|
||||
aPath = Split("/" & DocPath, "/")
|
||||
Root = Left(DocPath,Len(DocPath)-Len(aPath(UBound(aPath))))
|
||||
End Function
|
||||
|
||||
%>
|
Loading…
Reference in New Issue