check for correct perms