summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/util/__init__.py
diff options
context:
space:
mode:
authorTomás Touceda <chiiph@leap.se>2014-01-12 18:44:34 -0300
committerTomás Touceda <chiiph@leap.se>2014-01-12 18:44:34 -0300
commit001dfc4d5c994f60504ab626927a9711449ab9c6 (patch)
tree57a021f22815943bfdeea09e2b47208a4789935e /src/leap/bitmask/util/__init__.py
parent8dc5ed97f10e01f92aea23439aa749c480a29a56 (diff)
parent6cc752e403e08795273270f637ed212270d2eaef (diff)
Merge remote-tracking branch 'refs/remotes/kali/feature/offline-mode' into develop
Diffstat (limited to 'src/leap/bitmask/util/__init__.py')
-rw-r--r--src/leap/bitmask/util/__init__.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/leap/bitmask/util/__init__.py b/src/leap/bitmask/util/__init__.py
index b58e6e3b..85676d51 100644
--- a/src/leap/bitmask/util/__init__.py
+++ b/src/leap/bitmask/util/__init__.py
@@ -76,3 +76,16 @@ def is_empty_file(path):
Returns True if the file at path is empty.
"""
return os.stat(path).st_size is 0
+
+
+def make_address(user, provider):
+ """
+ Return a full identifier for an user, as a email-like
+ identifier.
+
+ :param user: the username
+ :type user: basestring
+ :param provider: the provider domain
+ :type provider: basestring
+ """
+ return "%s@%s" % (user, provider)