Results 1 to 4 of 4

Thread: app which ask authentication at startup

  1. #1
    jfouche NNTP User

    Default app which ask authentication at startup

    Hi everybody

    I'm new to Linux (OpenSUSE), and I have to create a software for it. This is a graphical software.
    My soft must change the local ip of the computer. I think I will use the following script :
    Code:
    /sbin/ifconfig eth0 192.168.1.10 netmask 255.255.250.0
    (for example), in the background of my app. But I think that I need to be a super user (or my app must be launched under sudo).
    Am I right ?
    If 'yes', what is the way to be sure that my app ask the superuser password at startup (like when I launch YaST) ?

    Sorry if this is not the good forum to ask this kind of question.
    --
    Jrmie

  2. #2

    Default Re: app which ask authentication at startup

    Take a look at the Pluggable Authentication Modules(PAM) for Linux. Do a 'man pam' which explains how this works with the config files(/etc/pam.d/ or /etc/pam.conf).

  3. #3

    Default Re: app which ask authentication at startup

    Depends. In yast, you can configure your network devices to allow non-root users to control them. This is enabled for default installs because of knetworkmanager. If someone went through the trouble to change the network settings, then you would run into this problem and would need to run via sudo for the script to run under non-root users.

  4. #4
    Join Date
    Jun 2008
    Location
    Germany
    Posts
    301

    Default Re: app which ask authentication at startup

    Hi,

    there are several was to do this, but I guess you are looking so kdesu (gnomesu on gnome) which uses yast for it's root authentication. It's very easy to use this just create a link to the program (right click and choose link to program) and in the tab where you choose the executable there is something like advanced configuration there you can select a different user for execution.

    Maybe you also want to have a look a sudo.

    Hope this helps

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •