Re: [Users] Authentication for REST APIs?

2012-10-03 Thread Brian Vetter
On Oct 3, 2012, at 12:55 AM, Itamar Heim wrote: snip ... So based upon what I see in this log file, it would seem that the connect API wants to make sure that I am an admin and not a regular user. Which gets me back to my original question: Do the REST API and the ovirt-shell require

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Itamar Heim
On 10/02/2012 06:28 AM, Brian Vetter wrote: I've done two different things. First, I associated one of my groups in my directory with being a VMUser which gave members access to a particular VM. If I login with one of those users via the User portal, I can see their VM (or VMs if I do more

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Steve Gordon
- Original Message - From: Itamar Heim ih...@redhat.com To: Brian Vetter bjvet...@gmail.com Cc: users@ovirt.org Sent: Tuesday, October 2, 2012 3:15:34 AM Subject: Re: [Users] Authentication for REST APIs? On 10/02/2012 06:28 AM, Brian Vetter wrote: I've done two different things

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Itamar Heim
On 10/02/2012 03:56 PM, Steve Gordon wrote: - Original Message - From: Itamar Heim ih...@redhat.com To: Brian Vetter bjvet...@gmail.com Cc: users@ovirt.org Sent: Tuesday, October 2, 2012 3:15:34 AM Subject: Re: [Users] Authentication for REST APIs? On 10/02/2012 06:28 AM, Brian Vetter

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Brian Vetter
Adding the Filter:true header to the curl request doesn't change anything. If the user account is not an admin account, I get a 401 status result. So my question still stands, can the REST API be used by a mere, non-admin mortal or is it only for administrative functions? I'm in the process of

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Itamar Heim
On 10/02/2012 04:52 PM, Brian Vetter wrote: Adding the Filter:true header to the curl request doesn't change anything. If the user account is not an admin account, I get a 401 status result. So my question still stands, can the REST API be used by a mere, non-admin mortal or is it only for

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Brian Vetter
3.1 added support for non admin to use the api. i.e., this should work. which specific version are you using? From the about box in the admin web app: oVirt Engine Version: 3.1.0-2.fc17 The curl command I send is: curl --cacert $CA_FILE -X GET -H Filter: true -u user@domain:password

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Brian Vetter
I also tried a simple connect to the home of the ovirt server in the ovirt-shell: [oVirt shell (disconnected)]# connect https://ovirtserver user pass error: 'str' object has no attribute 'product_info' [oVirt shell (disconnected)]# So this happens without trying to get to the api/vms. As to

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Michael Pasternak
Hi Brian, On 10/02/2012 05:52 PM, Brian Vetter wrote: I also tried a simple connect to the home of the ovirt server in the ovirt-shell: [oVirt shell (disconnected)]# connect https://ovirtserver user pass error: 'str' object has no attribute 'product_info' this could happen if

Re: [Users] Authentication for REST APIs?

2012-10-02 Thread Itamar Heim
On 10/03/2012 05:40 AM, Brian Vetter wrote: The error: 'str' object has no attribute 'product_info' was a red herring (mistyped url). The 401 errors for non-admins though is still quite real. Detailed response inside ... On Oct 2, 2012, at 1:48 PM, Michael Pasternak wrote: Hi Brian, On

Re: [Users] Authentication for REST APIs?

2012-10-01 Thread Yair Zaslavsky
Hi Brian, I looked at the wiki - I assume you're referring to the showVm part. Have you assigned any permissions to the user that is supposed to view the VMs? I assume you created the VMs with the administrator user, so any other user will require to have a proper permissions in order to view

Re: [Users] Authentication for REST APIs?

2012-10-01 Thread Brian Vetter
I've done two different things. First, I associated one of my groups in my directory with being a VMUser which gave members access to a particular VM. If I login with one of those users via the User portal, I can see their VM (or VMs if I do more than one). If I use the REST API (or