Commit Graph

15047 Commits

Author SHA1 Message Date
Emilio Pozuelo Monfort
1013caba75 bluez: add configure switch for BlueZ 5 2013-09-25 21:01:04 +02:00
Thomas Haller
a26271841c trivial: rename variable and fix whitespace errors
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-25 21:01:04 +02:00
Thomas Haller
816347d3e0 bluez: fail if connect_async is called when already being connected.
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-25 21:01:04 +02:00
Thomas Haller
ed966c7e3f bluez: pass NMBluetoothCapabilities to nm_bluez_device
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-25 21:01:04 +02:00
Emilio Pozuelo Monfort
7aa5128b41 bluez: move org.bluez Connection() handling to NMBluezDevice 2013-09-25 21:01:04 +02:00
Thomas Haller
e45fdcfd2d bluez: get rid of connected_id for disconnecting from signal
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-25 21:01:04 +02:00
Emilio Pozuelo Monfort
4be056f504 bluez: listen to Connected changes through NMBluezDevice 2013-09-25 21:01:03 +02:00
Emilio Pozuelo Monfort
180503eb1a bluez: listen to Connected changes in NMBluezDevice 2013-09-25 21:01:03 +02:00
Emilio Pozuelo Monfort
f422acc9d3 bluez: pass the NMBluezDevice down to the NMDeviceBt
So that the latter can use the former instead of listening
for changes over dbus.
2013-09-25 21:01:03 +02:00
Dan Williams
024f7e10b2 trivial: fix uninitialized bytes in ethtool driver name lookup
If the interface doesn't have an ethtool driver name, then '.driver'
will never be touched and (*drvinfo.driver) will access uninitialized
bytes.
2013-09-25 13:51:03 -05:00
Dan Winship
4959936704 libnm-util, libnm-glib: bump .so versions to be higher than 0.9.8.4's 2013-09-25 10:16:55 -04:00
Thomas Haller
c4e0326c21 core: fix resetting wrong field in nm_ip6_config_reset_addresses
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-24 18:40:06 +02:00
Thomas Haller
661e47311d core: add const qualifier to functions in nm-ip[46]-config
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-24 18:31:34 +02:00
Dan Winship
17607e74a2 infiniband: only check the last 8 bytes when doing hwaddr matches
IPoIB "hardware addresses" are only partly based on the hardware, and
partly based on the InfiniBand configuration. So when checking if a
configuration matches a device, we should only match the fixed part.
2013-09-24 11:54:35 -04:00
Dan Winship
5a39715f2d platform: fix InfiniBand partition handling
Fix infiniband_partition_add() to put the newly-created device into
the link_cache before returning. Fix link_is_software() to recognize
partition devices as software, so that link_get() is willing to return
them even before we get the udev info.
2013-09-24 11:54:34 -04:00
Dan Winship
e1e4740648 cli: recognize InfiniBand partitions as virtual
We don't need to hardcode the kinds of devices that are virtual here;
NMConnection already knows.
2013-09-24 11:54:34 -04:00
Dan Winship
b91d029021 core: short-circuit nm_device_spec_match_list()
If there are no specs, then the device can't match, so don't call the
virtual method (which might do work like building comparison strings
even when the list is empty).
2013-09-24 11:54:34 -04:00
Dan Winship
d20ac49dc9 platform: fix spelling of "announceable" 2013-09-24 11:54:34 -04:00
Jiri Popelka
a20fd994f4 examples: use GLib.MainLoop instead of deprecated GObject.MainLoop in python
jklimes:
made the change for new firewall-zone.py example as well.
2013-09-24 13:33:37 +02:00
Jiří Klimeš
8a04ab9135 examples: group python examples - dbus vs. gi
Move examples using dbus-python ('dbus' module) and GObject introspection into
their own directories.
2013-09-24 12:52:33 +02:00
Jiří Klimeš
217cb5fbca examples: add a python example getting/setting zone property using GI 2013-09-24 12:48:55 +02:00
Jiří Klimeš
2b72214e52 platform: fix a crash when nm_platform_sysctl_get() returns NULL (rh #1010522)
nm_platform_sysctl_get() can return NULL on an error (when file specified by
'path' argument doesn't exist, can't be opened, etc.)

https://bugzilla.redhat.com/show_bug.cgi?id=1010522
2013-09-23 18:28:36 +02:00
Jiří Klimeš
28530239fa platform: fix a memory leak on an error 2013-09-23 18:28:36 +02:00
Noriko Mizumoto
a3f3d76b24 po: updated Japanese (ja) translation (bgo #708631)
https://bugzilla.gnome.org/show_bug.cgi?id=708631

Reported-by: Jiro Matsuzawa <jmatsuzawa@gnome.org>
Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-23 17:02:56 +02:00
Jiří Klimeš
5471a6c678 ifcfg-rh: if IPv4 is disabled put DNS domains (DOMAIN) into IPv6 (rh #1004866)
The problem is that there is only a single variable in ifcfg file holding dns
domains - DOMAIN. Thus NetworkManager writes both IPv4 and IPv6 dns-search into
it. While reading there is no way to distinguish between IPv4 and IPv6 values,
so the DOMAIN value is read and only put into IPv4 dns-search.

But, when IPv4 is disabled or invalid, the domains got lost. So in such case
we put DOMAIN variable into IPv6 instead.

https://bugzilla.redhat.com/show_bug.cgi?id=1004866
2013-09-23 09:57:37 +02:00
Christian Kirbach
c1ce1b3185 po: updated German (de) translation (bgo #708533)
https://bugzilla.gnome.org/show_bug.cgi?id=708533
2013-09-23 09:23:54 +02:00
Dan Williams
44ccf3454b supplicant: suppress more bus activation failure errors
These are expected errors if the supplicant can't be launched
for some reason.  We should only log entirely unexpected errors
like wrong method arguments or types, really odd failures, etc.

NetworkManager[1312]: <error> [1379601146.148818] [supplicant-manager/nm-supplicant-interface.c:853] interface_add_cb(): (wlan0): error adding interface: 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.
NetworkManager[1312]: <error> [1379601171.160742] [supplicant-manager/nm-supplicant-interface.c:853] interface_add_cb(): (wlan0): error adding interface: Activation of fi.w1.wpa_supplicant1 timed out
2013-09-19 11:16:47 -05:00
Jiří Klimeš
f8c23077cc cli: fix bond questionnaire to be able to set miimon (rh #1007355)
Bonding options are related and some combinations don't make sense. Basically,
MIIMON and ARP monitoring mode (and related options) are mutually exclusive.
When nmcli set arp_interval of "0" (the default value),
nm_setting_bond_add_option() cleared the MIIMON options (miimon, updelay and
downdelay).

This commit works around libnm-util's nm_setting_bond_add_option() that clears
miimon options when arp_interval is being set and vice versa, but doesn't
take into account the value of "0" that should be regarded as 'disable'.

https://bugzilla.redhat.com/show_bug.cgi?id=1007355
2013-09-19 16:56:37 +02:00
Jiří Klimeš
9dacfd0a39 cli: always print success message (not only in --pretty mode) (rh #1006444)
The commands performing actions without an output only printed a successfull
message for --pretty mode. Some users don't like this silent operation.
This commit makes nmcli print operation success unconditionally. I think that
doesn't hurt; scripts/users can ignore the message if not interested.

https://bugzilla.redhat.com/show_bug.cgi?id=1006444
2013-09-19 15:24:13 +02:00
Jiří Klimeš
05980f9045 cli: fix the error message for valid IPv6 prefix range to <1-128> 2013-09-19 14:06:36 +02:00
Jiří Klimeš
295df3405c cli: accept gateway in the IP questionnaire of 'nmcli -a con add' (rh #1007368)
Also allow leading/trailing white spaces, and more white spaces between IP and
gateway. (Spaces in values and around / are not allowed).
 All of these are accepted:
'  1.2.3.4/11     1.2.3.254 '
' 1.2.3.4 '
'   fe80::215:ff:fe93:ffff/128  ::1 '
...

https://bugzilla.redhat.com/show_bug.cgi?id=1007368
2013-09-19 12:07:22 +02:00
Jiří Klimeš
2e8746aab2 core: remove 'wep40' and 'wep104' from several places in NM
wep40 and wep104 are not valid values for 'pairwise' property and they are not
used for dynamic WEP as 'group' ciphers as well.

See https://bugzilla.redhat.com/show_bug.cgi?id=1005171 for some details.
2013-09-18 12:07:29 +02:00
Piotr Drąg
cd00e3807e po: update Malayalam (ml) translation (bgo #708270)
https://bugzilla.gnome.org/show_bug.cgi?id=708270#c1

Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-18 09:21:11 +02:00
Piotr Drąg
7da55019f9 po: update Polish (pl) translation (bgo #708270)
https://bugzilla.gnome.org/show_bug.cgi?id=708270#c0

Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-18 09:20:18 +02:00
Jiří Klimeš
76c34d48ed core,settings: do not call functions with connection==NULL (rh #1008151)
check 'req' and 'connection' variables. Apparently, they can be NULL
on some circumstances.

NetworkManager[2830]: <info> (p6p1): device state change: secondaries -> disconnected (reason 'connection-removed') [90 30 38]
NetworkManager[2830]: <info> (p6p1): deactivating device (reason 'connection-removed') [38]
kernel: [ 2623.609111] NetworkManager[2830]: segfault at 50 ip 00007f1a309bf6a1 sp 00007fffc59e67e0 error 6 in NetworkManager[7f1a30915000+104000]
NetworkManager[2830]: (nm-device.c:5043):nm_device_state_changed: runtime check failed: (in_state_changed == FALSE)
NetworkManager[2830]: <info> (p6p1): device state change: disconnected -> failed (reason 'secondary-connection-failed') [30 120 54]
NetworkManager[2830]: nm_act_request_get_connection: assertion `NM_IS_ACT_REQUEST (req)' failed
NetworkManager[2830]: nm_connection_get_id: assertion `connection != NULL' failed
NetworkManager[2830]: <warn> Activation (p6p1) failed for connection '(null)'
NetworkManager[2830]: nm_settings_connection_get_timestamp: assertion `connection != NULL' failed
abrt[2882]: Saved core dump of pid 2830 (/usr/sbin/NetworkManager) to /var/tmp/abrt/ccpp-2013-09-15-11:38:39-2830 (18952192 bytes)
systemd[1]: NetworkManager.service: main process exited, code=dumped, status=11/SEGV
systemd[1]: Unit NetworkManager.service entered failed state.

https://bugzilla.redhat.com/show_bug.cgi?id=1008151
2013-09-17 19:14:39 +02:00
Loïc Yhuel
19b7fe5ca2 core: fix bridge device creation
Since 2688ae4950, bridge device creation
fails with "(br0): cannot use existing bridge for 'Bridge'" warning.

Signed-off-by: Thomas Haller <thaller@redhat.com>
2013-09-17 11:11:27 +02:00
Enrico Nicoletto
16fa0a7a89 po: updated Brazilian Portuguese (pt_BR) translation (bgo #707991)
https://bugzilla.gnome.org/show_bug.cgi?id=707991
2013-09-16 08:56:14 +02:00
Dan Williams
0f5f6da1a5 libnm-glib: fix NMDeviceModem connection compatible check for LTE connections
The 3GPP checks didn't include LTE capabilities, so the modem connection_compatible
check would fail for LTE connections with LTE compatible devices.
2013-09-14 18:46:32 -05:00
Jiří Klimeš
ee1a43175b po: add src/nm-sleep-monitor-systemd.c into po/POTFILES.in 2013-09-13 15:07:03 +02:00
Dan Winship
1b6247fc27 sleep-monitor: add missing include 2013-09-13 09:05:07 -04:00
Bastien Nocera
bc4a8f51fb sleep-monitor: give better inhibition reason (bgo #704863)
https://bugzilla.gnome.org/show_bug.cgi?id=704863
2013-09-13 13:03:54 +02:00
Enrico Nicoletto
6106b781d8 po: updated Brazilian Portuguese (pt_BR) translation (bgo #707991)
https://bugzilla.gnome.org/show_bug.cgi?id=707991
2013-09-13 12:35:02 +02:00
Jiří Klimeš
1f6e1fbc62 cli: editor 'change' command: output -> input format conversion (rh #998929)
The format of property values that nmcli prints is not the same (for some
properties) as the format nmcli editor accepts as input from user. The reasons
are that (a) output format is more descriptive and not much suitable to be
typed, (b) it comes in most cases from libnm-util.
'change' command displays current property value and allows users to edit it.
So we convert the output into input format, before presenting it to the user.

https://bugzilla.redhat.com/show_bug.cgi?id=998929
2013-09-13 10:56:20 +02:00
Dan Williams
42b6c6eac0 core: fix call to nm_device_bring_up()
Typo in ebdf1796f1
2013-09-12 19:11:06 -05:00
Dan Winship
ebdf1796f1 core: implement :mtu and :cloned-mac-address for VLAN 2013-09-12 18:34:23 -04:00
Dan Winship
68bb65fbab core: fix nm_device_supports_vlans()
The platform knows which device types support VLANs, so just ask it,
rather than only doing VLANs on ethernet.
2013-09-12 18:34:23 -04:00
Dan Winship
e0f0f60ff5 core: remove nm_device_hwaddr_matches() / get_connection_hw_address()
These were only needed to support the possibility of VLANs having
arbitrary additional hardware settings.
2013-09-12 18:34:23 -04:00
Dan Winship
066b592241 all: standardize on NMSettingWired:mac-address for all VLANs
Currently, ethernet-based VLANs can specify the hardware address of
the parent device (and, in theory, the cloned hardware address and MTU
of the VLAN device) by using an NMSettingWired in addition to the
NMSettingVlan.

The theory was that non-ethernet-based VLANs, when we eventually
supported them, would likewise use the setting type corresponding to
their parent device. However, this turns out to be both complicated
(the settings plugins and connection editor would have a
hard-to-impossible time figuring out which setting type to use in some
cases) and incorrect (for most L2 settings [eg, BSSID, bond mode,
etc], the VLAN can't have its own values separate from the parent
device).

What we should have done was just have :mac-address,
:cloned-mac-address, and :mtu properties on NMSettingVlan. However, at
this point, for backward-compatibility, we will just stick with using
a combination of NMSettingVlan and NMSettingWired, but we will use
NMSettingWired regardless of the underlying hardware type.
2013-09-12 18:34:23 -04:00
Dan Winship
2688ae4950 core: move software device creation logic out of NMManager
Rather than having NMManager know how to parse various settings to
create each kind of software device, add a _new_for_connection()
constructor to each of them and let them call NMPlatform to create the
device correctly themselves.
2013-09-12 18:34:23 -04:00
Dan Winship
23d4973835 core: set VLAN ingress/egress maps at activation time
Rather than setting the VLAN maps when the device is created, set them
at activation time, which is more in line with how other device types
work.

Like the old code, this doesn't attempt to reset any existing
ingress/egress mappings on the device.
2013-09-12 18:34:23 -04:00