Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
tails
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
947
Issues
947
List
Boards
Labels
Service Desk
Milestones
Merge Requests
12
Merge Requests
12
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tails
tails
Commits
163b76c5
Commit
163b76c5
authored
Sep 13, 2015
by
anonym
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Test that Tor Launcher uses the correct TBB libs.
parent
0f79c3dc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
4 deletions
+14
-4
features/step_definitions/browser.rb
features/step_definitions/browser.rb
+13
-4
features/tor_bridges.feature
features/tor_bridges.feature
+1
-0
No files found.
features/step_definitions/browser.rb
View file @
163b76c5
...
...
@@ -35,6 +35,7 @@ def xul_application_info(application)
'echo ${TBB_INSTALL}/firefox'
,
:libs
=>
'tor-browser'
).
stdout
.
chomp
address_bar_image
=
"BrowserAddressBar.png"
unused_tbb_libs
=
[
'libnssdbm3.so'
]
case
application
when
"Tor Browser"
user
=
LIVE_USER
...
...
@@ -53,10 +54,18 @@ def xul_application_info(application)
new_tab_button_image
=
"I2PBrowserNewTabButton.png"
when
"Tor Launcher"
user
=
"tor-launcher"
cmd_regex
=
"
#{
binary
}
\s
+-app /usr/local/lib/tor-launcher-standalone/application
\.
ini"
# We do not enable AppArmor confinement for the Tor Launcher.
binary
=
"
#{
binary
}
-unconfined"
tor_launcher_install
=
$vm
.
execute_successfully
(
'echo ${TOR_LAUNCHER_INSTALL}'
,
:libs
=>
'tor-browser'
).
stdout
.
chomp
cmd_regex
=
"
#{
binary
}
\s
+-app
#{
tor_launcher_install
}
/application
\.
ini.*"
chroot
=
""
new_tab_button_image
=
nil
address_bar_image
=
nil
# The standalone Tor Launcher uses fewer libs than the full
# browser.
unused_tbb_libs
.
concat
([
"libfreebl3.so"
,
"libnssckbi.so"
,
"libsoftokn3.so"
])
else
raise
"Invalid browser or XUL application:
#{
application
}
"
end
...
...
@@ -66,6 +75,7 @@ def xul_application_info(application)
:chroot
=>
chroot
,
:new_tab_button_image
=>
new_tab_button_image
,
:address_bar_image
=>
address_bar_image
,
:unused_tbb_libs
=>
unused_tbb_libs
,
}
end
...
...
@@ -108,8 +118,7 @@ Then /^the (.*) has no plugins installed$/ do |browser|
step
"I see
\"
TorBrowserNoPlugins.png
\"
after at most 30 seconds"
end
def
xul_app_shared_lib_check
(
pid
,
chroot
)
expected_absent_tbb_libs
=
[
'libnssdbm3.so'
]
def
xul_app_shared_lib_check
(
pid
,
chroot
,
expected_absent_tbb_libs
=
[])
absent_tbb_libs
=
[]
unwanted_native_libs
=
[]
tbb_libs
=
$vm
.
execute_successfully
(
"ls -1
#{
chroot
}
${TBB_INSTALL}/*.so"
,
...
...
@@ -141,7 +150,7 @@ Then /^the (.*) uses all expected TBB shared libraries$/ do |application|
info
=
xul_application_info
(
application
)
pid
=
$vm
.
execute_successfully
(
"pgrep --uid
#{
info
[
:user
]
}
--full --exact '
#{
info
[
:cmd_regex
]
}
'"
).
stdout
.
chomp
assert
(
/\A\d+\z/
.
match
(
pid
),
"It seems like
#{
application
}
is not running"
)
xul_app_shared_lib_check
(
pid
,
info
[
:chroot
])
xul_app_shared_lib_check
(
pid
,
info
[
:chroot
]
,
info
[
:unused_tbb_libs
]
)
end
Then
/^the (.*) chroot is torn down$/
do
|
browser
|
...
...
features/tor_bridges.feature
View file @
163b76c5
...
...
@@ -9,6 +9,7 @@ Feature: Using Tails with Tor pluggable transports
And
I capture all network traffic
When
the network is plugged
Then
the Tor Launcher autostarts
And
the Tor Launcher uses all expected TBB shared libraries
Scenario
:
Using bridges
When
I configure some Bridge pluggable transports in Tor Launcher
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment