How do I delete session data from a permanent sandbox?

If it doesn't fit elsewhere, it goes here
SimonF

How do I delete session data from a permanent sandbox?

Post by SimonF » Sun Mar 18, 2012 11:53 am

I'd probably say I'm an intermediate Sandboxie user and have been using the (paid-for) product for a few years. I'd like to do something but can't figure out how to do it. So this is a "how do I do this?" question. Although I have a specific problem, it seems that a solution (if possible) could be generally applied (Google Earth comes to mind, as a possible candidate).

I installed TOR the other day into its own sandbox. It now comes as a full package, complete with a TOR browser (Firefox). The problem is that the TOR software and browser are installed permanently on disk via a FileRootPath setting. But when I run the browser, I want *everything* from the browser session to be deleted, just like I do when I run my normal browser (which was installed outside of a sandbox). It's almost like I need another sandbox over the top of the TOR sandbox.

Any suggestions would be appreciated.

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Sun Mar 18, 2012 12:33 pm

Are you sure you mean FileRootPath and not something else?

In any case it seems like you'd like to delete the TOR/Firefox profile folder that is inside the sandbox, so you should probably do just that. Explore the sandbox to find that folder and delete it. If it's anything like normal Firefox, you need to find a series of folders called ...\Mozilla\Firefox\Profiles\... and then delete the folder or folders with that Profiles folder.
tzuk

SimonF

Post by SimonF » Sun Mar 18, 2012 1:04 pm

Yes, sorry the FileRootPath is a bit of a red herring.

Sorry to be unclear. I don't want to delete the profile data, since I'd like to configure Firefox a bit and retain all those settings each time I use it. Instead, I want to delete anything created during a TOR/FF browsing session.

When I run my normal FF browser, it's installed outside of a sandbox but runs inside its sandbox and clears out all data created during a browsing session. I'd like to replicate that functionality but have TOR/FF permanently installed inside a sandbox.

I also mentioned Google Earth as a potentially analogous example. I'd like to delete any session data but retain the Google Earth settings.

Hope this is a bit clearer.

Si

Guest10
Posts: 5124
Joined: Sun Apr 27, 2008 5:24 pm
Location: Ohio, USA

Post by Guest10 » Sun Mar 18, 2012 2:16 pm

I would think that the Firefox browser in that bundle would already be set up to discard all browsing history data, but probably will allow bookmarks to be saved.

On the Firefox > Tools > Options > Privacy tab
Under History, is either of these checked:
Firefox will: "Never remember history"
or,
Firefox will: "Use custom settings for history", and then check "Always use private browsing mode" and uncheck the option to "Accept cookies".
Paul
Win 10 Home 64-bit (w/admin rights) - Zone Alarm Pro Firewall, MalwareBytes Premium A/V, Cyberfox, Thunderbird
Sandboxie user since March 2007

SimonF

