question

LiZhu-5809 avatar image
0 Votes"
LiZhu-5809 asked RoyLi-MSFT commented

Windows Store App UAC Escalation doesn't work

Hi,

We have a Windows Store App built with Electron, which requires to register/install some "Shell Icon Overlay". We have an .exe called by Node.js child_process to do the register/install, which I believe requires admin privilege to run. The reason that we run this register through node.js is that Windows Store App cannot run any script like NSIS during installation (or can they?). The problem is that Windows Store app doesn't pop up UAC privilege window to allow user to escalate, so register failed to run. My questions are,
1). Is UAC privilege escalation not allowed with Windows Store App?
2). if yes, what is the other option with Windows Store app?

Thanks.

windows-uwp
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@LiZhu-5809 Any updates about this?

0 Votes 0 ·

1 Answer

RoyLi-MSFT avatar image
0 Votes"
RoyLi-MSFT answered RoyLi-MSFT commented

Hello,

Welcome to Microsoft Q&A!


Is UAC privilege escalation not allowed with Windows Store App?

Yes, UWP apps are not allowed to run with admin privilege. This is by design.

if yes, what is the other option with Windows Store app?

The possible way to implement what you want is to use Desktop bridge. You could create a console application that calls the script. Then package it together with the UWP app using Windows Application Package Project. After that, you need to configure the manifest file of the package project and add some parameters to the desktop:Extension.

You could open your search engine and search for App Elevation Samples stefanwick. It's a tutorial about how to implement this.


Thank you.


If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Thanks for quick response Roy. I will give App Elevation a try and will accept the answer if it works.

0 Votes 0 ·

Sure, Please let me know if you have other questions.

0 Votes 0 ·