Commit graph

23 commits

Author SHA1 Message Date
Dan Williams 5a7cf39a62 libnm-util: add secret flags for each secret describing how the secret is stored
This allows the necessary flexibility when handling secrets; otherwise
it wouldn't be known when NM should save secrets returned from agents
to backing storage, or when the agents should store the secrets. We
can't simply use lack of a secret in persistent storage as the indicator
of this, as (for example) when creating a new connection without
secrets the storage method would be abmiguous.

At the same time, fold in "always ask" functionality for OTP tokens
so user agents don't have to store that attribute themselves out-of-band.
2011-01-29 13:34:24 -06:00
Dan Williams 89fcc757a4 libnm-util: remove deprecated GSM bits 2011-01-27 18:38:45 -06:00
Dan Williams 389a297571 libnm-util: silence warning 2010-11-03 14:58:22 -05:00
Dan Williams a1731c6064 libnm-util: fix max APN length
It's not 20, it's DNS domain name length.
2010-09-22 13:44:18 -05:00
Dan Williams 0ec9bf2c73 libnm-util: enforce APN character restrictions
APNs can only contain alphanumeric characters, '.', and '-'.  To be
helpful we strip spaces off before setting the APN internally so that
previously (and incorrectly) valid APNs don't cause the whole
connection to fail validation and thus disappear.  The only case seen
in the wild was a Pelephone IL APN which erroneously had a trailing
space in the mobile broadband provider database.  Bad characters
cause the connection to fail with vague error messages about being
unable to activate the PDP context during PPP negotiation.
2010-09-22 13:20:02 -05:00
Dan Williams d924003320 libnm-util: add nm_setting_gsm_get_home_only()
For roaming control.
2010-03-16 23:52:37 -07:00
Dan Williams 9a5e3bd0b6 doc: document gsm setting properties 2009-11-11 14:06:33 -08:00
Dan Williams a770a14fd2 libnm-util: ensure GSM setting default values
Broken by 00f945e54e.
2009-10-18 22:51:43 -07:00
Dan Williams 00f945e54e gsm: correct GSM band implementation and settings
NM didn't pass it to MM anyway, so it was mainly unused, but the band settings
were still wrong.  Fix that (and still preserve ABI) by adding a new property
for allowed bands that can actually hold all the bands instead of limiting
to 16-bits.  Clean up some of the deprecation stuff at the same time to make
it clearer what's deprecated and what to do about it.
2009-10-07 12:18:57 -07:00
Dan Williams d548fc9a61 libnm-util: silence some of the GSM PUK warnings 2009-09-21 10:59:19 -07:00
Dan Williams e4ed9764b5 libnm-util: deprecate GSM PUK property
Unused anyway, and PUK is dangerous enough that it should be handled
by the client explicitly and not by NM.
2009-09-18 17:08:30 -07:00
Torgny Johansson a736385127 gsm: fix GSM network mode max value
So that you can actually prefer GSM/EDGE.
2009-07-10 07:58:55 -04:00
Dan Williams b61b199776 libnm-util: flag properties with G_PARAM_CONSTRUCT so default values get set
This caused the 'autoconnect' property of NMSettingConnection to not
get updated in some cases (as when a system setting plugin noticed a
change to autoconnect=true and emitted the Updated signal, which wouldn't
contain the new value).  Add a testcase for setting default values too.
2009-02-01 20:18:21 -05: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 76c366b546 2008-10-26 Dan Williams <dcbw@redhat.com>
Patch from Tambet Ingo <tambet@gmail.com>

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

	* src/nm-gsm-device.c
	  src/nm-hso-gsm-device.c
	  src/ppp-manager/nm-ppp-manager.c
		- Use those accessors



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4219 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-10-26 17:23:37 +00:00
Dan Williams 33110acba8 2008-09-27 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting-gsm.c
		- (verify): verify GSM network ID



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4118 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-09-28 03:17:09 +00:00
Dan Williams dbd1e23f13 2008-09-25 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting-gsm.c
	  libnm-util/nm-setting-gsm.h
		- Fix up NM_GSM_NETWORK_* constants to accurately reflect the network
			technology terms (bgo #551361)



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@4106 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-09-25 16:16:52 +00:00
Dan Williams e2aa087281 2008-08-04 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting-cdma.c
	  libnm-util/nm-setting-gsm.c
		- (verify): validate username & password if they exist
		- (need_secrets): if username given, require a password too



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3892 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-08-04 19:17:10 +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 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
Dan Williams 99ef193601 2008-06-11 Dan Williams <dcbw@redhat.com>
Patch from Tambet Ingo <tambet@gmail.com>

	* libnm-util/nm-setting-gsm.c
		- (verify): validate APN

	* src/nm-gsm-device.c
		- (manual_registration_done): start setting APN if needed
		- (set_apn, set_apn_done): set the APN
		- (do_dial): use the APN when dialing



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3750 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-11 18:08:35 +00:00
Dan Williams 2497bea1d2 2008-01-09 Dan Williams <dcbw@redhat.com>
* src/nm-device.c
	  src/nm-device.h
		- (device_activation_precheck, check_connection_complete): remove this
			virtual function; incomplete connections should be invalid by
			definition, complete-ness should be checked in the setting's
			verify function

	* src/nm-serial-device.c
	  src/nm-gsm-device.c
		- (real_check_connection_complete): remove

	* libnm-util/nm-setting-serial.c
		- (verify): new function; ensure there is a PPP setting too

	* libnm-util/nm-setting-gsm.c
		- (verify): ensure there is a serial setting too



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3225 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-01-09 18:27:23 +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
Renamed from libnm-util/nm-setting-umts.c (Browse further)