Using Powershell to autostart a program, in minimised mode and autologin

Hello,
Are there any Powershell experts out there?
I would like to create a Powershell script do to the three functions below. Please provide clear steps for doing this as I am a novice with Powershell

1. Start a program when Windows starts
2. The powershell script must start the programs by autologon using the programs stored usernames and passwords in the Powershell script (see attached files)
3. The programs must be started in minimised mode (in the taskbar)

My reason for doing this
* I don't want the programs to start in full mode or be launched manually for people to see the usernames or click SHOW to see the password. I also do not want to give out the usernames/passwords for these programs.

Both programs have the option of saving the passwords but after a few Windows reboots, the passwords are no longer remembered and require manual entry. I want to avoid this by not using the save passwords option but using Powershell instead.

If you're aware of any other scripting language that can do this, please let me know but I ask that you're clear with your instructions. I have ZERO knowledge of scripting.
steam.PNG
Origin.PNG
DonKwizoteAsked:
Who is Participating?
 
AlanConnect With a Mentor ConsultantCommented:
Hi Don,

Whilst this might be possible, I am not sure it makes sense.

There is already functionality built-in via Group Policy to run applications at login, and if required, they can run in the 'Local System' context, so would have a high level of privileges.

To do that, you would configure:

Computer Configuration
Policies
Administrative Templates
System
Logon
Run These Programs at User Logon

If you enable that policy, you can specific any exe on the domain workstation (I usually put in the full path).


Have you looked at that option?  If so, and you rejected it in favour of the PowerShell method you are asking for, please can you explain why, and perhaps we can find a way to make it work for you without risking compromise of credentials.

Thanks,

Alan.
1
 
DonKwizoteAuthor Commented:
Thanks Alan! I was not aware of that option. I'll test it in a few minutes and let you know the result
0
 
DonKwizoteAuthor Commented:
Hi Alan,
The programs require their own separate usernames/passwords to actually login. The accounts to login are not Windows accounts. I need a way to specify the usernames and passwords for the programs to login.
0
Creating Active Directory Users from a Text File

If your organization has a need to mass-create AD user accounts, watch this video to see how its done without the need for scripting or other unnecessary complexities.

 
AlanConsultantCommented:
Hi Don,

Depending on other GPOs, you might need to enable 'loopback processing' on the GPO you create for this.

Try it without, and if it doesn't work, try enabling that option.

Alan.
0
 
AlanConsultantCommented:
Hi Don,

The programs require their own separate usernames/passwords to actually login. The accounts to login are not Windows accounts. I need a way to specify the usernames and passwords for the programs to login.

The Group Policy option won't work for that, except perhaps to kick off a script.

I don't know that I am up to the PowerShell approach - I'll have a think, but no promises!


Alan.
0
 
DonKwizoteAuthor Commented:
Hi All,
Thanks for your input. Apologies for the delay. I have been trying lots of ideas. I tried several password managers like Keepass, One Password, Lastpass, Sticky Password but none could store and input the password into the application. In the end, I have published the password but restricted what users can do. That seems to be working for now.
0
 
AlanConsultantCommented:
Hi DonKwizote,

I guess if those credentials can't do anything other than the minimum required to get it to work, then the risk is probably quite low, so should be fine.  You might want to contact the software vendor, and ask how other businesses have set this up - maybe you could replicate one of their solutions?

However, if you are okay now, please can you close the question.

Thanks,

Alan.
0
 
AlanConsultantCommented:
Hi DonKwizote,

How are you gong on this?  Is there anything else we can help with?

If all done, please can you close the question.

Thanks,

Alan.
0
 
PberSolutions ArchitectCommented:
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.

I have recommended this question be closed as follows:

Accept: Alan (https:#a42346930)

If you feel this question should be closed differently, post an objection and the moderators will review all objections and close it as they feel fit. If no one objects, this question will be closed automatically the way described above.

Pber
Experts-Exchange Cleanup Volunteer
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.