Merge pull request #304 from Atheros1/master

[Minor] Move one line of code so that correct program activity is logged
Merge pull request #306 from Atheros1/master

Key file permissions
Merge pull request #297 from mybluevan/master

Adding configuration to listen for incoming connections when connected via SOCKS proxy
Merge pull request #307 from Atheros1/master

Store msgid in sent table
Correct indent on a single line