Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

431 lines
14 KiB

  1. <!--#INCLUDE file="..\include\asp\top.asp"-->
  2. <!--#INCLUDE file="..\include\inc\browserTest.inc"-->
  3. <!--#include file="..\include\asp\head.asp"-->
  4. <!--#include file="..\include\inc\autostrings.inc"-->
  5. <%
  6. Response.CharSet=strCharSet
  7. on error resume next
  8. '932 1252
  9. Select Case Request.QueryString("LCID")
  10. ' ***********************************************
  11. ' All German languages will go to the German site
  12. ' ***********************************************
  13. ' German(Standard) redirection
  14. ' Case 1031: Response.Redirect "https://oca.microsoft.de/secure/auto.asp?ID=" & Request.QueryString("ID")
  15. ' German(Swiss) redirection
  16. ' Case 2055: Response.Redirect "https://oca.microsoft.de/secure/auto.asp?ID=" & Request.QueryString("ID")
  17. ' German(Austrian) redirection
  18. ' Case 3079: Response.Redirect "https://oca.microsoft.de/secure/auto.asp?ID=" & Request.QueryString("ID")
  19. ' German(Luxembourg) redirection
  20. ' Case 4103: Response.Redirect "https://oca.microsoft.de/secure/auto.asp?ID=" & Request.QueryString("ID")
  21. ' German(Liechtenstein) redirection
  22. ' Case 5127: Response.Redirect "https://oca.microsoft.de/secure/auto.asp?ID=" & Request.QueryString("ID")
  23. ' ***********************************************
  24. ' All French languages will go to the French site
  25. ' ***********************************************
  26. ' French(Standard) redirection
  27. ' Case 1036: Response.Redirect "https://oca.microsoft.fr/secure/auto.asp?ID=" & Request.QueryString("ID")
  28. ' French(Belgian) redirection
  29. ' Case 2060: Response.Redirect "https://oca.microsoft.fr/secure/auto.asp?ID=" & Request.QueryString("ID")
  30. ' French(Canadian) redirection
  31. ' Case 3084: Response.Redirect "https://oca.microsoft.fr/secure/auto.asp?ID=" & Request.QueryString("ID")
  32. ' French(Swiss) redirection
  33. ' Case 4108: Response.Redirect "https://oca.microsoft.fr/secure/auto.asp?ID=" & Request.QueryString("ID")
  34. ' French(Luxembourg) redirection
  35. ' Case 5132: Response.Redirect "https://oca.microsoft.fr/secure/auto.asp?ID=" & Request.QueryString("ID")
  36. ' ***********************************************
  37. ' Japanese will go to the Japanese site
  38. ' ***********************************************
  39. ' Japanese redirection
  40. Case 1041: Response.Redirect "https://ocatestjpn/secure/auto.asp?ID=" & Request.QueryString("ID")
  41. ' ***********************************************
  42. ' All other languages go to the English site
  43. ' ***********************************************
  44. End Select
  45. %>
  46. <%
  47. dim rsHash
  48. Dim cnAuto
  49. Dim rsAuto
  50. Dim cmAuto
  51. Dim cmDriver
  52. dim cmHash
  53. dim cmSetHash
  54. dim x
  55. Dim strXML
  56. dim bolResults
  57. dim strSrc
  58. dim strDest
  59. Dim oXML
  60. Dim oNodeList
  61. Dim strFileName
  62. Dim strFileSize
  63. Dim strCreationDate
  64. Dim strVersion
  65. Dim strManufacturer
  66. Dim iIncident
  67. dim strOSName
  68. dim strOSVersion
  69. dim strOSLanguage
  70. dim strComputerName
  71. dim strDriver2
  72. dim iLength
  73. dim strHash
  74. dim bolHashExists
  75. Dim strTemp
  76. Dim strNewSrc
  77. Dim SourceID
  78. Dim strFrom
  79. Dim strProductName
  80. Dim oFileObj
  81. Dim obolFileExists
  82. Dim bol64Bit
  83. Dim strAnon
  84. Dim strPreviousPage
  85. Call CCreateObjects
  86. Call CCreateConnection
  87. strPreviousPage = Request.ServerVariables("SCRIPT_NAME")
  88. strPreviousPage = Right(strPreviousPage, len(strPreviousPage) - Instrrev(strPreviousPage, "/"))
  89. Response.Cookies("Misc")("PreviousPage") = strPreviousPage
  90. strAnon = Request.QueryString("user")
  91. if strAnon = "anon" then
  92. Response.Write "<br><div class='divLoad'><p class='clsPTitle'>"
  93. Response.Write L_RECEIVED_SUCCESS_PARTONE2_TEXT & "</p>"
  94. Response.Write "<p class='clsPBody'>" & L_RECEIVED_THANK_YOUTWO_TEXT & "</p>"
  95. Response.Write "<P class='clsPBody'><img Alt=" & L_WELCOME_GO_IMAGEALT_TEXT & " border='0' src='../include/images/go.gif' WIDTH='24' HEIGHT='24'><a class='clsALink' href='http://" & Request.ServerVariables("SERVER_NAME") & "/welcome.asp'>" & L_RECEIVED_NEWFILE_LINK_TEXT & "</a></p>"
  96. Response.Write "</div>"
  97. %>
  98. <!--#include file="..\include\asp\foot.asp"-->
  99. <%
  100. call CDestroyObjects
  101. Response.End
  102. end if
  103. SourceID = Request.QueryString("id")
  104. if SourceID = "" then
  105. Response.Redirect("http://" & Request.ServerVariables("SERVER_NAME") & "/welcome.asp")
  106. Response.End
  107. End If
  108. strDest = strOCAIISBox & Right(strSrc, len(strSrc) - Instrrev(strSrc, "\"))
  109. Call CMoveFile
  110. Call CVerifyHash
  111. if bolHashExists = true then
  112. oFileObj.DeleteFile CStr(strDest), true
  113. else
  114. Call CGetIncident
  115. strFrom = strDest
  116. strSrc = strFileMoverBox & iIncident & ".cab"
  117. strNewSrc = strFileMoverBox & "U_" & Hex(iIncident) & ".cab"
  118. strFileName = oCracker.GetDumpName(cstr(strFrom))
  119. oFileObj.CopyFile CStr(strFrom), CStr(strNewSrc), false
  120. oFileObj.DeleteFile CStr(strFrom), true
  121. end if 'hash exist
  122. Response.Cookies("Misc")("txtIncidentID") = iIncident
  123. Response.Cookies("ocaFileName") = strFileName
  124. Response.Cookies("strHash") = strHash
  125. if strOSVersion = "" then strOSVersion = 0
  126. Response.Cookies("selSystem") = strOSVersion
  127. Response.Cookies("Misc")("Auto") = "True"
  128. if len(strOSVersion) < 1 then strOSVersion = 0
  129. '_____________________________________________________________________________________________________________________
  130. 'Sub Procedures
  131. Private Sub CGetIncident
  132. on error resume next
  133. 'Prepare ADO recordset object
  134. With rsAuto
  135. .ActiveConnection = cnAuto
  136. .CursorLocation = adUseClient
  137. .CursorType = adOpenStatic
  138. .LockType = adLockOptimistic
  139. end with
  140. 'Get a new incident ID from the database
  141. set rsAuto = cnAuto.Execute("GetIncident NULL, NULL")
  142. if cnAuto.Errors.Count > 0 then
  143. Response.Write "<br><div class='divLoad'><p class='clsPTitle'>" & L_COMMENTS_UNABLE_TOCONNECT_ERRORMESSAGE & "</p>"
  144. Response.Write "<p class='clsPBody'>" & L_COMMENTS_DATABASE_FAILED_TEXT & "</p></div>"
  145. if Request.ServerVariables("SERVER_NAME") = "ocadeviis" then
  146. Response.Write "<span style='visibility:hidden' name=pError2 id=pError2>" & cnAuto.Errors(0).Description & "</span>"
  147. end if
  148. cnAuto.Errors.Clear
  149. %>
  150. <!--#include file="..\include\asp\foot.asp"-->
  151. <%
  152. call CDestroyObjects
  153. Response.End
  154. end if
  155. 'if nothing was returned to the database then problem
  156. if rsAuto.State = adStateOpen then
  157. set rsAuto.ActiveConnection = Nothing
  158. if rsAuto.RecordCount < 1 then
  159. Response.Write "<br><div class='divLoad'><P class='clsPTitle'>" & L_AUTO_UNABLETO_PROCESS_TEXT & "</P><P class='clsPBody'>"
  160. Response.write L_AUTO_UNABLETOPROCESS_COMMENT_TEXT & "</p><br><a class='clsALink' href='auto.asp?ID=" & SourceID & "'>" & L_AUTO_RESUBMIT_FILE_TEXT & "</a></div>"
  161. call CDestroyObjects
  162. %>
  163. <!--#include file="..\include\asp\foot.asp"-->
  164. <%
  165. Response.End
  166. end if
  167. else
  168. Response.Write "<br><div class='divLoad'><P class='clsPTitle'>" & L_AUTO_UNABLETO_PROCESS_TEXT & "</P><P class='clsPBody'>"
  169. Response.write L_AUTO_UNABLETOPROCESS_COMMENT_TEXT & "</p><br><a class='clsALink' href='auto.asp?ID=" & SourceID & "'>" & L_AUTO_RESUBMIT_FILE_TEXT & "</a></div>"
  170. call CDestroyObjects
  171. %>
  172. <!--#include file="..\include\asp\foot.asp"-->
  173. <%
  174. Response.End
  175. end if
  176. iIncident = rsAuto.Fields(0).Value
  177. End Sub
  178. Private Sub CVerifyHash
  179. on error resume next
  180. strHash = oCracker.GetHash(cstr(strDest))
  181. with cmHash
  182. .ActiveConnection = cnAuto
  183. .CommandText = "GetHash"
  184. .CommandType = adCmdStoredProc
  185. .CommandTimeout = strGlobalCommandTimeout
  186. .Parameters.Append .CreateParameter("@DumpHash", advarchar, adParamInput, 33, cstr(strHash))
  187. set rsHash = .Execute
  188. end with
  189. if bolResults <> 0 then
  190. Response.Write "<br><div class='divLoad'><P class='clsPTitle'>" & L_AUTO_UNABLETO_PROCESS_TEXT & "</P><P class='clsPBody'>"
  191. Response.write L_AUTO_UNABLETOPROCESS_COMMENT_TEXT & "</p><br><a class='clsALink' href='auto.asp?ID=" & SourceID & "'>" & L_AUTO_RESUBMIT_FILE_TEXT & "</a></div>"
  192. if Request.ServerVariables("SERVER_NAME") = "ocadeviis" then
  193. Response.Write "<span style='visibility:hidden' name=pError3 id=pError3>" & cnAuto.Errors(0).Description & "</span>"
  194. end if
  195. %>
  196. <!--#include file="..\include\asp\foot.asp"-->
  197. <%
  198. call CDestroyObjects
  199. Response.End
  200. end if
  201. bolHashExists = false
  202. if rsHash.State = adStateOpen then
  203. if rsHash.RecordCount > 0 then
  204. bolHashExists = true
  205. end if
  206. else
  207. bolHashExists = false
  208. end if
  209. if instr(1, strDest, "validate") > 0 then
  210. bolHashExists = false
  211. end if
  212. End Sub
  213. Private Sub CMoveFile
  214. on error resume next
  215. obolFileExists = oFileObj.FileExists(strSrc)
  216. oFileObj.CopyFile strSrc, strDest, true
  217. if obolFileExists = false then
  218. Response.Write "<br><div class='divLoad'><P class='clsPTitle'>" & L_AUTO_UNABLETO_PROCESS_TEXT & "</P><P class='clsPBody'>"
  219. Response.write L_AUTO_UNABLETOPROCESS_COMMENT_TEXT & "</p><br><a class='clsALink' href='auto.asp?ID=" & SourceID & "'>" & L_AUTO_RESUBMIT_FILE_TEXT & "</a></div>"
  220. if Request.ServerVariables("SERVER_NAME") = "ocadeviis" then
  221. Response.Write "<span style='visibility:hidden' name=pError4 id=pError4>File Object</span>"
  222. end if
  223. %>
  224. <!--#include file="..\include\asp\foot.asp"-->
  225. <%
  226. call CDestroyObjects
  227. Response.End
  228. end if
  229. End Sub
  230. Private Sub CCreateObjects
  231. on error resume next
  232. Set oFileObj = CreateObject("Scripting.FileSystemObject")
  233. set cnAuto = CreateObject("ADODB.Connection")
  234. set rsHash = createObject("ADODB.Recordset")
  235. set rsAuto = CreateObject("ADODB.Recordset")
  236. set cmHash = createObject("ADODB.Command")
  237. set cmAuto = CreateObject("ADODB.Command")
  238. set cmDriver = CreateObject("ADODB.Command")
  239. set cmSetHash = CreateObject("ADODB.Command")
  240. set oXML = CreateObject("msxml.DomDocument")
  241. bol64Bit = false
  242. obolFileExists = true
  243. strSrc = strFileOfficeWatson & Request.QueryString("id")
  244. End Sub
  245. Private Sub CDestroyObjects
  246. on error resume next
  247. set oFileObj = nothing
  248. set oNodeList = nothing
  249. set oCracker = nothing
  250. set oXML = nothing
  251. set cmAuto = nothing
  252. set cmDriver = nothing
  253. set cmHash = nothing
  254. set cmSetHash = nothing
  255. if rsHash.State = adStateOpen then rsHash.Close
  256. set rsHash = nothing
  257. if rsAuto.State = adStateOpen then rsAuto.Close
  258. set rsAuto = nothing
  259. if cnAuto.State = adStateOpen then cnAuto.Close
  260. set cnAuto = nothing
  261. End Sub
  262. Private Sub CCreateConnection
  263. on error resume next
  264. with cnAuto
  265. .ConnectionString = strCustomer
  266. .CursorLocation = adUseClient
  267. .ConnectionTimeout = strGlobalConnectionTimeout
  268. .Open
  269. end with
  270. if cnAuto.State = adStateClosed then
  271. Response.Write "<br><div class='divLoad'><p class='clsPTitle'>" & L_COMMENTS_UNABLE_TOCONNECT_ERRORMESSAGE & "</p>"
  272. Response.Write "<p class='clsPBody'>" & L_COMMENTS_DATABASE_FAILED_TEXT & "</p></div>"
  273. if Request.ServerVariables("SERVER_NAME") = "ocadeviis" then
  274. Response.Write "<span style='visibility:hidden' name=pError5 id=pError5>" & cnAuto.Errors(0).Description & "</span>"
  275. end if
  276. cnAuto.Errors.Clear
  277. %>
  278. <!--#include file="..\include\asp\foot.asp"-->
  279. <%
  280. call CDestroyObjects
  281. Response.End
  282. end if
  283. End Sub
  284. '_____________________________________________________________________________________________________________________
  285. %>
  286. <div class="clsDiv">
  287. <%
  288. if bolHashExists = true then
  289. %>
  290. <P class="clsPTitle">
  291. <% = L_AUTO_ALREADYHAVE_FILE_TEXT %>
  292. </P>
  293. <p class="clsPBody">
  294. <% = L_AUTO_ALREADYHAVE_FILEBODY_TEXT %>
  295. </p>
  296. <p class="clsPBody">
  297. <% = L_AUTO_ALREADYHAVE_NOCUSTOMERINFO_TEXT %>
  298. </p>
  299. <%
  300. else
  301. %>
  302. <P class="clsPTitle">
  303. <% = L_AUTO_UPLOAD_COMPLETE_TEXT %>
  304. </P>
  305. <%
  306. if bol64Bit = 1 then
  307. %>
  308. <p class="clsPBody">
  309. <% = L_AUTO_64BIT_DUMP_TEXT %>
  310. </p>
  311. <%
  312. else
  313. %>
  314. <p class="clsPBody">
  315. <% = L_AUTO_THANK_YOU_TEXT %>
  316. </p>
  317. <%
  318. end if
  319. %>
  320. <br>
  321. <div>
  322. <Table class="clstblLinks">
  323. <thead>
  324. <tr>
  325. <td>
  326. </td>
  327. <td>
  328. </td>
  329. </tr>
  330. </thead>
  331. <tbody>
  332. <tr>
  333. <td nowrap class="clsTDLinks">
  334. <A class="clsALink" href="https://<% =Request.ServerVariables("SERVER_NAME") %>/secure/auto.asp?user=anon">
  335. <img Alt="<% = L_WELCOME_GO_IMAGEALT_TEXT %>" border="0" src="../include/images/go.gif" WIDTH="24" HEIGHT="24">
  336. <%=L_AUTO_CLOSE_WELCOME_TEXT%></a>
  337. </td>
  338. </tr>
  339. <tr>
  340. <td nowrap class="clsTDLinks">
  341. <A class="clsALink" tabindex=0 href="https://<% =Request.ServerVariables("SERVER_NAME") %>/secure/customer.asp">
  342. <img Alt="<% = L_WELCOME_GO_IMAGEALT_TEXT %>" border="0" src="../include/images/go.gif" WIDTH="24" HEIGHT="24">
  343. <% =L_CUSTOMER_NEXT_LINK_TEXT %></a>
  344. </td>
  345. </tr>
  346. </tbody>
  347. </table>
  348. </div>
  349. <br>
  350. <%
  351. end if
  352. %>
  353. <NOSCRIPT>
  354. <p class="clsPWarning">
  355. <% = L_WELCOME_SCRIPT_TITLE_TEXT %>
  356. </p>
  357. <p class="clsPBody">
  358. <% = L_WELCOME_SCRIPT_BODY_TEXT %>
  359. </p>
  360. </NOSCRIPT>
  361. </div>
  362. <div id="divHiddenFields" name="divHiddenFields">
  363. <Input name="txtIncidentID" id="txtIncidentID" type="hidden" value="<%=iIncident%>">
  364. </div>
  365. <%
  366. Call CDestroyObjects
  367. %>
  368. <SCRIPT LANGUAGE=javascript>
  369. <!--
  370. document.body.onload = BodyLoad;
  371. function submitlink_onclick()
  372. {
  373. window.navigate("submit.asp");
  374. return;
  375. }
  376. function BodyLoad()
  377. {
  378. //var iHeight = window.screen.availHeight;
  379. //var iWidth = window.screen.availWidth;
  380. //iWidth = iWidth / 2;
  381. //iHeight = iHeight / 3.8;
  382. //var iTop = (window.screen.width / 2) - (iWidth / 2);
  383. //var iLeft = (window.screen.height / 2) - (iHeight / 2);
  384. //iResults = window.open("secondlevel.asp", "", "top=" + iTop + ",left=" + iLeft + ",height=" + iHeight + ",width=" + iWidth + ",status=yes,toolbar=no,menubar=no");
  385. }
  386. //-->
  387. </SCRIPT>
  388. <!--#include file="..\include\asp\foot.asp"-->