Commit graph

173 commits

Author SHA1 Message Date
Dan Williams a8d33c7e2c libnm-util: convert nm_connection_duplicate() to GHashTableIter 2013-04-01 17:18:54 -05:00
Dan Williams 7a7ce3b8e2 libnm-util: convert nm_connection_dump() to GHashTableIter 2013-04-01 17:18:54 -05:00
Dan Williams df02e7324c libnm-util: convert nm_connection_compare() to GHashTableIter
And finally add some testcases for it too.
2013-04-01 17:18:54 -05:00
Dan Williams 66230eb2f6 libnm-util: reduce memory used by NMConnection
The setting names used when inserting a setting into the hash
table are const since they are derived from GObject internals,
so there's no need to strdup them.
2013-04-01 17:18:53 -05:00
Dan Winship 331b69bd90 libnm-util: split GValue transforms out of nm-utils.c
nm-utils.c is really big, so split the GValue transforms out into
their own file.
2013-03-26 12:15:49 -04:00
Dan Winship 6f44b7f3c6 all: remove redundant return-if-fail checks
NM_IS_FOO(x) returns FALSE if x is NULL, so we don't need a separate
(x != NULL) check before it.
2013-03-07 07:32:27 -05:00
Dan Winship feeafb8cf1 core: Update device activation for :carrier-detect
Add a "need_carrier" argument to nm_device_is_available(), to allow
distinguishing between "device is not available", "device is fully
available", and "device is available except for not having carrier".

Adjust various parts of NMDevice and NMManager to allow for the
possibility of activating a connection with :carrier-detect = "no" on
a device with no carrier, and to avoid auto-disconnecting devices with
:carrier-detect = "on-activate".

https://bugzilla.gnome.org/show_bug.cgi?id=688284
2013-02-15 13:40:39 -05:00
Dan Winship 57327a6a57 libnm-util, libnm-glib: fix NMConnection:path again
24cda2bc broke the ability to set NMConnection:path back to NULL after
it had been set, as part of a hack to try to make
NMRemoteConnection:dbus-path work. Fix that by moving the hack
entirely into NMRemoteConnection.

https://bugzilla.gnome.org/show_bug.cgi?id=693829
2013-02-14 13:47:44 -05:00
Dan Winship 24cda2bc36 libnm-util, libnm-glib: Make NMRemoteConnection instantiable by NMObject
In order to resolve NMRemoteConnection-valued properties, NMObject
needs to be able to create NMRemoteConnections. But NMObject assumes
that all the objects it will be creating have "dbus-connection" and
"dbus-path" properties. So add those properties to NMRemoteConnection,
aliasing the existing "bus" and "path" properties (and ensure that
whichever version gets set, we keep that value, rather than letting it
get overwritten by the NULL default value of the other one).

https://bugzilla.gnome.org/show_bug.cgi?id=693669
2013-02-14 09:31:33 -05:00
Dan Williams d723457ac7 libnm-util: add NMSettingBridgePort 2012-11-30 13:21:50 -06:00
Dan Williams 8ecded9a9b libnm-util: add NMSettingBridge 2012-11-30 13:21:50 -06:00
Dan Williams 38e3819b4e libnm-util: clean up setting registration
Make setting type registration less icky; instead of having the
connection register all the settings, have the settings themselves
register that information at library load time.  Putting this sort
of thing in G_DEFINE_TYPE_WITH_CODE is apparently more standard
than the home-rolled stuff we had before.  Also document the
priority stuff so when adding new settings, people know what
priority to use.

(cleanups by jklimes)
2012-10-29 15:12:58 -05:00
Dan Williams 4106013753 trivial: fix documentation typo 2012-08-06 19:53:39 -05:00
Dan Williams 07db961a6a libnm-util: clean up some private symbols
Symbols starting with "nm" are expected to be exported,
even though these are not since they're static.  So don't
prefix them with nm.
2012-07-23 09:17:04 -05:00
Pantelis Koukousoulas 8039dd30d8 adsl: add libnm-glib and nmcli code
For the finale, this is the libnm-glib and nmcli part of the support,
with this you can now make a full pppoatm connection from NetworkManager
by configuring it in system scope in a keyfile.

As an example, here is mine:
(password and username snipped for obvious reasons)

[connection]
id=MYISP
uuid=34d04e69-fdd9-4231-af2c-25ed1f34dc1e
type=adsl
timestamp=1304621332

[adsl]
username=user@myisp.com
password=mypassword
vpi=8
vci=35
encapsulation=vcmux
protocol=pppoa

[ipv6]
method=ignore

[ipv4]
method=auto

