# Cannot edit connections with network-manager

## Princess Nell

Trying to edit wired connections with the nm-applet, the keyring symbol on the "Edit" and "Delete" buttons indicates that authentication is required to perform these actions. But it doesn't work here. ~/.xsession-errors logs:

 *Quote:*   

> 
> 
> ** (nm-connection-editor:6305): WARNING **: Caught error: Method "ObtainAuthorization" with signature "suu" on interface "org.freedesktop.PolicyKit.AuthenticationAgent" doesn't exist
> 
> 

 

Emerging dbus and network-manager did not help. gnome-keyring-daemon is running, so what did I miss?

----------

## Rexilion

huh? org.freedesktop.PolicyKit.AuthenticationAgent is what it's looking for, but I have: org.freedesktop.PolicyKit1.AuthenticationAgent. Are you mixing stable with unstable?

----------

## Princess Nell

I'm on stable. I've never used unstable.

Are there any files/directories I could remove to have them recreated at the next login?

----------

## Rexilion

Did you do:

```
etc-update
```

??

----------

## Princess Nell

Never do  :Smile:  But I have my own method of updating /etc files and they are therefore up to date.

 *Quote:*   

> 
> 
> #  etc-update 
> 
> Scanning Configuration files...
> ...

 

----------

## Rexilion

Ok, can you post the output of:

```
emerge -pv polkit networkmanager
```

please?

----------

## Princess Nell

```

# emerge -pv polkit networkmanager

These are the packages that would be merged, in order:

Calculating dependencies... done!

!!! All ebuilds that could satisfy "sys-auth/polkit" have been masked.

!!! One of the following masked packages is required to complete your request:

- sys-auth/polkit-0.96-r1 (masked by: ~x86 keyword)

- sys-auth/polkit-0.96 (masked by: ~x86 keyword)

For more information, see the MASKED PACKAGES section in the emerge

man page or refer to the Gentoo Handbook.

# 

```

I have net-misc/networkmanager-0.7.2 and sys-auth/policykit-0.9-r1 installed, no polkit. Now I'm wondering if https://forums.gentoo.org/viewtopic-t-826538-highlight-.html could be related.

If polkit is required, why is it masked?

----------

## Rexilion

Polkit provides that file which contains org.freedesktop.PolicyKit1.AuthenticationAgent so I thought it could have helped you too.

Can you post the output of only:

```
emerge -pv networkmanager
```

and:

```
grep -iR policykit /etc/dbus-1/
```

please?

----------

## Princess Nell

```

# emerge -pv networkmanager ; grep -iR policykit /etc/dbus-1/

These are the packages that would be merged, in order:

Calculating dependencies... done!

[ebuild   R   ] net-misc/networkmanager-0.7.2  USE="avahi resolvconf -connection-sharing -dhclient -dhcpcd -doc -gnutls -nss" 0 kB

Total: 1 package (1 reinstall), Size of downloads: 0 kB

/etc/dbus-1/system.d/org.freedesktop.PolicyKit.conf:    <allow own="org.freedesktop.PolicyKit"/>

/etc/dbus-1/system.d/org.freedesktop.PolicyKit.conf:    <allow send_destination="org.freedesktop.PolicyKit"/>

/etc/dbus-1/system.d/hal.conf:  <!-- Policykit regulates actual access -->

/etc/dbus-1/system.d/nm-system-settings.conf:           interface is secured via PolicyKit.

# 

```

----------

## Rexilion

Okay, long shot, please *do* try and install polkit...

----------

## Princess Nell

No luck  :Sad: 

I had to unmask gtk-doc-am, eggdbus and consolekit to install polkit. Then I moved the new /etc/dbus-1/system.d/ConsoleKit.conf into place instead of merging it, with the effect that the shutdown button on the panel was grayed out. Re-applying (a form of) the fix from https://bugs.gentoo.org/show_bug.cgi?id=274287 made it functional again, but no luck with nm.

Hhm, I just noticed that the nm applet isn't running, and /var/log/messages says

```

May  6 21:42:04 localhost NetworkManager: <WARN>  list_connections_cb(): Couldn't retrieve connections: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken..

```

Looks like it's getting ugly  :Wink: 

----------

## Princess Nell

Rebooted and nm-applet is back. Still no connection editing.

----------

## Rexilion

Damn :/ . I think you just need to reïnstall and merge config files with etc-update. I have no more clues about what to be done. You could consider deleting networkmanager and nm-applet and emerging them again but that is my last guess....

----------

## Princess Nell

Did that, removed and re-emerged the whole lot - consolekit, dbus, and so on. No change.

I guess I'll have to leave it at that for now.

----------

## Raptor85

I can't test this here (windows box at work), so this is little more than a wild guess...

Maybe the new build of networkmanager changed to use the polkit package you installed. It looks like 0.8 is in portage now (based on the website). Maybe try adding networkmanager-0.8 to your package.keywords and see if that version does the trick?

----------

## Princess Nell

You could say that it helped ... the nm-applet has now disappeared!  :Wink: 

Trying to emerge it again ... fails.

```

 * ERROR: gnome-extra/nm-applet-0.7.2 failed:

 *   econf failed

 * 

 * Call stack:

 *     ebuild.sh, line   54:  Called src_configure

 *   environment, line 3170:  Called gnome2_src_configure

 *   environment, line 2490:  Called econf '--disable-more-warnings' '--localstatedir=/var' '--with-dbus-sys=/etc/dbus-1/system.d'

 *     ebuild.sh, line  544:  Called die

 * The specific snippet of code:

 *            die "econf failed"

 * 

```

Adding it to package.keywords, trying again. Required unmasking net-misc/mobile-broadband-provider-info, which in turn required unmasking gnome-extra/polkit-gnome, which required net-wireless/gnome-bluetooth. Which is where it ends because the final package is blocked by net-wireless/bluez-gnome, which I need.

----------

## Rexilion

 *Princess Nell wrote:*   

> You could say that it helped ... the nm-applet has now disappeared! 
> 
> Trying to emerge it again ... fails.
> 
> ```
> ...

 

You are trying to compile nm-applet 0.7.2 against networkmanager 0.8.0 which is not good. Furthermore, to disable the bluetooth dependency, disable it's bluetooth USE.

----------

## Princess Nell

I think I'll just wait instead for dbus-glib-0.84.

https://bugs.gentoo.org/show_bug.cgi?id=298511

----------

## Rexilion

Good job, why didn't I think of that  :Razz:   :Mr. Green:  .

----------

## Princess Nell

dbus-glib-0.86 was just released, and it was worth the wait - problem gone!   :Very Happy: 

----------

