This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Saving admin login + password on the console ?

Hello,

I wonder if there's a way to save the login/password used to install Sophos to remote PCs because I've been typing it HUNDREDS of times (we can't really do batch installations) and I've got many more PC to do !

Thanks.

PJ.

:25845


This thread was automatically locked due to age.
Parents
  • HI,

    I assume you have to use SEC to deploy.  That being said..  It's not in the product, but you could use a tool such as AutoIt to automate this.  Below is some example code that if you save as "SECAutomateDeploy.au3" for example.  Download and install AutoIt (http://www.autoitscript.com/site/autoit-script-editor/downloads/ ) You can build an exe from the code below.  If you run this exe you'll get a AutoIt icon in your notification tray to show it's running and everytime the SEC deployment wizard is run and gets to that credential page it will autofill it in and click next for you.  In theory you could automate the GUI for the entire wizard but this will start you off.  

    Something you may wish to try.  You could probably build a more elegant script but I've just thrown this together as an example.

    Hope it helps.

    Regards,

    Jak

    ;Declare Vars
    dim $strUsername, $strPassword, $strWindowText, $strWindowTitleText
    
    ;Set Vars
    $strUsername        = "domain\user"  ;Default username
    $strWindowTitleText = "Sophos Enterprise Console - Protect Computers Wizard"
    $strWindowText      = "Enter details"
    
    $strUsername = InputBox("SEC Deploy Credentials", "Deploy username:", $strUsername)
    $strPassword = InputBox("SEC Deploy Credentials", "Deploy password:" ,"", "*")
    
    
    While 1 = 1
    ;Check if "Credentials" Window is active
    if WinWaitActive($strWindowTitleText, $strWindowText) Then
    	 	 
    	 sleep (1000)
    	 
    	 ;Set Fields
    	 ControlSetText($strWindowTitleText, $strWindowText ,"[CLASS:Edit; INSTANCE:1]", $strUsername)
             ControlSetText($strWindowTitleText, $strWindowText ,"[CLASS:Edit; INSTANCE:2]", $strPassword)
        
    	 sleep (1000)
    	
    	 ;Click Next
    	 ControlClick($strWindowTitleText, $strWindowText ,"[CLASS:Button; INSTANCE:5]")
    	 
    EndIf
      
    WEnd
    :25861
Reply
  • HI,

    I assume you have to use SEC to deploy.  That being said..  It's not in the product, but you could use a tool such as AutoIt to automate this.  Below is some example code that if you save as "SECAutomateDeploy.au3" for example.  Download and install AutoIt (http://www.autoitscript.com/site/autoit-script-editor/downloads/ ) You can build an exe from the code below.  If you run this exe you'll get a AutoIt icon in your notification tray to show it's running and everytime the SEC deployment wizard is run and gets to that credential page it will autofill it in and click next for you.  In theory you could automate the GUI for the entire wizard but this will start you off.  

    Something you may wish to try.  You could probably build a more elegant script but I've just thrown this together as an example.

    Hope it helps.

    Regards,

    Jak

    ;Declare Vars
    dim $strUsername, $strPassword, $strWindowText, $strWindowTitleText
    
    ;Set Vars
    $strUsername        = "domain\user"  ;Default username
    $strWindowTitleText = "Sophos Enterprise Console - Protect Computers Wizard"
    $strWindowText      = "Enter details"
    
    $strUsername = InputBox("SEC Deploy Credentials", "Deploy username:", $strUsername)
    $strPassword = InputBox("SEC Deploy Credentials", "Deploy password:" ,"", "*")
    
    
    While 1 = 1
    ;Check if "Credentials" Window is active
    if WinWaitActive($strWindowTitleText, $strWindowText) Then
    	 	 
    	 sleep (1000)
    	 
    	 ;Set Fields
    	 ControlSetText($strWindowTitleText, $strWindowText ,"[CLASS:Edit; INSTANCE:1]", $strUsername)
             ControlSetText($strWindowTitleText, $strWindowText ,"[CLASS:Edit; INSTANCE:2]", $strPassword)
        
    	 sleep (1000)
    	
    	 ;Click Next
    	 ControlClick($strWindowTitleText, $strWindowText ,"[CLASS:Button; INSTANCE:5]")
    	 
    EndIf
      
    WEnd
    :25861
Children
No Data