1. 28 May, 2013 6 commits
    • Dan Williams's avatar
      ifnet: track connections by UUID not conf.d net connection name · 689dadaf
      Dan Williams authored
      We'll need this for later with unsaved connections.  The ifnet
      plugin previously tracked connections by the "conn_name" which
      was derived from keys in the /etc/conf.d/net file.  These keys
      take two forms:
      
      1) interface name
      
      config_eth0=(
      "192.168.4.121/24"
      "dhcp6"
      )
      
      2) wifi SSID, either text or hex-encoded:
      
      config_myssid=("dhcp")
      config_0xab3ace=("dhcp")
      
      The conf.d net connection name is apparently usually an interface
      name, so when writing to /etc/conf.d/net the NM connection name is
      changed from eg "Ethernet connection 1" to the next available
      interface name based on the type of connection, eg "eth0".
      
      The ifnet plugin actively removed connections that were not present
      in /etc/conf.d/net during the reload_connections() call, but in the
      future we'll want to allow unsaved connections which in the case of
      ifnet clearly won't yet be written to the file.  Since only
      connections written to the file have a "conn_name", tracking
      connections by conn_name no longer works.
      689dadaf
    • Dan Williams's avatar
    • Dan Williams's avatar
      ifcfg-rh: track connections by UUID not file path · b225a9f5
      Dan Williams authored
      We'll need this for later with unsaved connections.
      b225a9f5
    • Dan Williams's avatar
    • Dan Williams's avatar
      keyfile: track connections by UUID not file path · 830f65fc
      Dan Williams authored
      We'll need this for later with unsaved connections.
      830f65fc
    • Dan Williams's avatar
      settings: track whether connection is saved to disk or not · cd5d9270
      Dan Williams authored
      Use the new NMConnection 'changed' signal to mark connections
      as dirty/unsaved, and reset that when they get flushed to disk.
      Previously, the 'Updated' signal was emitted only when the
      connection was changed and flushed to disk, but now we have
      more granular needs, and the signal is emitted whenever the
      connection actually *is* changed, regardless of whether its
      flushed to disk or not.
      cd5d9270
  2. 18 May, 2013 1 commit
  3. 14 May, 2013 3 commits
    • Dan Williams's avatar
      ifupdown: recalculate unmanaged specs on interface change (debian #707070) · f762fa58
      Dan Williams authored
      If a kernel interface changes its MAC address, and NM is not
      supposed to manage that interface, ifupdown needs to notice
      that MAC address change and tell NM that the unmanaged devices
      have changed, so that NM continues to not touch the device
      after the MAC has changed.
      f762fa58
    • Dan Williams's avatar
      ifupdown: fix naming confusion in plugin hash tables · a3705112
      Dan Williams authored
      well_known_interfaces -> eni_ifaces, since it's a hash of any
      interfaces read from /etc/network/interfaces.
      
      well_known_ifaces -> kernel_ifaces, since it's a hash of any
      network subsystem interface the kernel knows about
      a3705112
    • Dan Williams's avatar
      ifupdown: clarify name of connections hash · b2c67096
      Dan Williams authored
      'iface_connections' is really the list of all NMIfupdownConnections
      known to the plugin, read from /e/n/i and hashed by block name.  Since
      ifupdown doesn't store anything *except* connections from /e/n/i,
      just rename it to 'connections' to reduce confusion with the
      well_known_interfaces and well_known_ifaces hashes.
      b2c67096
  4. 08 May, 2013 1 commit
    • Dan Winship's avatar
      core: use non-recursive build · c4417c71
      Dan Winship authored
      Although having different parts of NM in different subdirectories
      keeps the source tree neat, it has made the build messy, particularly
      because of cross-dependencies between the subdirs.
      
      Reorganize to build all of the pieces of the NetworkManager binary
      from src/Makefile, and only use recursive make for test programs,
      helper binaries, and plugins.
      
      As part of this, get rid of all the per-directory convenience
      libraries, and switch to building a single top-level
      libNetworkManager.la, containing everything except main.c, which all
      of the test programs can then link against.
      c4417c71
  5. 03 May, 2013 1 commit
  6. 19 Apr, 2013 1 commit
    • Martin Pitt's avatar
      Use %NULL macro in doc strings · 57a9fb3c
      Martin Pitt authored
      Mass-converted "NULL" to "%NULL" in docstrings with
      
        find -name '*.c'| xargs sed -i '/^ \*.*[^%]NULL/ s/NULL\b/%NULL/g'
      57a9fb3c
  7. 11 Apr, 2013 2 commits
    • Dan Williams's avatar
      keyfile: ensure all-default VLAN setting is read correctly · 9f8b7ff5
      Dan Williams authored
      Settings with all-default values are not written to reduce
      complexity of the keyfile (and be more human-readable friendly)
      and that includes VLAN settings with a VLAN ID of zero.  So
      when reading this file back, if there is no 'base type' setting
      (eg, the setting specified by the connection::type property)
      then just add that setting.  nm_connection_verify() will catch
      cases where an empty 'base type' setting is invalid.
      9f8b7ff5
    • Dan Williams's avatar
      keyfile: use 'ethernet', 'wifi' and 'wifi-security' group names (bgo #696940) · c36200a2
      Dan Williams authored
      Add these aliases for the setting names '802-3-ethernet',
      '802-11-wireless', and '802-11-wireless-security' and write them by
      default.  It's much friendlier for administrators to type, and a lot
      less ugly.
      
      Also works for:
      
      [connection]
      type=ethernet
      c36200a2
  8. 05 Apr, 2013 1 commit
    • Dan Williams's avatar
      keyfile: fix testcase comparison · 1bcf3f63
      Dan Williams authored
      test-keyfile.c: In function 'test_read_string_ssid':
      test-keyfile.c:1154:51: error: argument to 'sizeof' in 'memcmp' call is the
         same expression as the second source; did you mean to provide an explicit
         length? [-Werror=sizeof-pointer-memaccess]
      ASSERT (memcmp (array->data, expected_ssid, sizeof (expected_ssid)) == 0,
      1bcf3f63
  9. 03 Apr, 2013 3 commits
  10. 28 Mar, 2013 1 commit
  11. 25 Mar, 2013 1 commit
  12. 22 Mar, 2013 1 commit
  13. 14 Mar, 2013 1 commit
  14. 13 Mar, 2013 2 commits
  15. 08 Mar, 2013 1 commit
    • Dan Williams's avatar
      ifcfg-rh: save bridge STP disabled setting (bgo #694841) · 20031e18
      Dan Williams authored
      STP defaults to yes in NetworkManager (and the initscripts), so a missing
      STP value in an ifcfg file means yes/on.  Calling svSetValue(STP, NULL)
      clears that line from the ifcfg, and thus STP gets interpreted as yes.
      Explicitly set stp to "no" so that the value actually gets saved.
      20031e18
  16. 07 Mar, 2013 2 commits
  17. 26 Feb, 2013 2 commits
    • Dan Winship's avatar
      tests: clean up gtester usage · f936400c
      Dan Winship authored
      Use g_test_add_func() and g_test_add_data_func() to simplify the test
      cases, getting rid of the GLIB_CHECK_VERSION calls in the process.
      f936400c
    • Dan Winship's avatar
      build: avoid GValueArray deprecation warnings · ed9e2d83
      Dan Winship authored
      Avoid warnings about GValueArray being deprecated by adding macros
      that wrap G_GNUC_BEGIN_IGNORE_DEPRECATIONS /
      G_GNUC_END_IGNORE_DEPRECATIONS around the GValueArray calls.
      ed9e2d83
  18. 25 Feb, 2013 1 commit
  19. 19 Feb, 2013 1 commit
  20. 15 Feb, 2013 1 commit
    • Dan Winship's avatar
      libnm-utils: add :carrier-detect properties · 5266e25e
      Dan Winship authored
      For settings corresponding to devices that have a :carrier property
      (ie bond, bridge, infiniband, vlan, and wired), add a :carrier-detect
      property specifying how that affects the connection:
      
        yes: The connection can only be activated when the device
            has carrier, and will be deactivated if the device loses
            carrier (for more than 4 seconds).
        no: The connection ignores carrier on the device; it can be
            activated when there is no carrier, and stays activated
            when carrier is lost.
        on-activate: The connection can only be activated when the
            device has carrier, but it will not be deactivated if the
            device loses carrier.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=688284
      5266e25e
  21. 13 Feb, 2013 2 commits
    • Dan Winship's avatar
      all: remove more pointless NULL checks · 08f04466
      Dan Winship authored
      GObject creation cannot normally fail, except for types that implement
      GInitable and take a GError in their _new() method. Some NM types
      override constructor() and return NULL in some cases, but these
      generally only happen in the case of programmer error (eg, failing to
      set a mandatory property), and so crashing is reasonable (and most
      likely inevitable anyway).
      
      So, remove all NULL checks after calls to g_object_new() and its
      myriad wrappers.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=693678
      08f04466
    • Dan Winship's avatar
      all: remove pointless NULL checks · d04f2863
      Dan Winship authored
      g_malloc(), etc, never return NULL, by API contract. Likewise, by
      extension, no other glib function ever returns NULL due to lack of
      memory. So remove lots of unnecessary checks (the vast majority of
      which would have immediately crashed had they ever run anyway, since
      g_set_error(), g_warning(), and nm_log_*() all need to allocate
      memory).
      
      https://bugzilla.gnome.org/show_bug.cgi?id=693678
      d04f2863
  22. 12 Feb, 2013 1 commit
  23. 18 Dec, 2012 1 commit
  24. 30 Nov, 2012 3 commits