Commit Graph

7740 Commits

Author SHA1 Message Date
Dan Winship
8a2267ab6b Fix a few misc issues noticed by Coverity 2012-04-05 13:30:09 -04:00
Daniel Nylander
6a1208b526 po: updated Swedish translation (bgo #673234) 2012-04-03 15:47:43 +02:00
Kristjan SCHMIDT
ee04badfc2 po: updated Esperanto translation (bgo #673353) 2012-04-03 15:40:22 +02:00
Fran Diéguez
73c9112f27 po: updated Galician translation (bgo #672597) 2012-04-03 15:31:20 +02:00
Jiří Klimeš
fe3f010044 ifcfg-rh: clear MACADDR before writing it in wired setting (bgo #672646)
Else it's not possible to delete Cloned MAC (e.g. in the editor).
2012-04-03 14:57:31 +02:00
Jiří Klimeš
8bb2789444 libnm-glib: initialize GError, else invalid free() crash can occur (rh #809123) 2012-04-02 16:37:55 +02:00
Jiří Klimeš
75de2034c8 trivial: whitespace fixes 2012-04-02 13:08:19 +02:00
Jiří Klimeš
2b879e3a33 Revert "libnm-glib: initialize NMRemoteSettings in nm_remote_settings_new() (rh #806664)"
This reverts commit dd0460697c.

The commit dd0460697c make nm_remote_settings_new()
create the NMRemoteSettings object synchronously. It fixed getting properties,
but undid the previous ability to initialize the object asynchronously.
It can be reverted now, because a4f450aa0b commit
ensure initialization in get_property() calls.
2012-04-02 12:58:19 +02:00
Jiří Klimeš
47f9eb80d8 core: call is_adhoc_wpa() only after we check '802-11-wireless' setting
This prevents assertion while checking a connection that is not a wireless one.
2012-04-02 12:57:30 +02:00
Daniel Nylander
02482101ff po: updated Swedish translation (bgo #671096) 2012-03-30 13:17:11 +02:00
Matej Urbančič
71e5ad27f7 po: updated Slovenian translation (bgo #671775) 2012-03-30 13:09:57 +02:00
Jiří Klimeš
6b64e4db2f ppp: don't use struct ifpppstatsreq that was removed from linux/ip_ppp.h
in recent kernels.

We can use ifreq and ppp_stats structures separately. They needn't have to
to be packed in a structure.
2012-03-28 17:03:19 +02:00
Dan Winship
a4f450aa0b libnm-glib: more ensure_inited() fixing
We need to do _nm_object_ensure_inited() /
_nm_remote_settings_ensure_inited() from the get_property()
implementations; in most cases, get_property() just calls another
accessor method (which will call _nm_object_ensure_inited()), but in a
few places, it reads priv->whatever directly, so we need to make sure
that it's valid.
2012-03-28 09:06:12 -04:00
Jiří Klimeš
dd0460697c libnm-glib: initialize NMRemoteSettings in nm_remote_settings_new() (rh #806664)
The object was not initialized after creation in nm_remote_settings_new(). This
was a regression caused by 762df85234.
2012-03-27 22:36:55 +02:00
Jiří Klimeš
876f318ee8 ifupdown: add missing test18-wired-static-verify-ip6 to Makefile.am 2012-03-27 15:55:21 +02:00
Jiří Klimeš
b48dc05b72 libnm-glib: ensure bindings-created NMClient object work (rh #802536)
Most of the stuff was done by 762df85234.
But to allow this piece of code:

from gi.repository import NMClient
nmclient = NMClient.Client()
print nmclient.get_active_connections()

we also need to set "dbus-path" property in NMClient constuctor(),
else parent NMObject is not properly constructed.
2012-03-27 14:53:31 +02:00
Michael Biebl
546c269f8d Fix format string vulnerability in verify ()
which caused a build failure when compiling with -Werror=format-security
2012-03-24 23:07:56 +01:00
Dan Williams
54618a72e3 docs: fixups for new settings 2012-03-23 19:01:41 -05:00
Dan Williams
3f7f5e50de release: bump version to 0.9.4.0 2012-03-23 15:55:59 -05:00
Dan Williams
e9b110b29e libnm-glib: bump soname minor 2012-03-23 15:55:36 -05:00
Dan Williams
145b37d6ff libnm-util: bump soname minor 2012-03-23 15:55:21 -05:00
Dan Williams
f5f85f8a83 release: update NEWS 2012-03-23 15:11:02 -05:00
Dan Williams
8126947e08 settings: quiet warning when checking for AdHoc WPA connections 2012-03-23 09:59:20 -05:00
Dan Williams
085d822f28 core: suppress pointless log message when route already exists (lp:958519) 2012-03-22 16:22:48 -05:00
Dan Winship
a44effc1c7 TODO: remove bridging/bonding and InfiniBand
Bonding and InfiniBand are done. Bridging isn't, but after removing
the bonding and generic infrstructure parts of that section, there
wasn't really enough left to be worth keeping.
2012-03-22 15:50:43 -04:00
Dan Winship
49105f7115 core: do a better job of applying bond configuration
Reset all known bond options to their default values, not just the
ones that NMSettingBond allows overriding. Also, remove any bond
slaves that were already attached to the bond before we managed it.

Only update bond parameters that need to be updated. In particular,
setting either arp_interval or miimon to 0 has the side effect of also
setting the other one to 0, so don't do that if it's already 0.

Fix the handling of arp_ip_target; the sysfs arp_ip_target node does
not work the same way as the ifcfg BONDING_OPTS line (which is what
the code was assuming before).
2012-03-22 13:12:57 -04:00
Dan Winship
c4994bba54 libnm-util: improve NMSettingBond:verify()
Add NM_SETTING_BOND_ERROR_INVALID_OPTION and
NM_SETTING_BOND_ERROR_MISSING_OPTION error codes so we can better
distinguish errors in different options, and add checks for various
incompatible sets of options.
2012-03-22 13:12:57 -04:00
Dan Winship
131b434054 libnm-util: fix an NMSettingBond bug
NMSettingBond sets the "miimon" option to "100" by default, but this
means that when reading in a saved configuration with "arp_interval"
set, it would end up with both "miimon" and "arp_interval" set, which
is invalid. Fix this by clearing "miimon" if "arp_interval" is set,
and vice versa.
2012-03-22 13:12:57 -04:00
Dan Winship
4ad810fdf4 core: fix NMDeviceBond:dispose() to chain up 2012-03-22 13:12:57 -04:00
Dan Williams
925119074d wifi: work around more wl.o stupidity
Sometimes returns 0 for the current frequency when the radio is
active.  WTF?
2012-03-22 11:50:11 -05:00
Dan Williams
71ad568cfb ip6: fix setting default route with libnl3 (bgo #668286)
libnl3 wants a destination address when setting a route, so just hand
it '::' with a address len of 0 so we don't get -NLE_MISSING_ATTR
when trying to set the IPv6 default route.
2012-03-22 09:21:38 -05:00
Dan Williams
1ecc9c215c trivial: formatting fixes 2012-03-21 22:58:00 -05:00
Dan Williams
2290a70385 firewall: set interface zone before IP configuration (rh #805405)
We need to set the interface's firewall zone before we kick off
any sort of IP configuration, so that rules for stuff like
DHCP are already handled by the time that these services are started.
2012-03-21 15:10:11 -05:00
Dan Williams
762df85234 libnm-glib: ensure bindings-created objects work as expected (rh #802536)
Bindings (like GObject Introspection) almost always create objects
using g_object_new() by default and don't use our helper functions
like nm_client_new().  Thus we need to make sure that if the
object is created in that way, any property accesses or functions
that return properties ensure that the object is fully initialized,
which is what the _new() functions were supposed to do.  In one
case in NMClient that was missing (getting active connections)
and wasn't happening at all in NMRemoteSettings, which are our two
entry points into libnm-glib.

This allows this python+GI sequence to return the expected active
connection list:

from gi.repository import NMClient
nmclient = NMClient.Client(dbus_path='/org/freedesktop/NetworkManager')
active = nmclient.get_active_connections()
print(active)

where previously it returned an empty list because the NMClient
wasn't fully initialized by the time nm_client_get_active_connections()
was called.
2012-03-21 12:37:39 -05:00
Dan Williams
43f449824a mobile: ensure IPv4 timeout fails activation
With the switch to IPv4 being allowed to fail by default we need
to clean up this old code a bit.  PPP failure during IP config
should trigger a timeout, and the core code will handle whether
to fail the device completely or not.  But if we got a valid IPv4
config and PPP failed later, the device gets failed.  Previously
the device would just sit in IP_CONFIG state because now IPv4
defaults may-fail to TRUE, and when PPP failed the
nm_device_ip_config_should_fail() check would obviously not pass.
2012-03-20 23:21:17 -05:00
Jiří Klimeš
5238aa4107 utils: override VPN plugin's never-default when ignoring auto routes (rh #804563)
Setting never-default ito TRUE when VPN server provides routes was done
in https://bugzilla.gnome.org/show_bug.cgi?id=621698
2012-03-20 17:17:49 +01:00
Dan Williams
ce6b667a68 wifi: make sure we're connected to netlink before using it
This should fix the warning "failed to allocate link cache" when a
new device is added.  It doesn't affect WiFi operation, and the
code would fall back to non-nl80211 mechanisms of detecting whether
a device was wifi or not, so it corrects this check and quiets the
error message.
2012-03-19 16:09:46 -05:00
Dan Williams
1da9738f1b libnm-glib: add 'registered' property for NMSecretAgent
So clients can track when the agent is actually registered and when
it's registration state changes.
2012-03-19 13:24:28 -05:00
Dan Williams
4f0ddb105a release: bump version to 0.9.3.997 (0.9.4-rc1) 2012-03-19 10:11:33 -05:00
Mathieu Trudel-Lapierre
1a531b7ecf keyfile: fix testcases after InfiniBand transport-mode default change 2012-03-19 10:10:36 -05:00
Dan Williams
69247a00ea wifi: disable Ad-Hoc WPA connections (lp:905748)
The kernel is broken for Ad-Hoc WPA, and creates the connections
as open connections instead.  Yeah, eventually we can use
wpa_supplicant with RSN support, but for now we just have to
disable Ad-Hoc WPA because it's a problem to say we're creating
a protected network but then have the kernel not do that for
us.  Will be re-enabled once all the necessary bits have been
fixed.

Note that Ad-Hoc WPA has been broken since at least 2.6.32 with
mac80211-based drivers, which is what most users will be using.
2012-03-16 17:58:23 -05:00
Dan Williams
c455eafbef infiniband: fix missing sentinal in 04959c39aa 2012-03-16 15:20:58 -05:00
Dan Winship
04959c39aa Add a workaround for a problem creating InfiniBand connections
It is currently not possible to create a connection where the
connection-type-specific NMSetting has all default values. This hasn't
been a problem in the past because each type had at least one property
that either had no default value or had a default value that didn't
pass verify(). But NMSettingInfiniband didn't have that property, so
it's impossible to create an InfiniBand connection unless you change
the value of at least InfiniBand-specific setting.

Work around this for now by making the default value of
NMSettingInfiniband:transport-mode be NULL, so it needs to be
overridden.
2012-03-16 14:13:52 -04:00
Dan Williams
deb042c656 release: update NEWS 2012-03-16 10:48:02 -05:00
Dan Williams
6b9511f6e9 core: treat missing IPv6 setting as AUTO
Like IPv4, if the connection contains no IPv6 setting, perform
IPv6 addressing.  Since may-fail defaults to TRUE for IPv6, failure
should have no consequence.
2012-03-16 09:43:16 -05:00
Jiří Klimeš
a11067f584 libnm-glib: add errors to device classes and nm_device_connection_compatible()
Add nm_device_connection_compatible() that returns an error when it fails.
nm_device_connection_valid() does the same work except it doesn't set GError.
2012-03-16 09:54:36 +01:00
Dan Williams
43ba4eb04b ifcfg-rh: fix testcase after 4abb300c96 2012-03-15 17:56:34 -05:00
Evan Broder
447342744e vpn: add a new field so VPN plugins can specify multiple domains 2012-03-15 17:10:15 -05:00
Mathieu Trudel-Lapierre
956e63a673 dnsmasq: allow proxying dnssec data (lp:946093)
This will allow DNSSEC data to be visible in browsers, which would otherwise
not be the case by default because of dnsmasq acting as a middle-man for
resolution.

Otherwise, we have a regression from the libc resolver behavior.
2012-03-15 16:58:19 -05:00
Andrew Bird
34aef8aaaa gsm: pass the PPP auth preferences for STATIC and DHCP device use
When using the either DHCP or STATIC IpMethods the modem manager
or device itself negotiates the PPP session so we need to pass
the authentication preferences through to MM.

Notes:
        1/ Using a bitfield now that happens to match the Ericsson
in the lower orders so that it's far more tidy.
        2/ Devices that wish to utilise this should observe the
following:
        If the bitfield doesn't exist in the dict, then MM uses the
modem default, if it does, MM tries to fulfill the request. If the
modem can only accept one value (Qualcomm-type devices accept only
None, PAP or CHAP with AT$QCPDPP) then MM picks the appropriate one
from the dict if only one of PAP or CHAP was given, otherwise we
default to PAP.

(dcbw: make enum a bitfield instead of the bit position)
2012-03-15 16:19:43 -05:00