Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Run] Add option to "Run as different user" #1605

Closed
htcfreek opened this issue Mar 17, 2020 · 13 comments
Closed

[Run] Add option to "Run as different user" #1605

htcfreek opened this issue Mar 17, 2020 · 13 comments
Assignees
Labels
Idea-Enhancement New feature or request on an existing product Product-PowerToys Run Improved app launch PT Run (Win+R) Window Resolution-Fix Committed Fix is checked in, but it might be 3-4 weeks until a release.
Milestone

Comments

@htcfreek
Copy link
Collaborator

htcfreek commented Mar 17, 2020

In the specification for power launcher I have seen an entry about adding "Run as admin" to the menu.
Will there also bee a menu item to run an app as "different user"?

Why do I ask this:
In our company we can't use the UAC. It is disabled and does not work.
Wen have to run apps as different user to change into Admin kontext.

Idea from @Borkason

Added 03/11/2021

Have a second "run as different user" button where we can define the user in PT Run settings. (#1605 (comment))

@jyuwono
Copy link
Contributor

jyuwono commented Mar 17, 2020

For v1, the team is focusing on implementing "run as admin" but "run as a different user" is a good suggestion! We can investigate and possibly add it in future versions.

@jyuwono jyuwono added Idea-Enhancement New feature or request on an existing product Product-PowerToys Run Improved app launch PT Run (Win+R) Window labels Mar 17, 2020
@jyuwono jyuwono added this to the Backlog milestone Mar 17, 2020
@crutkas
Copy link
Member

crutkas commented Jun 4, 2020

good idea, start menu can do this.
image

@crutkas crutkas added the Help Wanted We encourage anyone to jump in on these and submit a PR. label Jun 4, 2020
@danielniccoli
Copy link

As shown with screenshots in #4038 the start menu can't do it in a lot of cases. Of which all of them are used daily by IT professionals. There is a GPO to enable it, but that mostly doesn't work either.

@crutkas crutkas modified the milestones: Backlog, Help Wanted Sep 14, 2020
@enricogior enricogior changed the title [Question; Power Launcher] "Runs as different user"-Option [Run] Add option to "Run as different user" Jan 9, 2021
@danielniccoli
Copy link

There should be a setting to show or hide the Run as different user in the PT Run dialogs. And it should be disabled by default. I believe most people wouldn't need that option and this keeps the forms nice and clean for the majority of PowerToys users.

In addition to that, it would be great if we could have an option to add a second "run as different user" button to the form, that has a username preconfigured, so that I only need to enter the password of the preconfigured username. It would be important that only the username is stored, and the password must be entered every time. The use-case is that I have (as many admins do) a second Active Directory account that I use for many administrative tasks and it would be a great help if I would not have to enter the username every time I need to run an application as that user.

image

@htcfreek
Copy link
Collaborator Author

htcfreek commented Mar 11, 2021

In addition to that, it would be great if we could have an option to add a second "run as different user" button to the form, that has a username preconfigured, so that I only need to enter the password of the preconfigured username. It would be important that only the username is stored, and the password must be entered every time. The use-case is that I have (as many admins do) a second Active Directory account that I use for many administrative tasks and it would be a great help if I would not have to enter the username every time I need to run an application as that user.

Love this great idea. Can completely agree. I had the same use case for this feature.

@sourbrambles
Copy link

+1 this would be invaluable for my work processes.

@htcfreek
Copy link
Collaborator Author

htcfreek commented Mar 26, 2022

@crutkas
This is an easy thing. Plan this for next release (0.58).

To trigger the other user behavior we have to create the Process.StartInfo object with a different verb: runAsUser (Run as admin command uses runAs as verb.)

I think this makes sense for Program plugin, Shell plugin and Search plugin.

@htcfreek htcfreek added Status-In progress This issue or work-item is under development and removed Help Wanted We encourage anyone to jump in on these and submit a PR. labels Mar 26, 2022
@htcfreek htcfreek self-assigned this Mar 26, 2022
@htcfreek
Copy link
Collaborator Author

htcfreek commented Mar 26, 2022

@crutkas
I don't think we should implement a setting for a button with predefined credentials. This might be a security risk.

The actual implantation (see my PR) show the Run as different user dialog like explorer does.

@danielniccoli
Copy link

danielniccoli commented Mar 26, 2022

I don't think we should implement a setting for a button with predefined credentials. This might be a security risk.

@crutkas Nobody said anything about credentials. Please read the suggestion again.

It would be important that only the username is stored, and the password must be entered every time.

@crutkas
Copy link
Member

crutkas commented Mar 26, 2022

Let’s file the storing secondary user name as a different issue and we can revisit. I’d imagine terminal has had similar asks and IMO we should follow their philosophy

@htcfreek
Copy link
Collaborator Author

htcfreek commented Mar 27, 2022

Sory I read the suggestion to fast.

This should indeed be a second issue as it imo require the centralization of the run as user code.

@jaimecbernardo jaimecbernardo added Resolution-Fix Committed Fix is checked in, but it might be 3-4 weeks until a release. and removed Status-In progress This issue or work-item is under development labels Apr 4, 2022
@htcfreek
Copy link
Collaborator Author

htcfreek commented Apr 8, 2022

Cool that this is part of the hotfix. Didn't expect that.

@htcfreek
Copy link
Collaborator Author

htcfreek commented May 4, 2022

Shipped with 0.58.0 (Hotfix for 0.57.2)

@htcfreek htcfreek closed this as completed May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Idea-Enhancement New feature or request on an existing product Product-PowerToys Run Improved app launch PT Run (Win+R) Window Resolution-Fix Committed Fix is checked in, but it might be 3-4 weeks until a release.
Projects
None yet
Development

No branches or pull requests

6 participants