You are here

Flash temp dir

10 posts / 0 new
Last post
RR
Offline
Last seen: 16 years 4 months ago
Joined: 2008-02-04 17:09
Flash temp dir

Flash works fine.
However it writes in the %TEMP% and not locally.

Any suggestion to use a portable directory?

rab040ma
Offline
Last seen: 6 days 18 hours ago
Joined: 2007-08-27 13:35
That should be a matter of

Welcome to PortableApps.com

Redirecting %TEMP% should be a matter of choice. For some people, on a slow flash drive and with few concerns for privacy, it is better to use %TEMP% on the host computer's hard drive, especially if the program cleans up after itself. Much faster.

On the other hand, it is relatively easy to redirect it to your USB Drive if privacy is a concern. If you aren't averse to a bit of programming, search for StartPortableApps.nsi. My version has some code in it for redirecting TEMP. (If you redirect it for PAM, anything PAM starts will inherit the redirection.)

John mentioned something about a future update to PortableApps.com including better control of the TEMP directory. Haven't heard much more about it lately.

Firefox should be deleting Flash files after you are finished with them. Have you watched to see if it ever removes them, and under what circumstances it fails (or succeeds)? At any rate, whether or not Firefox cleans up temp files is something for Firefox developers, not PortableApps, and would be a concern even if the TEMP directory were redirected to the portable/removable drive (otherwise it fills up quickly).

It would be relatively easy to write a batch file to redirect the TEMP directory for FireFoxPortable. Respond if you have questions about it.

MC

RR
Offline
Last seen: 16 years 4 months ago
Joined: 2008-02-04 17:09
Yes, I'd need a portable

Yes, I'd need a portable TEMP for privacy reasons.

I think that a .bat would be better because I'm not using PAM (and also .nsi stuff is for now beyond my ehm skills).

However changing TEMP variable and executing Firefox making it inheriting the TEMP value does not work, can you suggest me some examples?

I'm also using Tor Portable thst's the reason why I'm not using PAM (right or wrong Wink

rab040ma
Offline
Last seen: 6 days 18 hours ago
Joined: 2007-08-27 13:35
Well, I just confirmed that

Well, I just confirmed that FF and FFP use the TEMP environment variable if it is set.

Environment variables can be tricky. If you aren't used to setting them, it is easy to set them in a place that doesn't get inherited somewhere else.

If you use ProcessExplorer (from sysinternals) it has a way to see what the environment variables are for a running program. That would be one way to test whether your environment variable setting is being inherited by Firefox.

I found something interesting: Firefox uses the TMP environment variable, if it is set.

Here is a batch file I used for testing (I named it test1.bat and put it into the FirefoxPortable directory, and started it from a command prompt in the same directory):

set TEMP=C:\TEMP\user1
SET TMP=V:\Documents
echo %TEMP% %TMP%
firefoxportable

I haven't made any effort to make the paths relative for the test. You'll need to change the drive letters, and perhaps path, to coincide with your own situation. In my situation the V: drive is the removable one. If you run from a command prompt you'll see the two variables displayed by the echo command. In my testing the flash temp file was created in V:\Documents.

It was also removed when Firefox exited.

At any rate, that should demonstrate to you that it is possible to set the environment variable, and Firefox does observe it.

Once you have convinced yourself that this will work, the next step is figuring out how to start FFP with that environment. You could use a batch file, but the paths might need to be tweaked; if the batch file starts TorPortable, and TorPortable starts FFP, the environment should get inherited.

MC

RR
Offline
Last seen: 16 years 4 months ago
Joined: 2008-02-04 17:09
Ok workin perfectly! I had

Ok workin perfectly!

I had checked working directory with the Process Monitor (from sysinternals as well) that now is showing the local dir access.

C:\Documents and Settings\XXXXX\Application Data\Macromedia\Flash Player\#SharedObjects

C:\Documents and Settings\XXXXX\Application Data\Macromedia\Flash Player\#SharedObjects\47X7HCNZ\video.google.com\videostats.sol

This means that privacy is an endless story!

I will use process explorer and let you know...

rab040ma
Offline
Last seen: 6 days 18 hours ago
Joined: 2007-08-27 13:35
Shared

Yikes. What is Flash doing... or what is video.google.com doing. Sigh.

I suppose we could try setting HOMEPATH or USERPROFILE or APPDATA environment variables, and see if Flash honors any of them.

MC

RR
Offline
Last seen: 16 years 4 months ago
Joined: 2008-02-04 17:09
Ok, apart from a few weird

Ok,
apart from a few weird file accesses no temp area seems to be used anymore. Redirected APPDATA + USERPROFILE (maybe the latter is not needed).

The same for Portable Tor.

I would like to shut down Tor + Firefox + Flush the USB. Any idea?

Thank you again

rab040ma
Offline
Last seen: 6 days 18 hours ago
Joined: 2007-08-27 13:35
Say more about what you mean

Say more about what you mean by "shut down" and/or "flush".

Are you talking about perhaps an autoit script that emulates the shutdown commands for those programs? Or a program that emulates the "safely remove hardware" functionality?

You could search the forums for "eject script" or that sort of thing.

MC

Tim Clark
Tim Clark's picture
Offline
Last seen: 13 years 2 months ago
Joined: 2006-06-18 13:55
Flush=Flash

I believe he is using "flush" as a euphemism for flash,
of course it could just be a typo

Tim

Things have got to get better, they can't get worse, or can they?

RR
Offline
Last seen: 16 years 4 months ago
Joined: 2008-02-04 17:09
ok sorry it was not precise,

ok sorry
it was not precise, referring to the eject functionality.

Any specific suggestion on terminating politely Firefox from a command line?

by politely I mean makin it perform any appropiate actions on exit (for example cleaning temp...)

Log in or register to post comments