Add create_permission to ensure that permissions are created with the correct type.

This function creates and returns a permission object of the correct
class (Permission vs. WildcardPermission). As such, it is useful for
creating a permission where you do not know at compile time whether it
is a Permission or WildcardPermission. In the event of id conflicts
(the permission already exists), this function returns False.

Signed-off-by: Tyler O'Meara <Tyler@TylerOMeara.com>