Backport SecurePoll bugfixes

Change-Id: I342ac8b9f5017e83bac06f5370031a574674a9df