Extract from logs:
NetworkManager[29155]: <info> Activation (ueagle-atm0) starting connection 'MYISP'
NetworkManager[29155]: <info> (ueagle-atm0): device state change: disconnected -> prepare (reason 'none') [30 40 0]
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 1 of 5 (Device Prepare) scheduled...
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 1 of 5 (Device Prepare) started...
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 2 of 5 (Device Configure) scheduled...
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 1 of 5 (Device Prepare) complete.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 2 of 5 (Device Configure) starting...
NetworkManager[29155]: <info> (ueagle-atm0): device state change: prepare -> config (reason 'none') [40 50 0]
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 2 of 5 (Device Configure) successful.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 3 of 5 (IP Configure Start) scheduled.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 2 of 5 (Device Configure) complete.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 3 of 5 (IP Configure Start) started...
NetworkManager[29155]: <info> (ueagle-atm0): device state change: config -> ip-config (reason 'none') [50 70 0]
NetworkManager[29155]: <info> starting PPP connection
NetworkManager[29155]: <debug> [1304671146.590156] [nm-ppp-manager.c:1047] nm_ppp_manager_start(): command line: /usr/sbin/pppd nodetach lock nodefaultroute user user@myisp.com plugin pppoatm.so 8.35 noipdefault noauth usepeerdns lcp-echo-failure 0 lcp-echo-interval 0 ipparam /org/freedesktop/NetworkManager/PPP/0 plugin /opt/nmadsl/lib/pppd/2.4.5/nm-pppd-plugin.so
NetworkManager[29155]: <info> pppd started with pid 29175
NetworkManager[29155]: <debug> [1304671146.591235] [NetworkManagerUtils.c:816] nm_utils_get_proc_sys_net_value(): (ueagle-atm0): error reading /proc/sys/net/ipv6/conf/ueagle-atm0/accept_ra: (4) Failed to open file '/proc/sys/net/ipv6/conf/ueagle-atm0/accept_ra': No such file or directory
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 3 of 5 (IP Configure Start) complete.
Plugin pppoatm.so loaded.
Plugin /opt/nmadsl/lib/pppd/2.4.5/nm-pppd-plugin.so loaded.
** Message: nm-ppp-plugin: (plugin_init): initializing
** Message: nm-ppp-plugin: (nm_phasechange): status 3 / phase 'serial connection'
NetworkManager[29155]: <debug> [1304671146.612937] [nm-udev-manager.c:621] handle_uevent(): UDEV event: action 'add' subsys 'net' device 'ppp0'
NetworkManager[29155]: <debug> [1304671146.613134] [nm-udev-manager.c:525] net_add(): ignoring interface with type 512
NetworkManager[29155]: <debug> [1304671146.617308] [nm-netlink-monitor.c:117] link_msg_handler(): netlink link message: iface idx 35 flags 0x1090
Using interface ppp0
Connect: ppp0 <--> 8.35
** Message: nm-ppp-plugin: (nm_phasechange): status 5 / phase 'establish'
** Message: nm-ppp-plugin: (nm_phasechange): status 6 / phase 'authenticate'
** Message: nm-ppp-plugin: (get_credentials): passwd-hook, requesting credentials...
NetworkManager[29155]: <debug> [1304671149.639511] [nm-agent-manager.c:1044] nm_agent_manager_get_secrets(): Secrets requested for connection /org/freedesktop/NetworkManager/Settings/0 (adsl)
NetworkManager[29155]: <debug> [1304671149.639684] [nm-settings-connection.c:717] nm_settings_connection_get_secrets(): (34d04e69-fdd9-4231-af2c-25ed1f34dc1e/adsl:1) secrets requested flags 0x1 hint 'password'
NetworkManager[29155]: <debug> [1304671149.640950] [nm-agent-manager.c:959] get_start(): (0x9b4ad10/adsl) system settings secrets sufficient
NetworkManager[29155]: <debug> [1304671149.641332] [nm-settings-connection.c:573] agent_secrets_done_cb(): (34d04e69-fdd9-4231-af2c-25ed1f34dc1e/adsl:1) existing secrets returned
NetworkManager[29155]: <debug> [1304671149.641541] [nm-settings-connection.c:579] agent_secrets_done_cb(): (34d04e69-fdd9-4231-af2c-25ed1f34dc1e/adsl:1) secrets request completed
NetworkManager[29155]: <debug> [1304671149.643074] [nm-settings-connection.c:618] agent_secrets_done_cb(): (34d04e69-fdd9-4231-af2c-25ed1f34dc1e/adsl:1) new agent secrets processed
** Message: nm-ppp-plugin: (get_credentials): got credentials from NetworkManager
PAP authentication succeeded
** Message: nm-ppp-plugin: (nm_phasechange): status 8 / phase 'network'
local  IP address 94.70.90.201
remote IP address 80.106.108.12
primary   DNS address 195.170.0.1
secondary DNS address 195.170.2.2
** Message: nm-ppp-plugin: (nm_phasechange): status 9 / phase 'running'
** Message: nm-ppp-plugin: (nm_ip_up): ip-up event
** Message: nm-ppp-plugin: (nm_ip_up): sending Ip4Config to NetworkManager...
NetworkManager[29155]: <debug> [1304671150.607440] [nm-netlink-monitor.c:117] link_msg_handler(): netlink link message: iface idx 35 flags 0x110D1
NetworkManager[29155]: <info> PPP manager(IP Config Get) reply received.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 4 of 5 (IP4 Configure Get) scheduled...
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 4 of 5 (IP4 Configure Get) started...
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 5 of 5 (IP Configure Commit) scheduled...
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 4 of 5 (IP4 Configure Get) complete.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 5 of 5 (IP Configure Commit) started...
NetworkManager[29155]: <debug> [1304671150.608918] [nm-system.c:222] sync_addresses(): (ppp0): syncing addresses (family 2)
NetworkManager[29155]: <info> (ueagle-atm0): device state change: ip-config -> activated (reason 'none') [70 100 0]
NetworkManager[29155]: <info> Policy set 'MYISP' (ppp0) as default for IPv4 routing and DNS.
NetworkManager[29155]: <info> Activation (ueagle-atm0) successful, device activated.
NetworkManager[29155]: <info> Activation (ueagle-atm0) Stage 5 of 5 (IP Configure Commit) complete.

Signed-off-by: Pantelis Koukousoulas <pktoss@gmail.com>
2012-05-18 15:42:56 -05:00
Weiping Pan 23c1b6ad30 libnm-util: add VLAN setting and properties
Signed-off-by: Weiping Pan <wpan@redhat.com>

(dcbw: formatting cleanups and priority map code simplifications)
2012-02-16 15:05:55 -06:00
Dan Winship 839eab5564 Use glib-mkenums to generate enum types
Rather than generating enum classes by hand (and complaining in each
file that "this should really be standard"), use glib-mkenums.

Unfortunately, we need a very new version of glib-mkenums in order to
deal with NM's naming conventions and to fix a few other bugs, so just
import that into the source tree temporarily.

