Dan Williams
47eaf97d67
core: add nm_auth_uid_in_acl()
...
For checking whether a specific user ID is:
1) in a known session
2) allowed by the connection's permissions ACL
2010-11-18 13:49:47 -06:00
Dan Williams
eccca738aa
core: make nm_auth_get_caller_uid() error description non-const
...
For consistency with the next commit, so we don't need to remember
when to free the description or not.
2010-11-18 13:47:04 -06:00
Dan Williams
c3c9d93b1d
settings: fix session checking for connection operations
2010-11-18 13:04:15 -06:00
Dan Williams
ac2438518d
settings: don't allow addition of invisible connections
...
Ensure that only connections which are visible to the user adding
the connection may be added.
2010-11-18 12:53:24 -06:00
Dan Williams
fe3002d9f1
settings: fix permission checking during add
2010-11-18 12:40:38 -06:00
Dan Williams
9db44c42ee
settings: remove unused variables
2010-11-18 10:55:21 -06:00
Dan Williams
ca063e4d0c
libnm-util: add nm_setting_connection_permissions_has_user()
...
Utility function to determine whether a given username is in the ACL.
2010-11-18 10:36:18 -06:00
Dan Williams
c0f5872b5a
settings: don't accept possible auth as success for saving hostname
...
Since user interaction is allowed when the permission for SaveHostname
is requested, if the user didn't authorize completely when polkit
returns, we don't want to proceed with the request. Otherwise we might
get into a situation where it's possible for the user to authorize,
but they didn't, and previously the code would allow the request.
2010-11-17 17:54:04 -06:00
Dan Williams
1bbc624477
settings: port AddConnection to NMAuthChain
...
More code saved. Yay.
2010-11-17 17:53:37 -06:00
Dan Williams
670da10764
settings: port SaveHostname to NMAuthChain
...
Every line of code we remove can then be spent on
rainbows and kittens.
2010-11-17 17:44:33 -06:00
Dan Williams
02d942320d
core: fix nm_settings_get_connections() result confusion
...
It used to reference items in the list, but no longer does because
that's stupid. Fixes some merge damage and a leak.
2010-11-17 17:42:22 -06:00
Dan Williams
3de9332f09
trivial: be a bit more paranoid about re-exporting connections
2010-11-17 17:33:00 -06:00
Dan Williams
98dab62d92
core: simplify device disconnect flow
2010-11-17 17:02:21 -06:00
Dan Williams
1064397904
core: add helper to access authentication result
2010-11-17 16:56:34 -06:00
Dan Williams
3391a00354
core: fix up merge damage
2010-11-16 18:23:27 -06:00
Dan Williams
cfaa80b261
Merge remote branch 'origin/master' into rm-userset
2010-11-16 18:08:48 -06:00
Dan Williams
cbb0d6d116
build: create NM state directory at install time
2010-11-08 09:09:54 -06:00
Wulf C. Krueger
3b4e9dd75e
backends: add Exherbo support (bgo #634058 )
2010-11-05 13:41:20 -05:00
Dan Williams
3d8b6acaba
core: revert API parts of fe493ec91e
...
And add a default autoconnect retries value.
2010-11-03 13:23:09 -05:00
Jiří Klimeš
fe493ec91e
core: add configurable auto connection retries (bgo #628825 )
...
Presently, when automatic connecting fails, the connection is marked
as invalid and is not retried again. This commit adds a configuration
parameter to specify how many times the connection should be re-tried.
2010-11-03 16:22:55 +01:00
Jiří Klimeš
607350294d
core: update timestamp in active system connections every 5 mins (bgo #583756 )
...
This patch updates timestamps in system connections. The update occurs on
connection activation and then periodically every 5 mins while the connection
is active. It only works for plugins having write support and for writable
connections (not read-only).
2010-11-03 16:07:15 +01:00
Dan Williams
453ea4d5c7
settings: make sure we use a clear error every time
2010-10-29 23:13:57 -05:00
Dan Williams
85db10a13f
settings: fix connection addition
...
Need to make sure we actually export the connection over D-Bus (via
claim_connection()) before we try to return its object path in the
AddConnection reply. Second, we need to send the path as a string
in the reply, not an object, since the return type is an object path.
2010-10-29 22:10:32 -05:00
Dan Williams
9d725be3a9
settings: fix signature of connection updated handler
2010-10-29 22:05:23 -05:00
Dan Williams
37845af954
settings: return new connection object path from AddConnection
...
Finally.
2010-10-29 14:34:33 -05:00
Dan Williams
3f64bf5e36
settings: rename NM_SYSCONFIG_SETTINGS_ERROR -> NM_SETTINGS_ERROR
2010-10-27 20:38:26 -05:00
Dan Williams
83ab4ec2ee
settings: system-settings -> settings
2010-10-27 20:22:14 -05:00
Dan Williams
1ec6b67162
settings: rename NMSysconfigSettings to NMSettings
2010-10-27 20:05:23 -05:00
Dan Williams
18f819d71d
policy: clean up device signal handling
2010-10-27 16:57:31 -05:00
Dan Williams
6329fadb48
core: fix refcounting of settings object
2010-10-27 16:50:57 -05:00
Dan Williams
e2275bba68
settings: fix handling of connection visibility changes
2010-10-27 16:50:09 -05:00
Dan Williams
3c32c02778
policy: fix and clean up policy signal disconnection on dispose
2010-10-27 16:46:32 -05:00
Dan Williams
b3b722e234
core: fix session monitor initialization
...
Braindead error handling on my part.
2010-10-27 16:45:52 -05:00
Dan Williams
33deafe69d
settings: return the right thing when listing connections
2010-10-27 16:24:48 -05:00
Dan Williams
153e11eeea
settings: small optimization
...
hash table already has the exported object path, no reason to ask
the connection itself for it.
2010-10-27 16:23:47 -05:00
Dan Williams
330cb35630
policy: make sure we have a valid settings object
2010-10-27 16:22:18 -05:00
Dan Williams
02711a0e67
settings: re-add exported NewConnection signal
...
Oops, got removed in an earlier commit.
2010-10-27 16:20:41 -05:00
Dan Williams
f1d4af6996
settings: make sure we get our D-Bus connection before using it
2010-10-27 16:17:44 -05:00
Dan Williams
84def2fedf
settings: remove connection tracking from NMManager
...
NMSysconfigSettings has the authoritative list of connections, no reason
to duplicate all that tracking code in NMManager. Add the missing bits
that the manager had to NMSysconfigSettings, and point NMPolicy at the
settings object instead of NMManager for that.
2010-10-27 15:47:10 -05:00
Dan Williams
b51cef3cba
settings: clean up connection visibility and session change handling
2010-10-26 16:33:47 -05:00
Dan Williams
edbf4a3ca2
core: allow ConsoleKit usage to be disabled
2010-10-26 15:57:03 -05:00
Dan Williams
e5adfcbabe
settings: remove remnants of unused CheckPermissions signal
2010-10-26 11:40:43 -05:00
Dan Williams
7b50607fc9
settings: consolidate settings connection purged and removed signals
...
They almost do the same thing.
2010-10-26 11:36:38 -05:00
Dan Williams
d2d48676fc
settings: remove older session monitor code
2010-10-26 11:19:29 -05:00
Dan Williams
925d69c6d1
core: use new session monitor in system connection class
2010-10-26 11:15:19 -05:00
Dan Williams
39ed9c2956
core: get D-Bus manager during auth if not provided
2010-10-26 11:00:30 -05:00
Jiří Klimeš
bc76e40dec
trivial: make connection activating error more precise
2010-10-26 13:46:17 +02:00
Dan Williams
1b21949380
core: move session monitor to core
...
We'll need it for agent authentication too, so move it out of
system settings specific code.
2010-10-25 23:43:04 -05:00
Dan Williams
0c409d75ea
settings: add a simpler session monitor
...
Heavily modified from polkitbackendsessionmonitor.c, thanks davidz!
2010-10-25 23:24:44 -05:00
Dan Williams
8b006f331d
dhcp: add support for Fedora dhclient RFC3442 routes (rh #639935 )
...
Add support for Fedora's dhclient's built-in RFC3442 classless static
routes format.
Since the Fedora format uses the same name as the dhcpcd format, we
need to refactor a bunch of the code to ensure we can distinguish
between the types. Do this at runtime now by consolidating the
classless static routes parsing code into the DHCP Client base class
and rework the unit tests so that we can test all variations of the
classless static route parsing code at the same time.
This also fixes a bug with the dhcpcd classless static route
gateway handling that would return the wrong gateway address.
Many thanks to Jiri Popelka from Red Hat for the initial patch
and explanations.
2010-10-21 13:34:40 -05:00