| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Otherwise merely including a header would trigger a deprecation warhing.
The signal slot is not really used anyway.
|
|
|
|
| |
Fixes: f7b1b2820245aff26da0c2c946b55752e91112e5
|
|
|
|
|
|
| |
Python 3 has no "cmp" argument to sorted().
Fixes: b0da972f5fa51608cca5837af9fe7094818204f8
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
NMActiveConnectionStateReason
NMVpnConnectionStateReason is no longer used and replaced by
NMActiveConnectionStateReason. However, the old enums should
stay in place as they were:
Otherwise:
#define NMVpnConnectionStateReason NMActiveConnectionStateReason
causes compiler warnings:
NMVpnConnectionStateReason x;
x = NM_VPN_CONNECTION_STATE_REASON_UNKNOWN; // -Wenum-conversion
if (x == NM_VPN_CONNECTION_STATE_REASON_NO_SECRETS) { } // -Wenum-compare
Similarly, a user who didn't upgrade shall continue to get the
old GType for NM_TYPE_VPN_CONNECTION_STATE_REASON.
In practice, old users will have no issues using the old enum
the places where it worked before.
The only use of the deprecated enum is in vpn_state_changed()
signal slot of NMVpnConnection. This makes the signal slot
itself deprecated. However, NMVpnConnection is an NMObject and commonly
created within libnm itself, not by the user. It is very unlikely that
a user of libnm subclassed NMVpnConnection and makes use of the
vpn_state_changed() signal slot. So, deprecate it without replacement.
Fixes: a91369f80d44d1fc748fc3a9f5d9ef0fb566c77c
|
|
|
|
| |
Fixes: 40ffb962bec3700e447254d4a1cc93f21b8a25dd
|
| |
|
|
|
|
|
| |
It's now the same as NMActiveConnectionStateReason. Keep a compatibility
typedef and enum.
|
| |
|
|
|
|
|
|
|
|
|
| |
Note that the reason tracking starts as soon as the object exists (which
is immediately after GDBusObject is created), not when the asynchronous
NMObject initialization finishes. That is so that we the reason changes
in between are not lost.
The vpn-connection should probably be doing the same.
|
|
|
|
|
|
|
|
| |
It includes a reason code that makes it possible for the clients to be
more reasonable about error messages.
The reason code is essentially copied from the VPN, plus three more
reasons that were useful for non-VPN connections.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In practice, this should only matter when there are multiple
header files with the same name. That is something we try
to avoid already, by giving headers a distinct name.
When building NetworkManager itself, we clearly want to use
double-quotes for including our own headers.
But we also want to do that in our public headers. For example:
./a.c
#include <stdio.h>
#include <nm-1.h>
void main() {
printf ("INCLUDED %s/nm-2.h\n", SYMB);
}
./1/nm-1.h
#include <nm-2.h>
./1/nm-2.h
#define SYMB "1"
./2/nm-2.h
#define SYMB "2"
$ cc -I./2 -I./1 ./a.c
$ ./a.out
INCLUDED 2/nm-2.h
Exceptions to this are
- headers in "shared/nm-utils" that include <NetworkManager.h>. These
headers are copied into projects and hence used like headers owned by
those projects.
- examples/C
|
|
|
|
|
|
|
| |
Unify marking GObject properties that are G_PARAM_CONSTRUCT_ONLY
with a comment
/* construct-only */
|
|
|
|
|
|
|
|
|
| |
The libnm cache types don't have public _new() functions.
However, such types can be easily created using g_object_new()
directly from user code.
Such a usage is not supported. Add an assertion that a valid
dbus-object is present.
|
|
|
|
| |
Fixes: 0fdd71fe6ece66a801f5ff66e0d26b7d26953c14
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds definition of a set of known route option attributes to
libnm-core and helper functions.
nm_ip_route_attribute_validate() performs the validation of the
attribute type and, in case of a formatted string attribute, of its
content.
nm_ip_route_get_variant_attribute_spec() returns the attribute format
specifier to be passed to nm_utils_parse_variant_attributes(). Since
at the moment NMIPRoute is the only user of NMVariantAttributeSpec and
the type is opaque to users of the library, the struct is extended to
carry some other data useful for validation.
|
|
|
|
|
|
|
|
|
|
|
| |
Various libnm objects (addresses, routes) carry an hash table of
attributes represented as GVariants indexed by name. Add common
routines to convert to and from a string representation.
To parse a string, a knowledge of the supported attributes (and their
types) is needed: we represent it as an opaque type
NMVariantAttributeSpec that callers must query to the library for the
specific object type and pass to the parse function.
|
|
|
|
|
|
| |
manager is gone
https://bugzilla.redhat.com/show_bug.cgi?id=1425838
|
| |
|
|
|
|
|
|
|
| |
Add support for creating dummy devices. This commit adds a D-Bus
interface 'org.freedesktop.NetworkManager.Device.Dummy' which is used
primarily for determining the device type but does not carry any
properties.
|
|
|
|
|
| |
The setting must be present in connections with type=dummy. It does
not contain any property.
|
|
|
|
|
|
|
| |
The property can be used to tune the authentication timeout. It's
especially useful to speed up the failure in case the port doesn't
support 802.1X and make NM try a different, non-authenticated
connection.
|
| |
|
| |
|
| |
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=778615
|
|
|
|
|
|
| |
Useful for certificates that are stored on PKCS#11 tokens. We fail
verification if someone tries tu specify a password for a blob or a flat
file.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I think NM_CACHED_QUARK_FCN() is better because:
- the implementation is in our hand, meaning it is clear that
putting a "static" before NM_CACHED_QUARK_FCN() is guaranteed to
work -- without relying on G_DEFINE_QUARK() to be defined in a way
that this works (in fact, we currently never do that and instead
make all functions non-static).
- it does not construct function names by appending "_quark".
Thus you can grep for the entire function name and finding
the place where it is implemented.
- same with the stings, where the new macro doesn't stringify the
argument, which is less surpising. Again, now you can grep
for the string including the double quoting.
(yes, I really use grep to understand the source-code)
|
|
|
|
|
|
|
|
|
|
| |
The -Wimplicit-fallthrough=3 warning is quite flexible of accepting
a fall-through warning.
Some comments were missing or not detected correctly.
Thereby, also change all other comments to follow the exact
same pattern.
|
|
|
|
|
|
|
| |
The user can't do much about it and we can recover. This is a temporary
measure to avoid unnecessarily bothering the user.
(cherry picked from commit 7fec0755c9072dc37140a7b63b491ed02a3539cd)
|
|
|
|
|
| |
Fixes: 6c96aafaa9a61ca4fe713551a4cd4b15fb7e8a63
(cherry picked from commit 22722b77322fb3ddc1a99509340e8175acddb154)
|
|
|
|
|
|
|
|
| |
At some point gobject-introspection added an API to add a library path
and stopped honoring the LD_LIBRARY_PATH (a bug, according to GI
documentation?).
(cherry picked from commit 6c96aafaa9a61ca4fe713551a4cd4b15fb7e8a63)
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The new NMSettingMacsec contains information necessary to establish a
MACsec connection. At the moment we support two different MACsec
modes, both using wpa_supplicant: PSK and EAP.
PSK mode is based on a static CAK key for the MACsec key agreement
protocol, while EAP mode derives keys from a 802.1x authentication and
thus requires the presence of a NMSetting8021x in the connection.
|
|
|
|
|
| |
At the moment the device only exposes the current link status, but
cannot create new links.
|
|
|
|
| |
The getters just return the whole URI as-is, without any mangling.
|
|
|
|
| |
Version of nm_utils_iface_valid_name() with error reporting.
|
|
|
|
|
| |
if (nm_utils_version () < NM_ENCODE_VERSION (1, 5, 0))
g_error ("Requires at least version 1.5.0");
|
|
|
|
| |
Fixes: a8d60052564371b530b8375716a9a0da77d22990
|
| |
|
|
|
|
|
|
|
|
|
| |
has_key() has long been dropped
https://docs.python.org/3.1/whatsnew/3.0.html#builtins
Should still work with anything from 2.3 onwards
https://github.com/NetworkManager/NetworkManager/pull/11
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From valgrind:
==21921== Invalid free() / delete / delete[] / realloc()
==21921== at 0x4C2CD5A: free (vg_replace_malloc.c:530)
==21921== by 0x81C4F2D: g_free (gmem.c:189)
==21921== by 0x81AB021: g_error_free (gerror.c:491)
==21921== by 0x81AB325: g_clear_error (gerror.c:674)
==21921== by 0x767B555: reg_request_cb (nm-secret-agent-old.c:616)
==21921== by 0x7A211F2: g_task_return_now (gtask.c:1107)
==21921== by 0x7A21228: complete_in_idle_cb (gtask.c:1121)
==21921== by 0x81BF6B9: g_main_dispatch (gmain.c:3154)
==21921== by 0x81BF6B9: g_main_context_dispatch (gmain.c:3769)
==21921== by 0x81BFA6F: g_main_context_iterate.isra.29 (gmain.c:3840)
==21921== by 0x81BFB1B: g_main_context_iteration (gmain.c:3901)
==21921== by 0x7A4748C: g_application_run (gapplication.c:2381)
==21921== by 0x118AEF: main (main.c:81)
It caused memory corruption and may result in strange nm-applet crashes.
|
|
|
|
|
| |
We may want to stop the plugin before we started connecting e.g. when the
plugin NeedsSecrets but we can't supply them.
|
|
|
|
|
|
|
|
| |
This makes it easier to install the files with proper names.
Also, it makes the makefile rules slightly simpler.
Lastly, the documentation is now generated into docs/api, which makes it
possible to get rid of the awkward relative file names in docbook.
|
|
|
|
| |
That serves no purpose whatsoever.
|
|
|
|
| |
It makes little sense to produce a YAML and then decompose it.
|
|
|
|
|
|
|
|
|
| |
Apparently, the client is used by the services we depend on (firewalld),
and an attempt to start the service would deadlock them.
This was an accidental change anyway.
Related firewalld change: https://github.com/t-woerner/firewalld/pull/171
|