summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.rst14
-rw-r--r--CONTRIBUTING.rst174
-rw-r--r--README.rst10
-rwxr-xr-xdocker/bitmask-docker.sh13
-rw-r--r--relnotes.txt10
-rw-r--r--src/leap/bitmask/logs/utils.py2
-rw-r--r--src/leap/bitmask/services/mail/emailfirewall.py5
-rw-r--r--src/leap/bitmask/services/soledad/soledadbootstrapper.py6
8 files changed, 221 insertions, 13 deletions
diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 2114c5ab..421389e2 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -3,6 +3,20 @@
Changelog
---------
+0.9.0rc4 October 05
++++++++++++++++++++
+
+Features
+~~~~~~~~
+- `#7471 <https://leap.se/code/issues/7471>`_: Disable email firewall if we are running inside a docker container.
+
+Bugfixes
+~~~~~~~~
+- `#7451 <https://leap.se/code/issues/7451>`_: Assign the timeout 'call later' before starting the sync to prevent race conditions.
+- `#7503 <https://leap.se/code/issues/7503>`_: Handle soledad init fail after several retries.
+- Remove bubble argument from the logbook NullHandler
+
+
0.9.0rc3 September 22
+++++++++++++++++++++
diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst
new file mode 100644
index 00000000..f9136de9
--- /dev/null
+++ b/CONTRIBUTING.rst
@@ -0,0 +1,174 @@
+Contributing to Bitmask
+=======================
+
+:+1::tada: First off, thanks for taking the time to contribute! :tada::+1:
+
+The following is a set of guidelines for contributing to Bitmask and its packages,
+which are hosted in the `LEAP git repo`_ and mirrored on the `LEAP
+organization`_ on GitHub.
+These are just guidelines, not rules, use your best judgment and feel free to
+propose changes to this document in a pull request.
+
+This project adheres to the `Contributor Covenant 1.2`_.
+By participating, you are expected to uphold this code. Please report
+unacceptable behavior to `info@leap.se`_.
+
+.. _`LEAP git repo`: https://leap.se/git/
+.. _`LEAP organization`: https://github.com/leapcode
+.. _`Contributor Covenant 1.2`: http://contributor-covenant.org/version/1/2/0
+.. _`info@leap.se`: info@leap.se
+
+
+Reporting bugs
+--------------
+
+Report all the bugs you can find to us! If something is not quite working yet,
+we really want to know. Reporting a bug to us is the best way to get it fixed
+quickly, and get our unconditional gratitude.
+
+It is quick, easy, and probably the best way to contribute to Bitmask
+development, other than submitting patches.
+
+**Reporting better bugs:** New to bug reporting? Here you have a `great
+document about this noble art`_.
+
+.. _`great document about this noble art`: http://www.chiark.greenend.org.uk/~sgtatham/bugs.html
+
+Where to report bugs
+~~~~~~~~~~~~~~~~~~~~
+
+We use the `LEAP Issue Tracker`_, although you can also use `Github issues`_.
+But we reaaaally prefer if you sign up in the former to send your bugs our way.
+
+.. _`LEAP Issue Tracker`: https://leap.se/code/
+.. _`Github issues`: https://github.com/leapcode/bitmask_client/issues
+
+What to include in your bug report
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+* The symptoms of the bug itself: what went wrong? What items appear broken, or
+ do not work as expected? Maybe an UI element that appears to freeze?
+* The Bitmask version you are running. You can get it by doing ``bitmask
+ --version``, or you can go to ``Help -> About Bitmask`` menu.
+* The installation method you used: bundle? from source code? debian package?
+* Your platform version and other details: Ubuntu 14.04? Debian unstable?
+ Windows 8? OSX 10.8.4? If relevant, your desktop system also (gnome, kde...)
+* When does the bug appear? What actions trigger it? Does it always happen, or
+ is it sporadic?
+* Maybe a screenshot of the problem you're seeing.
+* The exact error message, if any.
+* Attachments of the log files, if possible (see section below).
+
+Also, try not to mix several issues in your bug report. If you are
+finding several problems, it's better to issue a separate bug report for
+each one of them.
+
+Attaching log files
+~~~~~~~~~~~~~~~~~~~
+
+If you can spend a little time getting them, please add some logs to the
+bug report. They are **really** useful when it comes to debug a problem.
+To do it:
+
+Launch Bitmask in debug mode. Logs are way more verbose that way::
+
+ bitmask --debug
+
+Get your hand on the logs. You can achieve that either by clicking on
+the "Help -\> Show log" menu, and saving to file, or getting the log files from
+the config folder.
+
+Need human interaction?
+~~~~~~~~~~~~~~~~~~~~~~~
+
+You can also find us in the ``#leap`` channel on the `freenode network`_. If you
+do not have a IRC client at hand, you can `enter the channel via web`_.
+
+.. _`freenode network`: https://freenode.net
+.. _`enter the channel via web`: http://webchat.freenode.net/?nick=leaper....&channels=%23leap&uio=d4
+
+
+Pull Requests
+=============
+
+* Fork our repo
+* Work your code in a separate branch
+* Create a pull request against ``develop``
+* All tests should pass
+* The code needs to be pep8 compliant (run ``pep8 .`` from the top folder)
+* Remember to add an entry in the ``changes/`` folder, from where the CHANGELOG
+ for a given release is gathered.
+
+Git Commit Messages
+-------------------
+
+* Use the present tense ("add feature" not "added feature")
+* Use the imperative mood ("move cursor to..." not "moves cursor to...")
+* Short (50 chars or less) summary on the first line
+* Separate subject from body with a blank line
+* Wrap the body at 72 characters or less
+* Do not end the subject line with a period
+* Use the body to explain what and why vs. how
+
+For a good reference on commit messages and why does it matter see:
+http://chris.beams.io/posts/git-commit/
+
+Template for commits
+--------------------
+
+You can activate a standard template for your commits on this repo with:
+
+::
+
+ git config commit.template docs/leap-commit-template
+
+
+The template looks like this:
+
+::
+
+ [type] <subject>
+
+ <body>
+ <footer>
+
+Type should be one of the following:
+
+- bug (bug fix)
+- feat (new feature)
+- docs (changes to documentation)
+- style (formatting, pep8 violations, etc; no code change)
+- refactor (refactoring production code)
+- test (adding missing tests, refactoring tests; no production code change)
+- pkg (packaging related changes; no production code change)
+- i18n translation related changes
+
+Subject should use imperative tone and say what you did.
+For example, use 'change', NOT 'changed' or 'changes'.
+
+The body should go into detail about changes made.
+
+The footer should contain any issue references or actions.
+You can use one or several of the following:
+
+- Resolves: #XYZ
+- Related: #XYZ
+- Documentation: #XYZ
+- Releases: XYZ
+
+The Documentation field should be included in every new feature commit, and it
+should link to an issue in the bug tracker where the new feature is analyzed
+and documented.
+
+
+Example
+-------
+
+::
+
+ [feat] add soledad sync progress to the UI
+
+ Register to Soledad's sync (send and receive) events and display the
+ progress in the UI.
+
+ - Resolves: #7353
diff --git a/README.rst b/README.rst
index c2738041..0d686350 100644
--- a/README.rst
+++ b/README.rst
@@ -5,6 +5,9 @@ Bitmask
.. image:: https://badge.fury.io/py/leap.bitmask.svg
:target: http://badge.fury.io/py/leap.bitmask
+.. image:: https://img.shields.io/badge/IRC-leap-blue.svg
+ :target: http://webchat.freenode.net/?channels=%23leap&uio=d4
+ :alt: IRC
**Bitmask** is the multiplatform desktop client for the services offered by
`the LEAP Platform`_.
@@ -33,3 +36,10 @@ License
Bitmask is released under the terms of the `GNU GPL version 3`_ or later.
.. _`GNU GPL version 3`: http://www.gnu.org/licenses/gpl.txt
+
+Contributing
+============
+
+We welcome contributions! see the `Contribution guidelines
+<https://github.com/leapcode/bitmask_client/blob/develop/CONTRIBUTING.rst>`_
+
diff --git a/docker/bitmask-docker.sh b/docker/bitmask-docker.sh
index af91145b..329900f8 100755
--- a/docker/bitmask-docker.sh
+++ b/docker/bitmask-docker.sh
@@ -14,8 +14,8 @@ run(){
CREDS_OPTS="-e BITMASK_CREDENTIALS=/data/credentials.ini -v $BITMASK_CREDENTIALS:/data/credentials.ini"
fi
+ # NOTE: to use containerized VPN from the host you need to add `--net host`
docker run --rm -it \
- --net host \
--privileged \
-v /tmp/.X11-unix:/tmp/.X11-unix \
-e DISPLAY=unix$DISPLAY \
@@ -23,6 +23,7 @@ run(){
-v `pwd`/data/:/data/ -v `pwd`:/SHARED/ \
-v `pwd`/data/config:/root/.config/leap \
-p 1984:1984 -p 2013:2013 \
+ -e LEAP_DOCKERIZED=1 \
--name bitmask \
test/bitmask run $@
@@ -44,14 +45,15 @@ run(){
shell(){
xhost local:root
+ # NOTE: to use containerized VPN from the host you need to add `--net host`
docker run --rm -it \
- --net host \
--privileged \
-v /tmp/.X11-unix:/tmp/.X11-unix \
-e DISPLAY=unix$DISPLAY \
-v `pwd`/data/:/data/ -v `pwd`:/SHARED/ \
-v `pwd`/data/config:/root/.config/leap \
-p 1984:1984 -p 2013:2013 \
+ -e LEAP_DOCKERIZED=1 \
--name bitmask \
--entrypoint=bash \
test/bitmask
@@ -81,13 +83,14 @@ help() {
echo ">> Bitmask on docker"
echo "Run the bitmask app in a docker container."
echo
- echo "Usage: $0 {init bitmask.json | update | run | help }"
+ echo "Usage: $0 {init bitmask.json | update bitmask.json | build | shell | run | help}"
+ echo
+ echo " ?.json : The bitmask*.json file describes the version that will be used for each repo."
echo
echo " init : Clone repositories, install dependencies, and get bitmask ready to be used."
- echo " The bitmask.json file contains the version that will be used for each repo."
+ echo " update : Update the repositories and install new deps (if needed)."
echo " build : Build the docker image for bitmask."
echo " shell : Run a shell inside a bitmask docker container (useful to debug)."
- echo " update : Update the repositories and install new deps (if needed)."
echo " run : Run the client (any extra parameters will be sent to the app)."
echo " help : Show this help"
echo
diff --git a/relnotes.txt b/relnotes.txt
index 7a09f336..2b698771 100644
--- a/relnotes.txt
+++ b/relnotes.txt
@@ -1,9 +1,9 @@
-ANNOUNCING Bitmask 0.9.0rc2 release candidate
+ANNOUNCING Bitmask 0.9.0rc4 release candidate
The LEAP team is pleased to announce the immediate availability of Bitmask
-0.9.0rc2.
+0.9.0rc4.
-This is the second public *release candidate* of the Bitmask client that
+This is the fourth public *release candidate* of the Bitmask client that
supports our user friendly end to end encrypted mail service. Our work has
focused on speed and scale optimization by adapting the underlying components
(leap.keymanager and leap.mail) to use the new async API of Soledad. This
@@ -17,7 +17,7 @@ This is a release candidate aimed at getting more user feedback to influence
our next round of development. We have a list of known issues that we are
cranking through and will add more to the list as they come in.
-* Changelog: https://github.com/leapcode/bitmask_client/blob/0.9.0rc2/CHANGELOG.rst
+* Changelog: https://github.com/leapcode/bitmask_client/blob/0.9.0rc4/CHANGELOG.rst
TESTING
@@ -52,6 +52,6 @@ trains, rooftops, rainforests, lonely islands and, always, beyond any border.
The LEAP team,
-August 27, 2015
+October 5, 2015
Somewhere in the middle of the intertubes.
EOF
diff --git a/src/leap/bitmask/logs/utils.py b/src/leap/bitmask/logs/utils.py
index f709da8b..e38839c7 100644
--- a/src/leap/bitmask/logs/utils.py
+++ b/src/leap/bitmask/logs/utils.py
@@ -55,7 +55,7 @@ def get_logger(perform_rollover=False):
level = logbook.NOTSET
# This handler consumes logs not handled by the others
- null_handler = logbook.NullHandler(bubble=False)
+ null_handler = logbook.NullHandler()
null_handler.push_application()
silencer = SelectiveSilencerFilter()
diff --git a/src/leap/bitmask/services/mail/emailfirewall.py b/src/leap/bitmask/services/mail/emailfirewall.py
index 2cd2ec31..f7b5d7a2 100644
--- a/src/leap/bitmask/services/mail/emailfirewall.py
+++ b/src/leap/bitmask/services/mail/emailfirewall.py
@@ -34,6 +34,11 @@ def get_email_firewall():
"""
Return the email firewall handler for the current platform.
"""
+ # disable email firewall on a docker container so we can access from an
+ # external MUA
+ if os.environ.get("LEAP_DOCKERIZED"):
+ return None
+
if not (IS_LINUX):
error_msg = "Email firewall not implemented for this platform."
raise NotImplementedError(error_msg)
diff --git a/src/leap/bitmask/services/soledad/soledadbootstrapper.py b/src/leap/bitmask/services/soledad/soledadbootstrapper.py
index 57ae3849..f3d50925 100644
--- a/src/leap/bitmask/services/soledad/soledadbootstrapper.py
+++ b/src/leap/bitmask/services/soledad/soledadbootstrapper.py
@@ -253,6 +253,7 @@ class SoledadBootstrapper(AbstractBootstrapper):
logger.warning(msg)
continue
+ self._signaler.signal(self._signaler.soledad_bootstrap_failed)
logger.exception(exc)
raise SoledadInitError()
@@ -622,10 +623,10 @@ class Syncer(object):
logger.debug("BOOTSTRAPPER: trying to sync Soledad....")
# pass defer_decryption=False to get inline decryption
# for debugging.
- self._sync_deferred = self._soledad.sync(defer_decryption=True)
- self._sync_deferred.addCallbacks(self._success, self._error)
self._timeout_delayed_call = reactor.callLater(self.WAIT_MAX_SECONDS,
self._timeout)
+ self._sync_deferred = self._soledad.sync(defer_decryption=True)
+ self._sync_deferred.addCallbacks(self._success, self._error)
def _success(self, result):
logger.debug("Soledad has been synced!")
@@ -668,5 +669,6 @@ class Syncer(object):
self._try_sync()
else:
logger.error("Sync failed {0} times".format(self._tries))
+ self._signaler.signal(self._signaler.soledad_bootstrap_failed)
self._callback_deferred.errback(
SoledadSyncError("Too many retries"))