summaryrefslogtreecommitdiff
path: root/src/config.c
AgeCommit message (Collapse)AuthorFilesLines
2013-02-26config: Add a function to provision mutable serviceTomasz Bursztyka1-2/+103
The point here is to create a virtual configuration, which does not come from a real file. This is a handy way for plugins to be able to provision services without creating any file on the FS. In case of a wifi configuration type and if connect is requested, it will trigger a scan, thus leading to a possible service being provisioned by such virtual configuration. If so and if connect was requested: the service will be asked to connect.
2013-02-26config: Make load service from each keyfile group as a functionTomasz Bursztyka1-17/+24
2013-02-26config: Remove superfluous error codeTomasz Bursztyka1-22/+14
It simplifies the code removing uselesse variable, moreover such variable has the same name as an existing label in the same function.
2013-02-22config: Run service autoconnect after provisioning the wifi serviceJukka Rissanen1-0/+2
We trigger autoconnect request in service after the wifi service has been provisioned. This is useful in headless systems where there is no user to trigger the connect to provisioned service, and it might take some time before system autoconnect is run.
2013-02-22config: Add ethernet provisioning supportJukka Rissanen1-8/+44
2013-02-22config: Support static IP address for wifi serviceJukka Rissanen1-41/+456
2013-02-19config: Read only wifi configJukka Rissanen1-1/+5
2013-02-19config: Remove obsolete definitionJukka Rissanen1-2/+0
2012-11-23inotify: Move inotify code into its own fileDaniel Wagner1-120/+2
The inotify code will be used by the core (config.c) and the session policy plugin. We introduce a new API for file modifcation notifcation. We move the factored out code part from the last patch into a new file and also change the inotify code so that it allows to monitor not only STORAGEDIR. When registering a new observer, the callee has to tell which directory should be watched. inotify.c will group the observers together.
2012-11-23config: Factor out config inotify handlerDaniel Wagner1-45/+52
The inotify code can be reused. So before we introduce a new generic inotify API, let's factor out in order to simplify the review process.
2012-09-07config: Call g_clear_error to prevent memory leakDanny Jeongseok Seo1-0/+1
2012-09-04Use g_slist_prepend() where appropriatePatrik Flykt1-1/+1
Convert usage of g_slist_append() to g_slist_prepend() where appropriate. gdbus, dnsproxy, resolver, rtnl, session and session unit test have ordering requirements and thus not touched.
2012-07-15config: Avoid shadowing config structure variableMarcel Holtmann1-10/+15
2012-07-13config: Get configurations that are provisionedJukka Rissanen1-0/+81
We need the list of provisioned services so that all the hidden ones can be scanned.
2012-07-13config: Read hidden AP information from config fileJukka Rissanen1-0/+9
2012-06-11config: Check if we need to rescan the config file for any changesJukka Rissanen1-3/+17
2012-06-11config: No service removal on cleanupJukka Rissanen1-0/+9
We must not remove the services when connman is stopped.
2012-06-11config: Check individual service entries for removalJukka Rissanen1-1/+37
Check if we need to remove a service if user removes an entry from config file. If user changes entry name in config file, then we remove the service and then try to provision the service again because the SSID might still be found.
2012-06-11config: Use config file name and entry when deciding removalJukka Rissanen1-1/+1
We need to know the config file and entry name in next patch in order to know if the service entry was removed from config file.
2012-06-11config: Save service after provisioning itJukka Rissanen1-0/+2
2012-06-11service: Sort service sequence after checking provisioned servicesJukka Rissanen1-0/+2
2012-06-11service: Add function to set the favorite flagJukka Rissanen1-1/+1
Add a function that sets favorite flag but which does not touch the ordering of service sequence. This is needed when we check provisioned config file which traverses the service sequence. If a proper provisioned service is found, then it is marked as favorite but in this case we must not do any ordering of service sequence because we are in the middle of sequence traversal.
2012-06-11config: Set config information in serviceJukka Rissanen1-0/+10
This is needed so that service can know if the config file is removed when connmand is not running.
2012-06-11config: Remove service if config file is removedJukka Rissanen1-21/+48
If the user removes the config file, we disconnect and then try to remove the corresponding service directory and all known files (settings and data).
2012-05-28config: Remove unused functionJukka Rissanen1-56/+0
2012-05-15config: Reject invalid SSID hexadecimal entriesPatrik Flykt1-1/+7
Reject provisioning .config file SSID entries that are not in hexadecimal.
2012-04-29core: Update copyright informationMarcel Holtmann1-1/+1
2012-04-17config: Warn user if no configuration is foundJukka Rissanen1-3/+10
This is useful so that user gets information that he needs to fix the config file.
2011-09-12storage: Switch to settings fileAlok Barsode1-15/+4
All the global settings would reside in /var/lib/connman/settings. We also migrate global keys from /var/lib/connman/default.profile to /var/lib/connman/settings for a smooth transition.
2011-06-27config: Provision service after adding new .config files.Mohamed Abbas1-0/+22
For now if new .config files are added connman will create new config and but do not provision existing services. This patch will provision existing service if any config file are added or modified. Fixes bug #4880.
2011-06-16element: Remove element.cDaniel Wagner1-0/+1
2011-04-11config: Use static function to validate identifiersSamuel Ortiz1-2/+20
Config file names are not exposed through D-Bus, so there is no need to run connman_dbus_validate_ident() on them. Checking for a readable string still makes sense though.
2011-04-11config: Fix compiler warning on 64 bits hostsSamuel Ortiz1-1/+1
2011-04-11config: Default config protection set to TRUESamuel Ortiz1-2/+7
Configs will be protected, unless explicitely set otherwise.
2011-04-11config: Remove the from_fs config fieldSamuel Ortiz1-21/+1
D-Bus provisions will also be immutable, and will be allowed to overwrite unprotected configs.
2011-04-11config: Check SSID length before comparing protected SSIDsSamuel Ortiz1-0/+3
2011-04-11config: Save D-Bus provisioned filesSamuel Ortiz1-7/+60
They will not be able to overwrite protected configs though.
2011-04-11config: Fix service pointers memory leakSamuel Ortiz1-11/+20
2011-04-11config: Do not overwrite protected servicesSamuel Ortiz1-0/+44
2011-04-11config: Add configuration protected flagSamuel Ortiz1-0/+8
2011-04-11config: Set from_fs to connman_bool_tSamuel Ortiz1-1/+1
2011-04-11config: Avoid create_config forward declarationSamuel Ortiz1-16/+14
2011-04-11config: Export a function to load service configsHenri Bragge1-1/+39
__connman_config_load_service() function can be used by other parts of ConnMan core to load service configurations, which can later be used for service provisioning. Within config.c, a special field (from_fs) will be used to mark which configurations originate from the filesystem and which do not. This information is needed to manage service immutability. Also a special name "internal" will be used to label the "file" used for non-fs configurations. A real file will not be created by ConnMan, and it will be silently ignored if created by someone else. Filesystem storage can be implemented later if necessary.
2011-04-11config: Fix service configuration updateHenri Bragge1-1/+6
Service config should not be replaced after update (the existing struct shall be reused).
2011-01-18Use g_io_channel_read_chars instead of g_io_channel_readMarcel Holtmann1-7/+9
2011-01-05Add inotify monitoring .config file.Mohamed Abbas1-8/+163
Reflect new and modify *.config to connman config list. with patch any modified or added .config file will be read by connman and add these configuration for new provisioning.
2010-09-15Add verification of the .config file parametersFabien Marotte1-0/+55
Connman reads the *.config files in STORAGE_DIR during its boot but it looks only for parameters it is interrested in. The configuration parameters syntax is complex and it is very simple to make a mistake without getting connman warnings. This leads the user to think that connman understands the configuration file although it doesn't. This patch is the code that adds warnings to the logs if connman reads unknown parameters from the *.config files.
2010-09-15Move configuration key strings to be #defineFabien Marotte1-14/+33
2010-05-22Add configuration file option for passphraseDaniel Wagner1-0/+11
2010-01-07Fix some WPA Enterprise privacy issuesMarcel Holtmann1-11/+9