Override only the updated "User" methods in "patch_auth"

The function "patch_auth" creates a fake class to override the existing
kimchi.auth.User with a few updated methods. That attribution overrides
the entire User class along with all its methods.

In order to avoid side effects, override only the methods we need to
change in the "User" class. Other methods not related to "patch_auth"
will not be affected now.
Use proper term "user name" instead of "user id"

In the Linux environment, a user ID is an integer code which identifies
a user; a user name is the human friendly text identifier of that user.
Kimchi uses both terms interchangeably.

Rename all occurrences of "userid" (and its variants) to "username" (and
its variants) in external UI messages and internal code.

Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com>
Signed-off-by: Aline Manera <alinefm@br.ibm.com>
Add functions to check if a user/group exists

The user/group validation is done on the current system.

Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com>
Signed-off-by: Aline Manera <alinefm@br.ibm.com>
Return users and groups when fetching VM info

In order to have more control over what users can use a virtual machine
under Kimchi, a VM should have users and groups associated with it.

Kimchi uses metadata information
(http://libvirt.org/formatdomain.html#elementsMetadata) to store users
and groups to the virtual machines. The data is stored as string
representations of Python lists.
Keep in mind that these security restrictions will not apply when using
other virtual machine managers (e.g. virsh, virt-manager, etc).

Users and groups stored in the VM are now returned when the user queries the
VM data. Currently, there is no way to associate users and groups to a VM.

The REST command below now returns the users and groups of every virtual machine:

/vms/:name GET: It now lists the users and groups associated with that VM.

{
  "users":[
    "user1",
    "user2"
  ],
  "groups":[
    "group1",
    "group2"
  ],
...
}

If there is no metadata information about users and groups, empty lists
will be displayed

Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com>
Signed-off-by: Aline Manera <alinefm@br.ibm.com>
Add/remove users and groups to VMs

To update (add/remove) the users and groups of a virtual machine, you
should use the REST command:

/vms/<vm_name> PUT "{ 'users': [ 'user1', 'user2' ],
                      'groups': [ 'group1', 'group2' ] }"

Users and groups associated with a virtual machine must be valid when
they are
added to the VM. Such verification is not done when they are removed
from the
system. This means that virtual machines may contain outdated
information about
users and groups.

Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com>
Signed-off-by: Aline Manera <alinefm@br.ibm.com>