Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Show Fedora 17 Gnome authentication dialog
Forum Updated to NodeBB v4.3 + New Features

Show Fedora 17 Gnome authentication dialog

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 2.4k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • napajejenunedk0N Offline
    napajejenunedk0N Offline
    napajejenunedk0
    wrote on last edited by
    #1

    I want to execute a terminal command that requires root privileges through QProcess or the system() function. For example:
    @
    QProcess process;
    process.start("su -c "cp -f -r /home/<user>/file.txt /etc"");
    while( process.waitForFinished());
    @

    ... or ...:
    @
    system("su -c "cp -f -r /home/<user>/file.txt /etc"");
    @

    "su" is a command-line interface command for providing root privileges. I want to use a "gksu", "kdesu", "beesu" - a GUI equivalent of the command-line interface in Fedora 17 Gnome to ask the user for the root's password.

    I know that "beesu" could be installed additionally and thus provide the desired GUI interface, but it should be installed additionally. I want to use a GUI password authentication dialog that comes in Fedora 17 Gnome by default.

    When you install packages through the "Add/Remove Software" tool in Fedora, it asks you for the administrator/root password through a GUI interface:
    http://dox.bg/files/dw?a=c6fa01baa9

    This is the interface I want to use and call. Is this interface integrated in the "Add/Remove Software" tool or is it a separate program that can be called by any other program?

    Regards

    1 Reply Last reply
    0
    • ? Offline
      ? Offline
      A Former User
      wrote on last edited by
      #2

      Hi,

      I believe this is what you're looking for: "How to get applications running with root privileges":http://qt-project.org/wiki/How_to_get_applications_running_with_root_privileges

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved