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

Installs securedrop-proxy package in sd-journalist #170

Merged
merged 5 commits into from Oct 19, 2018

Conversation

conorsch
Copy link
Contributor

Review and merge #169 first.

Summary of changes:

  • Installs the securedrop-proxy package via https://apt-test-qubes.freedom.press into the sd-journalist VM (which is still called sd-journalist; once the client code lands in sd-svs, we can rename).
  • Configures dom0 RPC policies as described in the proxy docs
  • Reads the Onion URL from local config.json and stores that in /etc/sd-proxy.yaml inside sd-journalist.
  • Writes a few new tests so we can confirm the package is indeed present

Closes #161.

Testing

  1. Run make all in dom0 and confirm no errors.
  2. Run make test in dom0 and confirm no errors.
  3. Confirm you can download and view a test submission. A plaintext submission should be displayed in gedit in a DisposableVM.

Have not verified proxy functionality; waiting on client integration to make the bits flow.

Conor Schaefer added 5 commits October 19, 2018 11:54
Using a separate SLS file, since we need the apt-test repo configured in
more than just the `sd-workstation-template` VM: we need it at least in
`sd-journalist-template`, shortly to become the `sd-proxy-template`, for
installing the `securedrop-proxy` package.

Appends another task to the SLS file, ensuring that `python-apt` is
installed, because evidently Salt requires that package in order to
handle the repo configuration. Wasn't a problem against Debian 9, but
the Whonix-derived VMs such as `sd-journalist` errored out until the
package was installed.
Installing the `securedrop-proxy` package so that it's available for
integrating with the other Workstation tooling currently being packaged.
We'll soon rename `sd-journalist` to `sd-proxy`, but not yet.

Includes config tests updates to ensure the package is indeed installed.
These files must reside in dom0 in order for the inter-VM communication
to work for the securedrop-proxy service. Currently copying via Salt, we
can move those into the forthcoming dom0 config RPM package when that
work is ready.
The YAML config file contains site-specific information such as the
Onion URL, and is required for the `securedrop-proxy` package to
function. Would be ideal to write the YAML intelligently, rather than as
line substitutions, this "just worked". In the future perhaps we can
port the Salt to Python and `import yaml`.

Includes tests. We know the Onion URL we want to connect to (for the
sd-whonix config), so let's read that from the JSON file on disk and
make sure the configuration landed on the target VM as intended.
During development, re-ran `make sd-journalist` several times, and the
appmenu task failed simply because the VM was already running. Let's
pass a flag to continue in such a scenario, rather than erroring out.
@emkll emkll force-pushed the 161-install-proxy-package-in-sd-journalist branch from 099f7bd to 2ebe3b7 Compare October 19, 2018 15:55
@emkll
Copy link
Contributor

emkll commented Oct 19, 2018

Rebased on master after merging #169

Copy link
Contributor

@emkll emkll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All tests pass locally, the package successfully installed in sd-journalist, and the config file also exists. Good call on the apt repo logic split, LGTM !

@emkll emkll merged commit 2797777 into master Oct 19, 2018
@emkll emkll deleted the 161-install-proxy-package-in-sd-journalist branch October 19, 2018 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants