+Mon Mar 23 17:33:17 CET 2009 Daniel Veillard <veillard@redhat.com>
+
+ * src/virsh.c: fix missing authentication when command are issued
+ from the shell, patch by Matthias Bolte
+
Fri Mar 20 21:43:57 CET 2009 Daniel Veillard <veillard@redhat.com>
* src/util.c: flag unused parameters, by Maximilian Wilhelm
ctl->name = vshStrdup(ctl, vshCommandOptString(cmd, "name", NULL));
if (!ro) {
- ctl->conn = virConnectOpen(ctl->name);
ctl->readonly = 0;
} else {
- ctl->conn = virConnectOpenReadOnly(ctl->name);
ctl->readonly = 1;
}
+ ctl->conn = virConnectOpenAuth(ctl->name, virConnectAuthPtrDefault,
+ ctl->readonly ? VIR_CONNECT_RO : 0);
+
if (!ctl->conn)
vshError(ctl, FALSE, "%s", _("Failed to connect to the hypervisor"));
flags |= VIR_MIGRATE_LIVE;
/* Temporarily connect to the destination host. */
- dconn = virConnectOpen (desturi);
+ dconn = virConnectOpenAuth (desturi, virConnectAuthPtrDefault, 0);
if (!dconn) goto done;
/* Migrate. */