1. 11 Mar, 2019 3 commits
  2. 08 Mar, 2019 1 commit
  3. 07 Mar, 2019 8 commits
  4. 06 Mar, 2019 1 commit
    • Beniamino Galvani's avatar
      wifi-p2p: fix failed assertion when releasing supplicant interface · 25fdf0ab
      Beniamino Galvani authored
      Fix the following failed assertion:
      
        <debug> device[0x11dfec0] (p2p-dev-wlp4s0): P2P: Releasing WPA supplicant interface.
        <debug> supplicant: setting WFD IEs for P2P operation
        (../src/devices/nm-device.c:14769):_set_state_full: runtime check failed: (priv->in_state_changed == FALSE)
        <info>  device (p2p-dev-wlp4s0): state change: unmanaged -> unavailable (reason 'supplicant-failed', sys-iface-state: 'external')
        <debug> device[0x11dfec0] (p2p-dev-wlp4s0): add_pending_action (1): 'waiting-for-supplicant'
      
      supplicant_interfaces_release() can be called during a state change
      (for example by device_state_changed()) and so it can't trigger
      another state change.
      
      nm_device_wifi_p2p_set_mgmt_iface() now doesn't force an immediate
      state change and only schedules a recheck-available. This means that
      the device can be in an available state without
      priv->mgmt_iface. Adapt the code to deal gracefully with that
      situation. In particular, we need to cancel pending timeout sources
      (priv->sup_timeout_id) that use the management interface.
      
      Fixes: 27bc2cb2
      
      https://github.com/NetworkManager/NetworkManager/pull/302
      (cherry picked from commit d2e95856)
      25fdf0ab
  5. 05 Mar, 2019 14 commits
  6. 04 Mar, 2019 1 commit
  7. 26 Feb, 2019 3 commits
  8. 23 Feb, 2019 3 commits
    • Thomas Haller's avatar
      Revert "build/meson: name platform tests like autotools" · 5551b3ab
      Thomas Haller authored
      Older versions of meson don't support building the same names
      multiple times.
      
        Meson encountered an error in file src/tests/meson.build, line 14, column 2:
        Tried to create target "test-general", but a target of that name already exists.
      
      We really need to use unique filenames everywhere. Revert the name
      change for now.
      
      This breaks again the valgrind workaround in "tools/run-nm-test.sh".
      
      This reverts commit 5466edc6.
      5551b3ab
    • Thomas Haller's avatar
      build/meson: name platform tests like autotools · 5466edc6
      Thomas Haller authored
      Meson and autotools should name the tests the same way.
      Also, all tests binaries built by autotools start on purpose
      with "test-". Do that for meson too.
      
      Also, otherwise "tools/run-nm-test.sh" fails to workaround
      valgrind failures for platform tests as it does not expect
      the tests to be named that way:
      
          if [ $HAS_ERRORS -eq 0 ]; then
              # valgrind doesn't support setns syscall and spams the logfile.
              # hack around it...
              if [ "$TEST_NAME" = 'test-link-linux' -o \
                   "$TEST_NAME" = 'test-acd' ]; then
                  if [ -z "$(sed -e '/^--[0-9]\+-- WARNING: unhandled .* syscall: /,/^--[0-9]\+-- it at http.*\.$/d' "$LOGFILE")" ]; then
                      HAS_ERRORS=1
                  fi
              fi
          fi
      5466edc6
    • Thomas Haller's avatar
      build/meson: increase timeouts for some tests · b1f6d53b
      Thomas Haller authored
      The defaults for test timeouts in meson is 30 seconds. That is not long
      enough when running
      
        $ NMTST_USE_VALGRIND=1 ninja -C build test
      
      Note that meson supports --timeout-multiplier, and automatically
      increases the timeout when running under valgrind. However, meson
      does not understand that we are running tests under valgrind via
      NMTST_USE_VALGRIND=1 environment variable.
      
      Timeouts are really not expected to be reached and are a mean of last
      resort. Hence, increasing the timeout to a large value is likely to
      have no effect or to fix test failures where the timeout was too rigid.
      It's unlikely that the test indeed hangs and the increase of timeout
      causes a unnecessary increase of waittime before aborting.
      b1f6d53b
  9. 22 Feb, 2019 6 commits
    • Thomas Haller's avatar
      license: re-license initrd-generator and ibft reader as LGPL · 8f62c76c
      Thomas Haller authored
      New code we want to add LGPL licensed to make it easier to share code
      between libnm and the daemon.
      
      The code in question was only recently added in commit b544f724
      ("initrd: add iBFT reader") and mostly written from scratch by Lubomir.
      
      Some parts were adapted from earlier ibft code.
      
        $ git shortlog -s -e -- src/settings/plugins/ibft/  ':(exclude)*/meson.build'
             3    Beniamino Galvani <bgalvani@redhat.com>
             1    Colin Walters <walters@verbum.org>
             2    Dan Williams <dcbw@redhat.com>
            17    Dan Winship <danw@redhat.com>
             7    Lubomir Rintel <lkundrak@v3.sk>
            46    Thomas Haller <thaller@redhat.com>
      
        $ git log --no-merges -L '/^fill_ip4_setting_from_ibft/,/^}/:src/settings/plugins/ifcfg-rh/reader.c' fc9c1f15~ | grep '^Author: ' | sort | uniq
        Author: Dan Williams <dcbw@redhat.com>
        Author: Dan Winship <danw@redhat.org>
        Author: Jiří Klimeš <jklimes@redhat.com>
        Author: Pavel Šimerda <psimerda@redhat.com>
      
      Hence, all non-trival contributions were provided by Red Hat employees
      and the copy-right is with Red Hat.
      Acked-by: Dan Williams's avatarDan Williams <dcbw@redhat.com>
      Acked-by: default avatarDan Winship <danw@redhat.com>
      Acked-by: Lubomir Rintel's avatarLubomir Rintel <lkundrak@v3.sk>
      8f62c76c
    • Thomas Haller's avatar
      all/trivial: fix whitespace/indentation · 79af876e
      Thomas Haller authored
      79af876e
    • Thomas Haller's avatar
      device: fix suppressing warning log about unsupported IPv6LL handling · 46bc5feb
      Thomas Haller authored
      Wrongly did not suppress the message
      
          <warn>  [1550844832.3749] device (tunl0): failed to disable userspace IPv6LL address handling (not-supported)
      
      Fixes: d18f4032
      46bc5feb
    • Beniamino Galvani's avatar
      device: do ARP announcements only after masters have a slave · de102228
      Beniamino Galvani authored
      Delay ARP announcements for masters until the first interfaces gets
      enslaved. There is no point in doing it before as the ARP packets
      would be dropped in most cases; also, if the first slave is added when
      we already started announcing, the MAC of the master is going to
      change and so the remaining ARPs will have a wrong "sender mac
      address" field.
      
      https://bugzilla.redhat.com/show_bug.cgi?id=1678796
      
      https://github.com/NetworkManager/NetworkManager/pull/301
      de102228
    • Thomas Haller's avatar
      all: move nm_utils_hexstr2bin*() to shared · 53b747ff
      Thomas Haller authored
      libnm exposes simplified variants of hexstr2bin in its public API. I
      think that was a mistake, because libnm should provide NetworkManager
      specific utils. It should not provide such string functions.
      
      However, nmcli used to need this, so it was added to libnm.
      
      The better approach is to add it to our internally shared static
      library, so that all interested components can make use of it.
      53b747ff
    • Thomas Haller's avatar
      core/wireguard: add support for WireGuard peers · 2148d094
      Thomas Haller authored
      That is slightly complex, because we need to (DNS) resolve the endpoints,
      and we also have to retry periodically. For example, initially we may be
      unable to resolve an endpoint, but later we may be.
      
      What is also interesting is that during assume and reapply, we may not
      have all information in the profile. Most notably, the private keys will
      be missing. We need to cope with that and not reconfigure keys. However,
      we still need to resolve names and update the endpoints.
      2148d094