Prevent NullPointerException from account in SecurityFunctions
Merge pull request #546 from zanata/avoid-null-account

Avoid NullPointerExceptions for null accounts in SecurityFunctions