Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start brave in incognito+TOR mode using command line #2105

Closed
edouard-lopez opened this issue Nov 12, 2018 · 42 comments · Fixed by brave/brave-core#9533
Closed

Start brave in incognito+TOR mode using command line #2105

edouard-lopez opened this issue Nov 12, 2018 · 42 comments · Fixed by brave/brave-core#9533

Comments

@edouard-lopez
Copy link

Description

related: #690, #1457

Starting Brave in incognito mode via command is possible with the --incognito flag. However there is no such flag for the Tor feature.

Steps to Reproduce

To enable Tor you have to:

  1. Start brave manually or by CLI brave-browser --incognito (here in incognito mode) ;
  2. Hit Alt+Shift+N (Linux user) ;
  3. Close previous window.

Actual result:

Works

Expected result:

Open directly via a flag, e.g.:

 brave-browser --incognito --tor

Reproduces how often:

Every time

Brave version (brave://version info)

 Version 0.56.12 Chromium: 70.0.3538.77 (Official Build) (64-bit)
@srirambv srirambv added this to the 1.x Backlog milestone Nov 12, 2018
@tildelowengrimm tildelowengrimm added the priority/P5 Not scheduled. Don't anticipate work on this any time soon. label Nov 14, 2018
@jackcaron
Copy link

Yes please!!!

Not sure if the right issue also, but when installed on Ubuntu, you can lock Brave in the launcher. And with a right click, having option for the incognito and incognito+tor would also be great.

@jtbrown3
Copy link

Thanks for mentioning this @jackcaron - In Windows 10, this context feature of 'right-clicking' from the TaskBar or Start Menu also exists. It would be a GREAT if Brave could also add the "New Incognito+Tor Window" selection to these special context menus. This could be an extension of the command-line option being requested here...

@Brave-Matt
Copy link

Just had a user on Reddit confirm that a way to do this in Windows (tested and works on my end):
https://www.reddit.com/r/brave_browser/comments/a7aflb/how_to_launch_brave_browser_in_incognito_mode_by/
Method:

  1. Right-click on Brave Shortcut --> Properties
  2. In Target path, enter [space]--incognito after quotations
  3. Click Apply/OK
  4. Brave shortcut launches with Private Window
    Note: the [space] refers the actual space character - command throws invalid path error without the space between the last " and --incognito

@ghost
Copy link

ghost commented Dec 28, 2018

Yes, please, add the command line to open brave tor window.
That's a real need for us.

@rebron rebron modified the milestone: 1.x Backlog Feb 7, 2019
@manit-shah
Copy link

manit-shah commented Feb 27, 2019

+1 for adding CLI command to open Brave tor window (start Brave --tor perhaps?)
+1 for adding New private window with Tor option to Windows 10 special context menus

Additional (related) request:
Allow the user to specify the default new window type (normal window, private window, or private window with Tor). So that a user may choose for Brave to always open to a private window with Tor. This would be an outstanding addition (which even Chrome does not have).

@Brave-Matt
Copy link

+1 from reddit: https://www.reddit.com/r/brave_browser/comments/ck9z3v/command_line_option_to_launch_new_private_browser/

@ghost
Copy link

ghost commented Dec 6, 2019

@WhatDothLife
Copy link

Can't wait for this to be implemented.

@ghost
Copy link

ghost commented Apr 17, 2020

+1 bump

@RuthlessRuler
Copy link

+1 Bump.

@cybardev
Copy link

cybardev commented May 2, 2020

It's been 2 years already... Please implement it soon. It'd be a killer feature.
Also, please add it to the context menu (.desktop file on Linux) so we get a "New Incognito Window with Tor" option on right-clicking the shortcut.

@contre95
Copy link

contre95 commented May 3, 2020

It would be a great feature, yes !

@contre95
Copy link

contre95 commented May 3, 2020

how f*cking long this will take? Do hear me?
just parse a new cli argument and trigger incognito+tor mode just like incognito.

Calm down dude !

NullHypothesis pushed a commit to brave/brave-core that referenced this issue Jul 21, 2021
This commit implements a command line switch (--tor) that starts Brave
in Tor mode.  This is done by subclassing StartupBrowserCreatorImpl and
implementing a custom Launch method.  If the user provided a --tor
command line flag, the patch switches the profile to Tor mode and then
calls StartupBrowserCreatorImpl's original Launch method.

This commit resolves brave/brave-browser#2105.
NullHypothesis pushed a commit to brave/brave-core that referenced this issue Jul 28, 2021
This commit implements a command line switch (--tor) that starts Brave
in Tor mode.  This is done by subclassing StartupBrowserCreatorImpl and
implementing a custom Launch method.  If the user provided a --tor
command line flag, the patch switches the profile to Tor mode and then
calls StartupBrowserCreatorImpl's original Launch method.

This commit resolves brave/brave-browser#2105.
NullHypothesis pushed a commit to brave/brave-core that referenced this issue Jul 30, 2021
This commit implements a command line switch (--tor) that starts Brave
in Tor mode.  This is done by subclassing StartupBrowserCreatorImpl and
implementing a custom Launch method.  If the user provided a --tor
command line flag, the patch switches the profile to Tor mode and then
calls StartupBrowserCreatorImpl's original Launch method.

This commit resolves brave/brave-browser#2105.
NullHypothesis pushed a commit to brave/brave-core that referenced this issue Jul 30, 2021
This commit implements a command line switch (--tor) that starts Brave
in Tor mode.  This is done by subclassing StartupBrowserCreatorImpl and
implementing a custom Launch method.  If the user provided a --tor
command line flag, the patch switches the profile to Tor mode and then
calls StartupBrowserCreatorImpl's original Launch method.

This commit resolves brave/brave-browser#2105.
NullHypothesis pushed a commit to brave/brave-core that referenced this issue Aug 2, 2021
This commit implements a command line switch (--tor) that starts Brave
in Tor mode.  This is done by subclassing StartupBrowserCreatorImpl and
implementing a custom Launch method.  If the user provided a --tor
command line flag, the patch switches the profile to Tor mode and then
calls StartupBrowserCreatorImpl's original Launch method.

This commit resolves brave/brave-browser#2105.
@NullHypothesis
Copy link

This feature was implemented in brave/brave-core#9533. It makes it possible to start Brave in Tor mode by running:

brave-browser --tor

Note that if the --tor switch is used together with --silent-launch, Tor won't be launched.

@rebron
Copy link
Collaborator

rebron commented Aug 3, 2021

Closing. Fixed per comment above.

@rebron rebron closed this as completed Aug 3, 2021
@rebron rebron added this to the 1.29.x - Nightly milestone Aug 3, 2021
@xmha97
Copy link

xmha97 commented Aug 3, 2021

brave-browser --tor

This command doesn't work on the stable version.
image
Please help me or reopen this issue.

@stephendonner stephendonner added the QA/In-Progress Indicates that QA is currently in progress for that particular issue label Aug 3, 2021
@stephendonner
Copy link

stephendonner commented Aug 3, 2021

Verified PASSED using the testplan from brave/brave-core#9533 with

Brave 1.29.48 Chromium: 92.0.4515.131 (Official Build) nightly (x86_64)
Revision 6b8d6c56ce21e38a72f7c4becb5abc1fa5134f29-refs/branch-heads/4515@{#1933}
OS macOS Version 11.5.1 (Build 20G80)

Steps:

Test 1
  1. Open a website in browser window 1 (abc.com) and another website in browser window 2 (bbc.com)
  2. Quit Brave and launch it with --tor command line flag
  3. Open a normal window by pressing Ctrl + n or by clicking on Menu -> New window
  4. Windows from step 1 should be restored

Confirmed abc.com and bbc.com reopened

Screen Shot 2021-08-03 at 3 52 53 PM
Test 2
  1. Open a website in browser window 1 (abc.com) and another website in browser window 2 (bbc.com)
  2. Quit Brave and launch it with --tor command line flag
  3. Quit Brave
  4. Launch Brave without --tor
  5. Windows from step 1 should be restored

Confirmed abc.com and bbc.com reopened

Screen Shot 2021-08-03 at 3 50 28 PM
Test 3
  1. Open a website in browser window 1 (abc.com) and another website in browser window 2 (bcc.com)
  2. Crash browser using chrome://inducebrowsercrashforrealz/
  3. Launch Brave with --tor
  4. Open a normal window by pressing Ctrl + n or by clicking on Menu -> New window
  5. Windows from step 1 should be restored

Confirmed abc.com and bbc.com reopened

example example
Screen Shot 2021-08-03 at 3 43 45 PM Screen Shot 2021-08-03 at 3 52 53 PM
Test 4
  1. Open a website in browser window 1 (abc.com) and another website in browser window 2 (bbc.com)
  2. Crash browser using chrome://inducebrowsercrashforrealz/
  3. Launch Brave with --tor
  4. Quit Brave
  5. Launch Brave without --tor
  6. Windows from step 1 should be restored

Confirmed abc.com and bbc.com reopened

Screen Shot 2021-08-03 at 3 54 15 PM
Test 5
  1. Launch Brave with --tor
  2. Visit https://check.torproject.org/api/ip
  3. Make sure that the page contains the string "IsTor":true.

Confirmed I saw {"IsTor":true,"IP":"185.220.102.249"}

Screen Shot 2021-08-03 at 3 45 52 PM

Verification passed on

Brave 1.29.60 Chromium: 92.0.4515.131 (Official Build) beta (64-bit)
Revision 6b8d6c56ce21e38a72f7c4becb5abc1fa5134f29-refs/branch-heads/4515@{#1933}
OS Ubuntu 18.04 LTS

Verified test plan from brave/brave-core#9533

Test 1

image
image

Test 2

image
image

Test 3

image
image

Test 4

image
image

Test 5

image


Verification passed on

Brave | 1.29.74 Chromium: 93.0.4577.58 (Official Build) (64-bit)
-- | --
Revision | c4410ece044414ea42fa4ba328d08195e818a99c-refs/branch-heads/4577@{#1076}
OS | Windows 10 OS Version 2009 (Build 19043.1165)

Test 1

Confirmed cnn.com and nytimes.com reopened
image

Test 2 Confirmed twitter.com and buzzfeed.com reopened

image

Test 3

Confirmed theverge.com and orimi.com reopened
image
image

Test 4 Confirmed `gmail.com` and `indiatimes.com` reopened

image

Test 5

image

@stephendonner stephendonner added QA Pass-macOS and removed QA/In-Progress Indicates that QA is currently in progress for that particular issue labels Aug 3, 2021
@stephendonner
Copy link

brave-browser --tor

This command doesn't work on the stable version.
image
Please help me or reopen this issue.

hi @xmha97 - this does work in 1.29.48 and newer nightly builds, and will be in the August 31st release (https://github.com/brave/brave-browser/wiki/Brave-Release-Schedule), if not sooner (if we take the change and uplift/back-port to 1.28.x branch).

@gnfpt
Copy link

gnfpt commented Jul 16, 2023

Brave doesn't start in tor mode when app mode is also used.

ie:
brave --tor --app="https://whatismyipaddress.com/"

~/gnf.pt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment