| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Otherwise readline decides to initialize terminal handling at the first
readline call, and if that happens at the point it sees our
non-echoing rl_redisplay.
At that point, unless already intialized, readline wrongly convinces itself we
do our own handling of terminal peculiarities (such as cursor movement, or
erases). We do not -- we merely wrap the stock rl_redisplay(), temporarily
hiding the actual characters.
The rl_initialize() in nmc_readline_echo()s fixes broken line editing in
password prompts that weren't preceded a previous non-password prompt.
The other one is there for consistency only. (I guess we should be
initializing readline before use anyway; although it seems to initialize
itself anyway if we fail to do so...)
https://github.com/NetworkManager/NetworkManager/pull/241
|
|
|
|
|
|
|
|
|
|
|
| |
For upstream, we changed behavior here. However, I think certain
downstream don't want to do that, and revert patch "d37ad15f12 keyfile:
also add ".nmconnection" extension when writing keyfiles in /etc".
For that to make easier, keep the upstream sources closer to what
was. Revert.
This reverts commit e93d8cdb74d1bcd6d23ba33b4a1601b0e6dd8b99.
|
|
|
|
| |
Fixes: 8f107f5c00258c7a4fb780a25f299af6f116f575
|
|\
| |
| |
| | |
https://github.com/NetworkManager/NetworkManager/pull/236
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
is_available would recently return true after IWD had disconnected
if a connection was active because it would check that
priv->dbus_station_proxy was non-NULL (i.e. that the DBus interface was
still visible, which it wasn't) but that check would be overridden
if the NMDevice state was activated. Now require priv->dbus_obj to be
non-NULL, which would even be enough on its own although I'm leaving the
previous check there too to catch potential IWD states we don't support
in which priv->dbus_station_proxy is NULL without an active connection.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Sanity check networks received from the Station.GetOrderedNetworks()
DBus method. Duplicates shouldn't happen but the code should be safe
against bogus data received over DBus. There was a recent bug in a
library used by IWD causing occasional duplicates to be returned which
would cause invalid memory accesses reported by valgrind in NM because
g_hash_table_insert would free what we passed as the key.
|
| |
| |
| |
| |
| | |
Start a new scan with 0 delay after a device goes into the disconnected
state, goes UP or freshly appears on DBus instead of waiting 10 seconds.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Watch for connection-removed events and delete corresponding IWD network
configs if found. This mainly changes anything for 802.1X networks
where the deleted NM connections might annoyingly re-appear after a
restart. For PSK networks though it'll make IWD forget the password
which, until now, would be remembered by IWD even if it was removed or
changed in the NM profile, which is a bug.
This is still fragile because we don't handle "connection-updated"
events so the data->mirror_connection pointer for a known network record
may after some time point to an NMSettingsConnection with a different
SSID or security type and there are corner cases where the IWD-side
profile will not be forgotten. At least I'm trying to make sure we
don't crash and don't wrongly remove any IWD profile which could also be
annoying for complicated EAP configs.
|
| |
| |
| |
| |
| |
| |
| | |
Something is possibly wrong with the DBus signal handling if a newly
added KnownNetwork interface already has an entry in
priv->known_networks, but since we handle this case add a warning and
update the GDBusProxy pointer for that existing entry.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
interface_added expects mirror_8021x_connection() to return the pointer to
the existing connection if one exists, and NULL on error, rather than
NULL if a conneciton exists. While touching that, add logic to return
specifically a connection with EAP method set to 'external' if one
exists even though this should not affect any other logic we have
currently.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Some internal logic causes the secrets in a connection to be
occasionally moved to NMSettingConnection's priv->system_secrets after a
connection attempt so we need to use nm_act_request_get_secrets to get
them added to the device's settings connection and applied connection if
the PSK is missing during an AP or AdHoc mode activation (in
infrastructure mode we already do secret requests though they're cached
by IWD in most cases).
The common steps for the PSK available and unavailable scenarios is moved
from act_stage2_config to act_set_mode.
|
| |
| |
| |
| |
| | |
g_dbus_proxy_call and other GDBus function can accept a NULL as the
method call parameters.
|
|/
|
|
|
|
| |
This simplifies the code by using g_variant_lookup. In this handler
where we parse more than one property this is probably slower although
the number of string comparisons will be the same.
|
|\
| |
| |
| | |
https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/29
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
NMConnection keeps a list (hash table) of all settings.
There are two lookup methods to find a setting in a connection:
- nm_connection_get_setting() by GType
- nm_connection_get_setting_by_name() by name
Note, that nm_connection_get_setting_by_name() first converts the
name to a GType, and then looks up the setting by GType.
But then, nm_connection_get_setting() would again convert the GType to
the type name, and hash the name. That is pointless, just index by GType
directly.
Maybe, using a hash table is anyway overkill because commonly there are
only a handful of settings in a connection. Regardless of that, change
the hashing.
|
| | |
|
|/
|
|
|
| |
Literally ever use of nm_device_get_applied_setting() requires a
cast. Just don't.
|
|\
| |
| |
| | |
https://github.com/NetworkManager/NetworkManager/pull/239
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
For non-test code, we always passed TRUE.
For test code, setting with_extension is fine too, so drop the
argument.
|
| | |
|
| |
| |
| |
| |
| |
| | |
NM_CONFIG_KEYFILE_PATH_IN_MEMORY is now called NMS_KEYFILE_PATH_NAME_RUN.
This name seems odd in the current context, it will be more suitable
when we also have NMS_KEYFILE_PATH_NAME_LIB (for /usr/lib).
|
| |
| |
| |
| |
| |
| |
| | |
These utilities are concerned with valid file names (as NetworkManager
daemon requires it). This is relevant for everybody who wants to write
keyfile files directly. Hence, move it to libnm-core. Still as internal
API.
|
|/ |
|
|\
| |
| |
| | |
https://github.com/NetworkManager/NetworkManager/pull/238
|
| |
| |
| |
| |
| |
| |
| | |
For one, re-use the helper function instead of re-implementing
the check at multiple places.
Also, with this duplicate path separators are accepted.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Add a helper function for the common check whether a file is
inside a path. Also, this function handles special cases like
repeated file separators. However, as it is still entirely text
based, it also cannot recognize if two (literally) different
paths reference the same inode/file.
|
| |
| |
| |
| |
| |
| |
| | |
Previously, paths like ".", "./", ./." would all result in an
empty path. That is wrong, one dot must be kept.
https://github.com/systemd/systemd/commit/afbae3e9f23dc6682d48a1cc3585e8429ef07d8b
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We have a fork of a lot of useful systemd helper code.
However, until now we shyed away from using it aside from
the bits that we really need.
That means, although we have some really nice implementations
in our source-tree, we didn't use them. Either we were missing
them, or we had to re-implement them.
Add "nm-sd-utils.h" header to very carefully make internal
systemd API accessible to the rest of core.
This is not intended as a vehicle to access all of internal
API. Instead, this must be used with care, and only a hand picked
selection of functions must be exposed. Use with caution, but where it
makes sense.
|
|
|
|
|
|
|
|
|
|
| |
Previously a uint property was assigned with a guint64 value, which
has a different size. Fix this and add a warning when the read value
can't be converted.
Fixes: ecc074b2f8a6240d50f590c898b33158806b51a1
https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/66
|
|
|
|
|
|
|
|
|
| |
Fixed build with clang:
src/ndisc/nm-lndp-ndisc.c:494:27: error: unused variable 'ndisc_keep_alive' [-Werror,-Wunused-variable]
gs_unref_object NMNDisc *ndisc_keep_alive = g_object_ref (ndisc);
^
Fixes: 9aa628cedb707e9c4f0e0dba437ec22375a0032e
|
| |
|
|\
| |
| |
| | |
https://github.com/NetworkManager/NetworkManager/pull/173
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This makes it possible to utilize agents in the "external UI" mode
instead of hardcoded handling of VPN secrets requests.
Ideally this would be turned into a library so that nm-applet can share
the code, but figuring out the right API might be a non-trivial
undertaking.
|
| |
| |
| |
| |
| | |
We're basically rather careless when parsing the auth-dialog protocol.
Let's add some warning so we get an early alert when something's wrong.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
| |
Equals sign was picked as a continuation character arbitratily.
It would simplify parsing, if we cared.
DATA_KEY=some-key
DATA_VAL=string
=continued after a line break
SECRET_KEY=key names
=can have
=continuations too
SECRET_VAL=value
DONE
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On RHEL, openvswitch package is not in the base set of packages. Hence,
we cannot depend NetworkManager-ovs package on openvswitch.
This isn't really a problem, because NetworkManager's OVS plugin must
anyway behave graceful when openvswich service is not running or not
available. It only means, that a user who wants to use the OVS plugin
needs to explicitly install the openvswitch package.
https://bugzilla.redhat.com/show_bug.cgi?id=1629178
https://bugzilla.redhat.com/show_bug.cgi?id=1633190
|
|
|
|
|
| |
During gitlab-ci, some tests may take a long time. Increase
the default timeout.
|
|
|
|
|
| |
Improve "checkpatch-feature-branch.sh" to support accepting
range as argument.
|
| |
|
|
|
|
|
| |
Our gitlab CI sometimes takes a long time with the
"/link/create-many-links/1000" test.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The main purpose of "checkpatch-feature-branch.sh" is to test all
patches of a feature branch. When we run the script against master
(or nm-1-*), then there is no feature branch.
Previously, the script would just error out.
That is not very useful, in particular as we call this from gitlab-ci,
which also runs on master.
Instead, in that case, test the HEAD.
|
|\
| |
| |
| | |
https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/25
|
| |
| |
| |
| | |
See-also: https://docs.gitlab.com/ee/ci/yaml/
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This takes current HEAD branch, and finds all the commits what
are not on master or one of the nm-1-* branches, and runs
checkpatch.pl on each.
The use is to run checkpatch.pl on all patches of a feature
branch.
|
| |
| |
| |
| | |
It will be called by .gitlab-ci.yml to install the packages.
|
| |
| |
| |
| |
| | |
All platform tests were run twice with the `linux` platform, instead of
`fake` and `linux`, as expected.
|
| |
| |
| |
| |
| | |
Fix the test, to check that the nmp-object was deleted. It is
no longer visible and no longer alive.
|
|/
|
|
|
|
| |
This wouldn't even dereference the dangling pointer, but
merely comparing it for pointer equality. Still, it's actually
undefined behavior. Avoid it.
|
|
|
|
|
|
| |
ppp_status is of type NMPPPStatus whereas PHASE_RUNNING is pppd's type.
https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/28
|