`

Post by SimonF » Sun Mar 18, 2012 3:09 pm

Thanks for the input Guest10.

I'm familiar with the Firefox settings you refer to. The beauty of Sandboxie is that when I clear out the sandbox, I can be sure that all legitimate and illegitimate changes to my system will have been erased.

As mentioned, I'd also like to apply a similar principle to Google Earth, so am trying to find a more generic solution to the problem.

Si.

Guest10
Posts: 5124
Joined: Sun Apr 27, 2008 5:24 pm
Location: Ohio, USA

Post by Guest10 » Sun Mar 18, 2012 5:33 pm

If you don't want anything to change in a sandbox with programs inside of it, the only way that I can think of is to archive a copy of the sandbox folder after you set it up the way you want it.
Then copy it back to it's original location under C:\Sandbox\...\... when ready to use it.

If you want to allow some changes, but not all, then I can't think of anything.
Paul
Win 10 Home 64-bit (w/admin rights) - Zone Alarm Pro Firewall, MalwareBytes Premium A/V, Cyberfox, Thunderbird
Sandboxie user since March 2007

SimonF

Post by SimonF » Mon Mar 19, 2012 7:04 am

Many thanks for your help, Guest10. The suggestion is a bit clunky but might work, I guess.

I tried a different approach but it has its own problems. My "solution" was to try and run the TOR software from a separate sandbox. So, it's installed in one sandbox but run from another.

But how to do it? Given two sandboxes: TOR and TORRun, I can get it to work ok using the "Run Any Program" from the TORRun sandbox and drilling down through the "raw" sandboxed files until I reach the relevant executable:
"D:\Sandbox\xxx\TOR\drive\C\Temp\Tor Browser\Start Tor Browser.exe" But that too is a bit clunky and requires a tedious drill-down each time I want to run it.

So I tried to create a desktop shortcut (this is on XP/SP3) that runs the following command:
"C:\Program Files\Sandboxie\Start.exe" /box:TORRun "D:\Sandbox\xxx\TOR\drive\C\Temp\Tor Browser\Start Tor Browser.exe"
Unfortunately, this does not run in the TORRun sandbox, as the parameter specifies, but in the TOR sandbox, which rather defeats the purpose of the exercise.

At this point, I've reached the limits of my Sandboxie "expertise" (cough). Any ideas why the shortcut doesn't work correctly?

Si

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Mon Mar 19, 2012 7:28 am

SimonF wrote:So I tried to create a desktop shortcut (this is on XP/SP3) that runs the following command:
"C:\Program Files\Sandboxie\Start.exe" /box:TORRun "D:\Sandbox\xxx\TOR\drive\C\Temp\Tor Browser\Start Tor Browser.exe"
Unfortunately, this does not run in the TORRun sandbox, as the parameter specifies, but in the TOR sandbox, which rather defeats the purpose of the exercise.
I tried something similar but it works as expected for me: The program starts in the sandbox specified by the parameter and not the sandbox that corresponds to the path where the program resides.

So I would say that you should experiment with your Start.exe command line a bit and see if you can get it to work.
tzuk

Guest10
Posts: 5124
Joined: Sun Apr 27, 2008 5:24 pm
Location: Ohio, USA

Post by Guest10 » Mon Mar 19, 2012 8:34 am

SimonF wrote:But how to do it? Given two sandboxes: TOR and TORRun, I can get it to work ok using the "Run Any Program" from the TORRun sandbox and drilling down through the "raw" sandboxed files until I reach the relevant executable:
"D:\Sandbox\xxx\TOR\drive\C\Temp\Tor Browser\Start Tor Browser.exe" But that too is a bit clunky and requires a tedious drill-down each time I want to run it.
As far as the drill-down is concerned: when I install a program inside of a sandbox, and it doesn't put a shortcut on the sandboxed "Desktop" folder (like a portable program), I create my own.
Then I would use the "Run From Start Menu" item, and the new sandboxed shortcut will show at the top of the Sandboxie Start menu, under "Desktop".
Since I don't want to actually Recover this shortcut to my real Desktop, I don't have the "Desktop" folder set as a Recover Folder for that sandbox.

To create the shortcut:
Use "Run Windows Explorer" from that sandbox's menu; navigate to the .exe that you want to run and "Create Shortcut"; still in the sandboxed Explorer, move that shortcut to the "Desktop" folder.
SimonF wrote:So I tried to create a desktop shortcut (this is on XP/SP3) that runs the following command:
"C:\Program Files\Sandboxie\Start.exe" /box:TORRun "D:\Sandbox\xxx\TOR\drive\C\Temp\Tor Browser\Start Tor Browser.exe"
Unfortunately, this does not run in the TORRun sandbox, as the parameter specifies, but in the TOR sandbox, which rather defeats the purpose of the exercise.
It's not exactly your set up, since I didn't put 'Start Tor Browser.exe' in a sandbox, and I didn't use different hard drives, but I got the same results as you did.

I created a folder structure for a small utility program, and a shortcut:
"C:\Sandbox\(user)\TestBox\drive\C\Temp\Tor Browser\cports.exe"

then modified the shortcut's Properties > Target line:
"C:\Program Files\Sandboxie\Start.exe" /box:NonSecureBox "C:\Sandbox\(user)\TestBox\drive\C\Temp\Tor Browser\cports.exe"

The "cports.exe" program runs sandboxed using the sandbox it is located in, and not the one specified on my command line.
That's actually what I expected when I first read your test setup.
Paul
Win 10 Home 64-bit (w/admin rights) - Zone Alarm Pro Firewall, MalwareBytes Premium A/V, Cyberfox, Thunderbird
Sandboxie user since March 2007

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Mon Mar 19, 2012 8:51 am

Since I don't see this behavior, the only thing I can think of is that the "Start in" field in your shortcuts specifies the sandbox where the EXE resides (e.g. the TOR sandbox) while your /box parameter specifies some other sandbox (.e.g the TORRun sandbox). In this case the sandbox selected by the "Start in" field would override the one selected by /box.
tzuk

Guest10
Posts: 5124
Joined: Sun Apr 27, 2008 5:24 pm
Location: Ohio, USA

Post by Guest10 » Mon Mar 19, 2012 9:21 am

tzuk wrote:In this case the sandbox selected by the "Start in" field would override the one selected by /box.
Yes, that was it.
Once I deleted the text from the "Start In:" box, the shortcut worked.
Paul
Win 10 Home 64-bit (w/admin rights) - Zone Alarm Pro Firewall, MalwareBytes Premium A/V, Cyberfox, Thunderbird
Sandboxie user since March 2007

SimonF

Post by SimonF » Mon Mar 19, 2012 12:56 pm

Thanks for the help guys. Yes, TOR seems to install like a portable app, so I'll use your suggestion, Guest10.

I too had the "Start in" field set to the underlying [TOR] directory. I actually added this to the shortcut because the TOR startup program, Vidalia, would fail with an error:

"Failed to parse/validate config: Unknown option '__OwningControllerProcess'. Failing."

With the "Start in" set, the error goes away but TOR starts in the wrong sandbox. I wasn't aware that's how it works.

Unfortunately, the error means little to me but I see that the __OwningControllerProcess option was used (added?) to Vidalia version 0.2.16 to fix a bug: https://blog.torproject.org/blog/vidalia-0217-out The option seems to be TOR-specific.

Is is possible that sandboxie is somehow blocking this option? Currently, I'm not using dropped rights on either sandbox.

Si

SimonF

Post by SimonF » Mon Mar 19, 2012 2:04 pm

Problem solved. Guest10's suggestion of creating the shortcut in the TORRun sandbox did the trick. And no strange config errors, either.

I'm very grateful for your help.

Now for Google Earth...

Si

Anonymouse

Can you describe very full how you accomplished this?

Post by Anonymouse » Tue Apr 09, 2013 4:39 pm

SimonF wrote:Problem solved. Guest10's suggestion of creating the shortcut in the TORRun sandbox did the trick. And no strange config errors, either.

I'm very grateful for your help.

Now for Google Earth...

Si
I would like very much to do this as well. I am a novice Sandboxie user (I like to use it to open questionable pdf files) and would appreciate a small tutorial if you wouldn't mind :D

Like

1.

2.

3...

Dorota87
Posts: 1
Joined: Fri Apr 19, 2013 3:14 am
Contact:

yeah

Post by Dorota87 » Fri Apr 19, 2013 3:19 am

I would think that the Firefox browser in that bundle would already be set up to discard all browsing history data, but probably will allow bookmarks to be saved. Look at opportunities like okna katowice
Last edited by Dorota87 on Mon Apr 22, 2013 5:59 am, edited 2 times in total.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest