Usage of email on Android
This commit is contained in:
parent
6bdbcdeb95
commit
dcc2592c83
166
doc/EN/usage.org
166
doc/EN/usage.org
|
@ -206,8 +206,168 @@ By default you won't be able to see any folders which you may have created earli
|
|||
Make sure that "*show only subscribed folders*" is not checked. Then click the *ok* buttons. Folders will be re-scanned, which may take some time depending upon how much email you have, but your folders will then appear.
|
||||
|
||||
** K9 Android client
|
||||
*NOTE*: Currently the K9 email client will not work with the Freedombone since it doesn't support PGP/MIME encoding. However, there is development work taking place on that feature and it is hoped that K9 may be usable in the near future.
|
||||
*** A point about GPG on Android
|
||||
Before trying to set up email on Android you may want to consider whether you really need to do this. Android (and its variants) is not a particularly secure operating system and whether or not you wish to store GPG keys on it depends on your threat model and in what situations you'll be using your device.
|
||||
|
||||
If you are going to use email on an Android device then ensure that you have full encryption enabled via the security settings, so that if you subsequently lose it, or if it gets stolen, the chances of encryption keys being exposed are minimised.
|
||||
*** Compiling the development version
|
||||
To get K9 working with Freedombone you'll need to install development versions of OpenKeychain and K9. At the time of writing the versions available in F-Droid do not support PGP/MIME or the "hidden recipient" feature of GPG. It is hoped that at some stage the patches will be integrated into the mainline or functionally equivalent changes made. Admittedly, this is not at all user friendly, but currently it's the only way to read Freedombone email on Android systems.
|
||||
|
||||
Build script for OpenKeychain:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
#!/bin/bash
|
||||
|
||||
# This script is intended to be used on Debian systems for building
|
||||
# the project. It has been tested with Debian 8
|
||||
|
||||
USERNAME=$USER
|
||||
SIGNING_NAME='openkeychain'
|
||||
SDK_VERSION='r23.3.4'
|
||||
SDK_DIR=$HOME/android-sdk
|
||||
|
||||
cd ..
|
||||
|
||||
PROJECT_HOME=$(pwd)
|
||||
|
||||
sudo apt-get install build-essential default-jdk \
|
||||
lib32stdc++6 lib32z1 lib32z1-dev
|
||||
|
||||
if [ ! -d $SDK_DIR ]; then
|
||||
mkdir -p $SDK_DIR
|
||||
fi
|
||||
cd $SDK_DIR
|
||||
|
||||
# download the SDK
|
||||
if [[ ! -f $SDK_DIR/android-sdk_$SDK_VERSION-linux.tgz ]]; then
|
||||
wget https://dl.google.com/android/android-sdk_$SDK_VERSION-linux.tgz
|
||||
fi
|
||||
tar -xzvf android-sdk_$SDK_VERSION-linux.tgz
|
||||
SDK_DIR=$SDK_DIR/android-sdk-linux
|
||||
|
||||
echo 'Check that you have the SDK tools installed for Android 22, SDK 21.1.2'
|
||||
|
||||
export ANDROID_HOME=$SDK_DIR
|
||||
echo "sdk.dir=$SDK_DIR" > $ANDROID_HOME/local.properties
|
||||
export PATH=${PATH}:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools
|
||||
|
||||
cd $SDK_DIR/tools
|
||||
./android sdk
|
||||
|
||||
if [ ! -f $SDK_DIR/tools/android ]; then
|
||||
echo "$SDK_DIR/tools/android not found"
|
||||
exit -1
|
||||
fi
|
||||
cd $SDK_DIR
|
||||
chmod -R 0755 $SDK_DIR
|
||||
chmod a+rx $SDK_DIR/tools
|
||||
|
||||
# android sdk
|
||||
cd $PROJECT_HOME
|
||||
git submodule init && git submodule update
|
||||
|
||||
if [ ! -f $SDK_DIR/tools/templates/gradle/wrapper/gradlew ]; then
|
||||
echo "$SDK_DIR/tools/templates/gradle/wrapper/gradlew not found"
|
||||
exit -2
|
||||
fi
|
||||
. $PROJECT_HOME/gradlew assembleDebug
|
||||
|
||||
# cleaning up
|
||||
cd $PROJECT_HOME/OpenKeychain/build/outputs/apk
|
||||
if [ ! -f OpenKeychain-debug.apk ]; then
|
||||
echo 'OpenKeychain-debug.apk was not found'
|
||||
exit -3
|
||||
fi
|
||||
|
||||
echo 'Build script ended successfully'
|
||||
echo -n 'apk is available at: '
|
||||
echo "$PROJECT_HOME/OpenKeychain/build/outputs/apk/OpenKeychain-debug.apk"
|
||||
exit 0
|
||||
#+END_SRC
|
||||
|
||||
Build script for K9:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
#!/bin/bash
|
||||
|
||||
# This script is intended to be used on Debian systems for building
|
||||
# the project. It has been tested with Debian 8
|
||||
|
||||
USERNAME=$USER
|
||||
SIGNING_NAME='k-9'
|
||||
SDK_VERSION='r24.3.3'
|
||||
SDK_DIR=$HOME/android-sdk
|
||||
|
||||
cd ..
|
||||
|
||||
PROJECT_HOME=$(pwd)
|
||||
|
||||
sudo apt-get install build-essential default-jdk \
|
||||
lib32stdc++6 lib32z1 lib32z1-dev
|
||||
|
||||
if [ ! -d $SDK_DIR ]; then
|
||||
mkdir -p $SDK_DIR
|
||||
fi
|
||||
cd $SDK_DIR
|
||||
|
||||
# download the SDK
|
||||
if [ ! -f $SDK_DIR/android-sdk_$SDK_VERSION-linux.tgz ]; then
|
||||
wget https://dl.google.com/android/android-sdk_$SDK_VERSION-linux.tgz
|
||||
tar -xzvf android-sdk_$SDK_VERSION-linux.tgz
|
||||
fi
|
||||
SDK_DIR=$SDK_DIR/android-sdk-linux
|
||||
|
||||
echo 'Check that you have the SDK tools installed for Android 17, SDK 19.1'
|
||||
if [ ! -f $SDK_DIR/tools/android ]; then
|
||||
echo "$SDK_DIR/tools/android not found"
|
||||
exit -1
|
||||
fi
|
||||
cd $SDK_DIR
|
||||
chmod -R 0755 $SDK_DIR
|
||||
chmod a+rx $SDK_DIR/tools
|
||||
|
||||
ANDROID_HOME=$SDK_DIR
|
||||
echo "sdk.dir=$SDK_DIR" > $ANDROID_HOME/local.properties
|
||||
PATH=${PATH}:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools
|
||||
|
||||
android sdk
|
||||
cd $PROJECT_HOME
|
||||
|
||||
if [ ! -f $SDK_DIR/tools/templates/gradle/wrapper/gradlew ]; then
|
||||
echo "$SDK_DIR/tools/templates/gradle/wrapper/gradlew not found"
|
||||
exit -2
|
||||
fi
|
||||
. $PROJECT_HOME/gradlew assembleDebug
|
||||
|
||||
# cleaning up
|
||||
cd $PROJECT_HOME/k9mail/build/outputs/apk
|
||||
if [ ! -f k9mail-debug.apk ]; then
|
||||
echo 'k9mail-debug.apk was not found'
|
||||
exit -3
|
||||
fi
|
||||
echo 'Build script ended successfully'
|
||||
echo -n 'apk is available at: '
|
||||
echo "$PROJECT_HOME/k9mail/build/outputs/apk/k9mail-debug.apk"
|
||||
exit 0
|
||||
#+END_SRC
|
||||
|
||||
*** Import your GPG key into OpenKeychain
|
||||
With your device connected to a laptop via USB cable and with USB debugging enabled on it:
|
||||
|
||||
#+BEGIN_SRC bash
|
||||
ssh username@domainname -p 2222
|
||||
gpg --list-keys username@domainname
|
||||
gpg --output ~/public_key.gpg --armor --export KEY_ID
|
||||
gpg --output ~/private_key.gpg --armor --export-secret-key KEY_ID
|
||||
cat ~/public_key.gpg ~/private_key.gpg > ~/mygpgkey.asc
|
||||
exit
|
||||
scp -P 2222 username@domainname:/home/username/mygpgkey.asc ~/
|
||||
sudo apt-get install android-tools-adb
|
||||
push ~/mygpgkey.asc /sdcard/
|
||||
shred -zu ~/mygpgkey.asc
|
||||
#+END_SRC
|
||||
|
||||
Then on your device select OpenKeychain and import your key from file.
|
||||
*** Incoming server settings
|
||||
* Select settings/account settings
|
||||
* Select Fetching mail/incoming server
|
||||
|
@ -225,6 +385,10 @@ Make sure that "*show only subscribed folders*" is not checked. Then click the
|
|||
* Set authentication to PLAIN
|
||||
* Enter your username and password
|
||||
* Accept the SSL certificate
|
||||
*** Crypto settings
|
||||
Select *settings*, *Account settings*, *OpenKeychain* and then select your key and press *Allow*. You should now be able to decrypt emails by entering your GPG passphrase.
|
||||
|
||||
You may also want to change the amount of time for which passwords are remembered, so that you don't need to enter your passphrase very often.
|
||||
*** Folders
|
||||
To view any new folders which you may have created using the /mailinglistrule/ script from your inbox press the *K9 icon* at the top left to access folders, then press the *menu button* and select *refresh folder list*.
|
||||
|
||||
|
|
Loading…
Reference in New Issue