Author: jfthomps
Date: Thu Jul 20 18:01:44 2017
New Revision: 1802521

URL: http://svn.apache.org/viewvc?rev=1802521&view=rev
Log:
VCL-1062 - stop using Administrator account for Windows imaging reservations

requests.php: modified AJconnectRequest: removed check for imaging reservation 
and OStype being windows to set user to Administrator

utils.php: modified sendRDPfile: removed check for imaging reservation and 
OStype being windows to set user to Administrator

xmlrpcWrappers.php: modified XMLRPCgetRequestConnectData: removed check for 
imaging reservation and OStype being windows to set user to Administrator

Modified:
    vcl/trunk/web/.ht-inc/requests.php
    vcl/trunk/web/.ht-inc/utils.php
    vcl/trunk/web/.ht-inc/xmlrpcWrappers.php

Modified: vcl/trunk/web/.ht-inc/requests.php
URL: 
http://svn.apache.org/viewvc/vcl/trunk/web/.ht-inc/requests.php?rev=1802521&r1=1802520&r2=1802521&view=diff
==============================================================================
--- vcl/trunk/web/.ht-inc/requests.php (original)
+++ vcl/trunk/web/.ht-inc/requests.php Thu Jul 20 18:01:44 2017
@@ -4328,9 +4328,7 @@ function AJconnectRequest() {
                                $first = 0;
                        else
                                $h .= "<hr>\n";
-                       if($requestData['forimaging'] && $res['OStype'] == 
'windows')
-                               $conuser = 'Administrator';
-                       elseif(preg_match('/(.*)@(.*)/', $user['unityid'], 
$matches))
+                       if(preg_match('/(.*)@(.*)/', $user['unityid'], 
$matches))
                                $conuser = $matches[1];
                        else
                                $conuser = $user['unityid'];

Modified: vcl/trunk/web/.ht-inc/utils.php
URL: 
http://svn.apache.org/viewvc/vcl/trunk/web/.ht-inc/utils.php?rev=1802521&r1=1802520&r2=1802521&view=diff
==============================================================================
--- vcl/trunk/web/.ht-inc/utils.php (original)
+++ vcl/trunk/web/.ht-inc/utils.php Thu Jul 20 18:01:44 2017
@@ -10549,17 +10549,13 @@ function sendRDPfile() {
        print "redirectsmartcards:i:1\r\n";
        print "displayconnectionbar:i:1\r\n";
        print "autoreconnection enabled:i:1\r\n";
-       if($request["forimaging"] && $res['OStype'] == 'windows')
-               print "username:s:Administrator\r\n";
-       else {
-               if(preg_match('/(.*)@(.*)/', $user['unityid'], $matches))
-                       $userid =  $matches[1];
-               else
-                       $userid = $user["unityid"];
-               if($request['reservations'][0]['domainDNSName'] != '' && ! 
strlen($passwd))
-                       $userid .= "@" . 
$request['reservations'][0]['domainDNSName'];
-               print "username:s:$userid\r\n";
-       }
+       if(preg_match('/(.*)@(.*)/', $user['unityid'], $matches))
+               $userid =  $matches[1];
+       else
+               $userid = $user["unityid"];
+       if($request['reservations'][0]['domainDNSName'] != '' && ! 
strlen($passwd))
+               $userid .= "@" . $request['reservations'][0]['domainDNSName'];
+       print "username:s:$userid\r\n";
        print "clear password:s:$passwd\r\n";
        print "domain:s:\r\n";
        print "alternate shell:s:\r\n";

Modified: vcl/trunk/web/.ht-inc/xmlrpcWrappers.php
URL: 
http://svn.apache.org/viewvc/vcl/trunk/web/.ht-inc/xmlrpcWrappers.php?rev=1802521&r1=1802520&r2=1802521&view=diff
==============================================================================
--- vcl/trunk/web/.ht-inc/xmlrpcWrappers.php (original)
+++ vcl/trunk/web/.ht-inc/xmlrpcWrappers.php Thu Jul 20 18:01:44 2017
@@ -833,13 +833,10 @@ function XMLRPCgetRequestConnectData($re
                $connectMethods = getImageConnectMethodTexts(
                                     $requestData["reservations"][0]["imageid"],
                                     
$requestData["reservations"][0]["imagerevisionid"]);
-               if($requestData["forimaging"] && 
$requestData['reservations'][0]['OStype'] == 'windows')
-                       $thisuser = 'Administrator';
+               if(preg_match('/(.*)@(.*)/', $user['unityid'], $matches))
+                       $thisuser = $matches[1];
                else
-                       if(preg_match('/(.*)@(.*)/', $user['unityid'], 
$matches))
-                               $thisuser = $matches[1];
-                       else
-                               $thisuser = $user['unityid'];
+                       $thisuser = $user['unityid'];
                $natports = 
getNATports($requestData['reservations'][0]['reservationid']);
                $portdata = array();
                foreach($connectMethods as $key => $cm) {


Reply via email to