Permits and primary group updates

Moved primary group to an id in user table, implemented interface for
changing a user's primary group, added some more default permission
settings for groups.