Revert "selinux rewrite"

This reverts commit 4019f98017d6faf1401c0c2cd18e0aa90964f859.

Change-Id: I85e5c73bce3cfbbb666bbf76ff303325b8fdee17