UAC when updating on USB key

Hello,

We have distributed an .NET 4 application on USB keys and included the wyUpdate functionality. Every time we release an update, wyUpdate show the UAC message (Vista/7) or administrator rights (XP) dialog although we are only updating files on the USB key for which the user has write rights (no changes in the registry/com/service/...).

Why does wyUpdate asks for additional rights if we only replace files on a USB key for which the users has write access? How can we avoid that?

Kind regards,Robbie

Hey Robbie,

Currently wyUpdate sees folders as either "completely in the user's control" or "may or may not be completely in the user's control". If the folder is in the "completely in the user's control" group (i.e. the %appdata% folder, the desktop, the my documents folder, etc., etc.) then wyUpdate won't ask for elevation.

But, if the folder being updates is in the "may or may not be completely in the user's control" group then wyUpdate will always ask for elevation.

We do plan to make wyUpdate more flexible out-of-the-box. In the meantime, you can modify wyUpdate to never elevate. Or better yet, modify wyUpdate to dynamically check if the current user has permission to install to a custom folder (and then submit the patch back to us so we can include it for everyone). The relevent bit of code is in the "frmMain.UserElevation.cs" file. Specifically the "bool OnlyUpdatingLocalUser()" function.

Hello Sam,

I have a problem with the custom build version. I've followed the instructions in http://wyday.com/wybuild/help/custom-wyupdate-version.php but the existing wyUpdate.exe (2.6.16.4) does not update to my custom version 2.6.16.5 (all .NET 4)

Details.I created a New wyBuild project for my custom wyUpdate, build the updates, and uploaded it onto my server with selfupdate.wys as server filename. Two files are on the server: selfupdate.wys and wyupdatespecialbuild.all.to.2.6.16.5.wyu

In the Existing wyBuild project for my program:- I changed in File, Properties, wyUpdate to download the wyUpdate from my server: if I open the link in my browser, it downloads the selfupdate.wys file.- I added a new version in Files & Folders. I did NOT add 'wyUpdate.exe' version 2.6.16.5 there (do I need to this?)- I clicked on "build wyUpdate"- I clicked on "build updates"- I upload the update

In the programme, I check for updates, it downloads the updates, but i does not change the wyUpdate.exe: it stays at version 2.6.16.4

I already tried to add the custom 'wyUpdate.exe' version 2.6.16.5 in the Existing wyBuild in the Files & Folders, but that did not had any effect.

Any idea what goes wrong?

Robbie

P.S. If I want to contribute the UAC check code, where can I do that?

In the Existing wyBuild project for my program:- I changed in File, Properties, wyUpdate to download the wyUpdate from my server: if I open the link in my browser, it downloads the selfupdate.wys file.- I added a new version in Files & Folders. I did NOT add 'wyUpdate.exe' version 2.6.16.5 there (do I need to this?)- I clicked on "build wyUpdate"- I clicked on "build updates"- I upload the update

In this step also make sure you're include the latest client.wyc with your application (because this is where the new self-update site is stored). Of if you want to test your old version then select the old version from the drop-down menu (directly above the "Build wyUpdate" button). Then include *that* client.wyc with your old app.

Does that make sense? RIght now your old version doesn't know about the new self-update site because it's not in the old client.wyc file.

P.S. If I want to contribute the UAC check code, where can I do that?

You can email the changed files to us at support@wyday.com.

In this step also make sure you're include the latest client.wyc with your application (because this is where the new self-update site is stored).

Aha. I thought that the client.wyc file was always updated automatically.

However this also means that it will take 2 update rounds before everyone has the custom version of my wyUpdate.exe: the first round to get the client.wyc and the second round to get the actual latest version.

You can email the changed files to us at support@wyday.com.

It's in your mailbox.