Page 1 of 1

"Lost" database - Vista access permissions

Posted: Sun Sep 14, 2008 12:29 am
by krdu
Here is a real strange problem - it's a Vista problem more than a UE problem, I think.

After downloading some software from Usenet, I got a real bad trojan. Even after I eliminated as much as I could find, Vista crashes after about 5 minutes. It does not crash in safe mode. So, I merely copy everything I need, reload Vista, and reinstall. Time consuming, but doable.

But I have about 8 gigabytes of files downloaded but not saved in UE. The database is supposed to be in C:/Program Files/Usenet Explorer, but the only thing I can see there is UE.Exe! Searching on, say, "bodies" turns up nothing! Vista just can't find the folders! Yet UE finds them fine.

I actually moved the C:/Program Files/Usenet Explorer folder to the desktop, and UE still finds the database! Yet UE can't find the database in safe mode even when I move the Usenet Explorer folder back to C:/Program Files/. "Properties" says that the C:/Program Files/Usenet Explorer folder is 138K and when I copy it to another drive, 138K is copied - only UE.exe.

So I can't get the downloaded files out in normal mode because Vista crashes and I can't get them out in safe mode because Usenet Explorer, like me, can't find the database! Where is that database?

Posted: Sun Sep 14, 2008 1:45 am
by krdu
Here is a strange thing that might give you a clue - when I am in regular mode and I go to the properties menu, database location, UE can see the subdirectories in C"/program files/Usenet explorer. But in safe mode, UE can't seem to see these subdirectories.

Posted: Tue Sep 16, 2008 1:36 am
by alex
if UE sees them in that exact directory, check the subfolder permissions when running as administrator, if you are not sure about the directory the database folder is shown in UE edit menu->properties->general, database folder.

if you see the subdirectories when logged in as administrator you won't see them when running as regular user even if you copy them since you need to change the permissions to have them visible whoever is logged on.

Posted: Thu Sep 18, 2008 7:02 am
by krdu
It seems to be more complicated than that. Yes I am logged in as administrator. the "Program Files" directory seems to be some sort of a special directory in Vista. I have User Account Control turned off, but when it is turned on, moving a directory from "Program files" takes special permission that isn't necessary for other directories.

In any event, I can create a file in the "Usenet Explorer" directory (subdirectory of "Program Files") Usenet Explorer can see it and I can see it. But if Usenet Explorer creates the directory, UE can see the directory, read from it and write to it, but the directory is invisible to me. Try it - see what I mean. This behavior, so far, seems to be confined to subdirectories in "Program Files."

I haven't tested creating a directory and having UE write files to it and looking for the files. I would guess that this strange behavior is limited to directories.

The really strange things are:

1. Usenet Explorer cannot see a directory created under Program Files by it when running in Safe Mode.

2. When I move the Usenet Explorer directory to the desktop, UE can still find the database. Either that's because UE executable is in the same directory or somehow, the files are left in a hidden directory under "Program Files" which UE can find.

Yes, as noted in the first post, I checked "Properties" to find where UE thought the database was, copied it (to avoid typos), pasted it into the folder line at the top, and tried to go to the directory. No luck. Completely invisible. I also tried reading the directory with DOS... it gives me a cryptic error message I have never seen before and doesn't even see the UE executable. I haven't tried 4DOS yet because it isn't loaded.

I know that there are files that can't be erased or moved unless you use a rather complicated procedure to change its attributes... from a level even higher than "administrator." Is there such a level for directories which makes them invisible? If so, it would seem that it would be impossible for any human to ever see that directory since you wouldn't see it to to click on it to change its attributes. Maybe changing the higher directory (even though it would already be at a lower level) would affect the subdirectories? A moot question since I don't know if such a level even exists. But, on the other hand, such a level must exist since UE creates it.

Posted: Thu Sep 18, 2008 11:56 am
by Josef K
Try using the SuperAdmin account.

I find it's best to avoid using Program Files in Vista, especially with UAC turned on. Run UE from a different location, even Documents is better, create C:\Usenet Explorer or run it from a different drive or partition.

Posted: Sun Sep 28, 2008 4:57 pm
by krdu
Mystery Solved!

In Vista the rules are that if you don't have explicit (by requesting) elevated permissions to write to C:\Program Files, the system lets you think you are writing there but actually redirects (virtualizes) your writes elsewhere.

On the surface, this sucks in a huge way, in the "where are my files" kind of way.

As far as programs on my system, there's a number of "mal-behaved" programs that are getting their writer redirected to the "Virtual Store." Of note are MSN Messenger, the new Nero, and FireFox.

Ideally apps will write to the places they should be writing to, like Isolated Storage and such. Apps should include a manifest that explains what they're going to need (security and permissions demands) so that the consent dialog (run my Consent.exe of all things) would be issued automatically.

The other really bad UI issue is that there's no way to get to the compatibility-based Virtual Store from the common file open/save dialogs.

Maybe UE should take this weird Vista behavior into consideration and prevent the database being placed in "Program files." Certainly, it should prevent saving downloads to the "Program files" directory or any directory under it because even though they are saved there, they can't possibly be found! ALEX - if you happen to find this, I posted a copy in the "development" forum to be sure you see it.