[Gambas-user] How to authenticate and switch to root user from within gambas application?

Jose J. Rodriguez joe1962 at ...626...
Wed Oct 4 15:38:07 CEST 2006


On 10/4/06, Benoit Minisini <gambas at ...1...> wrote:
> On Wednesday 04 October 2006 08:35, Jose J. Rodriguez wrote:
> > On 10/4/06, Fabien Bodard <gambas.fr at ...626...> wrote:
> > > look at the console example !
> > >
> > > you can run a virtual shell and then execute something in it !
> > >
> > > maybe it can work ! And you need it as the instance for the program need
> > > to be the same as the su one !
> >
> > Checked out the console example. I'm afraid running "su" in it gives
> > the same error as SHELL: "su: su must be run from a terminal".
> >
> > Regards,
> > Joe1962
> >
>
> In the development version, you can EXEC or SHELL application in a virtual
> terminal when they are needed:
>
> EXEC [ "su" ] FOR INPUT OUTPUT
>
> instead of EXEC [ "su" ] FOR READ WRITE
>
> Then 'su' should not complain anymore, and you will be able to send it login
> and password.
>

I'll give it a try, but I'm trying to stick to 1.0.x for utilities to
be included as part of the next Vector Linux release, 1.9.x is still
changing to much... ;)

> The better, and maybe only good solution is to configurate and use the 'sudo'
> command. Because it is better for security reason to centralize all
> applications that need to be run as root and to define which users can use
> them.
>

Basically, I'm trying to replace gksu in the menu items of
configuration utilities for the upcoming Standard version of Vector
Linux, which will be XFCE only. Other options won't work because they
need kdelibs (maybe even more) in the case of kdesu, or quite a bit of
gnome in all the others, including the new gksu 2.0. It just happens
that gksu 1.x does not handle being called as root very well, it
simply hangs. This bug would mean separating the root and user menus,
something that could be done for the apps inside the iso, but is a lot
more trouble for any package to be installed or upgraded from the
repository.

Regards,
Joe1962




More information about the User mailing list