locked
XML files RRS feed

  • Question

  • I created a batch file for SCT that would allow me to lock and unlock the profile by applying an xml file using restrict.wsf.  If this not available in SteadyState.  This was a quick way to lock and unlock the profile without having to actually start SCT.  Here are my batch files for reference...

     

    LOCK.BAT

    cd\
    cd\program files\microsoft shared computer toolkit\scripts
    call cmdon.bat
    restrict.wsf /user:all /xml:..\xml\locked.xml /apply
    net localgroup administrators /delete all
    call cmdoff.bat

     

    UNLOCK.BAT

    cd\
    cd\program files\microsoft shared computer toolkit\scripts
    call cmdon.bat
    restrict.wsf /user:all /xml:..\xml\unlocked.xml /apply
    cd\program files\microsoft shared computer toolkit\bin
    net localgroup administrators /add all

     

    I would like to recreate these batch files for SteadyState.  Although SteadyState is a lot more user friendly than SCT was, these batch files were quick and easy to use.

    Wednesday, June 20, 2007 4:58 PM

Answers

  • Hi,

     

    You may be able to get similar functionality in SteadyState by using the /import and /export commandline arguments for sctui.exe.  You could create an unrestricted profile named Unlocked, then export that as Unlocked.ssu.  Once it's exported, you could delete the Unlocked user.  Similarly, you'd want to export the restricted user's profile to RestrictedUser.ssu.  Now you just replace calls to restrict.wsf with calls to sctui.exe and import the desired SSU file for the user that you want to lock or unlock. 

     

    To unlock the user:

    sctui.exe /import UserName Password123 "C:\Documents and Settings\Administrator\My Documents\Unlocked.ssu"

     

    And to lock the user again:

    sctui.exe /import UserName Password123 "C:\Documents and Settings\Administrator\My Documents\RestrictedUser.ssu"

     

     

     

    Here is the help for /import and /export (available via "sctui.exe /?"):

     

    IMPORT
            [username] [password] [Location to export to]

    Example:
            sctui.exe /Import Guest Password123 c:\guest.ssu.

     

    EXPORT
            [username] [Location to export to]
           

  • [Folder to export to]

    Using the * wilcard, all user profiles will be exported to the specified folder.

    Examples:
            sctui.exe /Export Guest c:\guest.ssu
            sctui.exe /Export * c:\Users

Wednesday, June 20, 2007 9:04 PM
  • Hi,

     

    You can use the following command to import the public profile ( assume the public.ssu is stored at c:\ ) :

     

    Sctui.exe /import public “” c:\public.ssu.

    ----------

     

    Sincerely,

    Sammy Yu

    Friday, June 29, 2007 9:51 AM
  • All replies

    • Hi,

       

      You may be able to get similar functionality in SteadyState by using the /import and /export commandline arguments for sctui.exe.  You could create an unrestricted profile named Unlocked, then export that as Unlocked.ssu.  Once it's exported, you could delete the Unlocked user.  Similarly, you'd want to export the restricted user's profile to RestrictedUser.ssu.  Now you just replace calls to restrict.wsf with calls to sctui.exe and import the desired SSU file for the user that you want to lock or unlock. 

       

      To unlock the user:

      sctui.exe /import UserName Password123 "C:\Documents and Settings\Administrator\My Documents\Unlocked.ssu"

       

      And to lock the user again:

      sctui.exe /import UserName Password123 "C:\Documents and Settings\Administrator\My Documents\RestrictedUser.ssu"

       

       

       

      Here is the help for /import and /export (available via "sctui.exe /?"):

       

      IMPORT
              [username] [password] [Location to export to]

      Example:
              sctui.exe /Import Guest Password123 c:\guest.ssu.

       

      EXPORT
              [username] [Location to export to]
             

    • [Folder to export to]

      Using the * wilcard, all user profiles will be exported to the specified folder.

      Examples:
              sctui.exe /Export Guest c:\guest.ssu
              sctui.exe /Export * c:\Users

    Wednesday, June 20, 2007 9:04 PM
  • Is there a way to use /Import  without a password or a blank password?

    We don't password the public profile for ease of use for the patron.

    Friday, June 22, 2007 7:05 PM
  • Hi,

     

    You can use the following command to import the public profile ( assume the public.ssu is stored at c:\ ) :

     

    Sctui.exe /import public “” c:\public.ssu.

    ----------

     

    Sincerely,

    Sammy Yu

    Friday, June 29, 2007 9:51 AM
  • Is there any other command line options to let this run silently?  ie - no requirement to hit enter to continue ?

    Monday, August 27, 2007 8:59 PM
  • Hi Darcy,

     

    As Sctui.exe only has two parameters: import & export, we have to press Enter when its task is complete.

     

    Best Regards,

    Tuesday, August 28, 2007 7:19 AM
  • Can this be added to the list of features for the next version?

     

    Darcy

    Wednesday, August 29, 2007 10:01 PM
  • Hi Darcy,

     

    The feature request has been sent to our product team for further consideration. Thank you for bring  this to our attention.

     

    Regards,

    Thursday, August 30, 2007 2:49 AM