[one-users] oneuser key command failing

Ruben S. Montero rsmontero at opennebula.org
Fri Jul 27 14:46:52 PDT 2012


Hi,

Looking at the code, the key argument is there for historical reasons, the
login option should be used instead as it generates a properly formatted
password and ONE_AUTH file, and it supports several auth methods ssh,
x509...

That's the reason for having this command not updated to the new auth
classes, and so the bug in 'key'.

I'll upload the fix so it will work and deprecate the command option so we
will finally remove it in 4.0.

Thanks!

Ruben

On Fri, Jul 27, 2012 at 11:21 AM, Daniel Molina <dmolina at opennebula.org>wrote:

> Hi,
>
> On 26 July 2012 01:41, Rogier Mars <rogier at fortytwo.nl> wrote:
> > I just upgrade to opennebula 3.6 (from the rpm's for CentOS) and decided
> to give ssh authentication a try. While following the documentation the
> step to output the public key failed:
> >
> > [root at cloudcontroller1 rogierm]# oneuser key
> > Enter PEM pass phrase:
> > /usr/bin/oneuser:250: undefined method `public_key' for
> #<SshAuth:0x7ffc04405ff8> (NoMethodError)
> >         from /usr/lib/one/ruby/cli/command_parser.rb:173:in `call'
> >         from /usr/lib/one/ruby/cli/command_parser.rb:173:in `run'
> >         from /usr/lib/one/ruby/cli/command_parser.rb:79:in `initialize'
> >         from /usr/bin/oneuser:36:in `new'
> >         from /usr/bin/oneuser:36
> >
> > I had a quick look at the code and method "public_key" that is
> referenced in oneuser line 250 does not exist in the file
> /usr/lib/one/ruby/ssh_auth.rb. There is a method password that seems to
> print the public key. I've changed line 250 in oneuser to the following:
> >
> > #        puts sshauth.public_key
> >         puts sshauth.password
> >
> > When I run "oneuser key" now the correct public key is displayed.
>
> Indeed, that is a bug. I have opened a bug to fix it:
> http://dev.opennebula.org/issues/1396
>
> Thanks for your feedback
>
> --
> Daniel Molina
> Project Engineer
> OpenNebula - The Open Source Solution for Data Center Virtualization
> www.OpenNebula.org | dmolina at opennebula.org | @OpenNebula
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>



-- 
Ruben S. Montero, PhD
Project co-Lead and Chief Architect
OpenNebula - The Open Source Solution for Data Center Virtualization
www.OpenNebula.org | rsmontero at opennebula.org | @OpenNebula
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20120727/3d8a9897/attachment-0003.htm>


More information about the Users mailing list