Also, to simplify the use of glib-mkenums, import Makefile.glib from
https://bugzilla.gnome.org/654395.

To avoid having to run glib-mkenums for every subdirectory of src/,
add a new "generated" directory, and put the generated enums files
there.

Finally, use Makefile.glib for marshallers too, and generate separate
ones for libnm-glib and NetworkManager.
2012-02-15 11:42:15 -05:00
Thomas Graf 1cd8d52061 bonding: add nm_connection_get_virtual_iface_name() to abstract kernel interface binding
Some connection types such as bonding, bridging and VLAN require
specific virtual kernel interfaces identified by name to be auto
connected to the connection.

The function nm_connection_get_virtual_iface_name() returns the name
of the kernel interface if the connection type requires this
functionatlity.

Each connection base type settings class can implement the function
get_virtual_iface_name() if the connection needs to be auto connected
to a specific kernel interface.

Signed-off-by: Thomas Graf <tgraf@redhat.com>
2011-12-08 09:56:47 -06:00
Thomas Graf 86d5a40677 libnm-util: add nm_connection_get_setting_serial()
Signed-off-by: Thomas Graf <tgraf@redhat.com>
2011-12-06 16:08:39 -06:00
Thomas Graf 5b7503e95e core: use nm_connection_get_setting_<type>() whenever possible
Leads to shorter, easier to read code and improves type casting safety.

Signed-off-by: Thomas Graf <tgraf@redhat.com>
2011-12-06 16:06:43 -06:00
Dan Winship d96bf9e866 libnm-util: add NMSettingInfiniband 2011-12-02 13:09:16 -06:00
Thomas Graf a2a0d78818 bonding: settings parser for ifcfg plugin + NMSettingBond class
Introduced a new TYPE=bond for ifcfg-rh configuration files.
Alternatively BONDING_MASTER=yes can be specified instead of
setting the type explicitely to maintain backwards compatibility
with existing configuration files.

Bonding device files require a DEVICE= line to be present which
specifies the virtual bonding interface in the kernel. We do not
allow auto-generation of the name in order to keep confusion to
a minimum when reusing existing bonding interfaces.

The BONDING_OPTS= parameter can be used to specify various bonding
related options, such as:
  - mode
  - miimon
  - updelay
  - downdelay
  - arp_interval
  - arp_ip_target

By default, the NMSettingBond class uses a miimon value of 100 which
seems like a sensible default value for 99% of all configurations.
If this is not suitable, an arp_ip_target needs to be specified
manually.

A writer is not yet implemented.

Changes v2:
 - renamed DeviceName property to InterfaceName
 - moved code to validate device name to dev_valid_name() for future use

Signed-off-by: Thomas Graf <tgraf@redhat.com>
2011-11-09 23:16:31 -06:00
Thomas Graf 594a2f677d libnm-util: add nm_connection_is_type()
Adds a helper nm_connection_is_type(connection, type) which returns TRUE
if a connection is of specified type.

Signed-off-by: Thomas Graf <tgraf@redhat.com>
2011-10-27 11:06:17 -05:00
Dan Winship 7b7d7bce2f libnm-util: add some more introspection annotations to silence warnings 2011-10-14 10:09:46 -05:00
Dan Williams 2b2404bbef settings: preserve agent secrets the right way
What we want to do here is keep separate caches of system and
agent secrets.  For system secrets, we cache them because NM
periodically clears secrets using nm_connection_clear_secrets() to
ensure they don't stay around in memory, and that transient secrets
get requested again when they are needed.  For agent secrets, we
only want them during activation, but a connection read from disk
will not include agent secrets becuase by definition they aren't
stored in system settings along with the connection.  Thus we need
to keep the agent/transient secrets somewhere for the duration of
the activation to ensure they don't get deleted.

This removes the copy-back hack in update_auth_cb() which copied
agent/transient secrets back into the connection over top of the
transient secrets that had been copied back in
nm_settings_connection_replace_settings().  No reason to copy
them twice if we keep an agent/transient secrets hash and do
the right thing with it.
2011-08-16 16:19:23 -05:00
Dan Williams e2d88f59e6 settings: preserve agent secrets over Update operation
The core problem was that the Update would trigger a write to
disk to save the connection's new settings, which called
nm_settings_connection_replace_settings().  Which saved existing
transient (agent/unsaved) secrets, replaced settings with the
new ones from Update(), then copied back the old transient
secrets.  This was to ensure that changes triggered from getting
agent secrets during activation (which might write the connection
out to disk if new system secrets were provided, which triggered
an inotify read-back of the connection, which blew away the
transient secrets just returned from the agent) didn't blow away
transient secrets.  Unfortunately that fix was too general.

