/build/static/layout/Breadcrumb_cap_w.png

Create local user on domain PC

Hi guys,

I need to create a local user on some domain PCs, so that if anyone forgets their password we can use this an emergency access account when the user is working remotely. The user should be the same on all PCs (let's call it TempIT).

I don't want to use psexec to push the command using Powershell so can someone tell me if this is possible using a K1000 script and what parameters and settings would be selected?

Thanks,

Phil

0 Comments   [ + ] Show comments

Answers (2)

Posted by: akmagnum 6 years ago
Red Belt
3

Use the scripting module in the K1 to deploy a batch script

Replace all capital letters with your info.


@echo off
net user USERNAME PASSWORD /add /comment:"COMMENT" /passwordchg:NO
wmic useraccount where "name='USERNAME'" set passwordexpires=FALSE
net localgroup "GROUP" USERNAME/add
exit

Posted by: PhilAngus 6 years ago
Senior White Belt
0

Brilliant, thanks. I had an initial issue but after I changed the run as to local system it worked fine (it wouldn't work when trying to push the user to a machine who's user was logged in without local admin rights).


Thanks very much

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