Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Vista kills app
Message
 
To
09/04/2007 21:29:16
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Vista
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01192452
Message ID:
01214087
Views:
20
How's this for scary?

I have an app that presents a brief summary on the main page of the app (i.e. "You have performed 47 searches, with 967 results found.").

During the course of testing last week (in Vista), I deleted all of my searches (and subsequent results) records.

I would expect that the next time I start the app, the summary page would say "You have performed 0 searches," like it has a thousand times before.

Before I closed the app though, I decided to do a Ctrl+Alt+Del (a normal test I would say, since *all* of my users seem to decide it's a good idea to work on the app while there is a major thunderstorm with their lights flickering on and off and a tornado headed their way). :)

When I restarted the app, the summary page still read "47 searches with 967 results". But, my detail pages showed zero searches and zero results.

When I looked at my tables, they had zero records.

The "virtualized" copy of my data had not been "copied" correctly before the Ctrl+Alt+Del. Now I have two copies of my data, and they are not synced.

The summary page is somehow pulling it's results from one set of the data, and yet later in the app I can see that I have 0 searches and 0 results.

I've given up for the moment at looking at the issue, since I decided to roll back to WinXP for day-to-day production. Maybe sometime in the next week I'll have time to retest on a clean Vista machine.

Kevin Ragsdale
Manchester, TN





>IMO, this Vista UAC thing is really poorly implemented. The Virtualization "feature" seems so dangerous, because an app can be using files that it thinks are centrally located (in the Program Files, for instance), when in fact, Vista has "silently" copied them to the Virtual folder under the Users\ folder tree, and the app is happily running using a copy of the files that are located off in never never land. How scary is that! Even MS apps, such as Visual Studio, IIS, and others are having problems with this. See the link below:
>
>http://msdn2.microsoft.com/en-us/vstudio/aa972193.aspx
>
>Ok, so I'm fuming, but I calm down and say, ok, let's put a check in my app to make sure I'm running "As Administrator". Well the only way I can see to do that check is to try and delete a file in your Program Files area that the installer created. You can't simply try opening a file for "write" access or creating a new file, because it will "silently" be copied over to the Virtual folder and you'll be able to open or create it. Golly, that's a disaster waiting in the shadows! IMO, Virtualization should be "OFF" by default, or either never invented. At the least, does anyone know of a method to determine if you are running "As Administrator"? Trying to create or open files for write doesn't do it.
>
>Does this UAC default really solve any security issues anyway, for what it's worth? What about malware writing to data folders? Why doesn't that have to be as protected as Program Files? And, exactly where are we supposed to put data files that are shared by "All Users"? I'm just amazed that Vista made such a huge problem for so many apps, for a change that doesn't seem to buy all that much security. But I'm definitely not the expert.
>
>Ok, I feel better, I think... If anyone can offer some advice that would help. I know I probably need to redesign my app and where it stores data, and how it does upgrades, etc, but I'm thinking, why? What security is all this buying? Users are going to get so sick of clicking "Allow this" and "Allow that", they will be numb to any security breaches. I'm already starting to click those prompts without reading them.
>
>Anyway, I'm about to change my app's install folder to a new root, called "Programs", and get on with life, knowing that my app runs solid again as it did on XP, if it's installed outside of Program Files.
>
>Mark
>
>
>>Hi Jim.
>>
>>>I've done a bit more research and according to what I've read, any files created in subfolders under ProgramData\ at install time are automatically read/write to all users, but to create/delete files your program needs administrator rights (one way or another). So as long as you create the folder and file through the installer, you should be OK. That doesn't address the issue of dynamically creating shared files, but I haven't had time to investigate that issue yet.
>>
>>I did a little playing tonight and found that files created in subfolders of ProgramData could only be written to by the creator user. Even admins can't modify a file created by another user. I haven't tested this with an installer, but I suspect the rules will be the same -- if the installer runs elevated as an admin user, any files it creates in ProgramData will be read-only to other users.
>>
>>I also found that files and folders in \Users\Public are read-write to all users, so perhaps that's the place to store global data.
>>
>>Still playing ...
>>
>>Doug
Previous
Reply
Map
View

Click here to load this message in the networking platform