As a quick hack for now, copy the new secrets and re-apply them
after nm_connection_replace_settings() has run.  We'll do the
actual fix later, but it's more involved and needs more testing
so we don't want to apply it this close to release.
2011-08-16 15:48:38 -05:00
Dan Williams 9ff4914ccc libnm-util: fix some GObject Introspection annotations
Unfortunately, GObject Introspection can no longer describe deeper
types, like those inside nested hash tables, which NM uses extensively
for the NMConnection type and other places.  So we have to remove
those descriptions.  But this moves us back into compliance with
GOI annotation formats.
2011-05-10 13:24:07 -05:00
Dan Williams df511f74f7 build: use -Wundef and fix up cases where stuff wasn't defined (bgo #647157) 2011-04-14 13:19:12 -05:00
Dan Williams 53ed3ab41f libnm-util: constify a variable 2011-04-13 15:52:30 -05:00
Dan Williams 74a0b1d9d1 libnm-util: verify connection's 'type' setting is actually a base type
By 'base type' I mean a hardware-related type that can actually be used
to activate the connection, like wifi, wired, gsm, cdma, wimax, bluetooth,
etc, but not ipv4, ipv6, 8021x, etc.
2011-03-28 10:40:38 -05:00
Giovanni Campagna 4480365db7 libnm-glib: introspection annotation fixes (bgo #643011) 2011-03-16 15:25:37 -05:00
Dan Williams 27e7177ec4 libnm-util: add setting accessor helpers (bgo #644746)
Makes code cleaner.
2011-03-15 10:32:42 -05:00
Kjartan Maraas b224ab8e56 trivial: let g_free and g_strdup handle NULL (bgo #644763) 2011-03-15 00:08:58 -05:00
Kjartan Maraas c2b4b9c1d7 build: fix return types (bgo #644665)
Some functions were returning FALSE or 0 instead of NULL.
2011-03-14 01:05:51 -05:00
Dan Williams 72dac886a7 libnm-util: allow setting-only hashes with nm_connection_update_secrets()
It's easier to be able to pass both a whole hashed connection, or just
a hashed setting to the function, and have it figure out what needs
to be updated based on the given setting_name.

Add some testcases to make sure that all works correctly too.
2011-03-09 09:31:44 -06:00
Jiří Klimeš 28cf83fe94 trivial: fix description of nm_connection_get_id() 2011-03-08 13:50:36 +01:00
Dan Williams 54918e32e4 libnm-util: add nm_connection_diff()
Returns a list of keys that differ between the settings in each
connection.  nm_connection_compare() can't do that.
2011-02-22 23:36:43 -06:00
Giovanni Campagna e77acd43b6 libnm-glib: more GObject introspection fixes (bgo #181415)
Fix some annotations and add the necessary ones for new functions.
2011-02-21 18:11:21 -06:00
Dan Williams c5235f87db libnm-util: add connection helpers for ID and UUID
Shortcuts.  Getting the ID and UUID is used in a ton of places
and this helps cut down on code.
2011-02-09 16:34:42 -06:00
Dan Williams 09d608b99c trivial: more spacing cleanups 2011-02-09 16:30:30 -06:00
Dan Williams c36c81e2b9 libnm-util: fix updating secrets
Broken by 5dd4f1ea01
2011-02-02 17:18:50 -06:00
Dan Williams c4ada67108 libnm-util: simplify nm_connection_for_each_setting_value()
And use less memory as a bonus.
2011-01-31 21:53:16 -06:00
Dan Williams 37a9303c2e libnm-util: fix hashing connections and settings
The first-level hash table key should be the setting name itself,
not the GType name of the setting's GObject.  There's probably a
better way to do this to reduce that confusion.
2011-01-27 10:37:01 -06:00
Dan Williams e68e27aa75 libnm-util: add 'flags' argument to nm_connection_to_hash() and nm_setting_to_hash()
Simplifies code internally, and makes it easier for clients as well in
some cases where they want to control what ends up in the resulting
hash and what does not.
2011-01-26 14:14:37 -06:00
Giovanni Campagna 3ebecd2a29 introspection: add GObject introspection support (bgo #637032)
Add the necessary annotations (the mininum required, that is those
on return values. NULL parameters or container types may require
more), and the Autotools stuff to get a NetworkManager GIR for
libnm-util and a NMClient for libnm-glib.
2011-01-21 14:46:09 -06:00
Dan Williams f9ceafd4a1 Merge remote branch 'origin/master' into rm-userset 2011-01-12 15:46:37 -06:00
Dan Williams 0587ef1179 Merge remote branch 'origin/master' into wimax 2011-01-02 17:24:23 -06:00
Dan Williams 8f699a77f2 libnm-util: check all valid permissions property types 2010-10-29 23:19:41 -05:00
Dan Williams 947efa3080 libnm-util: verify permissions property type
Connections are normally created from hashes using g_object_set()
which calls that object's set_property handler.  But GObject does
not allow errors to be returned from property handlers, so if the
type doesn't match what it should be, the property does not get
set, and error is printed to stdout, and life goes on.

But that's not what we want for the permissions property since the
client might expect that property to be set, but the connection now
is available to everyone.  So validate the permissions property
type (its really the only one we need to be so paranoid about)
and return an error when the incoming property type is wrong.
2010-10-29 22:31:23 -05:00
Daniel Gnoutcheff fa8c9304b5 libnm-*: remove user settings support
Remove code related to "connection scope" and such. Later, we will also
do lots of code flattening and simplification that's possible now that
user settings are gone.
2010-08-06 13:05:46 -04:00
Dan Williams 22aee1ac8b libnm-util: remove useless semicolons 2010-05-26 00:30:32 -07:00
Dan Williams 7754690e7e libnm-util: use hash table iterators for simpler code 2010-05-26 00:28:26 -07:00
Tambet Ingo ac0f32537e Merge branch 'master' into wimax 2009-12-29 11:25:37 +02:00
Dan Williams e2b9e401ca libnm-util: remove unused variable 2009-12-23 11:07:50 -08:00
Tambet Ingo 75c734f1a9 wimax: Implement WiMAX support 2009-12-18 15:41:27 +02:00
Dan Williams 74fbda9b85 doc: fixes 2009-08-30 23:31:07 -05:00
Dan Williams ce7ebaa7f9 libnm-util: ensure NMConnection scope & path can be set on construction 2009-08-11 00:02:05 -05:00
Dan Williams 0993ea3989 libnm-util: fix DEFAULT_MAP_SIZE; broken by ff88cf12c2 2009-08-10 15:21:16 -05:00
Daniel Drake ff88cf12c2 olpc: add mesh device logic and config setting 2009-08-05 16:34:02 -04:00
Dan Winship 90bd1ad5cd Install and fix up libnm-util IPv6 config stuff 2009-07-29 21:34:19 -04:00
Dan Williams d74ab39671 libnm-util: register settings hash in nm_connection_lookup_setting_type()
If not already registered by something else...
2009-06-01 10:45:11 -04:00
Dan Williams 4ab96e8eb6 bluetooth: add NMSettingBluetooth 2009-05-13 12:34:45 -04:00
Dan Williams ccbd9155ec Documentation updates
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4331 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-24 04:30:36 +00:00
Dan Williams d0dd5171ba Documentation updates
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4330 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-24 02:45:35 +00:00
Dan Williams 2328650d2e Documentation fixes
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4328 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-23 22:55:03 +00:00
Dan Williams 4d1859dc6a 2008-11-20 Dan Williams <dcbw@redhat.com>
* libnm-util/libnm-util.ver
	  libnm-util/nm-utils.c
	  libnm-util/nm-utils.h
	  libnm-util/nm-utils-private.h
	  libnm-util/nm-connection.c
		- (nm_utils_register_value_transformations): make private, called
			from NMConnection registration anyway



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4320 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 20:22:14 +00:00
Dan Williams 9e07f22295 documentation udpate
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4318 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 16:14:56 +00:00
Dan Williams c818262849 Doc update
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4317 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 16:06:57 +00:00
Dan Williams b8b93197a9 Fix argument names so they show up in the docs
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4316 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 16:03:00 +00:00
Dan Williams 320c3f378c 2008-11-20 Dan Williams <dcbw@redhat.com>
* libnm-util/libnm-util.ver
	  libnm-util/nm-setting.c
	  libnm-util/nm-setting.h
		- Add NMSetting errors
		- (nm_setting_update_secrets): return errors

	* libnm-util/nm-connection.c
	  libnm-util/nm-connection.h
		- (nm_connection_update_secrets): return errors

	* libnm-util/nm-setting-vpn.c
	  src/nm-activation-request.c
	  src/vpn-manager/nm-vpn-connection.c
		- Handle update secrets errors



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4314 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 15:44:57 +00:00
Dan Williams 034c1705ce Documentation updates
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4313 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 15:22:25 +00:00
Dan Williams 6e40cdb3a5 2008-11-20 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting.c
	  libnm-util/nm-setting.h
	  libnm-util/libnm-util.ver
		- (nm_setting_new_from_hash): rename from nm_setting_from_hash() to be
			consistent with nm_connection_new_from_hash()

	* src/nm-activation-request.c
	  libnm-util/nm-connection.c
		- Handle rename



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4312 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-20 14:47:08 +00:00
Dan Williams 9fc39274b9 2008-11-19 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-connection.h
	  libnm-util/nm-connection.c
		- Document public functions



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4301 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-19 18:30:38 +00:00
Dan Williams 3c2d8253ec 2008-11-19 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-connection.c
	  libnm-util/nm-connection.h
		- (nm_connection_replace_settings): take a GError

	* libnm-glib/nm-settings.c
	  libnm-glib/nm-dbus-connection.c
	  src/nm-manager.c
	  system-settings/plugins/ifcfg-suse/nm-suse-connection.c
	  system-settings/plugins/keyfile/nm-keyfile-connection.c
	  system-settings/plugins/keyfile/plugin.c
		- Handle, or don't handle, errors from nm_connection_replace_settings()



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4298 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-19 15:09:05 +00:00
Dan Williams 68a2fc9739 2008-11-19 Dan Williams <dcbw@redhat.com>
* libnm-util/libnm-util.ver
	  libnm-util/nm-connection.c
		- (nm_setting_register, nm_setting_unregister): unexport; they are
			private and don't have a use outside libnm-util



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4297 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-11-19 14:00:15 +00:00
Dan Williams 567396ad6d 2008-10-30 Dan Williams <dcbw@redhat.com>
* libnm-util/libnm-util.ver
	  libnm-util/nm-setting-ip6-config.c
	  libnm-util/nm-setting-ip6-config.h
	  libnm-util/Makefile.am
		- Make properties private and add accessor functions
		- Hide IPv6 stuff from public API, it's incomplete and completely unused

	* libnm-util/nm-connection.c
	  libnm-util/nm-utils.c
	  libnm-util/nm-utils.h
		- Ignore IPv6 stuff for now



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4240 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-10-30 19:39:51 +00:00
Dan Williams c438326110 2008-10-27 Dan Williams <dcbw@redhat.com>
Patch from Tambet Ingo <tambet@gmail.com>

	* libnm-util/nm-setting.h
	  libnm-util/nm-setting.c
		- Make properties private and add accessor functions

	* libnm-util/nm-connection.c
	  libnm-util/nm-setting-8021x.c
	  libnm-util/nm-setting-cdma.c
	  libnm-util/nm-setting-connection.c
	  libnm-util/nm-setting-gsm.c
	  libnm-util/nm-setting-ip4-config.c
	  libnm-util/nm-setting-ip6-config.c
	  libnm-util/nm-setting-ppp.c
	  libnm-util/nm-setting-pppoe.c
	  libnm-util/nm-setting-serial.c
	  libnm-util/nm-setting-template.c
	  libnm-util/nm-setting-vpn.c
	  libnm-util/nm-setting-wired.c
	  libnm-util/nm-setting-wireless-security.c
	  libnm-util/nm-setting-wireless.c
	  system-settings/plugins/keyfile/reader.c
	  system-settings/plugins/keyfile/writer.c
		- Use setting accessors



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4228 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-10-27 17:36:18 +00:00
Dan Williams d2ef616e51 Fill error when object isn't a connection (Alexander Sack)
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4074 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-09-18 13:31:11 +00:00
Dan Williams 10661abe17 2008-08-11 Dan Williams <dcbw@redhat.com>
Merge the vpn-properties setting with the vpn setting since it was pointless
	to keep both of them around.  Convert the vpn 'data' hash table to a hash
	of string:string (instead of string:variant) so that system settings plugins
	can have an easier time dealing with the arbitrary key/value pairs.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3923 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-08-11 17:13:22 +00:00
Dan Williams fb74207755 2008-08-04 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-connection.c
	  libnm-util/nm-connection.h
		- (nm_connection_verify): return error on missing 'connection' setting
			(found by Sjoerd Simons)



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3895 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-08-04 22:16:08 +00:00
Dan Williams 281791ac77 2008-07-27 Dan Williams <dcbw@redhat.com>
* libnm-util/*
		- Relicense to LGPLv2+



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3859 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-27 20:03:46 +00:00
Dan Williams 53e3399ab4 Actually handle registration of ipv6 setting
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3779 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-27 15:44:15 +00:00
Dan Williams 5a516abc4b 2008-06-26 Dan Williams <dcbw@redhat.com>
Patch from David Cantrell <dcantrell@redhat.com> and me

	* include/nm-dbus-glib-types.h
		- Add IP6 address types

	* libnm-util/Makefile.am
	  libnm-util/nm-setting-ip6-config.c
	  libnm-util/nm-setting-ip6-config.h
		- Add IP6 settings object

	* libnm-util/nm-connection.c
		- (register_default_settings): register ip6 settings object

	* libnm-util/nm-utils.c
	  libnm-util/nm-utils.h
		- (nm_utils_ip6_addresses_from_gvalue, nm_utils_ip6_addresses_to_gvalue,
		   nm_utils_ip6_dns_from_gvalue, nm_utils_ip6_dns_to_gvalue): add
			ip6 address conversion functions



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3778 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-26 21:30:33 +00:00
Tambet Ingo 2046ec13e3 2008-06-20 Tambet Ingo <tambet@gmail.com>
* libnm-util/nm-connection.c (nm_connection_duplicate): Implement.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3759 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-20 11:26:50 +00:00
Dan Williams 05e9de9402 2008-06-12 Dan Williams <dcbw@redhat.com>
Add a GError argument to nm_connection_verify() and nm_setting_verify(),
	and add error enums to each NMSetting subclass.  Each NMSetting subclass now
	returns a descriptive GError when verification fails.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3751 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-12 23:58:08 +00:00
Tambet Ingo 0d91f460d6 2008-04-15 Tambet Ingo <tambet@gmail.com>
* libnm-util/nm-setting.c (nm_setting_duplicate): Implement.

	* libnm-util/nm-connection.c (nm_connection_remove_setting): Implement.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3560 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-04-15 16:03:26 +00:00
Dan Williams 70e79d60dd 2008-03-17 Dan Williams <dcbw@redhat.com>
Split the 802.1x bits out of the wireless-security setting so they are
	generalized enough for wired 802.1x to use too.

	* introspection/nm-exported-connection.xml
		- GetSecrets now returns 'a{sa{sv}}' (a hash of settings hashes) instead
			of just a hash of the secrets for one setting

	* libnm-util/nm-setting-wireless-security.c
	  libnm-util/nm-setting-wireless-security.h
		- Remove 802.1x-specific stuff
		- Added leap-username and leap-password properties for old-school LEAP

	* src/nm-device.c
	  src/nm-device.h
		- (connection_secrets_updated_cb): take a list of updated settings names,
			not just one

	* src/supplicant-manager/nm-supplicant-config.c
	  src/supplicant-manager/nm-supplicant-config.h
		- (nm_supplicant_config_add_setting_wireless_security): remove 802.1x
			specific stuff; fix for updated LEAP bits; punt 802.1x stuff
			to nm_supplicant_config_add_setting_8021x()
		- (nm_supplicant_config_add_setting_8021x): add an 802-1x setting to
			the supplicant config

	* src/nm-device-802-11-wireless.c
		- (build_supplicant_config): pass in the 802.1x setting too, if any
		- (real_connection_secrets_updated): take a list of updated settings
			names, not just one

	* src/nm-device-802-3-ethernet.c
	  src/nm-cdma-device.c
	  src/nm-gsm-device.c
		- (real_connection_secrets_updated_cb): take a list of updated settings
			names, not just one

	* src/nm-activation-request.c
	  src/nm-activation-request.h
		- (nm_act_request_class_init): the 'connection-secrets-updated' signal
			now passes a list of updated settings names, not just one
		- (update_one_setting): new function; handle one updated setting
		- (get_secrets_cb): handle multiple settings returned from the
			settings service; have to be careful of ordering here as there are
			some dependencies between settings (ex. wireless-security and 802.1x
			in some cases)

	* src/marshallers/nm-marshal.list
		- new marshaller for connection-secrets-updated signal

	* libnm-util/nm-setting-8021x.c
		- Add back the 'pin' and 'psk' settings, for EAP-SIM and EAP-PSK auth
			methods
		- (verify): a valid 'eap' property is now required

	* libnm-util/nm-connection.c
		- (register_default_settings): add priorities to settings; there are
			some dependencies between settings, and during the need_secrets
			calls this priority needs to be respected.  For example, only the
			wireless-security setting knows whether or not the connection is
			going to use 802.1x or now, so it must be asked for secrets before
			any existing 802.1x setting is
		- (nm_connection_lookup_setting_type): expose

	* libnm-util/nm-setting-wireless.c
		- (verify): should verify even if all_settings is NULL; otherwise won't
			catch the case where there is missing security

	* libnm-util/nm-setting-wireless-security.c
		- Remove everything to do with 802.1x
		- Add old-school LEAP specific properties for username and password
		- (need_secrets): rework LEAP secrets checking
		- (verify): rework for LEAP and 802.1x verification



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3470 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-03-17 19:37:23 +00:00
Tambet Ingo 13e40f51ac commit de4e1e57541f62e610d5b622f2d38f5c84848daa
Author: Tambet Ingo <tambet@gmail.com>
Date:   Fri Mar 14 16:38:48 2008 -0600

    2008-03-14  Tambet Ingo  <tambet@gmail.com>

    	* libnm-util/Makefile.am: Add new files to build.

    	* libnm-util/nm-connection.c: Register NMSetting8021x.

    	* libnm-util/nm-setting-8021x.c
    	* libnm-util/nm-setting-8021x.h: Implement.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3466 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-03-14 22:40:35 +00:00
Tambet Ingo cc2675ebb1 Implement PPPoE.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3418 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-03-11 16:37:41 +00:00
Dan Williams 316abd62fd 2008-02-20 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-connection.c
	  libnm-util/nm-connection.h
		- (nm_connection_compare): accept compare flags and pass them to the
			setting compare function

	* libnm-util/nm-setting.c
	  libnm-util/nm-setting.h
		- (nm_setting_compare): accept compare flags; ignore properties that are
			marked fuzzy

	* libnm-util/nm-setting-connection.c
	  libnm-util/nm-setting-wireless.c
	  libnm-util/nm-setting-ppp.c
	  libnm-util/nm-setting-wired.c
		- Mark some setting properties as ignorable when doing a fuzzy compare

	* src/nm-device.c
		- (device_activation_precheck): use exact compare



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3336 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-02-21 04:34:34 +00:00
Dan Williams fd0ab916c8 2008-02-20 Dan Williams <dcbw@redhat.com>
* Global rename of NMConnectionSettings -> NMExportedConnection to cut down
		on confusing names

	* Add 'path' and 'scope' properties to NMConnection since both NM and the
		applet were having to hack this in anyway.  Remove the 'path' stuff from
		NMExportedConnection

	* Internally rename NMConnectionType -> NMConnectionScope

	* Provide default implementations of the 'get_id' and 'get_settings' methods
		of NMExportedConnection



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3334 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-02-20 22:37:39 +00:00
Dan Williams 54b327f35a 2008-01-21 Dan Williams <dcbw@redhat.com>
* include/NetworkManager.h
		- Add CDMA mobile broadband card device type

	* src/nm-hal-manager.c
		- (modem_device_creator): handle both CDMA and GSM modems; the device
			must now be tagged with 'cdma' or 'gsm' capability

	* src/nm-cdma-device.c
	  src/nm-cdma-device.h
	  src/Makefile.am
		- Add the CDMA mobile broadband card device class

	* libnm-util/nm-connection.c
		- (register_default_settings): add NMSettingCdma

	* libnm-util/nm-setting-cdma.c
	  libnm-util/nm-setting-cdma.h
	  libnm-util/Makefile.am
		- Add the CDMA mobile broadband card setting class

	* libnm-glib/nm-cdma-device.c
	  libnm-glib/nm-cdma-device.h
	  libnm-glib/Makefile.am
		- Add the CDMA mobile broadband card GLib proxy class

	* libnm-glib/nm-client.c
		- (get_device): handle CDMA devices too



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3261 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-01-21 19:14:18 +00:00
Tambet Ingo 0bd26c1abe 2007-12-10 Tambet Ingo <tambet@gmail.com>
* Replace all occurences of 'UMTS' with 'GSM'.




git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3161 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-12-10 09:17:40 +00:00
Tambet Ingo db5a10dc4d 2007-11-28 Tambet Ingo <tambet@gmail.com>
Merge the beginnings of the new GSM card support.

        * src/ppp-manager/nm-ppp-manager.c (nm_ppp_manager_stop): Remove
        * the
        ppp watch source before killing pppd - If this happens from
g_object_unref()
        then the ppp manager is already destroyed by the time the watch
callback runs.

        * src/nm-hal-manager.c: Add a device_type_name string to the
        * device
        creators, so that we can print a nice human readable string when
a
        device is added.

        * src/nm-umts-device.c (automatic_registration_get_network):
        * Query
        for the activated network, not much is done with the result
thought.

        * src/nm-serial-device.c (nm_serial_device_get_reply):
        * Implement.
        (ppp_ip4_config): Change the device state to activated here for
now.
        (real_check_connection): Make sure the connection includes ppp
setting.

        * libnm-glib/nm-client.c (get_device): Handle umts devices.

        * libnm-glib/Makefile.am: Add the new files to build.

        * libnm-glib/nm-umts-device.c: 
        * libnm-glib/nm-umts-device.h: Implement.

2007-11-26  Tambet Ingo  <tambet@gmail.com>

        * src/nm-umts-device.c (automatic_registration_get_network): For
        * now, dial
        immediately, nm_serial_device_get_reply() isn't implemented
correctly yet.

        * src/nm-serial-device.c (wait_for_reply_info_destroy): Don't
        * try to remove
        the timeout source - this function is only called when the
timeout source has
        been removed.
        (nm_serial_device_wait_for_reply): Allocate the duplicate
responses array
        to be big enough to contain the terminating zero element as
well.
        The timeout argument is meant to be in seconds now.
        (real_deactivate_quickly): Implement.

        * src/NetworkManager.conf: Allow root to own 
        "org.freedesktop.NetworkManager.PPP", deny it for everybody
else.

        * libnm-util/nm-setting-umts.c: Network type and band properties
        * are ints,
        (not unsigned ints).

        * libnm-util/nm-setting-serial.c (nm_setting_serial_class_init):
        * Fix a 
        small issue with parity bounds - capital letters have lower
ascii codes
        than lower case letters.

        * libnm-util/nm-connection.c (register_default_settings):
        * Register serial
        and umts settings.

2007-11-22  Tambet Ingo  <tambet@gmail.com>

        Remove the "index" property from devices as not all device types
have this.

        * include/NetworkManager.h (NM_DBUS_PATH_DEVICE): Remove.

        * src/nm-hal-manager.c (nm_get_device_index_from_hal): Remove.
        (wired_device_creator): Get the device interface from hal to
create the device.
        (wireless_device_creator): Ditto.

        * src/nm-device.c (nm_device_init): Remove the index member.
        (constructor): Remove the checks for index property, make
interface property
        a require constructor property.
        Use the HAL udi for DBus path for devices.
        (nm_device_get_index): Remove.
        (set_property): Remove index handling.
        (get_property): Ditto.
        (nm_device_get_dbus_path): Remove.

        * src/nm-device-interface.c (nm_device_interface_init): Remove
        * the index
        property.

        * src/nm-device-802-3-ethernet.c
        * (nm_device_802_3_ethernet_link_activated):
        Access the device index through it's interface.
        (nm_device_802_3_ethernet_link_deactivated): Ditto.
        (nm_device_802_3_ethernet_new): Remove the useless argument
test_dev. Remove
        index argument. Add interface argument.

        * src/nm-device-802-11-wireless.c
        * (nm_device_802_11_wireless_new): Remove
        the useless test_dev argument. Remove index argument. Add
interface arugment.

        * src/NetworkManagerSystem.c
        * (nm_system_device_set_from_ip4_config): Get the
        device index through interface.
        (nm_system_set_mtu): Ditto.

        * introspection/nm-device.xml: Remove the "Index" property.

2007-11-21  Tambet Ingo  <tambet@gmail.com>

        * src/nm-serial-device.c: 
        * src/nm-serial-device.c: 
        * src/nm-umts-device.c:
        * src/nm-umts-device.h: Implement.

        * src/nm-hal-manager.c (nm_get_device_driver_name):
        * libhal_free_string the string 
        allocated by libhal.
        (modem_device_creator): Implement.
        (register_built_in_creators): Register the modem creator.

        * src/nm-device-802-11-wireless.c
        * (nm_device_802_11_wireless_new): 
        Remove the unused test_dev argument.

        * src/nm-device-802-3-ethernet.c (nm_device_802_3_ethernet_new):
        * Ditto.

        * src/Makefile.am: Add new files to build.
        Link in ppp-manager.

        * libnm-util/nm-setting-umts.c: 
        * libnm-util/nm-setting-umts.h: 
        * libnm-util/nm-setting-serial.c: 
        * libnm-util/nm-setting-serial.h: Implement.

        * libnm-util/Makefile.am: Add new files to build.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3116 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-11-29 14:38:07 +00:00
Dan Williams 29c735dca4 Warning fixes
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3083 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-11-13 21:03:37 +00:00
Dan Williams a247281168 2007-11-08 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-connection.h
	  libnm-util/nm-connection.c
		- (nm_connection_need_secrets): add argument to return hints

	* src/nm-device-802-11-wireless.c
		- (link_timeout_cb, supplicant_connection_timeout_cb,
		   real_act_stage2_config, real_act_stage4_ip_config_timeout): handle
			nm_connection_need_secrets() change



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3072 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-11-08 19:25:00 +00:00
Tambet Ingo 6b79d40a76 2007-11-07 Tambet Ingo <tambet@gmail.com>
Rework NMSetting structures: Move each setting to it's own file.
        Convert to GObject. Remove home grown setting types and use
GTypes.
        Use GObject property introspection for hash conversion,
enumerating
        properties, etc.

        * libnm-util/nm-setting-connection.[ch]
        * libnm-util/nm-setting-ip4-config.[ch]
        * libnm-util/nm-setting-ppp.[ch]
        * libnm-util/nm-setting-vpn.[ch]
        * libnm-util/nm-setting-vpn-properties.[ch]
        * libnm-util/nm-setting-wired.[ch]
        * libnm-util/nm-setting-wireless.[ch]
        * libnm-util/nm-setting-wireless-security.[ch]

        New files, each containing a setting.

        * libnm-util/nm-setting-template.[ch]: A template for creating
        * new
        settings. To use it, just replace 'template' with the new
setting
        name, and you're half-way done.

        * libnm-util/nm-setting.c: Convert to GObject and use GObject
        introspection instead of internal types and tables.

        * libnm-util/nm-connection.c: Adapt the new NMSetting work.

        * libnm-util/nm-param-spec-specialized.[ch]: Implement. Handles
        GValue types defined by dbus-glib for composed types like
collections,
        structures and maps.

        * src/*: The API of NMSetting and NMConnection changed a bit:
        * Getting
        a setting from connection takes the setting type now. Also,
since
        the settings are in multiple files, include relevant settings.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3068 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-11-07 16:06:43 +00:00
Dan Williams d04ec21681 2007-10-31 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-connection.c
		- (gvalue_to_string): handle UINT32 arrays



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3059 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-31 22:12:12 +00:00
Dan Williams aedced3964 2007-10-23 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting.c
	  libnm-util/nm-setting.c
		- (nm_setting_compare): implement
		- (default_setting_compare_fn, do_one_compare, compare_gvalue_hash,
		   compare_one_hash_gvalue): compare the contents of a setting

	* libnm-util/nm-connection.c
		- (nm_connection_compare): implement



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3013 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-23 20:41:10 +00:00
Dan Williams fbd22c96bb 2007-10-23 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting.c
	  libnm-util/nm-setting.h
		- (nm_setting_verify): new function; verify one setting
		- (nm_settings_verify_all): rename from nm_settings_verify()
		- (setting_connection_verify, setting_wireless_verify): allow NULL
			all_settings

	* libnm-util/nm-connection.c
		- (nm_connection_replace_settings, nm_connection_verify,
		   nm_connection_new_from_hash): handle nm_settings_verify() rename



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3011 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-23 18:33:49 +00:00