PolicyKit: Branch 'master' - 70 commits

David Zeuthen david at kemper.freedesktop.org
Tue Jan 27 07:58:02 PST 2009


 .gitignore                                                   |   32 
 AUTHORS                                                      |    1 
 COPYING                                                      |  512 ++
 HACKING                                                      |   95 
 Makefile.am                                                  |   57 
 NEWS                                                         |  423 --
 README                                                       |   92 
 acinclude.m4                                                 |   51 
 actions/Makefile.am                                          |   16 
 actions/org.freedesktop.policykit.policy.in                  |   51 
 autogen.sh                                                   |   18 
 configure.ac                                                 |  471 ++
 configure.in                                                 |  677 ---
 data/Makefile.am                                             |   39 
 data/org.freedesktop.PolicyKit.AuthenticationAgent1.xml      |   24 
 data/org.freedesktop.PolicyKit1.AuthenticationAgent.xml      |   25 
 data/org.freedesktop.PolicyKit1.Authority.xml                |  253 +
 data/org.freedesktop.PolicyKit1.conf.in                      |   10 
 data/org.freedesktop.PolicyKit1.service.in                   |    4 
 data/polkit-1.in                                             |    6 
 data/polkit-1.pc.in                                          |   12 
 data/polkit-agent-1.pc.in                                    |   11 
 data/polkit-backend-1.pc.in                                  |   11 
 data/polkit-gobject-1.pc.in                                  |   13 
 data/polkit-grant-1.in                                       |    6 
 data/polkit-grant-1.pc.in                                    |   11 
 dev/null                                                     |binary
 doc/.gitignore                                               |    3 
 doc/Makefile.am                                              |   87 
 doc/TODO                                                     |   60 
 doc/man/Makefile.am                                          |   20 
 doc/man/PolicyKit.xml                                        |   63 
 doc/man/polkit-action.xml                                    |  194 
 doc/man/polkit-auth.xml                                      |  343 -
 doc/man/polkit-policy-file-validate.xml                      |   89 
 doc/polkit-diagrams.svg                                      | 1923 ---------
 doc/polkit-docs.xml                                          |  144 
 doc/spec/polkit-spec-configuration.xml                       |  295 -
 doc/spec/polkit-spec-introduction.xml                        |  136 
 doc/spec/polkit-spec-model.xml                               |  569 --
 doc/version.xml.in                                           |    1 
 docs/Makefile.am                                             |    4 
 docs/TODO                                                    |   71 
 docs/man/Makefile.am                                         |   22 
 docs/man/PolicyKit.xml                                       |   59 
 docs/man/polkit.xml                                          |  358 +
 docs/polkit/Makefile.am                                      |   80 
 docs/polkit/polkit-docs.xml                                  |  114 
 docs/polkitagent/Makefile.am                                 |   88 
 docs/polkitagent/polkitagent-docs.xml                        |    7 
 docs/polkitbackend/Makefile.am                               |   88 
 docs/polkitbackend/polkitbackend-docs.xml                    |    7 
 docs/version.xml.in                                          |    1 
 examples/tracker-example/README                              |    4 
 examples/tracker-example/dk.fubar.PolKitTestService.conf     |   10 
 examples/tracker-example/tracker-example-client.py           |   11 
 examples/tracker-example/tracker-example.c                   |  138 
 gtk-doc.make                                                 |  159 
 mkinstalldirs                                                |  111 
 po/LINGUAS                                                   |    3 
 po/POTFILES.in                                               |    2 
 po/da.po                                                     |   51 
 policy/Makefile.am                                           |   16 
 policy/org.freedesktop.policykit.policy.in                   |   61 
 polkit-backendd/Makefile.am                                  |   63 
 polkit-backendd/main.c                                       |  169 
 polkit-backendd/org.freedesktop.PolicyKit.Backend.conf.in    |   11 
 polkit-backendd/org.freedesktop.PolicyKit.Backend.service.in |    4 
 polkit-backendd/org.freedesktop.PolicyKit.Backend.xml        |   18 
 polkit-backendd/polkit-daemon-backend.c                      |  292 -
 polkit-backendd/polkit-daemon-backend.h                      |   81 
 src/Makefile.am                                              |    2 
 src/kit/Makefile.am                                          |   79 
 src/kit/kit-entity.c                                         |  163 
 src/kit/kit-entity.h                                         |   52 
 src/kit/kit-file.c                                           |  367 -
 src/kit/kit-file.h                                           |   54 
 src/kit/kit-hash.c                                           |  638 ---
 src/kit/kit-hash.h                                           |  144 
 src/kit/kit-lib.c                                            |  136 
 src/kit/kit-lib.h                                            |   52 
 src/kit/kit-list.c                                           |  348 -
 src/kit/kit-list.h                                           |   86 
 src/kit/kit-memory.c                                         |  422 --
 src/kit/kit-memory.h                                         |   80 
 src/kit/kit-message.c                                        |  113 
 src/kit/kit-message.h                                        |   53 
 src/kit/kit-spawn.c                                          |  675 ---
 src/kit/kit-spawn.h                                          |   69 
 src/kit/kit-string.c                                         | 1204 -----
 src/kit/kit-string.h                                         |   94 
 src/kit/kit-test-main.c                                      |   52 
 src/kit/kit-test.c                                           |  142 
 src/kit/kit-test.h                                           |   72 
 src/kit/kit.h                                                |  164 
 src/polkit-grant/Makefile.am                                 |  183 
 src/polkit-grant/polkit-authorization-db-dummy-write.c       |  111 
 src/polkit-grant/polkit-authorization-db-write.c             |  922 ----
 src/polkit-grant/polkit-explicit-grant-helper.c              |  219 -
 src/polkit-grant/polkit-grant-helper-pam.c                   |  247 -
 src/polkit-grant/polkit-grant-helper-shadow.c                |  148 
 src/polkit-grant/polkit-grant-helper.c                       |  816 ---
 src/polkit-grant/polkit-grant-test.c                         |   63 
 src/polkit-grant/polkit-grant-test.h                         |   47 
 src/polkit-grant/polkit-grant.c                              |  564 --
 src/polkit-grant/polkit-grant.h                              |  373 -
 src/polkit-grant/polkit-revoke-helper.c                      |  362 -
 src/polkit/.gitignore                                        |    9 
 src/polkit/Makefile.am                                       |  283 -
 src/polkit/polkit-action-description.c                       | 1398 ------
 src/polkit/polkit-action-description.h                       |   92 
 src/polkit/polkit-action.c                                   |  398 -
 src/polkit/polkit-action.h                                   |   64 
 src/polkit/polkit-authorization-constraint.c                 | 1001 ----
 src/polkit/polkit-authorization-constraint.h                 |  108 
 src/polkit/polkit-authorization-db-dummy.c                   |  227 -
 src/polkit/polkit-authorization-db.c                         | 1470 -------
 src/polkit/polkit-authorization-db.h                         |  175 
 src/polkit/polkit-authorization.c                            |  879 ----
 src/polkit/polkit-authorization.h                            |  140 
 src/polkit/polkit-caller.c                                   |  461 --
 src/polkit/polkit-caller.h                                   |   65 
 src/polkit/polkit-context.c                                  |  622 ---
 src/polkit/polkit-context.h                                  |  129 
 src/polkit/polkit-debug.c                                    |   87 
 src/polkit/polkit-debug.h                                    |   41 
 src/polkit/polkit-error.c                                    |  253 -
 src/polkit/polkit-error.h                                    |  100 
 src/polkit/polkit-implicit-authorization.c                   |  572 --
 src/polkit/polkit-implicit-authorization.h                   |   80 
 src/polkit/polkit-private.h                                  |  107 
 src/polkit/polkit-read-auth-helper.c                         |  421 --
 src/polkit/polkit-resolve-exe-helper.c                       |  168 
 src/polkit/polkit-result.c                                   |  155 
 src/polkit/polkit-result.h                                   |  114 
 src/polkit/polkit-seat.c                                     |  234 -
 src/polkit/polkit-seat.h                                     |   57 
 src/polkit/polkit-session.c                                  |  504 --
 src/polkit/polkit-session.h                                  |   68 
 src/polkit/polkit-set-default-helper.c                       |  227 -
 src/polkit/polkit-simple.c                                   |  599 --
 src/polkit/polkit-simple.h                                   |   52 
 src/polkit/polkit-sysdeps.c                                  |  406 -
 src/polkit/polkit-sysdeps.h                                  |   51 
 src/polkit/polkit-test.c                                     |   79 
 src/polkit/polkit-test.h                                     |   63 
 src/polkit/polkit-tracker.c                                  | 1556 -------
 src/polkit/polkit-tracker.h                                  |   70 
 src/polkit/polkit-types.h                                    |  109 
 src/polkit/polkit-utils.c                                    |  175 
 src/polkit/polkit-utils.h                                    |   45 
 src/polkit/polkit.h                                          |   77 
 src/polkit/polkitactiondescription.c                         |  228 +
 src/polkit/polkitactiondescription.h                         |   61 
 src/polkit/polkitauthority.c                                 | 1152 +++++
 src/polkit/polkitauthority.h                                 |  212 +
 src/polkit/polkitauthorization.c                             |  145 
 src/polkit/polkitauthorization.h                             |   57 
 src/polkit/polkitauthorizationresult.c                       |   43 
 src/polkit/polkitauthorizationresult.h                       |   50 
 src/polkit/polkitcheckauthorizationflags.c                   |   35 
 src/polkit/polkitcheckauthorizationflags.h                   |   50 
 src/polkit/polkiterror.c                                     |   48 
 src/polkit/polkiterror.h                                     |   60 
 src/polkit/polkitidentity.c                                  |  219 +
 src/polkit/polkitidentity.h                                  |   63 
 src/polkit/polkitimplicitauthorization.c                     |  126 
 src/polkit/polkitimplicitauthorization.h                     |   62 
 src/polkit/polkitprivate.h                                   |   49 
 src/polkit/polkitsubject.c                                   |  252 +
 src/polkit/polkitsubject.h                                   |   63 
 src/polkit/polkitsystembusname.c                             |  204 
 src/polkit/polkitsystembusname.h                             |   53 
 src/polkit/polkittypes.h                                     |   55 
 src/polkit/polkitunixgroup.c                                 |  229 +
 src/polkit/polkitunixgroup.h                                 |   55 
 src/polkit/polkitunixprocess.c                               |  390 +
 src/polkit/polkitunixprocess.h                               |   58 
 src/polkit/polkitunixsession.c                               |  192 
 src/polkit/polkitunixsession.h                               |   51 
 src/polkit/polkitunixuser.c                                  |  229 +
 src/polkit/polkitunixuser.h                                  |   55 
 src/polkitagent/Makefile.am                                  |   82 
 src/polkitagent/polkitagent.h                                |   30 
 src/polkitagent/polkitagentauthenticationagent.c             |  205 +
 src/polkitagent/polkitagentauthenticationagent.h             |   69 
 src/polkitagent/polkitagentauthenticationsession.c           |  362 +
 src/polkitagent/polkitagentauthenticationsession.h           |  139 
 src/polkitagent/polkitagenthelper.c                          |  309 +
 src/polkitagent/polkitagenttypes.h                           |   38 
 src/polkitbackend/Makefile.am                                |   99 
 src/polkitbackend/org.freedesktop.ConsoleKit.xml             |  276 +
 src/polkitbackend/polkitbackend.h                            |   37 
 src/polkitbackend/polkitbackendactionpool.c                  | 1051 +++++
 src/polkitbackend/polkitbackendactionpool.h                  |   78 
 src/polkitbackend/polkitbackendauthority.c                   |  176 
 src/polkitbackend/polkitbackendauthority.h                   |  198 
 src/polkitbackend/polkitbackendlocalauthority.c              | 2255 +++++++++++
 src/polkitbackend/polkitbackendlocalauthority.h              |   77 
 src/polkitbackend/polkitbackendpendingcall.c                 |  167 
 src/polkitbackend/polkitbackendpendingcall.h                 |   85 
 src/polkitbackend/polkitbackendprivate.h                     |   34 
 src/polkitbackend/polkitbackendserver.c                      |  527 ++
 src/polkitbackend/polkitbackendserver.h                      |   53 
 src/polkitbackend/polkitbackendsessionmonitor.c              |  571 ++
 src/polkitbackend/polkitbackendsessionmonitor.h              |   67 
 src/polkitbackend/polkitbackendtypes.h                       |   44 
 src/polkitd/Makefile.am                                      |   42 
 src/polkitd/main.c                                           |  104 
 src/programs/Makefile.am                                     |   32 
 src/programs/polkit.c                                        |  907 ++++
 test/Makefile.am                                             |   16 
 test/create-coverage-report.sh                               |   64 
 test/invalid/test-invalid-1-action-id.policy                 |   14 
 test/invalid/test-invalid-2-bogus-any.policy                 |   14 
 test/invalid/test-invalid-3-bogus-inactive.policy            |   14 
 test/invalid/test-invalid-4-bogus-active.policy              |   14 
 test/invalid/test-invalid-5-max-depth.policy                 |   87 
 test/valid/test-valid-1.policy                               |   14 
 test/valid/test-valid-2-annotations.policy                   |   27 
 test/valid/test-valid-3-lang.policy                          |   28 
 test/valid/test-valid-4-unknown-tags.policy                  |   20 
 test/valid/test-valid-5-wrong-extension.policy~              |   14 
 tools/.gitignore                                             |    9 
 tools/Makefile.am                                            |   31 
 tools/polkit-action.c                                        |  356 -
 tools/polkit-auth.c                                          | 1023 ----
 tools/polkit-bash-completion-1.sh                            |  125 
 tools/polkit-policy-file-validate.c                          |  155 
 229 files changed, 15142 insertions(+), 31801 deletions(-)

New commits:
commit 94ff3c28193a0a3b1f0f4aa7952fa0844da619db
Merge: f2f2f6d... 8377067...
Author: David Zeuthen <davidz at redhat.com>
Date:   Tue Jan 27 10:52:09 2009 -0500

    Merge branch 'master' of /home/davidz/Hacking/polkit

commit f2f2f6db1ef8ea855737cff91d8876365b9b308d
Author: David Zeuthen <davidz at redhat.com>
Date:   Tue Jan 27 10:51:10 2009 -0500

    prepare for merge of rewritten PolicyKit

diff --git a/.gitignore b/.gitignore
deleted file mode 100644
index a3a977f..0000000
--- a/.gitignore
+++ /dev/null
@@ -1,32 +0,0 @@
-aclocal.m4
-autom4te.cache
-compile
-config.guess
-config.h
-config.h.in
-config.log
-config.status
-config.sub
-configure
-depcomp
-INSTALL
-install-sh
-intltool-extract
-intltool-extract.in
-intltool-merge
-intltool-merge.in
-intltool-update
-intltool-update.in
-libtool
-ltmain.sh
-Makefile
-Makefile.in
-missing
-mkinstalldirs
-policy-kit
-polkit.pc
-py-compile
-stamp-h1
-*.o
-ChangeLog
-*.tar.gz
diff --git a/AUTHORS b/AUTHORS
deleted file mode 100644
index c686966..0000000
--- a/AUTHORS
+++ /dev/null
@@ -1 +0,0 @@
-David Zeuthen <davidz at redhat.com>
diff --git a/COPYING b/COPYING
deleted file mode 100644
index 7c66d06..0000000
--- a/COPYING
+++ /dev/null
@@ -1,32 +0,0 @@
-Copyright (C) 2007-2008 David Zeuthen <davidz at redhat.com>.
-All Rights Reserved.
-
-The PolicyKit source code is licensed under the MIT/X11 license. The
-license is included below.
-
--- BEGIN MIT/X11 License ---
-
-Permission is hereby granted, free of charge, to any person
-obtaining a copy of this software and associated
-documentation files (the "Software"), to deal in the
-Software without restriction, including without limitation
-the rights to use, copy, modify, merge, publish, distribute,
-sublicense, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so,
-subject to the following conditions:
-
-The above copyright notice and this permission notice shall
-be included in all copies or substantial portions of the
-Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
-KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
-WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
-PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS
-BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
-IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
-OTHER DEALINGS IN THE SOFTWARE.
-
--- END MIT/X11 License ---
-
diff --git a/HACKING b/HACKING
deleted file mode 100644
index 67445f4..0000000
--- a/HACKING
+++ /dev/null
@@ -1,94 +0,0 @@
-SCM
-===
-
- - anonymous checkouts
-
-   $ git clone git://git.freedesktop.org/git/PolicyKit.git
-
- - checkouts if you got an ssh account on fd.o (username@ is optional)
-
-   $ git clone ssh://[username@]git.freedesktop.org/git/PolicyKit.git
-
- - commit to local repository
-
-   $ git commit -a
-
- - push local repository to master repository at fd.o (remember most patches
-   requires review at the mailing list)
-
-   $ git push
-
- - pull changes from master repository at fd.o
-
-   $ git pull
-
- - diff of working tree versus local repository
-
-   $ git diff
-
- - diff of local repository vs. master repository at fd.o
-
-   synchronize with upstream repo:
-   $ git pull
-
-   (possibly merge changes)
-
-   generate the diff:
-   $ git diff origin HEAD
-
- - influential environment variables (set these in e.g. .bash_profile)
-
-   export GIT_AUTHOR_NAME='Your Full Name'
-   export GIT_COMMITTER_NAME='Your Full Name'
-   export GIT_COMMITTER_EMAIL=youremail at domain.net
-   export GIT_AUTHOR_EMAIL=youremail at domain.net
-
- - see also
-
-    http://www.kernel.org/pub/software/scm/git/docs/
-
-
-Committing code
-===
-
- - Commit messages should be of the form (the five lines between the
-   lines starting with ===)
-
-=== begin example commit ===
-short explanation of the commit
-
-Longer explanation explaining exactly what's changed, whether any
-external or private interfaces changed, what bugs were fixed (with bug
-tracker reference if applicable) and so forth. Be concise but not too brief.
-=== end example commit ===
-
- - Always add a brief description of the commit to the _first_ line of
-   the commit and terminate by two newlines (it will work without the
-   second newline, but that is not nice for the interfaces). 
-
- - First line (the brief description) must only be one sentence and
-   must not start with a capital letter. Don't use a trailing period
-   either.
-
- - The main description (the body) is normal prose and should use normal
-   punctuation and capital letters where appropriate. Normally, for patches
-   sent to a mailing list it's copied from there.
-
- - When committing code on behalf of others use the --author option, e.g.
-   git commit -a --author "Joe Coder <joe at coder.org>"
-
-Coding Style
-===
-
- - Please follow the coding style already used - it's not a must, but it's
-   nice to have consistency.
-
- - Write docs for all functions and structs and so on. We use gtkdoc format.
-
- - All external interfaces (network protocols, file formats, etc.)
-   should have documented specifications sufficient to allow an
-   alternative implementation to be written. Our implementation should
-   be strict about specification compliance (should not for example
-   heuristically parse a file and accept not-well-formed
-   data). Avoiding heuristics is also important for security reasons;
-   if it looks funny, ignore it (or exit, or disconnect).
diff --git a/Makefile.am b/Makefile.am
deleted file mode 100644
index 4e88e9c..0000000
--- a/Makefile.am
+++ /dev/null
@@ -1,66 +0,0 @@
-## Process this file with automake to produce Makefile.in
-
-SUBDIRS = data src polkit-backendd doc tools policy po test
-
-# Creating ChangeLog from git log (taken from cairo/Makefile.am):
-ChangeLog: $(srcdir)/ChangeLog
-
-$(srcdir)/ChangeLog:
-	@if test -d "$(srcdir)/.git"; then \
-	  (cd "$(srcdir)" && \
-	  ./missing --run git-log --stat) | fmt --split-only > $@.tmp \
-	  && mv -f $@.tmp $@ \
-	  || ($(RM) $@.tmp; \
-	      echo Failed to generate ChangeLog, your ChangeLog may be outdated >&2; \
-	      (test -f $@ || echo git-log is required to generate this file >> $@)); \
-	else \
-	  test -f $@ || \
-	  (echo A git checkout and git-log is required to generate ChangeLog >&2 && \
-	  echo A git checkout and git-log is required to generate this file >> $@); \
-	fi
-
-if POLKIT_GCOV_ENABLED
-.PHONY: ChangeLog $(srcdir)/ChangeLog coverage-report.txt
-coverage-report.txt :
-	make -C src/kit coverage-report.txt
-	make -C src/polkit coverage-report.txt
-	make -C src/polkit-dbus coverage-report.txt
-	make -C src/polkit-grant coverage-report.txt
-	$(top_srcdir)/test/create-coverage-report.sh "PolicyKit" `cat src/kit/covered-files.txt src/polkit/covered-files.txt src/polkit-dbus/covered-files.txt src/polkit-grant/covered-files.txt` > coverage-report.txt
-
-check-coverage: coverage-report.txt
-	cat coverage-report.txt
-else
-.PHONY: ChangeLog $(srcdir)/ChangeLog
-
-coverage-report.txt:
-	@echo "Need to reconfigure with --enable-gcov"
-
-check-coverage:
-	@echo "Need to reconfigure with --enable-gcov"
-endif
-
-if POLKIT_BUILD_TESTS
-install:
-	@echo "Cowardly refusing to install with --enable-tests."
-	@exit 1
-endif
-
-EXTRA_DIST = 			\
-	HACKING 		\
-	mkinstalldirs 		\
-	ChangeLog 		\
-	intltool-extract.in 	\
-	intltool-merge.in 	\
-	intltool-update.in
-
-DISTCLEANFILES = \
-	intltool-extract	\
-	intltool-merge		\
-	intltool-update
-
-# xsltproc barfs on 'make distcheck'; disable for now
-DISTCHECK_CONFIGURE_FLAGS=--disable-man-pages --disable-gtk-doc
-
-clean-local :
-	rm -f *~
diff --git a/NEWS b/NEWS
deleted file mode 100644
index e7ec24e..0000000
--- a/NEWS
+++ /dev/null
@@ -1,423 +0,0 @@
-==========
-PolicyKit 0.9
-==========
-
-Released on July 22 2008.
-
-This release should be ABI compatible with PolicyKit 0.6 and later.
-
-David Zeuthen (10):
-      need to link with libkit.la for some helpers
-      fix some build stuff to so the test suites run
-      fix autotools screwup
-      fix typo
-      always allow uid 0 to ask about authorizations for anyone
-      fix up permissions / docs for certain helpers and files/directories
-      update README (for the right wiki page) and COPYING (for my email address)
-      update NEWS for release
-      fix 'make distcheck'
-      update NEWS again
-
-Joe Marcus Clarke (2):
-      add support for FreeBSD
-      remove watch on fd when reaching EOF
-
-==========
-PolicyKit 0.8 "The Ties That Bind"
-==========
-
-Released on April 16 2008.
-
-This release should be ABI compatible with PolicyKit 0.6 and later.
-
-NOTE NOTE NOTE: The permissions and modes of certain files has changed
-                since PolicyKit 0.7. Make sure to update your spec files
-                to reflect this. See the output of configure for details.
-
-Carlos Corbacho (4):
-      remove unncessary PAM header inclusions
-      split out authentication framework from authorisation database
-      add Shadow authentication framework
-      also add the new C file for the shadow helper
-
-David Zeuthen (33):
-      be more precise about permissions in the blurb at the end of configure
-      post release version bump to 0.8
-      use strlen to avoid writing garbage at the end of the test auth file
-      add bogus Returns: to make gtk-doc happy
-      add constraints for exe and SELinux context when granting an authorization
-      add note about new polkit-resolve-exe-helper
-      add additional checks when using strtoul
-      add docs and bash completion bits for new exe and selinux_context constraints
-      fix typo in docs
-      make the docs show an index of new symbols in 0.8
-      make polkit-grant-helper-pam world readable
-      actually check for bash in polkit-bash-completion.sh
-      avoid use normal timeout when showing auth dialog; use INT_MAX instead
-      fix doc in bugs for PolKitContextAddIOWatch
-      make polkit-policy-file-validate require that actions are properly packaged
-      add convenience API to consistently report authorization failures over D-Bus
-      also add polkit_dbus_error_parse_from_strings() function
-      fix typo in docs for polkit_dbus_error_parse_from_strings()
-      don't check key/values in KitHash; they are not neccesarily pointers
-      clarify docs for POLKIT_AUTHORIZATION_CONSTRAINT_TYPE_REQUIRE_EXE
-      invalidate memory cache after revoking one shot authorization
-      remove debug spew
-      remove more debug spew
-      print stack traces for where leaks were allocated
-      clear the right block when growing a string
-      don't leak the copied authorizations list on OOM
-      fix build when tests are disabled
-      don't include libkit api docs
-      fix issue where users allowed to change defaults can delete override files
-      print warning to stderr if a policy file is malformed and we're ignoring it
-      ensure object is first in the list/hash iterator callback functions
-      be careful about what symbols we export
-      update NEWS for release
-
-Holger Macht (1):
-      avoid reliance on DT_REG so we work on reiserfs as well
-
-Jim Li (1):
-      add support for Solaris platform
-
-Jim Meyering (5):
-      handle kit_strdup_printf failure.
-      remove unnecessary strdup.
-      (do_auth): rename local: s/buf/password/
-      avoid unnecessary/leaky use of strdup.
-      handle kit_strdup failure.
-
-Kees Cook (1):
-      fix for CVE-2008-1658: format string vulnerability in password input
-
-==========
-PolicyKit 0.7 "Common sense ain't common"
-==========
-
-Released on December 5th 2007.
-
-This is the fifth release of PolicyKit. This release is mostly ABI and
-API compatible with 0.6 (100% compatible for existing mechanisms). The
-authorization backend has changed; authorizations gained from earlier
-PolicyKit releases are no longer valid and will be ignored.
-
-Highlights of this release:
-
- o  All code is now licensed under the MIT/X11 license
-
- o  libpolkit and libpolkit-dbus no longer depends on libglib.
-
- o  Unit test framework and coverage reporting. As of this release, 64%
-    of the codebase is currently tested during 'make check'.
-
- o  New system D-Bus service (activated on demand) providing the major
-    functionality of libpolkit.so from a mechanism point of view. This
-    is useful for chroot(2)'ed services like Avahi.
-
- o  A class for tracking D-Bus connections to minimize the amount
-    of IPC necessary. Useful for long running daemons.
-
- o  Pluggable authorization database backend.
-
- o  New API for interacting with the authorization database
-
- o  A very simple convenience API useful for (legacy) commandline tools.
-
- o  A way to specify that an implicit authorization can be one-shot
-    only.
-
- o  Vendor name, site and icon support in .policy files.
-
- o  Improved documentation.
-
- o  Negative authorizations.
-
- o  Bash completions for all command line tools.
-
-Changes from PolicyKit 0.6 "There is no stopping in a red zone"
-
-David Zeuthen (126):
-      add the convenience class PolKitTracker
-      add id's so the generated HTML has stable and predictable file names
-      post-release version bump
-      add support to PolKitTracker for also asking on pid
-      add C++ include guards and a new method to get pfe's by annotation
-      avoid including regex.h from a public header file
-      don't spew debug output in libpolkit-dbus
-      work on the docs
-      use the Since: tag so gtk-doc can print what symbols are new in 0.7
-      add docs for POLKIT_[BEGIN|END]_DECLS and also add POLKIT_GNUC_DEPRECATED
-      create an API for interfacing with the Authorization Database
-      move POLKIT_GNUC_DEPRECATED to a separate line so gtk-doc is happy
-      remember to set uid on PolKitSession
-      rewrite authorization database and polkit-grant (now known as polkit-auth)
-      make the authdb pluggable and add a dummy backend as an example
-      move all private functions into a private header file
-      move Linux specific code into a single file
-      minor build system and doc fixes
-      let authdb backends synthesize policy file entries
-      fix build with dummy backend
-      fix docs
-      fix uid retrival when getting auths from all users
-      use _destroy, not _unref for hash tables
-      rearrange the docs so all API is in one section
-      move authdb write functions to libpolkit-grant
-      provide a polkit D-Bus service that is activated on demand
-      remember to reset killtimer and fix an error message
-      avoid defining the same functions in both libpolkit and libpolkit-grant
-      rename revoke_if_oneshot to is_mechanism and also expose this on D-Bus
-      make polkit_context_is_[caller|session]_authorized() take a PolKitError
-      introduce one-shot authorizations
-      updated TODO list
-      add unit test framework with gcov coverage support (make check-coverage)
-      extend test coverage for PolKitAction
-      remove dead code
-      add tests for PolKitError
-      implement OOM testing
-      add unit tests for PolKitResult
-      add unit tests for PolKitSeat
-      add unit tests for PolKitSession
-      add unit tests for PolKitCaller
-      add unit tests for PolKitPolicyDefault
-      add unit tests for PolKitPolicyFileEntry
-      implement our own hash table with 100% test coverage
-      export memory mangement and hash table functions
-      implement polkit_hash_foreach
-      improve coverage of PolKitPolicyFileEntry by switching to PolKitHashTable
-      add unit tests for PolKitPolicyFile and add some features to PolKitHash
-      fix some unaligned access bugs
-      increase test coverage for PolKitPolicyFile
-      also dist test .policy files
-      hook up expat to use our memory handling API
-      add doubly-linked lists
-      reimplement string hashing and comparison
-      move all library source to a src/ directory
-      fix build with all library soruce in src/
-      add some gtk-doc to private bits to get doc coverage to 100%
-      add test case for PolKitError to get to 100%
-      use unique action names
-      add unit tests of PolKitPolicyCache
-      forgot to add src/Makefile.am
-      add unit tests for PolKitAuthorizationConstraint
-      add unit tests for PolKitAuthorization
-      split utility bits into a private statically linked library
-      also include libkit in top-level coverage report
-      add strsplit function
-      use kit_strsplit in polkit-sysdeps
-      add (empty, for now) tests for remaining files
-      add spawn function to libkit
-      actually include the files with the spawn functions
-      don't overflow when splitting a string
-      remove glib dependency from libpolkit.so
-      tweak how we do coverage reporting
-      also check for file descriptor leaks
-      fix build for dummy backend
-      add unit test framework to the rest of the library sources
-      build system fixes and refuse to install if built with --enable-tests
-      create /var/lib/misc on 'make install'
-      fix parallel build
-      fix a grave bug where the wrong authorizations were returned
-      add API for overriding defaults and make polkit-action(1) use this API.
-      restrict new API to the default backend only
-      add support for vendor, vendor_url and icon_name tags in .policy files
-      provide convenience functions for auth checking and port helpers to use them
-      require org.fd.pk.revoke to revoke auths for self if granted by someone else
-      export the policydir in the .pc file
-      add support for negative authorizations
-      provide a way to force a reload of all caches etc.
-      make PolKitAuthorization a bit more future proof by adding get_type()
-      define abstract Authentication Agent interface and make polkit-auth(1) use it
-      remove Since gtk-doc tags from the internal libkit library
-      fix 'make check-coverage'
-      make dummy backend work
-      add support for percent encoding/decoding and colon separated kv-lists
-      set errno to ENOMEM when forcibly failing an allocation
-      rework the .auths file format to use key/value pairs and make it future-proof
-      also encode \n\r\t characters
-      update TODO
-      avoid adding newline at the end of generated entry
-      write newline since kit_string_entry_create doesn't do that any more
-      add test harness for polkit-utils
-      fix a bug where the childs environment wasn't inherited
-      build with -rdynamic for maint mode and use this to print a stack trace
-      add (partial) test cases for polkit-authorization-db.c
-      relicense everything to the MIT/X11 license
-      avoid logging to syslog even for invalid files
-      only fail the Nth alloc, not all allocs greater than N
-      add test-friendly abstractions for getpwnam and getpwuid
-      fix unit tests for polkit-authorization-db.c
-      add .gitignore files to get test tree structure in the repo
-      update .gitignore files
-      add some more test env variables so we can bypass ConsoleKit in the tests
-      fix OOM handling in p-a-db.c and only invalidate the cache when necessary
-      add some more test cases for p-a-db.c
-      add a new KitString class
-      implement kit_hash_foreach_remove()
-      remove glib dep from libpolkit-dbus
-      fix a bug where KitList elements were not properly freed
-      downgrade to session scope when granting authorizations for blank passwords
-      don't require .policy files for auth lookups
-      refactor constraints API so there is one entry per constraint in the auth file
-      fix dummy backend so it builds
-      update TODO
-      update TODO to mention Piter PUNK's patch
-      update completion + man page since polkit-auth(1) takes >1 --constraint args
-      update NEWS file
-
-==========
-PolicyKit 0.6 "There is no stopping in a red zone"
-==========
-
-Released on October 11th 2007.
-
-This is the fourth release of PolicyKit. There are no major changes
-since 0.5 expect a) better handling of unknown XML tags in the config
-and policy files (we simply ignore unknown sub-trees) to make it
-easier to add features in the future; b) native support for more
-distributions; and c) the addition of a <allow_any> tag to the .policy
-files.
-
-Changes from PolicyKit 0.5 "Urban Living"
-
-David Zeuthen (6):
-      post-release version bump
-      add specifics for the Pardus distro
-      add TODO item detailing how to handle upgrades
-      implement <allow_any> to specify default answer for any user
-      don't fail on unknown XML tags, just skip them
-      make polkit-list-actions print information about <allow_any>
-
-Doug Goldstein (3):
-      gentoo OS type support
-      install hook for setuid/setgid
-      use chgrp instead of chown with group only
-
-
-==========
-PolicyKit 0.5 "Urban Living"
-==========
-
-Released on August 31st 2007.
-
-This is the third release of PolicyKit. Since 0.4 both source- and
-file-format level incomptible changes have been introduced. Accordingly, 
-the library so-names have been bumped to reflect this. Porting effort
-should be minimal though; see the example in PolicyKit-gnome for details.
-
-WARNING WARNING WARNING: do not use this software in a stable
-distribution; there are still security sensitive things that needs to
-be audited.
-
-Changes from PolicyKit 0.4 "Off the Grid"
-
-Danny Kukawka (3):
-      added missing files to git repo
-      fixed code documentation issues
-      fixed compiler warning about uid_t handling
-
-David Zeuthen (37):
-      move PAM stack usage to separate helper
-      remove the isatty() call so it's easier to audit the helper
-      put back isatty() checks when calling user is not uid 0
-      use waitpid() to avoid Zombie processes
-      provide a high-level interaction diagram of how this works
-      post-release version number bump
-      use correct type for conversation_done() function
-      make the /var/lib/PolicyKit/reload writable for group polkituser
-      when granting privileges, touch the /var/lib/PolicyKit/reload file
-      export PolKitConfig and provide a <define_admin_auth/> config file directive
-      properly support i18n'ed messages from .policy files
-      handle the case where we don't load descriptions
-      make polkit-grant(1) work with <define_admin_user /> feature
-      make libpolkit-grant less noisy
-      rip out group concept from .policy files and rename <policy> element to <action>
-      minor doc cleanups
-      avoid the now defunct group concept in polkit-list-actions
-      gracefully handle bad config/policy files, drop polkit-reload-config, syslog
-      add support for annotations
-      give a little love to polkit-list-actions(1) and polkit-grant(1)
-      Merge branch 'master' of ssh://david@git.freedesktop.org/git/PolicyKit
-      delay loading the configuration until it's needed
-      convert manual page sources to Docbook, add polkit-config-file-validate tool
-      clean up our documentation
-      revert "fixed code documentation issues"
-      fix up manual pages for some trivial errors
-      update inline API docs
-      some more doc fixes
-      make config file override grant database
-      forgot to add doc/version.xml.in
-      also add another missing file
-      also forgot to add polkit-docs.xml
-      minor doc changes
-      add an example of how define_admin_auth is used
-      make polkit-grant-helper-pam out of reach for normal users
-      fix 'make distcheck' by avoiding with man pages on distcheck
-      bump so name
-      update NEWS file
-
-Richard Hughes (1):
-      work when SELinux is disabled
-
-
-==========
-PolicyKit 0.4 "Off the Grid"
-==========
-
-Released on July 25th 2007.
-
-This is the second release of PolicyKit. 
-
-WARNING WARNING WARNING: do not use this software in a stable
-distribution; there are still security sensitive things that needs to
-be audited.
-
-Changes from PolicyKit 0.3 "No Man's Land"
-
-David Zeuthen (18):
-      post-release version bump
-      remove the notion of modules
-      replace configuration reload mechanism
-      get proper pid and SELinux context
-      add support for an /etc/PolicyKit/PolicyKit.conf config file
-      document the /etc/PolicyKit/PolicyKit.conf file with a manual page
-      update TODO
-      switch from VIA_ROOT to VIA_ADMIN
-      remove RESULT_NOT_AUTHORIZED_TO_KNOW and s/RESULT_UNKNOWN_ACTION/RESULT_UNKNOWN/
-      fix up some of the docs
-      change default username
-      fix typo
-      require that policy files also provide a <message> element
-      fix docs
-      fix up proper naming of some methods on the PolKitPolicyFileEntry class
-      for PolKitContext, mention that a mechanism need to provide .policy files
-      update NEWS
-      actually reload config and policy files when they change
-
-Requirements for PolicyKit 0.4 ""
-
- - dbus             >= 0.90
- - glib             >= 2.6.0
- - ConsoleKit       >= 0.2.1
- - expat            >= 1.95.8
- - libselinux       >= 1.30   (optional)
-
-==========
-PolicyKit 0.3 "No Man's Land"
-==========
-
-Released on June 20th 2007.
-
-This is the first release of PolicyKit. 
-
-WARNING WARNING WARNING: do not use this software in a stable
-distribution; there are still security sensitive things that needs to
-be audited.
-
-Requirements for PolicyKit 0.3 "No Man's Land"
-
- - dbus             >= 0.90
- - glib             >= 2.6.0
- - ConsoleKit       >= 0.2.1
- - expat            >= 1.95.8
-
diff --git a/README b/README
deleted file mode 100644
index 307df96..0000000
--- a/README
+++ /dev/null
@@ -1,92 +0,0 @@
-
-PolicyKit is an authorization framework. It is typically used by
-privileged user space daemons to control access.
-
-See also the file HACKING for notes of interest to developers working
-on PolicyKit.
-
-See http://www.freedesktop.org/wiki/Software/PolicyKit for lots of
-documentation, mailing lists, etc.
-
--------------------------------------------------------
-Rationale for permissions/modes for the default backend
--------------------------------------------------------
-
-0770 root:polkituser /var/run/polkit-1
-0770 root:polkituser /var/lib/polkit-1
-
-We store authorizations for each user here. Since we don't want users
-to know what authorizations other users has, no one can read these
-files. However, when checking authorizations we need to be able to
-read from here; we use this helper
-
-2755 root:polkituser /usr/libexec/polkit-read-auth-helper-1
-
-which can read from here since it's setgid 'polkituser'. This helper
-will refuse to return authorizations for other users than the calling
-user except if the calling user is authorized for org.fd.pk.read.
-
-We also want to be able to grant authorizations through authentication.
-That happens with this helper
-
-2755 root:polkituser /usr/libexec/polkit-grant-helper-1
-
-This program is setgid 'polkituser' so it can write files in
-/var/{run,lib}/polkit-1. Note that these files are created with mode
-464.
-
-To do the actual authentication check when granting authorizations
-through authentication, polkit-grant-helper-1 uses another helper
-
-4754 root:polkituser /usr/libexec/polkit-grant-helper-pam-1
-
-This one is setuid root because checking authentications might need
-require that (you may be checking the root password). The reason
-polkit-grant-helper-pam is is owned by group 'polkituser' is to ensure
-that random users can't execute it; only setgid 'polkituser' programs
-can do this. Which polkit-grant-helper is.
-
-On to
-
-2755 root:polkituser /libexec/polkit-revoke-helper-1
-
-This one is used to revoke authorizations. It will only allow uid 0 and
-users with the org.fd.pk.revoke authorization to do so. It needs to be
-setgid polkituser to be able to modify authorization files
-in /var/{run,lib}/polkit-1.
-
-2755 root:polkituser /usr/libexec/polkit-explicit-grant-helper-1
-
-Same story as for polkit-revoke-helper only this grants authorizations.
-Only allowed for uid 0 and users with the org.fd.pk.grant authorization.
-
-On to
-
-0755 polkituser:root /var/lib/polkit-public-1
-
-This is where we store modifications to the defaults. Anyone should be
-able to read these files. They are created with mode 644. These files
-are written / modified by this helper
-
-4755 polkituser:root /usr/libexec/polkit-set-default-helper-1
-
-which is setuid polkituser to be able to write/modify files.
-
-On to
-
-4755 root:root /usr/libexec/polkit-resolve-exe-helper-1
-
-This is used to find the executable name for a process. On Linux this is
-the /proc/<pid>/exe symlink and you can only do this for processes you
-own. This helper finds the executable name for processes not owned by
-you but only if you have the org.fd.pk.read authorization. This is
-important to let e.g. user 'haldaemon' check authorizations for a user
-requesting service.
-
-0664 polkituser:polkituser /var/lib/misc/polkit-1.reload
-
-This file is used by libpolkit to detect when something has changed
-(authorizations granted/revoked, defaults changed etc.). It is
-writable by both user 'polkituser' and group 'polkituser' because we
-have helpers running with both euid 'polkituser' and egid 'polkituser'
-that wants to trigger a reload.
diff --git a/acinclude.m4 b/acinclude.m4
deleted file mode 100644
index 18fa66a..0000000
--- a/acinclude.m4
+++ /dev/null
@@ -1,51 +0,0 @@
-dnl GTK_DOC_CHECK borrowed from cairo, thanks!
-
-dnl Usage:
-dnl   GTK_DOC_CHECK([minimum-gtk-doc-version])
-AC_DEFUN([GTK_DOC_CHECK],
-[
-  AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
-  AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
-  dnl for overriding the documentation installation directory
-  AC_ARG_WITH(html-dir,
-    AC_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
-    [with_html_dir='${datadir}/gtk-doc/html'])
-  HTML_DIR="$with_html_dir"
-  AC_SUBST(HTML_DIR)
-
-  dnl enable/disable documentation building
-  AC_ARG_ENABLE(gtk-doc,
-    AC_HELP_STRING([--enable-gtk-doc],
-                   [use gtk-doc to build documentation [default=yes]]),,
-    enable_gtk_doc=yes)
-
-  have_gtk_doc=no
-  if test x$enable_gtk_doc = xyes; then
-    if test -z "$PKG_CONFIG"; then
-      AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
-    fi
-    if test "$PKG_CONFIG" != "no" && $PKG_CONFIG --exists gtk-doc; then
-      have_gtk_doc=yes
-    fi
-
-  dnl do we want to do a version check?
-ifelse([$1],[],,
-    [gtk_doc_min_version=$1
-    if test "$have_gtk_doc" = yes; then
-      AC_MSG_CHECKING([gtk-doc version >= $gtk_doc_min_version])
-      if $PKG_CONFIG --atleast-version $gtk_doc_min_version gtk-doc; then
-        AC_MSG_RESULT(yes)
-      else
-        AC_MSG_RESULT(no)
-        have_gtk_doc=no
-      fi
-    fi
-])
-    if test "$have_gtk_doc" != yes; then
-      enable_gtk_doc=no
-    fi
-  fi
-
-  AM_CONDITIONAL(ENABLE_GTK_DOC, test x$enable_gtk_doc = xyes)
-  AM_CONDITIONAL(GTK_DOC_USE_LIBTOOL, test -n "$LIBTOOL")
-])
diff --git a/autogen.sh b/autogen.sh
deleted file mode 100755
index 05b1526..0000000
--- a/autogen.sh
+++ /dev/null
@@ -1,95 +0,0 @@
-#!/bin/sh
-# Run this to generate all the initial makefiles, etc.
-
-srcdir=`dirname $0`
-test -z "$srcdir" && srcdir=.
-
-DIE=0
-
-(test -f $srcdir/configure.in) || {
-    echo -n "**Error**: Directory $srcdir does not look like the"
-    echo " top-level package directory"
-    exit 1
-}
-
-(autoconf --version) < /dev/null > /dev/null 2>&1 || {
-  echo
-  echo "**Error**: You must have autoconf installed."
-  echo "Download the appropriate package for your distribution,"
-  echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
-  DIE=1
-}
-
-(grep "^AM_PROG_LIBTOOL" $srcdir/configure.in >/dev/null) && {
-  (libtool --version) < /dev/null > /dev/null 2>&1 || {
-    echo
-    echo "**Error**: You must have libtool installed."
-    echo "You can get it from: ftp://ftp.gnu.org/pub/gnu/"
-    DIE=1
-  }
-}
-
-(automake --version) < /dev/null > /dev/null 2>&1 || {
-  echo
-  echo "**Error**: You must have automake installed."
-  echo "You can get it from: ftp://ftp.gnu.org/pub/gnu/"
-  DIE=1
-  NO_AUTOMAKE=yes
-}
-
-
-# if no automake, don't bother testing for aclocal
-test -n "$NO_AUTOMAKE" || (aclocal --version) < /dev/null > /dev/null 2>&1 || {
-  echo
-  echo "**Error**: Missing aclocal.  The version of automake"
-  echo "installed doesn't appear recent enough."
-  echo "You can get automake from ftp://ftp.gnu.org/pub/gnu/"
-  DIE=1
-}
-
-if test "$DIE" -eq 1; then
-  exit 1
-fi
-
-if test -z "$*"; then
-  echo "**Warning**: I am going to run configure with no arguments."
-  echo "If you wish to pass any to it, please specify them on the"
-  echo $0 " command line."
-  echo
-fi
-
-case $CC in
-xlc )
-  am_opt=--include-deps;;
-esac
-
-      aclocalinclude="$ACLOCAL_FLAGS"
-
-      if grep "^AM_PROG_LIBTOOL" configure.in >/dev/null; then
-	if test -z "$NO_LIBTOOLIZE" ; then 
-	  echo "Running libtoolize..."
-	  libtoolize --force --copy
-	fi
-      fi
-      echo "Running aclocal $aclocalinclude ..."
-      aclocal $aclocalinclude
-      if grep "^AM_CONFIG_HEADER" configure.in >/dev/null; then
-	echo "Running autoheader..."
-	autoheader
-      fi
-      echo "Running automake --gnu -Wno-portability $am_opt ..."
-      automake --add-missing --gnu -Wno-portability $am_opt
-      echo "Running autoconf ..."
-      autoconf
-
-intltoolize --copy --force --automake                  || exit 1
-
-conf_flags="--enable-maintainer-mode --enable-gtk-doc"
-
-if test x$NOCONFIGURE = x; then
-  echo "Running $srcdir/configure $conf_flags $@ ..."
-  $srcdir/configure $conf_flags "$@" \
-  && echo "Now type make to compile." || exit 1
-else
-  echo "Skipping configure process."
-fi
diff --git a/configure.in b/configure.in
deleted file mode 100644
index 50b3ae0..0000000
--- a/configure.in
+++ /dev/null
@@ -1,677 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-
-AC_PREREQ(2.59c)
-AC_INIT(PolicyKit, 0.90, http://lists.freedesktop.org/mailman/listinfo/polkit-devel)
-AM_INIT_AUTOMAKE(PolicyKit, 0.90)
-AM_CONFIG_HEADER(config.h)
-AM_MAINTAINER_MODE
-
-# libtool versioning - this applies to all libraries in this package
-#
-# See http://sources.redhat.com/autobook/autobook/autobook_91.html#SEC91 for details
-#
-LT_CURRENT=1
-LT_REVISION=0
-LT_AGE=0
-AC_SUBST(LT_CURRENT)
-AC_SUBST(LT_REVISION)
-AC_SUBST(LT_AGE)
-
-AC_ISC_POSIX
-AC_PROG_CC
-AM_PROG_CC_STDC
-AC_HEADER_STDC
-AM_PROG_LIBTOOL
-AC_PROG_MAKE_SET
-AC_PROG_LN_S
-AC_SYS_LARGEFILE
-AM_PROG_CC_C_O
-
-# Taken from dbus
-AC_ARG_ENABLE(ansi,             [  --enable-ansi           enable -ansi -pedantic gcc flags],enable_ansi=$enableval,enable_ansi=no)
-AC_ARG_ENABLE(verbose-mode,     [  --enable-verbose-mode   support verbose debug mode],enable_verbose_mode=$enableval,enable_verbose_mode=$USE_MAINTAINER_MODE)
-AC_ARG_ENABLE(tests, AS_HELP_STRING([--enable-tests],[enable unit test code]),enable_tests=$enableval,enable_tests=$USE_MAINTAINER_MODE)
-AC_ARG_ENABLE(gcov, AS_HELP_STRING([--enable-gcov],[compile with coverage profiling instrumentation (gcc only)]),enable_gcov=$enableval,enable_gcov=no)
-AC_ARG_ENABLE(man-pages,        [  --enable-man-pages      build manual pages],enable_man_pages=$enableval,enable_man_pages=yes)
-
-AM_CONDITIONAL(KIT_BUILD_TESTS, test x$enable_tests = xyes)
-AM_CONDITIONAL(POLKIT_BUILD_TESTS, test x$enable_tests = xyes)
-if test x$enable_tests = xyes; then
-    AC_DEFINE(KIT_BUILD_TESTS,1,[Build test code])
-    AC_DEFINE(POLKIT_BUILD_TESTS,1,[Build test code])
-fi
-
-if test x$enable_gcov = xyes; then
-     if test x$enable_tests = xno; then
-          AC_ERROR([It only makes sense to use gcov if tests are enabled.])
-     fi
-     ## so that config.h changes when you toggle gcov support
-     AC_DEFINE_UNQUOTED(KIT_GCOV_ENABLED, 1, [Defined if gcov is enabled to force a rebuild due to config.h changing])
-     AC_DEFINE_UNQUOTED(POLKIT_GCOV_ENABLED, 1, [Defined if gcov is enabled to force a rebuild due to config.h changing])
-fi
-AM_CONDITIONAL(KIT_GCOV_ENABLED, test x$enable_gcov = xyes)
-AM_CONDITIONAL(POLKIT_GCOV_ENABLED, test x$enable_gcov = xyes)
-
-if test "${enable_verbose_mode}" != no; then
-    # To get -rdynamic you pass -export-dynamic to libtool.
-    AC_DEFINE(BUILT_R_DYNAMIC,1,[whether -export-dynamic was passed to libtool])
-    R_DYNAMIC_LDFLAG=-export-dynamic
-else
-    R_DYNAMIC_LDFLAG=
-fi
-AC_SUBST(R_DYNAMIC_LDFLAG)
-
-if test "${enable_man_page}" != no; then
-dnl
-dnl Check for xsltproc
-dnl
-AC_PATH_PROG([XSLTPROC], [xsltproc])
-  if test -z "$XSLTPROC"; then
-    enable_man_pages=no
-  fi
-fi
-AM_CONDITIONAL(MAN_PAGES_ENABLED, test x$enable_man_pages = xyes)
-
-
-GTK_DOC_CHECK([1.3])
-
-#### gcc warning flags
-
-if test "x$GCC" = "xyes"; then
-  changequote(,)dnl
-  case " $CFLAGS " in
-  *[\ \	]-Wall[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wall" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wchar-subscripts[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wchar-subscripts" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wmissing-declarations[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wmissing-declarations" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wnested-externs[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wnested-externs" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wpointer-arith[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wpointer-arith" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wcast-align[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wcast-align" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wsign-compare[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wsign-compare" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wformat[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wformat" ;;
-  esac
-
-  case " $CFLAGS " in
-  *[\ \	]-Wformat-security[\ \	]*) ;;
-  *) CFLAGS="$CFLAGS -Wformat-security" ;;
-  esac
-
-  if test "x$enable_ansi" = "xyes"; then
-    case " $CFLAGS " in
-    *[\ \	]-ansi[\ \	]*) ;;
-    *) CFLAGS="$CFLAGS -ansi" ;;
-    esac
-
-    case " $CFLAGS " in
-    *[\ \	]-D_POSIX_C_SOURCE*) ;;
-    *) CFLAGS="$CFLAGS -D_POSIX_C_SOURCE=199309L" ;;
-    esac
-
-    case " $CFLAGS " in
-    *[\ \	]-D_BSD_SOURCE[\ \	]*) ;;
-    *) CFLAGS="$CFLAGS -D_BSD_SOURCE" ;;
-    esac
-
-    case " $CFLAGS " in
-    *[\ \	]-pedantic[\ \	]*) ;;
-    *) CFLAGS="$CFLAGS -pedantic" ;;
-    esac
-  fi
-  if test x$enable_gcov = xyes; then
-    case " $CFLAGS " in
-    *[\ \	]-fprofile-arcs[\ \	]*) ;;
-    *) CFLAGS="$CFLAGS -fprofile-arcs" ;;
-    esac
-    case " $CFLAGS " in
-    *[\ \	]-ftest-coverage[\ \	]*) ;;
-    *) CFLAGS="$CFLAGS -ftest-coverage" ;;
-    esac
-
-    ## remove optimization
-    CFLAGS=`echo "$CFLAGS" | sed -e 's/-O[0-9]*//g'`
-  fi
-  changequote([,])dnl
-else
-  if test x$enable_gcov = xyes; then
-    AC_MSG_ERROR([--enable-gcov can only be used with gcc])
-  fi
-fi
-
-AM_CONDITIONAL(GCOV, test x$enable_gcov = xyes)
-
-PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.6.0])
-AC_SUBST(GLIB_CFLAGS)
-AC_SUBST(GLIB_LIBS)
-
-PKG_CHECK_MODULES(DBUS, [dbus-1 >= 1.0])
-AC_SUBST(DBUS_CFLAGS)
-AC_SUBST(DBUS_LIBS)
-
-PKG_CHECK_MODULES(DBUS_GLIB, [dbus-glib-1 >= 0.73])
-AC_SUBST(DBUS_GLIB_CFLAGS)
-AC_SUBST(DBUS_GLIB_LIBS)
-
-AC_CHECK_FUNCS(getgrouplist readdir64 getline strndup clearenv)
-
-EXPAT_LIB=""
-AC_ARG_WITH(expat, [  --with-expat=<dir>      Use expat from here],
-                      [
-                      expat=$withval
-                      CPPFLAGS="$CPPFLAGS -I$withval/include"
-                      LDFLAGS="$LDFLAGS -L$withval/lib"
-                      ]
-                      )
-AC_CHECK_HEADERS(expat.h, [AC_DEFINE(HAVE_EXPAT_H)], 
-		 [AC_MSG_ERROR([Can't find expat.h. Please install expat.])])
-AC_CHECK_LIB(expat,XML_ParserCreate,[EXPAT_LIBS="-lexpat"],
-	     [AC_MSG_ERROR([Can't find expat library. Please install expat.])])
-AC_SUBST(EXPAT_LIBS)
-
-if test "x$GCC" = "xyes"; then
-  LDFLAGS="-Wl,--as-needed $LDFLAGS"
-fi
-
-dnl ---------------------------------------------------------------------------
-dnl - User and group
-dnl ---------------------------------------------------------------------------
-
-AC_ARG_WITH(polkit_user,[  --with-polkit-user=<user>  user for PolicyKit])
-if test -z "$with_polkit_user" ; then
-    POLKIT_USER=polkituser
-else
-    POLKIT_USER=$with_polkit_user
-fi
-AC_SUBST(POLKIT_USER)
-AC_DEFINE_UNQUOTED(POLKIT_USER, "$POLKIT_USER", [User for PolicyKit])
-
-AC_ARG_WITH(polkit_group,[  --with-polkit-group=<grp>  group for PolicyKit])
-if test -z "$with_polkit_group" ; then
-    POLKIT_GROUP=polkituser
-else
-    POLKIT_GROUP=$with_polkit_group
-fi
-AC_SUBST(POLKIT_GROUP)
-AC_DEFINE_UNQUOTED(POLKIT_GROUP,"$POLKIT_GROUP", [Group for PolicyKit])
-
-dnl ---------------------------------------------------------------------------
-dnl - SELinux
-dnl ---------------------------------------------------------------------------
-
-AC_ARG_ENABLE(selinux, AS_HELP_STRING([--enable-selinux],[build with SELinux support]),enable_selinux=$enableval,enable_selinux=auto)
-
-# SELinux detection
-if test x$enable_selinux = xno ; then
-    have_selinux=no;
-else
-    # See if we have SELinux library
-    AC_CHECK_LIB(selinux, is_selinux_enabled, 
-                 have_selinux=yes, have_selinux=no)
-
-    if test x$enable_selinux = xauto ; then
-        if test x$have_selinux = xno ; then
-                AC_MSG_WARN([SELinux library not found])
-        fi
-    else 
-        if test x$have_selinux = xno ; then
-                AC_MSG_ERROR([SElinux explicitly required, and SELinux library not found])
-        fi
-    fi
-fi
-
-AM_CONDITIONAL(HAVE_SELINUX, test x$have_selinux = xyes)
-
-if test x$have_selinux = xyes ; then
-    # the selinux code creates threads
-    # which requires libpthread even on linux
-    AC_CHECK_FUNC(pthread_create,,[AC_CHECK_LIB(pthread,pthread_create,
-                                                [SELINUX_THREAD_LIBS="-lpthread"])])
-
-    SELINUX_LIBS="-lselinux $SELINUX_THREAD_LIBS"
-    AC_DEFINE(HAVE_SELINUX,1,[SELinux support])
-else
-    SELINUX_LIBS=
-fi
-AC_SUBST(SELINUX_LIBS)
-
-dnl ---------------------------------------------------------------------------
-dnl - Select what authorization database to use
-dnl ---------------------------------------------------------------------------
-
-AC_ARG_WITH([authdb],
-	    AS_HELP_STRING([--with-authdb=<name>], 
-                           [Authorization database (default/dummy)]))
-if ! test -z "$with_authdb" ; then
-  POLKIT_AUTHDB=$with_authdb
-else
-  POLKIT_AUTHDB=default
-fi
-
-AC_SUBST(POLKIT_AUTHDB)
-AC_DEFINE_UNQUOTED(POLKIT_AUTHDB,"$POLKIT_AUTHDB", [Authorization Database to use])
-
-case $POLKIT_AUTHDB in
-  dummy)
-    AC_DEFINE(POLKIT_AUTHDB_DUMMY, 1, [If using the dummy authorization database])
-    ;;
-
-  default)
-    AC_DEFINE(POLKIT_AUTHDB_DEFAULT, 1, [If using the default authorization database])
-    ;;
-
-  *)
-    AC_MSG_ERROR([Unknown Authorization Database: $POLKIT_AUTHDB])
-    ;;
-esac
-
-AM_CONDITIONAL(POLKIT_AUTHDB_DUMMY, [test x$POLKIT_AUTHDB = xdummy], [Using dummy authdb])
-AM_CONDITIONAL(POLKIT_AUTHDB_DEFAULT, [test x$POLKIT_AUTHDB = xdefault], [Using default authdb])
-
-dnl ---------------------------------------------------------------------------
-dnl - Select which authentication framework to use
-dnl ---------------------------------------------------------------------------
-
-AC_ARG_WITH([authfw],
-	    AS_HELP_STRING([--with-authfw=<name>], 
-                           [Authentication framework (none/pam/shadow)]))
-if ! test -z "$with_authfw" ; then
-  if test x$with_authdb = xdummy ; then
-    if ! test x$with_authfw = xnone ; then
-      AC_MSG_ERROR([Only 'none' is a valid authentication framework for the dummy authorization database])
-    fi
-  else
-      if test x$with_authfw = xnone ; then
-        AC_MSG_ERROR(['none' is only a valid authentication framework for the dummy authorization database])
-      fi
-  fi
-  POLKIT_AUTHFW=$with_authfw
-else
-  if test x$with_authdb = xdummy ; then
-    POLKIT_AUTHFW=none
-  else
-    POLKIT_AUTHFW=pam
-  fi
-fi
-
-AC_SUBST(POLKIT_AUTHFW)
-AC_DEFINE_UNQUOTED(POLKIT_AUTHFW,"$POLKIT_AUTHFW", [Authentication Framework to use])
-
-case $POLKIT_AUTHFW in
-  none)
-    need_pam=no
-    AC_DEFINE(POLKIT_AUTHFW_NONE, 1, [If using no authentication framework])
-    ;;
-
-  pam)
-    need_pam=yes
-    AC_DEFINE(POLKIT_AUTHFW_PAM, 1, [If using the PAM authentication framework])
-    ;;
-
-  shadow)
-    need_pam=no
-    AUTH_LIBS="${AUTH_LIBS} -lcrypt"
-    AC_DEFINE(POLKIT_AUTHFW_SHADOW, 1, [If using the Shadow authentication framework])
-    ;;
-
-  *)
-    AC_MSG_ERROR([Unknown Authentication Framework: $POLKIT_AUTHFW])
-    ;;
-esac
-
-AM_CONDITIONAL(POLKIT_AUTHFW_NONE, [test x$POLKIT_AUTHFW = xnone], [Using no authfw])
-AM_CONDITIONAL(POLKIT_AUTHFW_PAM, [test x$POLKIT_AUTHFW = xpam], [Using PAM authfw])
-AM_CONDITIONAL(POLKIT_AUTHFW_SHADOW, [test x$POLKIT_AUTHFW = xshadow], [Using Shadow authfw])
-
-
-dnl ---------------------------------------------------------------------------
-dnl - Check for PAM
-dnl ---------------------------------------------------------------------------
-
-withval=""
-AC_ARG_WITH(pam-prefix,
-[  --with-pam-prefix=<prefix> specify where pam files go],[
-if test x$withval != x; then
-   AC_MSG_RESULT("PAM files will be installed in prefix ${withval}.")
-fi])
-if test x$withval != x; then
-	PAM_PREFIX_UNEXPANDED="$withval"
-else
-	PAM_PREFIX_UNEXPANDED="$sysconfdir"
-fi
-PAM_PREFIX=`eval echo $PAM_PREFIX_UNEXPANDED`
-AC_SUBST(PAM_PREFIX)
-
-have_pam=no
-if test "$need_pam" = yes ; then
-  AC_CHECK_LIB(pam, pam_start, have_pam=yes)
-fi
-
-if test x$have_pam = xno; then
-    if test "$need_pam" = yes ; then
-      AC_ERROR([Could not find pam/pam-devel, please install the needed packages.])
-    fi
-else
-    AUTH_LIBS="${AUTH_LIBS} -lpam"
-    AC_DEFINE(HAVE_PAM, 1, [Define if PAM support is included])
-
-    # On Linux, sigtimedwait() is in libc; on Solaris, it's in librt.
-    have_timedwait=no
-    AC_CHECK_LIB(c, sigtimedwait, [have_timedwait=yes])
-    if test "$have_timedwait" = no ; then
-      AC_CHECK_LIB(rt, sigtimedwait, [AUTH_LIBS="${AUTH_LIBS} -lrt"])
-    fi
-
-    AC_MSG_CHECKING(how to call pam_strerror)
-    AC_CACHE_VAL(ac_cv_pam_strerror_args,
-     [AC_TRY_COMPILE([#include <stdio.h>
-                      #include <stdlib.h>
-                      #include <security/pam_appl.h>],
-                     [pam_handle_t *pamh = 0;
-                      char *s = pam_strerror(pamh, PAM_SUCCESS);],
-                     [ac_pam_strerror_args=2],
-                     [AC_TRY_COMPILE([#include <stdio.h>
-                                      #include <stdlib.h>
-                                      #include <security/pam_appl.h>],
-                                     [char *s =
-                                       pam_strerror(PAM_SUCCESS);],
-                                     [ac_pam_strerror_args=1],
-                                     [ac_pam_strerror_args=0])])
-      ac_cv_pam_strerror_args=$ac_pam_strerror_args])
-    ac_pam_strerror_args=$ac_cv_pam_strerror_args
-    if test "$ac_pam_strerror_args" = 1 ; then
-      AC_MSG_RESULT(one argument)
-    elif test "$ac_pam_strerror_args" = 2 ; then
-      AC_DEFINE(PAM_STRERROR_TWO_ARGS, 1, [Define if pam_strerror takes two arguments])
-      AC_MSG_RESULT(two arguments)
-    else
-      AC_MSG_RESULT(unknown)
-    fi
- 
-fi
-
-AM_CONDITIONAL(HAVE_PAM, test x$have_pam = xyes)
-AC_SUBST(HAVE_PAM)
-AC_SUBST(AUTH_LIBS)
-
-AC_CHECK_HEADER(security/pam_modutil.h, [AC_DEFINE(HAVE_PAM_MODUTIL_H, [], "Have pam_modutil.h")])
-AC_CHECK_HEADER(security/pam_ext.h, [AC_DEFINE(HAVE_PAM_EXT_H, [], "Have pam_ext.h")])
-AC_CHECK_LIB(pam, pam_vsyslog, [AC_DEFINE(HAVE_PAM_VSYSLOG, [], "Have pam_vsyslog")])
-
-AC_ARG_WITH(pam-module-dir, [  --with-pam-module-dir=[dirname]  directory to install PAM security module])
-if ! test -z "$with_pam_module_dir"; then
-    PAM_MODULE_DIR=$with_pam_module_dir
-else
-    PAM_MODULE_DIR="/lib/security"
-fi
-
-AC_SUBST(PAM_MODULE_DIR)
-
-AC_ARG_WITH(os-type,     [  --with-os-type=<os>        distribution or OS (redhat/suse/gentoo/pardus/solaris)])
-
-#### Check our operating system (distro-tweaks required)
-if test "z$with_os_type" = "z"; then
-	AC_CHECK_FILE(/etc/redhat-release,distro_type="redhat")
-	AC_CHECK_FILE(/etc/SuSE-release,distro_type="suse")
-	AC_CHECK_FILE(/etc/gentoo-release,distro_type="gentoo")
-	AC_CHECK_FILE(/etc/pardus-release,distro_type="pardus")
-	if test "z$distro_type" = "z"; then
-		echo "Linux distribution autodetection failed, specify the distribution to target using --with-os-type="
-	else
-		operating_system=`echo ${distro_type} | tr '[[:upper:]]' '[[:lower:]]' `
-	fi
-fi
-
-#### Sort out OS (distro-tweaks required)
-if test x$with_os_type = x; then
-    if test x$operating_system = xredhat ; then
-        with_os_type=redhat
-    elif test x$operating_system = xsuse ; then
-        with_os_type=suse
-    elif test x$operating_system = xgentoo ; then
-        with_os_type=gentoo
-    elif test x$operating_system = xpardus ; then
-        with_os_type=pardus
-    elif test x$operating_system = xsolaris ; then
-	with_os_type=solaris
-    else
-        with_os_type=unknown
-    fi
-fi
-
-# (distro-tweaks required)
-AM_CONDITIONAL(OS_TYPE_UNKNOWN, test x$with_os_type = xunknown, [Running on unknown OS])
-AM_CONDITIONAL(OS_TYPE_RED_HAT, test x$with_os_type = xredhat, [Running on Red Hat OS'es])
-AM_CONDITIONAL(OS_TYPE_SUSE, test x$with_os_type = xsuse, [Running on SUSE OS'es])
-AM_CONDITIONAL(OS_TYPE_GENTOO, test x$with_os_type = xgentoo, [Running on Gentoo OS'es])
-AM_CONDITIONAL(OS_TYPE_PARDUS, test x$with_os_type = xpardus, [Running on Pardus OS'es])
-AM_CONDITIONAL(OS_TYPE_SOLARIS, test x$with_os_type = xsolaris, [Running os Solaris OS'es])
-AM_CONDITIONAL(OS_TYPE_FREEBSD, test x$with_os_type = xfreebsd, [Running on FreeBSD OS'es])
-
-AC_ARG_WITH(pam-include, [  --with-pam-include=<file>  pam file to include])
-
-#### Set up pam file to include (distro-tweaks required)
-if ! test -z "$with_pam_include"; then
-   PAM_FILE_INCLUDE_AUTH=$with_pam_include
-   PAM_FILE_INCLUDE_ACCOUNT=$with_pam_include
-   PAM_FILE_INCLUDE_PASSWORD=$with_pam_include
-   PAM_FILE_INCLUDE_SESSION=$with_pam_include
-elif test x$with_os_type = xredhat -o x$with_os_type = xgentoo -o x$with_os_type = xpardus ; then
-   PAM_FILE_INCLUDE_AUTH=system-auth
-   PAM_FILE_INCLUDE_ACCOUNT=system-auth
-   PAM_FILE_INCLUDE_PASSWORD=system-auth
-   PAM_FILE_INCLUDE_SESSION=system-auth
-elif test x$with_os_type = xsuse -o x$with_os_type = xsolaris ; then
-   PAM_FILE_INCLUDE_AUTH=common-auth
-   PAM_FILE_INCLUDE_ACCOUNT=common-account
-   PAM_FILE_INCLUDE_PASSWORD=common-password
-   PAM_FILE_INCLUDE_SESSION=common-session
-elif test x$with_os_type = xfreebsd ; then
-    PAM_FILE_INCLUDE_AUTH=system
-    PAM_FILE_INCLUDE_ACCOUNT=system
-    PAM_FILE_INCLUDE_PASSWORD=system
-    PAM_FILE_INCLUDE_SESSION=system
-else
-   PAM_FILE_INCLUDE_AUTH=system-auth
-   PAM_FILE_INCLUDE_ACCOUNT=system-auth
-   PAM_FILE_INCLUDE_PASSWORD=system-auth
-   PAM_FILE_INCLUDE_SESSION=system-auth
-fi
-
-AC_SUBST(PAM_FILE_INCLUDE_AUTH)
-AC_SUBST(PAM_FILE_INCLUDE_ACCOUNT)
-AC_SUBST(PAM_FILE_INCLUDE_PASSWORD)
-AC_SUBST(PAM_FILE_INCLUDE_SESSION)
-AC_DEFINE_UNQUOTED(PAM_FILE_INCLUDE_AUTH, "$PAM_FILE_INCLUDE_AUTH", [pam file auth])
-AC_DEFINE_UNQUOTED(PAM_FILE_INCLUDE_ACCOUNT, "$PAM_FILE_INCLUDE_ACCOUNT", [pam file account])
-AC_DEFINE_UNQUOTED(PAM_FILE_INCLUDE_PASSWORD, "$PAM_FILE_INCLUDE_PASSWORD", [pam file password])
-AC_DEFINE_UNQUOTED(PAM_FILE_INCLUDE_SESSION, "$PAM_FILE_INCLUDE_SESSION", [pam file session])
-
-dnl ---------------------------------------------------------------------------
-dnl - check OS 
-dnl ---------------------------------------------------------------------------
-case "$host_os" in
-  *linux*)
-	;;
-  *solaris*)
-	AC_DEFINE([HAVE_SOLARIS], 1, [Is this a Solaris system?])
-	;;
-  *freebsd*)
-  	AC_DEFINE([HAVE_FREEBSD], 1, [Is this a FreeBSD system?])
-	;;
-esac
-
-have_inotify=no
-AC_CHECK_HEADERS([linux/inotify.h], [have_inotify=yes])
-AC_CHECK_HEADERS([sys/inotify.h], [have_inotify=yes])
-
-AM_CONDITIONAL(HAVE_INOTIFY, test "x$have_inotify" = "xyes")
-
-if test "x$have_inotify" = "xyes" ; then
-    AC_DEFINE([HAVE_INOTIFY], 1, [Enable Linux inotify() usage])
-fi
-
-have_kqueue=yes
-AC_CHECK_FUNCS([kqueue],,have_kqueue=no)
-
-AM_CONDITIONAL(HAVE_KQUEUE, test "x$have_kqueue" = "xyes")
-
-if test "x$have_kqueue" = "xyes" ; then
-    AC_DEFINE([HAVE_KQUEUE], 1, [Enable BSD kqueue() usage])
-fi
-
-# ********************
-# Internationalisation
-# ********************
-
-IT_PROG_INTLTOOL([0.36.0])
-GETTEXT_PACKAGE=PolicyKit
-AC_SUBST([GETTEXT_PACKAGE])
-AM_GLIB_GNU_GETTEXT
-AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE],["$GETTEXT_PACKAGE"],[gettext domain])
-
-
-AC_OUTPUT([
-Makefile
-data/Makefile
-data/polkit-grant-1
-data/polkit-1.pc
-data/polkit-grant-1.pc
-src/Makefile
-src/kit/Makefile
-src/polkit/Makefile
-src/polkit-grant/Makefile
-polkit-backendd/Makefile
-tools/Makefile
-doc/Makefile
-doc/version.xml
-doc/man/Makefile
-policy/Makefile
-po/Makefile.in
-test/Makefile
-])
-
-dnl ==========================================================================
-echo "
-                  PolicyKit $VERSION
-                =================
-
-        prefix:                     ${prefix}
-        libdir:                     ${libdir}
-        libexecdir:                 ${libexecdir}
-        bindir:                     ${bindir}
-        sbindir:                    ${sbindir}
-        datadir:                    ${datadir}
-        sysconfdir:                 ${sysconfdir}
-        localstatedir:              ${localstatedir}
-        docdir:                     ${docdir}
-
-        compiler:                   ${CC}
-        cflags:                     ${CFLAGS}
-        cppflags:                   ${CPPFLAGS}
-        xsltproc:                   ${XSLTPROC}
-
-        user for PolicyKit:         ${POLKIT_USER}
-        group for PolicyKit:        ${POLKIT_GROUP}
-
-        authorization database:     ${POLKIT_AUTHDB}
-        authentication framework:   ${POLKIT_AUTHFW}
-
-        Distribution/OS:            ${with_os_type}
-        SELinux support:            ${have_selinux}
-
-        PAM support:                ${have_pam}"
-
-if test "$have_pam" = yes ; then
-echo "        PAM file auth:              ${PAM_FILE_INCLUDE_AUTH}
-        PAM file account:           ${PAM_FILE_INCLUDE_ACCOUNT}
-        PAM file password:          ${PAM_FILE_INCLUDE_PASSWORD}
-        PAM file session:           ${PAM_FILE_INCLUDE_SESSION}"
-fi
-
-echo "
-        Maintainer mode:            ${USE_MAINTAINER_MODE}
-        Building unit tests:        ${enable_tests}
-        GCC coverage profiling:     ${enable_gcov}
-        Building verbose mode:      ${enable_verbose_mode}
-        Building api docs:          ${enable_gtk_doc}
-        Building man pages:         ${enable_man_pages}
-"
-
-if test x$enable_tests = xyes; then
-  echo "NOTE: Building with unit tests increases the size of the installed "
-  echo "      library and renders it insecure."
-  echo
-fi
-
-if test x$enable_gcov = xyes; then
-  echo "NOTE: Building with coverage profiling is definitely for developers only."
-  echo 
-fi
-
-if test "${POLKIT_AUTHDB}" = default ; then
-  echo "NOTE: Remember to create user ${POLKIT_USER} and group ${POLKIT_GROUP}"
-  echo "      before 'make install'"
-  echo
-  echo "NOTE: The directories ${localstatedir}/run/polkit-1 and ${localstatedir}/lib/polkit-1 will be"
-  echo "      owned by group ${POLKIT_GROUP} and will be mode 770."
-  echo
-  echo "NOTE: The directory ${localstatedir}/lib/polkit-public-1 will be"
-  echo "      owned by user ${POLKIT_USER} and will be mode 755."
-  echo
-  echo "NOTE: The file ${localstatedir}/lib/misc/polkit-1.reload will be"
-  echo "      owned by user ${POLKIT_USER} and group ${POLKIT_GROUP} and will be mode 664."
-  echo
-  echo "NOTE: ${libexecdir}/polkit-set-default-helper-1 will be owned by"
-  echo "      user ${POLKIT_USER} and installed with mode 4755 (setuid binary)."
-  echo
-  echo "NOTE: ${libexecdir}/polkit-read-auth-helper-1 will be owned by"
-  echo "      group ${POLKIT_GROUP} and installed with mode 2755 (setgid binary)."
-  echo
-  echo "NOTE: ${libexecdir}/polkit-revoke-helper-1 will be owned by"
-  echo "      group '${POLKIT_GROUP} and installed with mode 2755 (setgid binary)."
-  echo
-  echo "NOTE: ${libexecdir}/polkit-grant-helper-1 will be owned by"
-  echo "      group ${POLKIT_GROUP} and installed with mode 2755 (setgid binary)."
-  echo
-  echo "NOTE: ${libexecdir}/polkit-explicit-grant-helper-1 will be owned by"
-  echo "      group ${POLKIT_GROUP} and installed with mode 2755 (setgid binary)."
-  echo
-  echo "NOTE: ${libexecdir}/polkit-grant-helper-pam-1 will be owned by group"
-  echo "      ${POLKIT_GROUP} and installed with mode 4754 (setuid root binary)."
-fi
-
-echo
-echo "NOTE: ${libexecdir}/polkit-resolve-exe-helper-1 will be installed with"
-echo "      mode 4755 (setuid root binary)."
-echo
-echo "NOTE: For packaging, remember to retain the modes and ownership."
-echo
-echo "See the README file for the rationale for these modes/permissions."
-echo
diff --git a/data/Makefile.am b/data/Makefile.am
deleted file mode 100644
index 3625609..0000000
--- a/data/Makefile.am
+++ /dev/null
@@ -1,21 +0,0 @@
-## Process this file with automake to produce Makefile.in
-
-# See polkit-grant/Makefile.am for discussion
-#
-if POLKIT_AUTHFW_PAM
-pamdir = $(sysconfdir)/pam.d
-pam_DATA = polkit-grant-1
-endif
-
-pkgconfigdir = $(libdir)/pkgconfig
-pkgconfig_DATA = polkit-1.pc polkit-grant-1.pc
-
-dbusifdir = $(datadir)/dbus-1/interfaces
-dbusif_DATA = org.freedesktop.PolicyKit.AuthenticationAgent1.xml
-
-DISTCLEANFILES = polkit-1.pc polkit-grant-1.pc
-
-EXTRA_DIST = polkit-grant-1.in polkit-1.pc.in polkit-grant-1.pc.in org.freedesktop.PolicyKit.AuthenticationAgent1.xml
-
-clean-local :
-	rm -f *~
diff --git a/data/org.freedesktop.PolicyKit.AuthenticationAgent1.xml b/data/org.freedesktop.PolicyKit.AuthenticationAgent1.xml
deleted file mode 100644
index bf692aa..0000000
--- a/data/org.freedesktop.PolicyKit.AuthenticationAgent1.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN" 
-         "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
-
-<!-- This file is provided by the PolicyKit project -->
-
-<node>
-  <interface name="org.freedesktop.PolicyKit.AuthenticationAgent1">
-
-    <method name="ObtainAuthorization">
-      <!-- IN: PolicyKit action identifier; see PolKitAction -->
-      <arg name="action_id" direction="in" type="s"/>
-
-      <!-- IN: X11 window ID for the top-level X11 window the dialog will be transient for (pass zero if no window) -->
-      <arg name="xid" direction="in" type="u"/>
-
-      <!-- IN: Process ID to grant authorization to -->
-      <arg name="pid" direction="in" type="u"/>
-
-      <!-- OUT: whether the user gained the authorization -->
-      <arg name="gained_authorization" direction="out" type="b"/>
-    </method>
-
-  </interface>
-</node>
diff --git a/data/polkit-1.pc.in b/data/polkit-1.pc.in
deleted file mode 100644
index 5bc073c..0000000
--- a/data/polkit-1.pc.in
+++ /dev/null
@@ -1,12 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-policydir=@datarootdir@/polkit-1/policy/
-actiondir=@datarootdir@/polkit-1/policy/
-
-Name: polkit
-Description: Authorization API
-Version: @VERSION@
-Libs: -L${libdir} -lpolkit-1
-Cflags: -I${includedir}/polkit-1
diff --git a/data/polkit-grant-1.in b/data/polkit-grant-1.in
deleted file mode 100644
index 142dadd..0000000
--- a/data/polkit-grant-1.in
+++ /dev/null
@@ -1,6 +0,0 @@
-#%PAM-1.0
-
-auth       include      @PAM_FILE_INCLUDE_AUTH@
-account    include      @PAM_FILE_INCLUDE_ACCOUNT@
-password   include      @PAM_FILE_INCLUDE_PASSWORD@
-session    include      @PAM_FILE_INCLUDE_SESSION@
diff --git a/data/polkit-grant-1.pc.in b/data/polkit-grant-1.pc.in
deleted file mode 100644
index 5d75382..0000000
--- a/data/polkit-grant-1.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: polkit-grant-1
-Description: Library for obtaining authorizations through authentication
-Version: @VERSION@
-Requires: polkit-1
-Libs: -L${libdir} -lpolkit-grant-1
-Cflags: -I${includedir}/polkit-1
diff --git a/doc/.gitignore b/doc/.gitignore
deleted file mode 100644
index 8f1b0d9..0000000
--- a/doc/.gitignore
+++ /dev/null
@@ -1,3 +0,0 @@
-Makefile
-Makefile.in
-*.o
diff --git a/doc/Makefile.am b/doc/Makefile.am
deleted file mode 100644
index 4064815..0000000
--- a/doc/Makefile.am
+++ /dev/null
@@ -1,87 +0,0 @@
-## Process this file with automake to create Makefile.in.
-
-SUBDIRS = man
-
-NULL =
-
-AUTOMAKE_OPTIONS = 1.7
-
-# The name of the module.
-DOC_MODULE=polkit-1
-
-# The top-level SGML file.
-DOC_MAIN_SGML_FILE=polkit-docs.xml
-
-# Extra options to supply to gtkdoc-scan
-SCAN_OPTIONS=--ignore-headers=config.h
-
-# The directory containing the source code. Relative to $(srcdir)
-DOC_SOURCE_DIR=../src
-
-# Used for dependencies
-HFILE_GLOB=$(top_srcdir)/src/*/*.h
-CFILE_GLOB=$(top_srcdir)/src/*/*.c
-
-# Headers to ignore
-IGNORE_HFILES= \
-	$(NULL)
-
-# CFLAGS and LDFLAGS for compiling scan program. Only needed
-# if $(DOC_MODULE).types is non-empty.
-INCLUDES = \
-	$(DBUS_GLIB_CFLAGS)	\
-	$(GLIB_CFLAGS)		\
-	-I$(top_srcdir)/src 	\
-	-I$(top_builddir)/src	\
-	$(NULL)
-
-GTKDOC_LIBS = \
-	$(DBUS_GLIB_LIBS)					\
-	$(GLIB_LIBS)						\
-	$(top_builddir)/src/kit/libkit.la			\
-	$(top_builddir)/src/polkit/libpolkit.la			\
-	$(top_builddir)/src/polkit-dbus/libpolkit-dbus.la	\
-	$(top_builddir)/src/polkit-grant/libpolkit-grant.la	\
-	$(NULL)
-
-# Extra options to supply to gtkdoc-mkdb
-MKDB_OPTIONS=--sgml-mode --output-format=xml
-
-# Extra options to supply to gtkdoc-mktmpl
-MKTMPL_OPTIONS=
-
-# Non-autogenerated SGML files to be included in $(DOC_MAIN_SGML_FILE)
-content_files =  			    	\
-	version.xml			    	\
-	man/PolicyKit.xml		    	\
-	man/polkit-auth.xml		    	\
-	man/polkit-action.xml		    	\
-	man/polkit-policy-file-validate.xml 	\
-	spec/polkit-spec-configuration.xml  	\
-	spec/polkit-spec-introduction.xml   	\
-	spec/polkit-spec-model.xml	    	\
-	$(NULL)
-
-# Images to copy into HTML directory
-HTML_IMAGES = 				\
-	diagram-bus-model.png		\
-	diagram-interaction.png
-
-# Extra options to supply to gtkdoc-fixref
-FIXXREF_OPTIONS=
-
-MAINTAINERCLEANFILES =	\
-	*~		\
-	Makefile.in	\
-	polkit.types	\
-	polkit-*.txt	\
-	$(NULL)
-
-if ENABLE_GTK_DOC
-include $(top_srcdir)/gtk-doc.make
-else
-EXTRA_DIST =
-endif
-
-# Version information for marking the documentation
-EXTRA_DIST += version.xml.in
diff --git a/doc/TODO b/doc/TODO
deleted file mode 100644
index fd51180..0000000
--- a/doc/TODO
+++ /dev/null
@@ -1,60 +0,0 @@
-
- - On every polkit_context_is_[caller|session]_authorized we load
-   all .policy XML files. This is bad. Dave Jones will kill us. 
-   We should
-
-   1. Suggest that a single .policy file only contains actions
-      with a given name space com.example.MyApp. We do this
-      by printing a big fat WARNING in polkit-policy-file-validate(1)
-      if it isn't the case.
-
-   2. We make the policy cache smart and look for the right .policy
-      file when called from the is_*_authorized path. If it aint there
-      or if it doesn't contain the given action we load all the
-      .policy XML files.
-
-   3. When we break ABI (for 1.0 or sooner) we turn the WARNING
-      from 1. into an ERROR and drop the "Load all XML files"
-      from the is_*_authorized path. Of course, other paths
-      (iterate over all declared actions; find action by
-      annotation) will still need to load the bulk of the files.
-      But normally only polkit-auth(1) and polkit-action(1)
-      and other management tools will ever do this.
-
- - Increase test suite coverage
-
- - Finish up documentation; in particular how results from
-   config files, defaults and authorizations play together
-
- - Potentially drop the glib dependency from polkit-grant
-
- - Kill the config file
-
- - Add support for granting authorizations to a) UNIX Groups; and 
-   b) SELinux security contexts
-
- - Add API and support in polkit-auth/polkit-action for maintaining
-   a list of entities for whom implicit authorizations do not apply.
-   (Typical example is that in a desktop OS one wants a UNIX group
-    for "Restricted Users". Another example is a guest account.)
-
- - Add API and support in polkit-auth/polkit-action to define what
-   administrator auth means.
-
- - Add k/v dictionaries to Actions; e.g. the Mechanism for dial-up
-   networking can attach the key/value pair
-
-     "phone_number" -> "555-123-4567"
-
-   The is a bit like Objects mentioned in the spec (and what we used
-   to have as PolKitResource) but a bit more blurry. They need to be
-   typed too for presentation in the UI
-
- - Go to 1.0 soon
-
- - Include the patch from Piter PUNK to optionally avoid the PAM
-   dependency (manually checks against /etc/shadow instead)
-
- - To avoid work we should maintain a cache in the get_exe_for_pid()
-   functions. The key into the cache should be (pid, pid_start_time)
-   and the values should be the exe-paths
diff --git a/doc/diagram-bus-model.png b/doc/diagram-bus-model.png
deleted file mode 100644
index bba3014..0000000
Binary files a/doc/diagram-bus-model.png and /dev/null differ
diff --git a/doc/diagram-interaction.png b/doc/diagram-interaction.png
deleted file mode 100644
index 64ede01..0000000
Binary files a/doc/diagram-interaction.png and /dev/null differ
diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am
deleted file mode 100644
index 76c53f3..0000000
--- a/doc/man/Makefile.am
+++ /dev/null
@@ -1,20 +0,0 @@
-
-if MAN_PAGES_ENABLED
-
-man_MANS = polkit-auth-1.1 	           \
-	   polkit-action-1.1 		   \
-	   polkit-policy-file-validate-1.1 \
-	   PolicyKit-1.8
-
-%-1.1 %-1.8 : %.xml
-	$(XSLTPROC) -nonet http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
-
-endif # MAN_PAGES_ENABLED
-
-EXTRA_DIST= PolicyKit.xml                   	\
-	    polkit-auth.xml	            	\
-	    polkit-action.xml             	\
-	    polkit-policy-file-validate.xml
-
-clean-local:
-	rm -f *~ *.1 *.5 *.8
diff --git a/doc/man/PolicyKit.xml b/doc/man/PolicyKit.xml
deleted file mode 100644
index 071f0b3..0000000
--- a/doc/man/PolicyKit.xml
+++ /dev/null
@@ -1,63 +0,0 @@
-<refentry id="PolicyKit-1.8">
-  <refentryinfo>
-    <title>PolicyKit-1</title>
-    <date>August 2007</date>
-    <productname>PolicyKit-1</productname>
-  </refentryinfo>
-  
-  <refmeta>
-    <refentrytitle>PolicyKit-1</refentrytitle>
-    <manvolnum>8</manvolnum>
-    <refmiscinfo class="version"></refmiscinfo>
-  </refmeta>
-  
-  <refnamediv>
-    <refname>PolicyKit-1</refname>
-    <refpurpose>Authorization API</refpurpose>
-  </refnamediv>
-  
-  <refsect1><title>DESCRIPTION</title> 
-    <para>
-      For more information about the big picture refer to the
-      PolicyKit specification which can be normally be found
-      under <filename>/usr/share/doc</filename>.
-    </para>
-    
-    <para>
-      <emphasis>TODO:</emphasis> This manual page should contain a
-      simple introduction to PolicyKit for a system administrator
-      audience. Remains to be written.
-    </para>
-  </refsect1>
-  
-  
-  <refsect1><title>AUTHOR</title> 
-    <para>
-      Written by David Zeuthen <email>david at fubar.dk</email> with
-      a lot of help from many others.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>BUGS</title> 
-    <para>
-      Please send bug reports to either the distribution or the
-      polkit-devel mailing list,
-      see <ulink url="http://lists.freedesktop.org/mailman/listinfo/polkit-devel"/>.
-      to subscribe.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>SEE ALSO</title>
-    <para>
-      <citerefentry>
-        <refentrytitle>polkit-action-1</refentrytitle><manvolnum>1</manvolnum>
-      </citerefentry>, 
-      <citerefentry>
-        <refentrytitle>polkit-auth-1</refentrytitle><manvolnum>1</manvolnum>
-      </citerefentry>
-    </para>
-  </refsect1>
-</refentry>
-
diff --git a/doc/man/polkit-action.xml b/doc/man/polkit-action.xml
deleted file mode 100644
index 629d7ea..0000000
--- a/doc/man/polkit-action.xml
+++ /dev/null
@@ -1,194 +0,0 @@
-<refentry id="polkit-action-1.1">
-  <refentryinfo>
-    <title>polkit-action-1</title>
-    <date>August 2007</date>
-    <productname>PolicyKit-1</productname>
-  </refentryinfo>
-  
-  <refmeta>
-    <refentrytitle>polkit-action-1</refentrytitle>
-    <manvolnum>1</manvolnum>
-    <refmiscinfo class="version"></refmiscinfo>
-  </refmeta>
-  
-  <refnamediv>
-    <refname>polkit-action-1</refname>
-    <refpurpose>List and modify registered PolicyKit actions</refpurpose>
-  </refnamediv>
-  
-  <refsynopsisdiv>
-    <cmdsynopsis>
-      <command>polkit-action-1</command>
-      <arg><option>--action <replaceable>action</replaceable></option></arg>
-      <arg><option>--reset-defaults <replaceable>action</replaceable></option></arg>
-      <arg><option>--show-overrides</option></arg>
-      <arg><option>--set-defaults-any <replaceable>action</replaceable> <replaceable>value</replaceable></option></arg>
-      <arg><option>--set-defaults-inactive <replaceable>action</replaceable> <replaceable>value</replaceable></option></arg>
-      <arg><option>--set-defaults-active <replaceable>action</replaceable> <replaceable>value</replaceable></option></arg>
-      <arg><option>--version</option></arg>
-      <arg><option>--help</option></arg>
-    </cmdsynopsis>
-  </refsynopsisdiv>
-  
-  <refsect1>
-    <title>DESCRIPTION</title> 
-    <para>
-      polkit-action-1 is used to list and modify the PolicyKit actions
-      that are registered on the system.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>OPTIONS</title> 
-    <variablelist>
-      <varlistentry>
-        <term><option>--action <replaceable>action</replaceable></option></term>
-        <listitem>
-          <para>
-            Show detailed information about a specific action.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option>--reset-defaults <replaceable>action</replaceable></option></term>
-        <listitem>
-          <para>
-            Reset the defaults for the specified action to the factory
-            defaults. The authorization needed to do this is
-            <emphasis>org.freedesktop.policykit.modify-defaults</emphasis>.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option>--show-overrides</option></term>
-        <listitem>
-          <para>
-            Prints all actions for where the defaults are overridden.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option>--set-defaults-any <replaceable>action</replaceable> <replaceable>value</replaceable></option></term>
-        <listitem>
-          <para>
-            Override the <emphasis>any</emphasis> stanza for the given
-            action with the supplied value. The authorization needed
-            to do this is <emphasis>org.freedesktop.policykit.modify-defaults</emphasis>.
-            Valid values for <emphasis>value</emphasis> are
-            <emphasis>no</emphasis>,
-            <emphasis>auth_admin_one_shot</emphasis>,
-            <emphasis>auth_admin</emphasis>,
-            <emphasis>auth_admin_keep_session</emphasis>,
-            <emphasis>auth_admin_keep_always</emphasis>,
-            <emphasis>auth_self_one_shot</emphasis>,
-            <emphasis>auth_self</emphasis>,
-            <emphasis>auth_self_keep_session</emphasis>,
-            <emphasis>auth_self_keep_always</emphasis>,
-            and <emphasis>yes</emphasis>.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option>--set-defaults-inactive <replaceable>action</replaceable> <replaceable>value</replaceable></option></term>
-        <listitem>
-          <para>
-            Override the <emphasis>inactive</emphasis> stanza for the given
-            action with the supplied value. The authorization needed
-            to do this is <emphasis>org.freedesktop.policykit.modify-defaults</emphasis>.
-            Valid values for <emphasis>value</emphasis> are
-            <emphasis>no</emphasis>,
-            <emphasis>auth_admin_one_shot</emphasis>,
-            <emphasis>auth_admin</emphasis>,
-            <emphasis>auth_admin_keep_session</emphasis>,
-            <emphasis>auth_admin_keep_always</emphasis>,
-            <emphasis>auth_self_one_shot</emphasis>,
-            <emphasis>auth_self</emphasis>,
-            <emphasis>auth_self_keep_session</emphasis>,
-            <emphasis>auth_self_keep_always</emphasis>,
-            and <emphasis>yes</emphasis>.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option>--set-defaults-active <replaceable>action</replaceable> <replaceable>value</replaceable></option></term>
-        <listitem>
-          <para>
-            Override the <emphasis>active</emphasis> stanza for the given
-            action with the supplied value. The authorization needed
-            to do this is <emphasis>org.freedesktop.policykit.modify-defaults</emphasis>.
-            Valid values for <emphasis>value</emphasis> are
-            <emphasis>no</emphasis>,
-            <emphasis>auth_admin_one_shot</emphasis>,
-            <emphasis>auth_admin</emphasis>,
-            <emphasis>auth_admin_keep_session</emphasis>,
-            <emphasis>auth_admin_keep_always</emphasis>,
-            <emphasis>auth_self_one_shot</emphasis>,
-            <emphasis>auth_self</emphasis>,
-            <emphasis>auth_self_keep_session</emphasis>,
-            <emphasis>auth_self_keep_always</emphasis>,
-            and <emphasis>yes</emphasis>.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      
-      <varlistentry>
-        <term><option>--version</option></term>
-        <listitem>
-          <para>
-            Show version and exit.
-          </para>
-        </listitem>
-      </varlistentry>
-      
-      <varlistentry>
-        <term><option>--help</option></term>
-        <listitem>
-          <para>
-            Show usage information and exit.
-          </para>
-        </listitem>
-      </varlistentry>
-    </variablelist>
-  </refsect1>
-
-  <refsect1>
-    <title>COMPLETION</title> 
-    <para>
-      PolicyKit ships with a collection of shell functions such that
-      completion on options, <emphasis>action</emphasis>
-      and <emphasis>value</emphasis> works when using the
-      <citerefentry>
-        <refentrytitle>bash</refentrytitle><manvolnum>1</manvolnum>
-      </citerefentry>
-      shell.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>BUGS</title> 
-    <para>
-      Please send bug reports to either the distribution or the
-      polkit-devel mailing list,
-      see <ulink url="http://lists.freedesktop.org/mailman/listinfo/polkit-devel"/>.
-      to subscribe.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>SEE ALSO</title>
-    <para>
-      <citerefentry>
-        <refentrytitle>PolicyKit</refentrytitle><manvolnum>8</manvolnum>
-      </citerefentry>, 
-      <citerefentry>
-        <refentrytitle>polkit-auth-1</refentrytitle><manvolnum>1</manvolnum>
-      </citerefentry>
-    </para>
-  </refsect1>
-</refentry>
diff --git a/doc/man/polkit-auth.xml b/doc/man/polkit-auth.xml
deleted file mode 100644
index bea49f5..0000000
--- a/doc/man/polkit-auth.xml
+++ /dev/null
@@ -1,343 +0,0 @@
-<refentry id="polkit-auth-1.1">
-  <refentryinfo>
-    <title>polkit-auth-1</title>
-    <date>August 2007</date>
-    <productname>PolicyKit-1</productname>
-  </refentryinfo>
-  
-  <refmeta>
-    <refentrytitle>polkit-auth-1</refentrytitle>
-    <manvolnum>1</manvolnum>
-    <refmiscinfo class="version"></refmiscinfo>
-  </refmeta>
-  
-  <refnamediv>
-    <refname>polkit-auth-1</refname>
-    <refpurpose>Manage authorizations</refpurpose>
-  </refnamediv>
-  
-  <refsynopsisdiv>
-    <cmdsynopsis>
-      <command>polkit-auth-1</command>
-      <arg><option>--obtain <replaceable>action</replaceable></option></arg>
-      <arg><option>--show-obtainable</option></arg>
-      <arg><option><arg><option>--user <replaceable>user</replaceable></option></arg> --explicit</option></arg>
-      <arg><option><arg><option>--user <replaceable>user</replaceable></option></arg> --explicit-detail</option></arg>
-      <arg><option><arg><option>--user <replaceable>user</replaceable></option></arg> --grant <replaceable>action</replaceable></option><arg><option>--constraint <replaceable>constraint</replaceable></option></arg>*</arg>
-      <arg><option><arg><option>--user <replaceable>user</replaceable></option></arg> --block <replaceable>action</replaceable></option><arg><option>--constraint <replaceable>constraint</replaceable></option></arg>*</arg>
-      <arg><option><arg><option>--user <replaceable>user</replaceable></option></arg> --revoke <replaceable>action</replaceable></option></arg>
-      <arg><option>--version</option></arg>
-      <arg><option>--help</option></arg>
-    </cmdsynopsis>
-  </refsynopsisdiv>
-  
-  <refsect1>
-    <title>DESCRIPTION</title> 
-    <para>
-      polkit-auth-1 is used to inspect, obtain, grant and revoke
-      PolicyKit authorizations. If invoked without any options, the
-      authorizations of the calling process will be printed.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>OPTIONS</title> 
-    <variablelist>
-      <varlistentry>
-        <term><option>--obtain <replaceable>action</replaceable></option></term>
-        <listitem>
-          <para>
-            Attempt to obtain an authorization through authentication
-            for the given action. This is only useful for implicit
-            authorizations requiring authentication; e.g. when an
-            appropriate stanza in the defaults section of the .policy
-            file for the action specifies
-            <literal>auth_*</literal>. 
-          </para>
-          <para> 
-
-            The gained authorization will be constrained as much as
-            possible using the constraints specified in
-            <xref linkend="polkit-auth-constraints"/>. For example, on
-            a system running SELinux, if the caller runs uses this
-            tool to obtain an authorization from a shell in a desktop
-            in an active session, then constraints
-            for <emphasis>local</emphasis>, <emphasis>active</emphasis>, <emphasis>exe</emphasis>
-            and <emphasis>selinux_context</emphasis> will all be
-            added.
-          </para>
-          <para> 
-            If an Authentication Agent (such as the one from
-            PolicyKit-gnome) is available in the session, it will used
-            for authentication unless the environment variable
-            POLKIT_AUTH_FORCE_TEXT is set. If the environment variable
-            POLKIT_AUTH_GRANT_TO_PID is set, the authorization will be
-            granted to that process id instead of the invoking process
-            (e.g. the shell from which polkit-auth-1 is launched).
-          </para>
-        </listitem>
-      </varlistentry>
-      
-      <varlistentry>
-        <term><option>--show-obtainable</option></term>
-        <listitem>
-          <para>
-             Prints all actions that can be obtained via
-             authentication and for which an authorization does not
-             exist.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option><arg><option>--user <replaceable>user</replaceable></option></arg> --explicit</option></term>
-        <listitem>
-          <para>
-            Show explicit authorizations. Duplicates are not
-            printed. If used with the <option>--user</option> option,
-            the authorization
-            <literal>org.freedesktop.policykit.read</literal> is required.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option><arg><option>--user <replaceable>user</replaceable></option></arg> --explicit-detail</option></term>
-        <listitem>
-          <para>
-            Show detailed information about explicit
-            authorizations. In contrast to
-            the <literal>--explicit</literal>, duplicates are printed
-            as several authorizations with different scope and
-            constraints may exist.
-          </para>
-        </listitem>
-      </varlistentry>
-      
-      <varlistentry>
-        <term><option><arg><option>--user <replaceable>user</replaceable></option></arg> --grant <replaceable>action</replaceable></option><arg><option>--constraint <replaceable>constraint</replaceable></option></arg>*</term>
-        <listitem>
-          <para>
-            Grant an authorization for an action. This is different
-            than <literal>--obtain</literal> insofar that
-            the <literal>defaults</literal> stanza of the .policy file
-            is not consulted. Optionally, one or more constraints on
-            the granted authorization can be specified, see
-            <xref linkend="polkit-auth-constraints"/> for details. The
-            authorization needed to grant authorizations is
-            <literal>org.freedesktop.policykit.grant</literal>.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option><arg><option>--user <replaceable>user</replaceable></option></arg> --block <replaceable>action</replaceable></option><arg><option>--constraint <replaceable>constraint</replaceable></option></arg>*</term>
-        <listitem>
-          <para>
-            Grant an negative authorization for an action. Negative
-            authorizations are normally used to block users that would
-            normally be authorized due to implicit
-            authorizations. Optionally, one or more constraints on the
-            granted authorization can be specified, see
-            <xref linkend="polkit-auth-constraints"/> for details. The
-            authorization needed to grant negative authorizations is
-            <literal>org.freedesktop.policykit.grant</literal> if the
-            "beneficiary" is another user.
-          </para>
-        </listitem>
-      </varlistentry>
-
-      <varlistentry>
-        <term><option><arg><option>--user <replaceable>user</replaceable></option></arg> --revoke <replaceable>action</replaceable></option></term>
-        <listitem>
-          <para>
-            Revoke all authorizations for an action. If the user is
-            not specified the calling user is used. The
-            authorization <literal>org.freedesktop.policykit.revoke</literal>
-            is needed to revoke authorizations from other users.
-          </para>
-        </listitem>
-      </varlistentry>
-      
-      <varlistentry>
-        <term><option>--version</option></term>
-        <listitem>
-          <para>
-            Show version and exit.
-          </para>
-        </listitem>
-      </varlistentry>
-      
-      <varlistentry>
-        <term><option>--help</option></term>
-        <listitem>
-          <para>
-            Show this information.
-          </para>
-        </listitem>
-      </varlistentry>
-    </variablelist>
-  </refsect1>
-  
-  <refsect1 id="polkit-auth-constraints">
-    <title>CONSTRAINTS</title> 
-    <para>
-      One can put one or more <emphasis>constraints</emphasis> on an
-      authorization. They are used to limit where the authrorization
-      applies. Presently the following constraints are supported
-
-      <variablelist>
-        <varlistentry>
-          <term><option>--constraint local</option></term>
-          <listitem>
-            <para>
-              The caller must be in a session on a local console
-              attached to the system. For example processes that
-              belong to remote XDMCP or ssh connections will fail to
-              meet this constraint and as such the authorization with
-              such a constraint won't apply.
-            </para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term><option>--constraint active</option></term>
-          <listitem>
-            <para>
-              The caller must be in an active session. This is
-              typically used with a <emphasis>local</emphasis>
-              constraint to ensure that the caller is only authorized
-              if his session is in the foreground. This is typically
-              used for fast user switching (multiple sessions on the
-              same console) to prevent inactive sessions from doing
-              privileged operations like spying (using a webcam or a
-              sound card) on the current active session.
-            </para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term><option>--constraint exe:<replaceable>/path/to/program</replaceable></option></term>
-          <listitem>
-            <para>
-              The authorization is constrained to processes for where
-              executable path (<literal>/proc/pid/exe</literal> on
-              Linux) matches the given path. See
-              <xref linkend="polkit-auth-notes"/> for limitations on
-              why this may not be secure.
-            </para>
-          </listitem>
-        </varlistentry>
-
-        <varlistentry>
-          <term><option>--constraint selinux_context:<replaceable>system_u:object_r:some_context_t</replaceable></option></term>
-          <listitem>
-            <para>
-              The authorization is constrained to processes for where
-              their SELinux security context matches the given
-              context.
-            </para>
-          </listitem>
-        </varlistentry>
-      </variablelist>
-
-    </para>
-  </refsect1>
-
-  <refsect1 id="polkit-auth-notes">
-    <title>NOTES</title> 
-    <para>
-      Note that the executable path for a process is not necessary
-      reliable information and as such shouldn't be relied on 100% to
-      make a security decision. In fact, this information is only
-      trustworthy in situations where the given binary is securely
-      locked down meaning that 1) it can't
-      be <literal>ptrace(2)</literal>'d; 2) libc secure mode kicks in
-      (e.g <literal>LD_PRELOAD</literal> won't work); 3) there are no
-      other attack vectors (e.g. GTK_MODULES, X11, CORBA, D-Bus) to
-      patch running code into the process.
-    </para>
-    <para>
-      In other words: the risk of relying on constraining an
-      authorization to a path of an executable is high. Suppose that
-      the program <literal>/usr/bin/gullible</literal> obtains an
-      authorization via authentication for the action
-      <literal>org.example.foo</literal>. We add a constraint to say
-      that the gained authorization only applies to processes for whom
-      <literal>/proc/pid/exe</literal> points to
-      <literal>/usr/bin/gullible</literal>.
-    </para>
-    <para>
-      Now enter <literal>/usr/bin/evil</literal>. It knows that the
-      program <literal>/usr/bin/gullible</literal> is not "securely
-      locked down" (per the definition in the above paragraph). So
-      <literal>/usr/bin/evil</literal> simply sets
-      <literal>LD_PRELOAD</literal> and execs
-      <literal>/usr/bin/gullible</literal> and it can now run code in a
-      process where <literal>/proc/pid/exe</literal> points to
-      <literal>/usr/bin/gullible</literal>. Thus, the recently gained
-      authorization for <literal>org.example.foo</literal> applies. Also,
-      <literal>/usr/bin/evil</literal> could use a host of other attack
-      vectors to run it's own code under the disguise of pretending to be
-      <literal>/usr/bin/gullible</literal>.
-    </para>
-    <para>
-      Specifically for interpreted languages like Python and Mono it
-      is the case that <literal>/proc/pid/exe</literal> always points
-      to
-      <literal>/usr/bin/python</literal>
-      resp. <literal>/usr/bin/mono</literal>. Thus, it's not very useful
-      to rely on that the result for this function if you want to
-      constrain an authorization to
-      e.g. <literal>/usr/bin/tomboy</literal> or
-      <literal>/usr/bin/banshee</literal>.
-    </para>
-    <para>
-      It is however possible to write programs that are "securely
-      locked down" (per the definition in the above paragraph); for
-      example all properly written <literal>setuid</literal>
-      and <literal>setgid</literal> programs are written in this way.
-    </para>
-  </refsect1>
-
-  <refsect1>
-    <title>COMPLETION</title> 
-    <para>
-      PolicyKit ships with a collection of shell functions such that
-      completion on users, actions and constraints work when using the
-      <citerefentry>
-        <refentrytitle>bash</refentrytitle><manvolnum>1</manvolnum>
-      </citerefentry>
-      shell. For completion to properly work for polkit-auth-1,
-      arguments should be entered in the order specified in this
-      manual page; for example. <option>--user</option> should be
-      specified before <option>--revoke</option> to complete only on
-      the authorizations the given user has. Note that if the calling
-      user lacks the <literal>org.freedesktop.policykit.read</literal>
-      authorization, the completion function will fall back to
-      completing on all registered actions.
-    </para>
-  </refsect1>
-
-  <refsect1>
-    <title>BUGS</title> 
-    <para>
-      Please send bug reports to either the distribution or the
-      polkit-devel mailing list,
-      see <ulink url="http://lists.freedesktop.org/mailman/listinfo/polkit-devel"/>.
-      to subscribe.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>SEE ALSO</title>
-    <para>
-      <citerefentry>
-        <refentrytitle>PolicyKit-1</refentrytitle><manvolnum>8</manvolnum>
-      </citerefentry>, 
-      <citerefentry>
-        <refentrytitle>polkit-action-1</refentrytitle><manvolnum>1</manvolnum>
-      </citerefentry>
-    </para>
-  </refsect1>
-</refentry>
diff --git a/doc/man/polkit-policy-file-validate.xml b/doc/man/polkit-policy-file-validate.xml
deleted file mode 100644
index 61a17e2..0000000
--- a/doc/man/polkit-policy-file-validate.xml
+++ /dev/null
@@ -1,89 +0,0 @@
-<refentry id="polkit-policy-file-validate-1.1">
-  <refentryinfo>
-    <title>polkit-policy-file-validate-1</title>
-    <date>August 2007</date>
-    <productname>PolicyKit-1</productname>
-  </refentryinfo>
-  
-  <refmeta>
-    <refentrytitle>polkit-policy-file-validate-1</refentrytitle>
-    <manvolnum>1</manvolnum>
-    <refmiscinfo class="version"></refmiscinfo>
-  </refmeta>
-  
-  <refnamediv>
-    <refname>polkit-policy-file-validate-1</refname>
-    <refpurpose>Validate a PolicyKit policy file</refpurpose>
-  </refnamediv>
-  
-  <refsynopsisdiv>
-    <cmdsynopsis>
-      <command>polkit-policy-file-validate-1 <replaceable>policy-files</replaceable></command>
-      <arg><option>--version</option></arg>
-      <arg><option>--help</option></arg>
-    </cmdsynopsis>
-  </refsynopsisdiv>
-  
-  <refsect1>
-    <title>DESCRIPTION</title> 
-    <para>
-      polkit-policy-file-validate-1 is used to verify that one or
-      more PolicyKit <emphasis>.policy</emphasis> files are valid.
-    </para>
-    
-    <para>
-      Normally this tool is used in the software release process
-      (typically during <emphasis>"make check"</emphasis>) and
-      during software installation (e.g. in
-      the <emphasis>%post</emphasis> section of a RPM spec file).
-    </para>
-    
-    <para>
-      This program exit with exit code 0 if all the files
-      validate. If not, the program exits with a non-zero exit
-      code.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>OPTIONS</title> 
-    <variablelist>
-      <varlistentry>
-        <term><option>--version</option></term>
-        <listitem>
-          <para>
-            Show version and exit.
-          </para>
-        </listitem>
-      </varlistentry>
-      
-      <varlistentry>
-        <term><option>--help</option></term>
-        <listitem>
-          <para>
-            Show usage information and exit.
-          </para>
-        </listitem>
-      </varlistentry>
-    </variablelist>
-  </refsect1>
-  
-  <refsect1>
-    <title>BUGS</title> 
-    <para>
-      Please send bug reports to either the distribution or the
-      polkit-devel mailing list,
-      see <ulink url="http://lists.freedesktop.org/mailman/listinfo/polkit-devel"/>.
-      to subscribe.
-    </para>
-  </refsect1>
-  
-  <refsect1>
-    <title>SEE ALSO</title>
-    <para>
-      <citerefentry>
-        <refentrytitle>PolicyKit-1</refentrytitle><manvolnum>8</manvolnum>
-      </citerefentry>, 
-    </para>
-  </refsect1>
-</refentry>
diff --git a/doc/polkit-diagrams.svg b/doc/polkit-diagrams.svg
deleted file mode 100644
index ffa4c27..0000000
--- a/doc/polkit-diagrams.svg
+++ /dev/null
@@ -1,1923 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-<svg
-   xmlns:dc="http://purl.org/dc/elements/1.1/"
-   xmlns:cc="http://web.resource.org/cc/"
-   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-   xmlns:svg="http://www.w3.org/2000/svg"
-   xmlns="http://www.w3.org/2000/svg"
-   xmlns:xlink="http://www.w3.org/1999/xlink"
-   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
-   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
-   width="744.09448819"
-   height="1052.3622047"
-   id="svg2"
-   sodipodi:version="0.32"
-   inkscape:version="0.45.1"
-   sodipodi:docbase="/home/davidz/Hacking/PolicyKit/doc"
-   sodipodi:docname="polkit-diagrams.svg"
-   inkscape:output_extension="org.inkscape.output.svg.inkscape">
-  <defs
-     id="defs4">
-    <linearGradient
-       id="linearGradient30011">
-      <stop
-         style="stop-color:#ffffff;stop-opacity:1;"
-         offset="0"
-         id="stop30013" />
-      <stop
-         style="stop-color:#9d9fff;stop-opacity:0;"
-         offset="1"
-         id="stop30015" />
-    </linearGradient>
-    <linearGradient
-       id="linearGradient30001">
-      <stop
-         style="stop-color:#ffffff;stop-opacity:1;"
-         offset="0"
-         id="stop30003" />
-      <stop
-         style="stop-color:#ff9d9d;stop-opacity:0;"
-         offset="1"
-         id="stop30005" />
-    </linearGradient>
-    <linearGradient
-       id="linearGradient28966">
-      <stop
-         style="stop-color:#ffffff;stop-opacity:1;"
-         offset="0"
-         id="stop28968" />
-      <stop
-         style="stop-color:#9dff9d;stop-opacity:0;"
-         offset="1"
-         id="stop28970" />
-    </linearGradient>
-    <linearGradient
-       inkscape:collect="always"
-       id="linearGradient22901">
-      <stop
-         style="stop-color:#9da7d7;stop-opacity:1;"
-         offset="0"
-         id="stop22903" />
-      <stop
-         style="stop-color:#9da7d7;stop-opacity:0;"
-         offset="1"
-         id="stop22905" />
-    </linearGradient>
-    <marker
-       inkscape:stockid="Arrow1Lend"
-       orient="auto"
-       refY="0.0"
-       refX="0.0"
-       id="Arrow1Lend"
-       style="overflow:visible;">
-      <path
-         id="path17830"
-         d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
-         style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none;"
-         transform="scale(0.8) rotate(180) translate(12.5,0)" />
-    </marker>
-    <marker
-       inkscape:stockid="Arrow1Lstart"
-       orient="auto"
-       refY="0.0"
-       refX="0.0"
-       id="Arrow1Lstart"
-       style="overflow:visible">
-      <path
-         id="path17827"
-         d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
-         style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;marker-start:none"
-         transform="scale(0.8) translate(12.5,0)" />
-    </marker>
-    <linearGradient
-       id="linearGradient14609">
-      <stop
-         id="stop14611"
-         offset="0"
-         style="stop-color:#ffffff;stop-opacity:1;" />
-      <stop
-         id="stop14613"
-         offset="1"
-         style="stop-color:#ff9d9d;stop-opacity:0;" />
-    </linearGradient>
-    <linearGradient
-       id="linearGradient14599">
-      <stop
-         id="stop14601"
-         offset="0"
-         style="stop-color:#b1c8ff;stop-opacity:1;" />
-      <stop
-         id="stop14603"
-         offset="1"
-         style="stop-color:#ffffff;stop-opacity:0;" />
-    </linearGradient>
-    <linearGradient
-       id="linearGradient9630">
-      <stop
-         style="stop-color:#030000;stop-opacity:1;"
-         offset="0"
-         id="stop9632" />
-      <stop
-         style="stop-color:#030000;stop-opacity:0;"
-         offset="1"
-         id="stop9634" />
-    </linearGradient>
-    <linearGradient
-       id="linearGradient3144">
-      <stop
-         style="stop-color:#ffffff;stop-opacity:1;"
-         offset="0"
-         id="stop3146" />
-      <stop
-         style="stop-color:#898585;stop-opacity:0;"
-         offset="1"
-         id="stop3148" />
-    </linearGradient>
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient7620"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,14.768091,-4.73212)" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient7664"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,135.98639,-4.73213)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient7684"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,260.23514,-4.73212)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient14609"
-       id="linearGradient13600"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,73.861991,207.39991)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient14609"
-       id="linearGradient13602"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,198.11074,207.39991)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <radialGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient22901"
-       id="radialGradient22907"
-       cx="214.15234"
-       cy="161.40764"
-       fx="214.15234"
-       fy="161.40764"
-       r="34.795188"
-       gradientUnits="userSpaceOnUse" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient23025"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,18.600748,302.65487)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient14609"
-       id="linearGradient28994"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,18.600773,481.17778)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient28966"
-       id="linearGradient28996"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7361648,0,0,0.2163389,18.431136,546.16953)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient29026"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,407.77533,303.18174)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient14609"
-       id="linearGradient29028"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,407.77536,481.70465)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient28966"
-       id="linearGradient29030"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7361648,0,0,0.2163389,407.60572,546.6964)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient30011"
-       id="linearGradient30009"
-       x1="407.16495"
-       y1="793.64789"
-       x2="513.12079"
-       y2="793.64789"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.8453762,0,0,0.6900936,261.57945,20.793414)" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient30045"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,17.702047,632.20205)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient14609"
-       id="linearGradient30047"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,17.702072,810.72493)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient28966"
-       id="linearGradient30049"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7361648,0,0,0.2163389,17.532435,875.71673)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient30079"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,406.70205,631.77348)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient30099"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,577.84491,631.77865)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient28966"
-       id="linearGradient30111"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7361648,0,0,0.2163389,577.38958,697.06866)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient30141"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,13.987768,950.59751)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient30143"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,185.13064,950.60271)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient28966"
-       id="linearGradient30145"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7361648,0,0,0.2163389,184.67531,1015.8927)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient30011"
-       id="linearGradient30155"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.8453762,0,0,0.6900936,-115.27956,642.95653)"
-       x1="407.16495"
-       y1="793.64789"
-       x2="513.12079"
-       y2="793.64789" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient30011"
-       id="linearGradient30207"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.8453762,0,0,0.6900936,255.57759,668.81627)"
-       x1="407.16495"
-       y1="793.64789"
-       x2="513.12079"
-       y2="793.64789" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient3144"
-       id="linearGradient30209"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,401.77347,951.20458)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient14609"
-       id="linearGradient30211"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7347995,0,0,0.5175383,401.7735,1129.7274)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-    <linearGradient
-       inkscape:collect="always"
-       xlink:href="#linearGradient28966"
-       id="linearGradient30213"
-       gradientUnits="userSpaceOnUse"
-       gradientTransform="matrix(0.7361648,0,0,0.2163389,401.60386,1194.7192)"
-       x1="52.07793"
-       y1="89.181732"
-       x2="196.4196"
-       y2="89.181732" />
-  </defs>
-  <sodipodi:namedview
-     id="base"
-     pagecolor="#ffffff"
-     bordercolor="#666666"
-     borderopacity="1.0"
-     gridtolerance="10000"
-     guidetolerance="10"
-     objecttolerance="10"
-     inkscape:pageopacity="0.0"
-     inkscape:pageshadow="2"
-     inkscape:zoom="0.7"
-     inkscape:cx="284.9253"
-     inkscape:cy="317.35971"
-     inkscape:document-units="px"
-     inkscape:current-layer="layer1"
-     inkscape:window-width="1026"
-     inkscape:window-height="1108"
-     inkscape:window-x="0"
-     inkscape:window-y="0" />
-  <metadata
-     id="metadata7">
-    <rdf:RDF>
-      <cc:Work
-         rdf:about="">
-        <dc:format>image/svg+xml</dc:format>
-        <dc:type
-           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
-      </cc:Work>
-    </rdf:RDF>
-  </metadata>
-  <g
-     inkscape:label="Layer 1"
-     inkscape:groupmode="layer"
-     id="layer1">
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.47417995;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect31304"
-       width="302.2439"
-       height="3.4562778"
-       x="417.59393"
-       y="1105.9136"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="677.01654"
-       y="1086.4985"
-       id="text31306"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="677.01654"
-         y="1086.4985"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31308">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="677.01654"
-         y="1098.9985"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31310">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="675.82733"
-       y="1120.5072"
-       id="text31312"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="675.82733"
-         y="1120.5072"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31314">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="675.82733"
-         y="1133.0072"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31316">(privileged)</tspan></text>
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.47417995;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect31290"
-       width="302.2439"
-       height="3.4562778"
-       x="417.61426"
-       y="435.89325"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="677.03687"
-       y="416.47827"
-       id="text31292"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="677.03687"
-         y="416.47827"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31294">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="677.03687"
-         y="428.97827"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31296">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="675.84766"
-       y="450.48694"
-       id="text31298"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="675.84766"
-         y="450.48694"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31300">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="675.84766"
-         y="462.98694"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31302">(privileged)</tspan></text>
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.47417995;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect31262"
-       width="302.2439"
-       height="3.4562778"
-       x="55.903503"
-       y="1106.2942"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="101.32614"
-       y="1086.8793"
-       id="text31264"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="101.32614"
-         y="1086.8793"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31266">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="101.32614"
-         y="1099.3793"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31268">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="100.13693"
-       y="1120.8879"
-       id="text31270"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="100.13693"
-         y="1120.8879"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31272">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="100.13693"
-         y="1133.3879"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31274">(privileged)</tspan></text>
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.47417995;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect31248"
-       width="302.2439"
-       height="3.4562778"
-       x="55.903503"
-       y="765.45148"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="315.32614"
-       y="746.0365"
-       id="text31250"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="315.32614"
-         y="746.0365"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31252">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="315.32614"
-         y="758.5365"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31254">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="314.13693"
-       y="780.04517"
-       id="text31256"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="314.13693"
-         y="780.04517"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31258">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="314.13693"
-         y="792.54517"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31260">(privileged)</tspan></text>
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.47417995;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect31216"
-       width="302.2439"
-       height="3.4562778"
-       x="56.020889"
-       y="434.34576"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="315.44351"
-       y="414.93082"
-       id="text31218"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="315.44351"
-         y="414.93082"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31220">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="315.44351"
-         y="427.43082"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31222">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="314.2543"
-       y="448.93945"
-       id="text31224"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="314.2543"
-         y="448.93945"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31226">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="314.2543"
-         y="461.43945"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31228">(privileged)</tspan></text>
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.63319677;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect15862"
-       width="564.94202"
-       height="3.297261"
-       x="33.201633"
-       y="103.93921"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <rect
-       style="opacity:1;fill:url(#linearGradient7620);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect2160"
-       width="105.40086"
-       height="54.89323"
-       x="53.365585"
-       y="13.976227"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="107.07617"
-       y="38.39238"
-       id="text7646"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="107.07617"
-         y="38.39238"
-         id="tspan7650"
-         style="text-align:center;text-anchor:middle">Networking</tspan><tspan
-         sodipodi:role="line"
-         x="107.07617"
-         y="53.39238"
-         id="tspan7654"
-         style="text-align:center;text-anchor:middle">Applet</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient7664);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect7656"
-       width="105.40086"
-       height="54.89323"
-       x="174.58391"
-       y="13.976227"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="228.29448"
-       y="38.392403"
-       id="text7658"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="228.29448"
-         y="38.392403"
-         id="tspan7662"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="228.29448"
-         y="53.392403"
-         style="text-align:center;text-anchor:middle"
-         id="tspan7668">Manager</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient7684);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect7676"
-       width="105.40086"
-       height="54.89323"
-       x="298.83267"
-       y="13.976227"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="352.54324"
-       y="38.392403"
-       id="text7678"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="352.54324"
-         y="38.392403"
-         style="text-align:center;text-anchor:middle"
-         id="tspan7682">Power</tspan><tspan
-         sodipodi:role="line"
-         x="352.54324"
-         y="53.392403"
-         style="text-align:center;text-anchor:middle"
-         id="tspan7688">Manager</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient13600);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect13584"
-       width="105.40086"
-       height="54.89323"
-       x="112.4595"
-       y="226.10825"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="166.17007"
-       y="250.52441"
-       id="text13586"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="166.17007"
-         y="250.52441"
-         style="text-align:center;text-anchor:middle"
-         id="tspan13590">org.freedesktop.</tspan><tspan
-         sodipodi:role="line"
-         x="166.17007"
-         y="265.52441"
-         style="text-align:center;text-anchor:middle"
-         id="tspan13606">Hal</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient13602);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect13592"
-       width="105.40086"
-       height="54.89323"
-       x="236.70827"
-       y="226.10828"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="290.41885"
-       y="250.52444"
-       id="text13594"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="290.41885"
-         y="250.52444"
-         style="text-align:center;text-anchor:middle"
-         id="tspan13598">org.freedesktop.</tspan><tspan
-         sodipodi:role="line"
-         x="290.41885"
-         y="265.52444"
-         style="text-align:center;text-anchor:middle"
-         id="tspan13610">NetworkManager</tspan></text>
-    <path
-       sodipodi:type="arc"
-       style="opacity:1;fill:url(#radialGradient22907);fill-opacity:1;stroke:#000000;stroke-width:0.89999998;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="path13612"
-       sodipodi:cx="214.15234"
-       sodipodi:cy="161.40764"
-       sodipodi:rx="34.345188"
-       sodipodi:ry="34.345188"
-       d="M 248.49753 161.40764 A 34.345188 34.345188 0 1 1  179.80716,161.40764 A 34.345188 34.345188 0 1 1  248.49753 161.40764 z"
-       transform="translate(13.131983,6.28427)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="227.69116"
-       y="158.47198"
-       id="text16841"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="227.69116"
-         y="158.47198"
-         style="text-align:center;text-anchor:middle"
-         id="tspan16845">System</tspan><tspan
-         sodipodi:role="line"
-         x="227.69116"
-         y="173.47198"
-         style="text-align:center;text-anchor:middle"
-         id="tspan16849">Message</tspan><tspan
-         sodipodi:role="line"
-         x="227.69116"
-         y="188.47198"
-         style="text-align:center;text-anchor:middle"
-         id="tspan16851">Bus</tspan></text>
-    <path
-       style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-mid:none;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 122.22846,79.80864 L 186.87822,141.42794"
-       id="path18030"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <path
-       style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-mid:none;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 224.25387,76.73757 L 225.26402,128.25535"
-       id="path18032"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <path
-       style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-mid:none;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 259.6092,138.39749 C 336.3808,75.76803 336.3808,75.76803 336.3808,75.76803"
-       id="path18034"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <path
-       style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-mid:none;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 302.03561,217.18938 L 261.62951,184.8645"
-       id="path18036"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <path
-       style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-mid:none;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 148.49242,218.19954 L 189.90868,187.89496"
-       id="path18038"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="503.40186"
-       y="64.444763"
-       id="text22909"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text22919.png"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="503.40186"
-         y="64.444763"
-         style="font-size:18px;text-align:center;text-anchor:middle"
-         id="tspan22913">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="503.40186"
-         y="86.944763"
-         style="font-size:18px;text-align:center;text-anchor:middle"
-         id="tspan22917">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="506.21265"
-       y="128.4534"
-       id="text22919"
-       inkscape:export-xdpi="127.3"
-       inkscape:export-ydpi="127.3"><tspan
-         sodipodi:role="line"
-         x="506.21265"
-         y="128.4534"
-         style="font-size:18px;text-align:center;text-anchor:middle"
-         id="tspan22923">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="506.21265"
-         y="150.9534"
-         style="font-size:18px;text-align:center;text-anchor:middle"
-         id="tspan22927">(privileged)</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient23025);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect22959"
-       width="105.40086"
-       height="54.89323"
-       x="57.198269"
-       y="321.36322"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="109.3157"
-       y="345.77936"
-       id="text22961"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="109.3157"
-         y="345.77936"
-         id="tspan22963"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="109.3157"
-         y="360.77936"
-         style="text-align:center;text-anchor:middle"
-         id="tspan22965">Manager</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 74.682016,381.43904 L 104.24392,491.69186"
-       id="path25955"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="416.05093"
-       y="20.590385"
-       id="text25957"
-       transform="matrix(0.2589804,0.9658826,-0.9658826,0.2589804,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan25959"
-         x="416.05093"
-         y="20.590385">Mount()</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-end:none;stroke-opacity:1"
-       d="M 116.72967,713.71023 L 150.59062,822.71953"
-       id="path26968"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="734.48871"
-       y="94.180153"
-       id="text26970"
-       transform="matrix(0.2966428,0.9549885,-0.9549885,0.2966428,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan26972"
-         x="734.48871"
-         y="94.180153">Not Privileged</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.6543473px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 554.54111,568.48473 L 601.89116,568.48473"
-       id="path27000"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="580.93542"
-       y="562.5321"
-       id="text27971"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="580.93542"
-         y="562.5321"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan27975">Check</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30009);fill-opacity:1;stroke:#030000;stroke-width:0.42391345;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect27977"
-       width="89.103386"
-       height="37.881466"
-       x="606.02161"
-       y="549.54401"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="651.82117"
-       y="564.31549"
-       id="text27981"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="651.82117"
-         y="564.31549"
-         style="text-align:center;text-anchor:middle"
-         id="tspan27985">Authorization</tspan><tspan
-         sodipodi:role="line"
-         x="651.82117"
-         y="579.31549"
-         style="text-align:center;text-anchor:middle"
-         id="tspan27989">Database</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient28994);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect28980"
-       width="105.40086"
-       height="54.89323"
-       x="57.198269"
-       y="499.88608"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:url(#linearGradient28996);fill-opacity:1;stroke:#030000;stroke-width:0.35916778;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect28982"
-       width="105.5967"
-       height="22.946213"
-       x="57.100349"
-       y="553.98993"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="110.21804"
-       y="524.30225"
-       id="text28984"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="110.21804"
-         y="524.30225"
-         style="text-align:center;text-anchor:middle"
-         id="tspan28986">org.freedesktop.</tspan><tspan
-         sodipodi:role="line"
-         x="110.21804"
-         y="539.30225"
-         style="text-align:center;text-anchor:middle"
-         id="tspan28988">Hal</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="109.47976"
-       y="568.22235"
-       id="text28990"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="109.47976"
-         y="568.22235"
-         style="text-align:center;text-anchor:middle"
-         id="tspan28992">libpolkit</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient29026);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect28998"
-       width="105.40086"
-       height="54.89323"
-       x="446.37286"
-       y="321.89014"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="498.49026"
-       y="346.30627"
-       id="text29000"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="498.49026"
-         y="346.30627"
-         id="tspan29002"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="498.49026"
-         y="361.30627"
-         style="text-align:center;text-anchor:middle"
-         id="tspan29004">Manager</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 463.8566,381.96591 L 493.4185,492.21873"
-       id="path29006"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="517.3515"
-       y="-355.17126"
-       id="text29008"
-       transform="matrix(0.2589804,0.9658826,-0.9658826,0.2589804,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan29010"
-         x="517.3515"
-         y="-355.17126">Mount()</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient29028);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect29012"
-       width="105.40086"
-       height="54.89323"
-       x="446.37286"
-       y="500.41296"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:url(#linearGradient29030);fill-opacity:1;stroke:#030000;stroke-width:0.35916778;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect29014"
-       width="105.5967"
-       height="22.946213"
-       x="446.27493"
-       y="554.51678"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="499.39261"
-       y="524.8291"
-       id="text29016"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="499.39261"
-         y="524.8291"
-         style="text-align:center;text-anchor:middle"
-         id="tspan29018">org.freedesktop.</tspan><tspan
-         sodipodi:role="line"
-         x="499.39261"
-         y="539.8291"
-         style="text-align:center;text-anchor:middle"
-         id="tspan29020">Hal</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="498.65433"
-       y="568.74921"
-       id="text29022"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="498.65433"
-         y="568.74921"
-         style="text-align:center;text-anchor:middle"
-         id="tspan29024">libpolkit</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30045);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30017"
-       width="105.40086"
-       height="54.89323"
-       x="56.299564"
-       y="650.9104"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="108.417"
-       y="675.32654"
-       id="text30019"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="108.417"
-         y="675.32654"
-         id="tspan30021"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="108.417"
-         y="690.32654"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30023">Manager</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 73.783317,710.98622 L 103.34522,821.23903"
-       id="path30025"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="734.12262"
-       y="106.80471"
-       id="text30027"
-       transform="matrix(0.2589804,0.9658826,-0.9658826,0.2589804,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan30029"
-         x="734.12262"
-         y="106.80471">Mount()</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30047);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30031"
-       width="105.40086"
-       height="54.89323"
-       x="56.299564"
-       y="829.43323"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:url(#linearGradient30049);fill-opacity:1;stroke:#030000;stroke-width:0.35916778;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30033"
-       width="105.5967"
-       height="22.946213"
-       x="56.201649"
-       y="883.53711"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="109.31934"
-       y="853.84949"
-       id="text30035"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="109.31934"
-         y="853.84949"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30037">org.freedesktop.</tspan><tspan
-         sodipodi:role="line"
-         x="109.31934"
-         y="868.84949"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30039">Hal</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="108.58106"
-       y="897.76953"
-       id="text30041"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="108.58106"
-         y="897.76953"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30043">libpolkit</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30079);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30051"
-       width="105.40086"
-       height="54.89323"
-       x="445.29956"
-       y="650.48181"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="497.41699"
-       y="674.89795"
-       id="text30053"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="497.41699"
-         y="674.89795"
-         id="tspan30055"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="497.41699"
-         y="689.89795"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30057">Manager</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.6543473px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 557.32498,676.80788 L 604.67503,676.80788"
-       id="path30085"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="579.71936"
-       y="670.85529"
-       id="text30087"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="579.71936"
-         y="670.85529"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan30089">Use</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30099);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30091"
-       width="105.40086"
-       height="54.89323"
-       x="616.44238"
-       y="650.48694"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="668.55981"
-       y="674.90308"
-       id="text30093"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="668.55981"
-         y="674.90308"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30097">Authentication</tspan><tspan
-         sodipodi:role="line"
-         x="668.55981"
-         y="689.90308"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30103">Agent</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30111);fill-opacity:1;stroke:#030000;stroke-width:0.35916778;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30105"
-       width="105.5967"
-       height="22.946213"
-       x="616.05884"
-       y="704.88904"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="668.43817"
-       y="719.12146"
-       id="text30107"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="668.43817"
-         y="719.12146"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30109">libpolkit-grant</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30141);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30113"
-       width="105.40086"
-       height="54.89323"
-       x="52.585289"
-       y="969.30579"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="104.70271"
-       y="993.72192"
-       id="text30115"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="104.70271"
-         y="993.72192"
-         id="tspan30117"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="104.70271"
-         y="1008.7219"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30119">Manager</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.6543473px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 164.61071,995.63194 L 211.96076,995.63194"
-       id="path30121"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="187.00504"
-       y="989.6792"
-       id="text30123"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="187.00504"
-         y="989.6792"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan30125">Use</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30143);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30127"
-       width="105.40086"
-       height="54.89323"
-       x="223.72812"
-       y="969.31091"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="275.84558"
-       y="993.72699"
-       id="text30129"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="275.84558"
-         y="993.72699"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30131">Authentication</tspan><tspan
-         sodipodi:role="line"
-         x="275.84558"
-         y="1008.727"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30133">Agent</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30145);fill-opacity:1;stroke:#030000;stroke-width:0.35916778;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30135"
-       width="105.5967"
-       height="22.946213"
-       x="223.34451"
-       y="1023.7131"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="275.72391"
-       y="1037.9456"
-       id="text30137"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="275.72391"
-         y="1037.9456"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30139">libpolkit-grant</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30155);fill-opacity:1;stroke:#030000;stroke-width:0.42391345;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30147"
-       width="89.103386"
-       height="37.881466"
-       x="229.1626"
-       y="1171.7073"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="274.96222"
-       y="1186.4788"
-       id="text30149"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="274.96222"
-         y="1186.4788"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30151">Authorization</tspan><tspan
-         sodipodi:role="line"
-         x="274.96222"
-         y="1201.4788"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30153">Database</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 254.31223,1055.3785 L 283.87413,1165.6314"
-       id="path30157"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="1091.5134"
-       y="3.301826"
-       id="text30159"
-       transform="matrix(0.2589804,0.9658826,-0.9658826,0.2589804,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan30161"
-         x="1091.5134"
-         y="3.301826">On successful,</tspan><tspan
-         sodipodi:role="line"
-         x="1091.5134"
-         y="18.301826"
-         id="tspan30163">auth, write cookie</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.6543473px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 548.53925,1216.5075 L 595.8893,1216.5075"
-       id="path30165"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="574.93365"
-       y="1210.5551"
-       id="text30167"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="574.93365"
-         y="1210.5551"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan30169">Check</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30207);fill-opacity:1;stroke:#030000;stroke-width:0.42391345;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30171"
-       width="89.103386"
-       height="37.881466"
-       x="600.01978"
-       y="1197.567"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="645.81934"
-       y="1212.3383"
-       id="text30173"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="645.81934"
-         y="1212.3383"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30175">Authorization</tspan><tspan
-         sodipodi:role="line"
-         x="645.81934"
-         y="1227.3383"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30177">Database</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30209);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30179"
-       width="105.40086"
-       height="54.89323"
-       x="440.37097"
-       y="969.91284"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="492.48843"
-       y="994.32898"
-       id="text30181"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="492.48843"
-         y="994.32898"
-         id="tspan30183"
-         style="text-align:center;text-anchor:middle">File</tspan><tspan
-         sodipodi:role="line"
-         x="492.48843"
-         y="1009.329"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30185">Manager</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-end:url(#Arrow1Lend);stroke-opacity:1"
-       d="M 457.85474,1029.9888 L 487.41664,1140.2415"
-       id="path30187"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="1141.7095"
-       y="-181.54793"
-       id="text30189"
-       transform="matrix(0.2589804,0.9658826,-0.9658826,0.2589804,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan30191"
-         x="1141.7095"
-         y="-181.54793">Mount()</tspan></text>
-    <rect
-       style="opacity:1;fill:url(#linearGradient30211);fill-opacity:1;stroke:#030000;stroke-width:0.55500662;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30193"
-       width="105.40086"
-       height="54.89323"
-       x="440.37097"
-       y="1148.4359"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:url(#linearGradient30213);fill-opacity:1;stroke:#030000;stroke-width:0.35916778;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30195"
-       width="105.5967"
-       height="22.946213"
-       x="440.27307"
-       y="1202.5397"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="493.39078"
-       y="1172.8521"
-       id="text30197"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="493.39078"
-         y="1172.8521"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30199">org.freedesktop.</tspan><tspan
-         sodipodi:role="line"
-         x="493.39078"
-         y="1187.8521"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30201">Hal</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="492.6525"
-       y="1216.7721"
-       id="text30203"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="492.6525"
-         y="1216.7721"
-         style="text-align:center;text-anchor:middle"
-         id="tspan30205">libpolkit</tspan></text>
-    <path
-       style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow1Lstart);marker-end:none;stroke-opacity:1"
-       d="M 496.01522,1030.2861 L 529.87617,1139.2954"
-       id="path30221"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="1173.8359"
-       y="-173.60796"
-       id="text30223"
-       transform="matrix(0.2966428,0.9549885,-0.9549885,0.2966428,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan30225"
-         x="1173.8359"
-         y="-173.60796">OK</tspan></text>
-    <rect
-       style="opacity:1;fill:#4c4c4c;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.70579964;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30227"
-       width="717.72656"
-       height="3.224658"
-       x="16.136728"
-       y="610.74988"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:#4c4c4c;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.70579964;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30229"
-       width="717.72656"
-       height="3.224658"
-       x="9.7081537"
-       y="937.03558"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:#4c4c4c;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.8039602;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect30231"
-       width="960.48553"
-       height="3.1264975"
-       x="310.69086"
-       y="-371.56323"
-       transform="matrix(0,1,-1,0,0,0)"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <rect
-       style="opacity:1;fill:#aaaaaa;fill-opacity:1;stroke:#c9c9c9;stroke-width:0.47417995;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:19;stroke-opacity:1"
-       id="rect31276"
-       width="302.2439"
-       height="3.4562778"
-       x="417.58118"
-       y="765.91351"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997" />
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="677.00378"
-       y="746.49854"
-       id="text31278"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="677.00378"
-         y="746.49854"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31280">User Session</tspan><tspan
-         sodipodi:role="line"
-         x="677.00378"
-         y="758.99854"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31282">(unprivileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="675.81458"
-       y="780.5072"
-       id="text31284"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         x="675.81458"
-         y="780.5072"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31286">System Context</tspan><tspan
-         sodipodi:role="line"
-         x="675.81458"
-         y="793.0072"
-         style="font-size:10px;text-align:center;text-anchor:middle"
-         id="tspan31288">(privileged)</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="5.7142835"
-       y="343.79077"
-       id="text31318"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan31320"
-         x="5.7142835"
-         y="343.79077"
-         style="font-size:36px">1.</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="382.24597"
-       y="344.3414"
-       id="text31322"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan31324"
-         x="382.24597"
-         y="344.3414"
-         style="font-size:36px">2.</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="5.9801025"
-       y="650.06604"
-       id="text31326"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan31328"
-         x="5.9801025"
-         y="650.06604"
-         style="font-size:36px">3.</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="382.51178"
-       y="650.6167"
-       id="text31330"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan31332"
-         x="382.51178"
-         y="650.6167"
-         style="font-size:36px">4.</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="5.1229744"
-       y="979.06604"
-       id="text31334"
-       inkscape:export-filename="/home/davidz/Hacking/PolicyKit/doc/text31338.png"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan31336"
-         x="5.1229744"
-         y="979.06604"
-         style="font-size:36px">5.</tspan></text>
-    <text
-       xml:space="preserve"
-       style="font-size:12px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Bitstream Vera Sans"
-       x="381.65466"
-       y="979.6167"
-       id="text31338"
-       inkscape:export-xdpi="99.129997"
-       inkscape:export-ydpi="99.129997"><tspan
-         sodipodi:role="line"
-         id="tspan31340"
-         x="381.65466"
-         y="979.6167"
-         style="font-size:36px">6.</tspan></text>
-  </g>
-</svg>
diff --git a/doc/polkit-docs.xml b/doc/polkit-docs.xml
deleted file mode 100644
index 91e0bec..0000000
--- a/doc/polkit-docs.xml
+++ /dev/null
@@ -1,144 +0,0 @@
-<?xml version="1.0"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
-               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
-<!ENTITY version SYSTEM "version.xml">
-]>
-<book id="index" xmlns:xi="http://www.w3.org/2003/XInclude">
-  <bookinfo>
-    <title>PolicyKit Library Reference Manual</title>
-    <releaseinfo>Version &version;</releaseinfo>
-    <authorgroup>
-      <author>
-	<firstname>David</firstname>
-	<surname>Zeuthen</surname>
-	<affiliation>
-	  <address>
-	    <email>david at fubar.dk</email>
-	  </address>
-	</affiliation>
-      </author>
-    </authorgroup>
-
-    <copyright>
-      <year>2007</year>
-      <holder>The PolicyKit Authors</holder>
-    </copyright>
-
-    <legalnotice>
-      <para>
-	Permission is granted to copy, distribute and/or modify this
-	document under the terms of the <citetitle>GNU Free
-	Documentation License</citetitle>, Version 1.1 or any later
-	version published by the Free Software Foundation with no
-	Invariant Sections, no Front-Cover Texts, and no Back-Cover
-	Texts. You may obtain a copy of the <citetitle>GNU Free
-	Documentation License</citetitle> from the Free Software
-	Foundation by visiting <ulink type="http"
-	url="http://www.fsf.org">their Web site</ulink> or by writing
-	to:
-
-	<address>
-	  The Free Software Foundation, Inc.,
-	  <street>59 Temple Place</street> - Suite 330,
-	  <city>Boston</city>, <state>MA</state> <postcode>02111-1307</postcode>,
-	  <country>USA</country>
-	</address>
-      </para>
-
-      <para>
-	Many of the names used by companies to distinguish their
-	products and services are claimed as trademarks. Where those
-	names appear in any GNOME documentation, and those trademarks
-	are made aware to the members of the GNOME Documentation
-	Project, the names have been printed in caps or initial caps.
-      </para>
-    </legalnotice>
-  </bookinfo>
-
-  <reference id="ref-design">
-    <title>Design Overview</title>
-    <partintro>
-      <para>
-	This part presents the design documentation for PolicyKit.
-        <xi:include href="man/PolicyKit.xml"/>
-      </para>
-    </partintro>
-    <xi:include href="spec/polkit-spec-introduction.xml" />
-    <xi:include href="spec/polkit-spec-model.xml" />
-    <xi:include href="spec/polkit-spec-configuration.xml" />    
-  </reference>
-
-  <reference id="ref-core">
-    <title>Core API Reference</title>
-    <partintro>
-      <para>
-	This part presents the class and function reference for the
-	core PolicyKit
-	libraries, <literal>libpolkit</literal>, <literal>libpolkit-grant</literal>
-	and <literal>libpolkit-dbus</literal>. Note that unless
-	explictly stated, a function belongs
-	to <literal>libpolkit</literal>. The split is arranged such
-	that mechanisms checking for authorizations only need to link
-	with <literal>libpolkit</literal>.
-      </para>
-    </partintro>
-    <xi:include href="xml/polkit-types.xml"/>
-    <xi:include href="xml/polkit-sysdeps.xml"/>
-    <xi:include href="xml/polkit-simple.xml"/>
-    <xi:include href="xml/polkit-error.xml"/>
-    <xi:include href="xml/polkit-result.xml"/>
-    <xi:include href="xml/polkit-action.xml"/>
-    <xi:include href="xml/polkit-seat.xml"/>
-    <xi:include href="xml/polkit-session.xml"/>
-    <xi:include href="xml/polkit-caller.xml"/>
-    <xi:include href="xml/polkit-tracker.xml"/>
-    <xi:include href="xml/polkit-context.xml"/>
-    <xi:include href="xml/polkit-config.xml"/>
-    <xi:include href="xml/polkit-policy-file.xml"/>
-    <xi:include href="xml/polkit-policy-file-entry.xml"/>
-    <xi:include href="xml/polkit-policy-default.xml"/>
-    <xi:include href="xml/polkit-policy-cache.xml"/>
-    <xi:include href="xml/polkit-authorization.xml"/>
-    <xi:include href="xml/polkit-authorization-constraint.xml"/>
-    <xi:include href="xml/polkit-authorization-db.xml"/>
-    <xi:include href="xml/polkit-grant.xml"/>
-  </reference>
-
-  <reference id="tools-fileformats">
-    <title>Tools and file formats</title>
-    <partintro>
-      <para>
-	This part presents the tools, file formats used and assorted documentation distributed with PolicyKit.
-      </para>
-    </partintro>
-    <xi:include href="man/PolicyKit.xml"/>
-    <xi:include href="man/PolicyKit.conf.xml"/>
-    <xi:include href="man/polkit-auth.xml"/>
-    <xi:include href="man/polkit-action.xml"/>
-    <xi:include href="man/polkit-policy-file-validate.xml"/>
-    <xi:include href="man/polkit-config-file-validate.xml"/>
-  </reference>
-
-  <index role="deprecated">
-    <title>Index of deprecated symbols</title>
-  </index>
-  <index role="0.7">
-    <title>Index of new symbols in 0.7</title>
-  </index>
-  <index role="0.8">
-    <title>Index of new symbols in 0.8</title>
-  </index>
-
-  <index>
-    <title>Index</title>
-  </index>
-
-  <!-- License -->
-
-  <appendix id="license">
-    <title>License</title>
-    <para>
-<programlisting><xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="../COPYING" parse="text"><xi:fallback>FIXME: MISSING XINCLUDE CONTENT</xi:fallback></xi:include></programlisting>
-    </para>
-  </appendix>
-</book>
diff --git a/doc/spec/polkit-spec-configuration.xml b/doc/spec/polkit-spec-configuration.xml
deleted file mode 100644
index 63b432c..0000000
--- a/doc/spec/polkit-spec-configuration.xml
+++ /dev/null
@@ -1,295 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-
-<chapter id="polkit-conf">
-  <title>PolicyKit configuration</title>
-
-  <sect1 id="conf-declaring-actions">
-    <title>Declaring Actions</title>
-    
-    <para>
-      A Mechanism needs to declare what Actions it supports. This is
-      achieved by dropping one or more XML files with the suffix <literal>.policy</literal>
-      into the <literal>/usr/share/PolicyKit/policy</literal> directory.
-    </para>
-    <para>
-      The name of the XML file is significant. Each XML file can only
-      declare actions from the namespace of it's own name; for example
-      actions <literal>org.foobar.action-a</literal>, <literal>org.foobar.action-b</literal>
-      and <literal>org.foobar.action-c</literal> would all go into the
-      file <literal>org.foobar.policy</literal> while
-      actions <literal>com.my-company.product-awesome.action-a</literal>, <literal>com.mycompany.product-awesome.action-b</literal>
-      would go into the
-      file <literal>com.mycompany.product-awesome.policy</literal>.
-    </para>
-    <para>
-      An example of a <literal>.policy</literal> file would be the following:
-    </para>
-    <programlisting>
-      <![CDATA[
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE policyconfig PUBLIC
- "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
- "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
-<policyconfig>
-  <vendor>The PolicyKit Project</vendor>
-  <vendor_url>http://hal.freedesktop.org/docs/PolicyKit/</vendor_url>
-  <icon_name>polkit-icon</icon_name>
-
-  <action id="org.gnome.policykit.examples.frobnicate">
-    <description>Frobnicate</description>
-    <description xml:lang="da">Frobniker</description>
-    <description xml:lang="en_CA">Frobnicate, Aye!</description>
-    <message>System policy prevents the PolicyKit-gnome example helper from Frobnicating</message>
-    <message xml:lang="da">System indstillinger forhindrer PolicyKit-gnome eksempel hjælper i at Frobnikere!</message>
-    <message xml:lang="en_CA">System policy prevents the PolicyKit-gnome example helper from Frobnicating, Aye!</message>
-
-    <icon_name>polkit-icon-frobnicate</icon_name>
-    <vendor_url>http://hal.freedesktop.org/docs/PolicyKit/about-frobnicating</vendor_url>
-
-    <defaults>
-      <allow_any>no</allow_any>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_self</allow_active>
-    </defaults>
-  </action>
-  
-  <action id="org.gnome.policykit.examples.tweak">
-    <description>Tweak</description>
-    <description xml:lang="da">Tvæk</description>
-    <description xml:lang="en_CA">Tweak, Aye!</description>
-    <message>System policy prevents the PolicyKit-gnome example helper from Tweaking</message>
-    <message xml:lang="da">System indstillinger forhindrer PolicyKit-gnome eksempel hjælper i at Tvække!</message>
-    <message xml:lang="en_CA">System policy prevents the PolicyKit-gnome example helper from Tweaking, Aye!</message>
-
-    <!-- just inherit icon_name and vendor_url -->
-
-    <defaults>
-      <allow_any>no</allow_any>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_admin</allow_active>
-    </defaults>
-  </action>
-
-</policyconfig> 
-]]>
-    </programlisting>
-    <para>
-      The policy declaration includes:
-      <itemizedlist>
-        <listitem>
-          <para>
-            <emphasis>Action Identifier:</emphasis> This identifies
-            the action and can only contain the
-            characters <literal>[a-z][0-9].-</literal>,
-            e.g. lower-case ASCII, digits, period and hyphen. In
-            addition the identifier needs to start with a lower-case
-            ASCII character. The rationale for having everything is
-            lower case is to make it easy to make a distinction
-            between PolicyKit actions and D-Bus methods / interfaces
-            as the latter is normally using CamelCase.
-          </para><para> 
-            In order for the identifier to be unique, it is
-            recommended that a revser domain name is chosen, for
-            example if the company Acme Inc. has a product called
-            Frakker that exports two Actions Blit and Blop the action
-            names should be chosen
-            as <literal>com.acme.frakker.blit</literal>
-            and <literal>com.acme.frakker.blop</literal>.
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>Defaults:</emphasis>
-            The <literal>allow_any</literal>, <literal>allow_inactive</literal>
-            and <literal>allow_active</literal> tags specify the
-            default answer that <literal>libpolkit</literal> will
-            return for respectively any, inactive and active
-            sessions. See below for valid values and their
-            meaning. Any of these elements, including the
-            enclosing <literal>defaults</literal> elements may be
-            omitted.
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>Textual descriptions:</emphasis> Simply included
-            for convenience and organizational purposes. Useful for
-            graphical editors for
-            authorizations. Standard <literal>xml:lang</literal>
-            mechnanisms are used to convey localized strings (note
-            that intltool 0.36 or greater includes native support for
-            handling <literal>.policy</literal> files).
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>Vendor:</emphasis> The <literal>vendor</literal>
-            and <literal>vendor_url</literal> describes who is
-            supplying the action. Both can be set at the top-level of
-            the <literal>.policy</literal> file and each Action can
-            further override it. These tags are optional.
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>Icon:</emphasis>
-            The <literal>icon_name</literal> tag can be used to
-            specify an icon name for the action or group of
-            actions. The name must adhere to the freedesktop.org Icon
-            Naming spec (for theming purposes) and cannot include
-            directory separators and must not include filename
-            extensions like <literal>.png</literal>. Like with vendor
-            tags, this tag can be set at the top level and also be
-            specialized for each individual action. This tag is
-            optional.
-          </para>
-        </listitem>
-      </itemizedlist>
-      The following values for the defaults are
-      <itemizedlist>
-        <listitem>
-          <para>
-            <emphasis>no</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_self_one_shot</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_self</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_self_keep_session</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_self_keep_always</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_admin_one_shot</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_admin</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_admin_keep_session</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>auth_admin_keep_always</emphasis>
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>yes</emphasis>
-          </para>
-        </listitem>
-      </itemizedlist>
-      The main point here is that individual upstream software
-      projects can provide sensible defaults, e.g. it's sensible for
-      the example with a dial-up mechanism to configure
-      the <literal>org.freedesktop.networkmanager.dialup-trusted</literal> Action to
-      return <emphasis>yes</emphasis> for local active sessions and
-      the Action
-      <literal>org.freedesktop.networkmanager.dialup-untrusted</literal> to perhaps
-      return <emphasis>auth_admin_keep_session</emphasis>. See
-      <xref linkend="beyond-defaults"/> for how individual machines
-      and sites can customize this.
-    </para>
-
-    <para>
-      The <literal>polkit-list-actions</literal>(1) tool will list all
-      the Actions known to <literal>libpolkit</literal> in a
-      convenient
-      format. The <literal>polkit-policy-file-validate</literal>(1)
-      tool can be used to check policy files as part of the software
-      release and installation process.
-    </para>
-
-    <sect2 id="conf-declaring-actions-annotations">
-      <title>Annotations</title>
-      <para>
-        When declaring an Action, one can also annotate it with one or
-        more key/value pairs: 
-      </para>
-    <programlisting>
-      <![CDATA[
-  <action id="com.example.blahblaster.run-as-root">
-    <description>Run the graphical BlahBlaster application as the super user</description>
-    <message>System policy prevents the BlahBlaster application</message>
-    <defaults>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_admin</allow_active>
-    </defaults>
-    <annotate key="org.freedesktop.PolicyKit.run-as-superuser.path">/usr/bin/BlahBlaster</annotate>
-  </action>
-]]>
-    </programlisting>
-      <para>
-        This is useful when writing an extensible Mechanism that other
-        applications wants to use. The example declaration above is
-        dealing with an (hypothetical and setuid root) mechanism,
-        let's call it
-        <literal>run-as-superuser</literal>, that can start graphical
-        applications as uid 0. Suppose the user invokes it like this
-      </para>
-      <programlisting>
-        run-as-superuser /usr/bin/BlahBlaster
-      </programlisting>
-      <para>
-        Now, the <literal>run-as-superuser</literal> mechanism is only
-        passed a path to the application to start. In order to
-        determine if the calling user is allowed to run the given
-        application as root, we need to determine the PolicyKit Action
-        and then use libpolkit as usual to get an answer (and possibly
-        make the user authenticate to gain the privilege to run the
-        application). By using annotations,
-        the <literal>run-as-superuser</literal> mechanism can query
-        what the action is simply by searching for the Action that has
-        an annotation
-        where <literal>org.freedesktop.PolicyKit.run-as-superuser.path</literal>
-        equals the given path,
-        e.g. <literal>/usr/bin/BlahBlaster</literal>. It then becomes
-        part of the documentation for
-        the <literal>run-as-superuser</literal> program to specify
-        that applications wanting to use it, simply just needs to
-        provide a PolicyKit <literal>.policy</literal> file that
-        declares an Action with an
-        annotation <literal>org.freedesktop.PolicyKit.run-as-superuser.path</literal>
-        whose value is the path to the binary.
-      </para>
-
-    </sect2>
-  </sect1>
-
-  <sect1 id="beyond-defaults">
-    <title>Beyond the Defaults</title>
-
-    <para>
-      System administrators and sites can tweak what
-      answer <literal>libpolkit</literal> returns depending on the
-      Action and Subject and other factors through the configuration
-      file <literal>/etc/PolicyKit/PolicyKit.conf</literal>. The
-      configuration file format, along with examples, is described in
-      the associated manual page of the same name. Note that this file
-      is not supposed to be modified by individual packages, it is
-      solely the responsibility of the system administrator to make
-      changes to this file.
-    </para>
-  </sect1>
-
-</chapter>
diff --git a/doc/spec/polkit-spec-introduction.xml b/doc/spec/polkit-spec-introduction.xml
deleted file mode 100644
index e156773..0000000
--- a/doc/spec/polkit-spec-introduction.xml
+++ /dev/null
@@ -1,136 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-
-<chapter id="introduction">
-  <title>Introduction</title>
-  
-  <sect1 id="intro-about">
-    <title>About</title>
-    
-    <para>
-      PolicyKit is an application-level toolkit for defining and
-      handling the policy that allows unprivileged processes to speak
-      to privileged processes: It is a framework for centralizing the
-      decision making process with respect to granting access to
-      privileged operations for unprivileged applications. PolicyKit
-      is specifically targeting applications in rich desktop
-      environments on multi-user UNIX-like operating systems. It does
-      not imply or rely on any exotic kernel features.
-    </para>
-  </sect1>
-
-  <sect1 id="polkit-spec-history">
-    <title>History and Prior Art</title>
-    
-    <para>
-      Traditionally UNIX-like operating systems have a clear
-      distinction between ordinary unprivileged users and the almight
-      and powerful super user 'root'.  However, in order for a user to
-      access and configure hardware additional privileges and rights
-      are needed. Hitherto, this have been done in a number of often
-      OS-specific ways. For example, Red Hat based systems usually
-      grant access to devices to a user if, and only if, the user is
-      logged in at a local console. In contrast, Debian-based systems
-      often relies on group membership, e.g. users in the 'cdrom'
-      group can access optical drives, users in the 'plugdev' group
-      can mount removable media and so on.
-    </para>
-
-    <para>
-      In addition, access was not only granted to devices; Red
-      Hat-based systems, for example, provides a mechanism to allow a
-      user at a local system to run certain applications (such as the
-      system-config-* family) as the super user provided they could
-      authenticate as the super user (typically by entering the root
-      password using a graphical utility). Other distributions rely on
-      sudo (with various graphical frontends) to provide similar
-      functionality. Both the pam-console and sudo approaches doesn't
-      require applications to be modified.
-    </para>
-
-    <para>
-      Finally, some classes of software (such as HAL, NetworkManager
-      and gnome-system-tools) utilizes IPC mechanism (typically D-Bus)
-      to provide a very narrow and well-defined subset of privileged
-      operations to unprivileged desktop applications. It varies what
-      mechanism is used to deny users.
-    </para>
-  </sect1>
-
-  <sect1 id="intro-define-problem">
-    <title>Defining the Problem</title>
-
-    <para>
-      There's a couple of problems with the mechanisms described in
-      <xref linkend="polkit-spec-history"/>.
-
-      <itemizedlist>
-        <listitem>
-          <para>
-            Mechanisms are coarsely grained: either you're at the
-            console or you're not (pam_console). Either you're a
-            member of a group or you're not (Debian). There is no easy
-            way to specify that only a subset of privileged operations
-            should be available for a given user (e.g. it's hard to
-            express "it's fine to mount removable media; it's not fine
-            to mount fixed media; it's not fine to change the
-            timezone" in a coherent way).
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            The way most people use pam-console and sudo is
-            fundamentally broken. Full-fledged GTK+ or Qt applications
-            run as the super user which means that millions of line of
-            code (including code such as image loaders that
-            historically have lots of security problems) runs
-            privileged. This is in direct violation of the well-known
-            "least privilege" principle. In addition, often
-            applications look out of place because settings in such
-            programs now read per-user settings from root's home
-            directory.
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            UNIX group membership have always been problematic; if a
-            user is a member of a group once, he can always become
-            member of the group again
-            (copy <literal>/bin/bash</literal> to $HOME; chown to
-            group, set the setgid bit, done).
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            It is difficult for upstream projects (such as GNOME or
-            KDE) to implement features that requires administrative
-            privileges because most downstream consumers
-            (e.g. operating systems) have different ways of
-            implementing access control. As a result most of these
-            features are punted to OS distributors who have their own
-            code for doing the same thing e.g. setting the
-            date/timezone etc.; there is no way for file sharing
-            applications (such as gnome-user-share, Banshee,
-            Rhythmbox) to punch a hole in the firewall.
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            Without a centralized framework, access control
-            configuration is often scattered throughout the system
-            which makes it hard for system administrators to grasp how
-            to configure the system. There's literally a bunch of
-            different configuration files all with different formats
-            and semantics.
-          </para>
-        </listitem>
-
-      </itemizedlist>
-    </para>
-  </sect1>
-
-</chapter>
diff --git a/doc/spec/polkit-spec-model.xml b/doc/spec/polkit-spec-model.xml
deleted file mode 100644
index 4d3b885..0000000
--- a/doc/spec/polkit-spec-model.xml
+++ /dev/null
@@ -1,569 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-
-<chapter id="model">
-  <title>PolicyKit Model</title>
-
-  <sect1 id="model-mechanism-vs-policy">
-    <title>Mechanims vs. Policy</title>
-    
-    <para>
-      PolicyKit assumes a model where a program is split into two
-      parts.  One part, the Mechanism, runs privileged (with no user
-      interface elements) and the other part, the policy agent, runs
-      unprivileged. The two parts of the program are in different
-      processes and communicate through some IPC mechanism such as
-      pipes or the system message bus (D-Bus). In some instances the
-      Mechanism can be considered part of the core OS and the policy
-      agent part of the desktop stack.
-    </para>
-
-    <para>
-    </para>
-
-    <para>
-      A Mechanism should never trust any application that tries to
-      use; it needs to carefully verify all data and requests passed
-      to it from the application. This is the model employed by HAL
-      and NetworkManager:
-    </para>
-    <para>
-      <inlinegraphic fileref="diagram-bus-model.png" format="PNG"/>
-    </para>
-    <para>
-      This model is not by any means restricted to applications using
-      D-Bus; it applies to most other security sensitive
-      applications. For example, the PAM module for checking your
-      password can run unprivileged and uses a simple and easy to
-      audit privileged helper
-      application, <literal>/sbin/unix_chkpwd</literal> on Red Hat
-      systems, to actually check the password
-      against <literal>/etc/shadow</literal>. In a similar fashion,
-      all
-      <ulink type="http"
-             url="http://en.wikipedia.org/wiki/Setuid">setuid
-             root</ulink> applications carefully check (or at least
-             should) incoming parameters and the environment in which
-             they are launched.
-    </para>
-    
-    <para>
-      In general, such an architecture is thought of as secure as long
-      as the Mechanism (and it's dependent libraries) have been
-      verified to be secure.
-    </para>
-
-  </sect1>
-
-  <sect1 id="model-concepts">
-    <title>Concepts</title>
-    
-    <para>
-      Typically the entities that a Mechanism cares about can be split
-      into three groups:
-      <itemizedlist>
-        <listitem>
-          <para>
-            <emphasis>Subject</emphasis>: the entity requesting the
-            Action; ie. an unprivileged application. To make a
-            decision about whether to carry out the Action, the
-            Mechanism needs to know as much about the Subject as
-            possible, e.g. UNIX user id, UNIX process id, possible
-            security attributes (such as SELinux security context) and
-            other data such as if the Subject is a participant in a
-            local or remote desktop session, whether said desktop
-            session is currently active and so forth.
-          </para>
-        </listitem>
-        
-        <listitem>
-          <para>
-            <emphasis>Object</emphasis>: some canonical representation
-            of the Object; some Objects represent tangible things such
-            as a UNIX device file, other Objects can be more abstract
-            and represent e.g. a network connection to a specific
-            destination, a reference to the power management
-            subsystem, a reference to a piece of software tracked by
-            the native package manager.
-          </para>
-        </listitem>
-        
-        <listitem>
-          <para>
-            <emphasis>Action:</emphasis> what the Subject is
-            attempting to do to the Object; this depends of the nature
-            of the Object and examples include mounting a block
-            device, formatting a block device with a file system,
-            establishing a dial-up connection to connect to private or
-            public networks, putting the system into a suspended
-            state, installing an unsigned piece of software, updating
-            the system with signed software, changing the timezone,
-            gaining access to a webcam and so forth.
-          </para>
-        </listitem>
-      </itemizedlist>
-    </para>
-
-    <para>
-      One way to think about a Mechanism is that the Mechanism is
-      split into an enforcer and a decider component. When an
-      application attempts to access the Mechanism, the enforcer
-      component will only carry out the Action if the decider
-      component (supplied with the appropriate input parameters about
-      the Subject, Object and Action) says it's OK.
-    </para>
-  </sect1>
-  
-  <sect1 id="model-theory-of-operation">
-    <title>Theory of Operation</title>
-    
-    <para>
-      The core of PolicyKit is implemented as a shared library that
-      Mechanisms can link to and use as the decider component. There's
-      a small set of (extensible) data structures that establish a
-      vocabulary for <literal>libpolkit</literal> and the Mechanism to
-      describe the Subject and Action in question. The Mechanism
-      should think about <literal>libpolkit</literal> as a black box;
-      it's sole purpose is to answer whether a given Subject is
-      permitted to do a specific Action. The answer, obviously, comes
-      from a configuration source read by the library and maintained
-      by the system administrator; see <xref linkend="polkit-conf"/>
-      for details on PolicyKit configuration.
-    </para>
-    
-    <para>
-      The answer from <literal>libpolkit</literal> is not limited to a
-      boolean value; essentially the following values can be returned
-      <itemizedlist>
-        <listitem>
-          <para>
-            <emphasis>Yes:</emphasis> It is ok for the Mechanism to
-            carry out the Action requsted by the given Subject.
-          </para>
-        </listitem>
-        <listitem>
-          <para>
-            <emphasis>No:</emphasis> The Mechanism should not carry
-            out the Action requested by the given Subject.
-          </para>
-        </listitem>
-        <listitem>          
-          <para>
-            <emphasis>Require authentication:</emphasis> The Subject
-            (e.g. the UI application) needs to ask the user to
-            authenticate in order for the Mechanism to carry out this
-            Action.
-          </para>
-        </listitem>
-      </itemizedlist>
-      In addition,
-      <itemizedlist>
-        <listitem>
-          <para>
-            Authentication can be specified (in the return value
-            from <literal>libpolkit</literal>) as either user
-            authentication (user puts in his own password) or super
-            user authentication (user puts in the root password or a
-            user in an administrator group authenticates).
-          </para>
-        </listitem>
-        <listitem>          
-          <para>
-            The authorization can be kept (this is also specified in
-            the return value from <literal>libpolkit</literal>) either
-            1) indefinitely (e.g. it persists across reboots and
-            different desktop sessions); 2) for the remainder of the
-            desktop session the Subject is part of; or 3) confined to
-            the process life-time of the Subject.
-          </para>
-        </listitem>
-      </itemizedlist>
-    </para>
-    
-    <para>
-      To facilitate the authentication step, there's a shared library
-      called <literal>libpolkit-grant</literal>. Given an Action, this
-      library uses a privileged helper (as in it's a <literal>setgid
-      polkit</literal> application) to authenticate the user (using
-      PAM) and upon successful authentication leave a cookie
-      specifying that the given Action can be carried out. It is the
-      presence and contents of this cookie that will
-      allow <literal>libpolkit</literal> to
-      return <emphasis>Yes</emphasis> when the Subject asks the
-      Mechanism to carry out the Action again. This whole process is
-      best explained by a diagram:
-    </para>
-    
-    <para>
-      <inlinegraphic fileref="diagram-interaction.png" format="PNG"/>
-    </para>
-
-    <para>
-      Detail on the diagram:
-      <orderedlist>
-        <listitem>
-          <para>
-            The user double clicks an icon on the desktop that
-            resembles a hard drive. As mounting file systems is a
-            privileged operation, the File Manager calls, via the
-            system message bus, into the Mechanism (HAL).
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            The Mechanism identifies the caller, using ConsoleKit, all
-            the relevant information about the caller and stores this
-            information in
-            a <link linkend="polkit-polkit-caller">PolKitCaller</link>
-            object. This information includes
-            <itemizedlist>
-              <listitem>
-                <para>
-                  UNIX user id (uid)
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  UNIX process id (pid)
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  An identifier for the desktop session and whether
-                  the session is active (e.g. currently showing on a
-                  display), whether it's local and if it's remote, the
-                  address of the remote display
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  Optional OS specific attributes such as the SELinux security context.
-                </para>
-              </listitem>
-            </itemizedlist>
-          </para>
-          <para>
-            Second, the Mechanism creates
-            a <link linkend="polkit-polkit-action">PolKitAction</link>
-            object that represents the action that the caller wants
-            the Mechanism to perform on it's behalf. Specifically, for
-            HAL, the D-Bus method call <literal>Mount()</literal> maps
-            into two
-            actions: <literal>org.freedesktop.hal.storage.mount-fixed</literal>
-            and <literal>org.freedesktop.hal.storage.mount-removable</literal>. As
-            the device the user wants to mount is an internal hard
-            disk, HAL
-            picks <literal>org.freedesktop.hal.storage.mount-fixed</literal>
-            and constructs
-            the <link linkend="polkit-polkit-action">PolKitAction</link>
-            object.
-          </para>
-          <para>
-            Third, HAL now calls
-            the <link linkend="polkit-context-can-caller-do-action">polkit_context_can_caller_do_action()</link>
-            function in <literal>libpolkit</literal> and passes
-            the <link linkend="polkit-polkit-action">PolKitAction</link>
-            and <link linkend="polkit-polkit-caller">PolKitCaller</link>
-            objects as parameters. Armed with all this
-            information, <literal>libpolkit</literal> is now in a
-            position to make a decision; see
-            <xref linkend="polkit-conf"/> for how exactly this is
-            done.
-          </para>
-          <para>
-            The result
-            from <literal>libpolkit</literal> is of the
-            type <link linkend="polkit-polkit-result">PolKitResult</link>
-            and tells whether the given caller is allowed to do the
-            given action. If the result is yes
-            (e.g. POLKIT_RESULT_YES), the Mechanism carries out the
-            action on behalf of the caller.
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            If the result from <literal>libpolkit</literal> is not
-            yes, the Mechanism sends a reply back to the caller with
-            two pieces of information: 
-            <itemizedlist>
-              <listitem>
-                <para>
-                  The result from <literal>libpolkit</literal> itself.
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  The action that the caller needs to be authorized to
-                  do.
-                </para>
-              </listitem>
-            </itemizedlist>
-            For this example, HAL returns an exception via D-Bus with
-            the
-            name <literal>org.freedesktop.Hal.Device.PermissionDeniedByPolicy</literal>
-            and the detail text
-            string <literal>"org.freedesktop.hal.storage.mount-fixed
-            auth_admin_keep_always"</literal> (assuming the return code
-            was POLKIT_RESULT_AUTH_ADMIN_KEEP_ALWAYS). This enables
-            the caller to take action and acquire authorization to do
-            this action.
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            The File Manager receives the exception from the Mechanism
-            and since the exception
-            name <literal>org.freedesktop.Hal.Device.PermissionDeniedByPolicy</literal>
-            is well-defined it decodes the exception detail string to
-            learn that in order to do what the user asked it (by
-            double clicking an icon resembling a hard drive), it needs
-            to make the user authenticate as an administrator in order
-            to be authorized for the
-            action <literal>org.freedesktop.hal.storage.mount-fixed</literal>.
-          </para>
-          <para>
-            The File Manager now proceeds to call into
-            an <emphasis>Authentication Agent</emphasis> and passes
-            two items of information
-            <itemizedlist>
-              <listitem>
-                <para>
-                  The <link linkend="polkit-polkit-result">PolKitResult</link>
-                  that <literal>libpolkit</literal> returned to the
-                  Mechanism and passed on to the File Manager.
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  The <link linkend="polkit-polkit-action">PolKitAction</link>
-                  that <literal>libpolkit</literal> returned to the
-                  Mechanism and passed on to the File Manager.
-                </para>
-              </listitem>
-            </itemizedlist>
-            In fact, the File Manager could implement an
-            Authentication Agent by itself but for both practical
-            reasons (implementing an Authentication Agent is not
-            trivial) and security reasons (it is typically a good idea
-            to have password handling in as few processes as possible)
-            it is preferable to have this done in a separate
-            process. PolicyKit defines an abstract interface to
-            interact with the an Authentication Agent, see the
-            <link linkend="model-authentication-agent">Authentication
-            Agent section</link> for details. For details on the
-            Authentication Agent for the GNOME desktop, please see
-            the <ulink type="http"
-            url="http://hal.freedesktop.org/docs/PolicyKit-gnome/ref-auth-daemon.html">PolicyKit-gnome</ulink>
-            documentation.
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            The first thing that the Authentication Agent does when it
-            receives a request from an application is to validate the
-            incoming parameters to see if they are correct;
-            essentially it's doing exactly the same check as the
-            Mechanism was doing in step 2;
-            e.g. constructing <link linkend="polkit-polkit-caller">PolKitCaller</link>
-            and <link linkend="polkit-polkit-caller">PolKitAction</link>
-            objects, calling
-            into <link linkend="polkit-context-can-caller-do-action">polkit_context_can_caller_do_action()</link>
-            and examining the
-            returned <link linkend="polkit-polkit-result">PolKitResult</link>.
-          </para>
-          <para>
-            If the parameters check out, the Authentication Agent now
-            pops up a window to explain the user than authentication
-            is required to perform the desired action. Note that the
-            text to put in the dialog stems from files that are not
-            under the users control (see
-            <xref linkend="conf-declaring-actions"/> for details) so
-            there is no chance for any application to spoof the dialog
-            to trick the user into agreeing to authenticate for
-            something while in fact the authentication is about
-            something else.
-          </para>
-          <para>
-            Internally the Authentication Agent uses services provided
-            by the
-            <link linkend="polkit-polkit-grant">PolKitGrant</link>
-            class and is little more than a thin layer above the PAM
-            user API. The authentication itself is performed in a
-            privileged helper program (e.g. running
-            with <ulink type="http"
-            url="http://en.wikipedia.org/wiki/Setgid">setgid</ulink>
-            privileges) that communicates with the (graphical)
-            Authentication Agent through pipes. As such, if the user
-            successfully authenticates, the privileged helper program
-            writes an entry into the Authorization Database (it can do
-            so only because it is privileged). When the user is done
-            with the dialog (either through successful authentication
-            or by cancelling) a reply including whether the
-            authorization was gained is sent back to the File Manager
-          </para>
-          <para>
-            As mentioned, an authorization has a notion of scope which
-            is indicated in
-            the <link linkend="polkit-polkit-result">PolKitResult</link>
-            value from <literal>libpolkit</literal>. The user, when
-            authenticating, can also opt to lessen the scope
-            (e.g. keep the authorization only for the remainder of his
-            desktop session instead of forever)
-            (see <link linkend="PolKitGrantOverrideGrantType">this
-            section</link> for details) but he can never widen it -
-            this is checked and enforced by the privileged helper
-            program. The way the authorization is stored is as
-            follows:
-            <itemizedlist>
-              <listitem>
-                <para>
-                  For POLKIT_RESULT_AUTH_[SELF|ADMIN] the
-                  authorization is limited to the requesting process;
-                  in this example it would be the File Manager. Thus,
-                  the UNIX process id (and start time of the process
-                  to avoid clashes caused by pid recycling) is used as
-                  the primary key in the Authorization
-                  Database. Entries like these are flushed when the
-                  system is restarted.
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  For POLKIT_RESULT_AUTH_[SELF|ADMIN]_KEEP_SESSION the
-                  authorization is limited to processes in the same
-                  desktop session as the calling process (e.g. the
-                  File Manager). The ConsoleKit session identifier is
-                  used as the the primary key in the Authorization
-                  Database. Entries like these are also flushed when
-                  the system is restarted.
-                </para>
-              </listitem>
-              <listitem>
-                <para>
-                  For POLKIT_RESULT_AUTH_[SELF|ADMIN]_KEEP_ALWAYS the
-                  authorization is limited to processes owned by the
-                  same user as the calling process (e.g. the File
-                  Manager). The UNIX uid of the user is used as the
-                  the primary key in the Authorization Database. These
-                  entries are not flushed when the system is
-                  restarted.
-                </para>
-              </listitem>
-            </itemizedlist>
-          </para>
-        </listitem>
-
-        <listitem>
-          <para>
-            If the File Manager is told by the Authentication Agent
-            that the authorization for it to do the
-            action <literal>org.freedesktop.hal.storage.mount-fixed</literal>
-            was obtained (because the user successfully
-            authenticated), it asks the Mechanism (HAL to perform the
-            action again. This time, because an entry now exists in
-            the Authorization Database, the Mechanism (HAL) will
-            receive the answer POLKIT_RESULT_YES
-            from <literal>libpolkit</literal> and carry out the action
-            on behalf of the File Manager.
-          </para>
-        </listitem>
-
-      </orderedlist>
-    </para>
-    
-    <para>
-      Furthermore, as hinted above, any program can check,
-      using <literal>libpolkit</literal>, whether a given caller is
-      authorized to do a specific Action (though users may be limited
-      to asking questions only about themselves; not about other
-      users). This is a feature, not a bug, as it allows to build user
-      interfaces where it's possible to use this information to aid
-      the user in carrying out work.
-    </para>
-    <para>
-      For example, the UI configuration dialog for the desktop clock
-      may provide a button for reconfiguring the system time (which is
-      a privileged operation). Using <literal>libpolkit</literal>, the
-      desktop code can determine, in advance, if the user is
-      authorized to do the
-      Action <literal>org.gnome.clockapplet.mechanism.settime</literal>. If
-      the user is authorized, the desktop will paint an ordinary
-      button <literal>"Set System Time"</literal>, if authentication
-      is required, it can paint another button <literal>"[L] Set
-      System Time..."</literal> where the L is an icon depicting a
-      closed padlock and if the answer is POLKIT_RESULT_NO it can make
-      the button insensitive so it can't be clicked. In fact, the
-      aforementioned PolicyKit-gnome library, provides
-      exactly <ulink type="http"
-      url="http://hal.freedesktop.org/docs/PolicyKit-gnome/PolKitGnomeAction.html">such
-      services</ulink> for GTK+ applications.
-    </para>
-
-    <para>
-      In order to keep the PolicyKit model reasonably simple, there is
-      no representation of the Object. Instead, a Mechanism that cares
-      about Objects (and many don't; for example, Mechanisms to change
-      the timezone, punch a hole in the firewall or add a user all
-      operate on a singleton Object: the system as a whole) must
-      instead divide a given Action into multiple sub-Actions
-      depending on the nature of the Object.
-    </para>
-
-    <para>
-      For example, consider a Mechanism for dial-up networking. Here,
-      the Subject is a UI applet running in a desktop session, the
-      Object is the phone number to dial and the Action is to
-      establish the connection (another Action could be to hang-up an
-      existing connection). Suppose that the Mechanism has a
-      white-list of phone numbers that are trusted; this could simply
-      be a
-      directory <literal>/var/lib/dialup-helper/trusted-dialup.d</literal>
-      where the system administrator can drop simple text or XML files
-      with phone numbers that are considered safe to dial. If the
-      phone number given by the client matches this white-list, the
-      Mechanism chooses the Action to
-      be <literal>dialup-connect-trusted</literal>. If it's not in the
-      white-list, the Action will be
-      <literal>dialup-connect-untrusted</literal>.  Hence, depending
-      on how PolicyKit is configured it may return different answers
-      since these are different Actions; one sensible thing in a
-      default desktop rollout would be to always allow the
-      Action <literal>dialup-connect-trusted</literal> for local
-      active sessions and always require authentication for the Action
-      <literal>dialup-connect-untrusted</literal>.
-    </para>
-  </sect1>
-
-  <sect1 id="model-authentication-agent">
-    <title>Authentication Agent</title>
-    <para>
-      To gain authorizations through authentication, an Authentication
-      Agent is used. The section defines an abstract interface that
-      applications can use to interact with such an agent. This allows
-      different desktop environments to implement different agents
-      with native look and feel.
-    </para>
-    <para>
-      The interface is quite simple. Basically, a PolicyKit
-      Authentication Agent must provide the D-Bus session service with
-      the unique
-      name <literal>org.freedesktop.PolicyKit.AuthenticationAgent</literal>
-      that exposes a single object with the path <literal>/</literal> that exports the 
-      <literal>org.freedesktop.PolicyKit.AuthenticationAgent</literal>
-      D-Bus interface. The interface is defined by the following D-Bus
-      introspection data:
-
-<programlisting><xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="../../data/org.freedesktop.PolicyKit.AuthenticationAgent.xml" parse="text"><xi:fallback>FIXME: MISSING XINCLUDE CONTENT</xi:fallback></xi:include></programlisting>
-
-      This file is available
-      as <literal>/usr/share/dbus-1/interfaces/org.freedesktop.PolicyKit.AuthenticationAgent.xml</literal>
-      on a system with PolicyKit development packages installed. It
-      can be used to generating client glue code.
-    </para>
-  </sect1>
-  
-</chapter>
diff --git a/doc/version.xml.in b/doc/version.xml.in
deleted file mode 100644
index d78bda9..0000000
--- a/doc/version.xml.in
+++ /dev/null
@@ -1 +0,0 @@
- at VERSION@
diff --git a/examples/tracker-example/README b/examples/tracker-example/README
deleted file mode 100644
index b2d0e3b..0000000
--- a/examples/tracker-example/README
+++ /dev/null
@@ -1,4 +0,0 @@
-
-This is a simple example to show how the PolKitTracker class is
-used. For a detailed explanation, refer to the API docs for
-PolKitTracker.
diff --git a/examples/tracker-example/dk.fubar.PolKitTestService.conf b/examples/tracker-example/dk.fubar.PolKitTestService.conf
deleted file mode 100644
index 84650e3..0000000
--- a/examples/tracker-example/dk.fubar.PolKitTestService.conf
+++ /dev/null
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?> <!-- -*- XML -*- -->
-<!DOCTYPE busconfig PUBLIC
- "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
- "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
-<busconfig>
-  <policy context="default">
-    <allow own="dk.fubar.PolKitTestService"/>
-  </policy>
-</busconfig>
-
diff --git a/examples/tracker-example/tracker-example-client.py b/examples/tracker-example/tracker-example-client.py
deleted file mode 100755
index 2b658c2..0000000
--- a/examples/tracker-example/tracker-example-client.py
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/usr/bin/python
-
-import dbus
-import time
-
-bus = dbus.Bus(dbus.Bus.TYPE_SYSTEM)
-obj = dbus.Interface(bus.get_object("dk.fubar.PolKitTestService", "/"), "dk.fubar.PolKitTestService")
-
-while True:
-    print obj.Test()
-    time.sleep(1)
diff --git a/examples/tracker-example/tracker-example.c b/examples/tracker-example/tracker-example.c
deleted file mode 100644
index 406f3fc..0000000
--- a/examples/tracker-example/tracker-example.c
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Small example of how to use the PolKitTracker class.
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- * 
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use,
- * copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following
- * conditions:
- * 
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- * 
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
- * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- */
-
-#include <stdio.h>
-#include <glib.h>
-#include <dbus/dbus.h>
-#include <polkit-dbus/polkit-dbus.h>
-
-/* Note, on purpose, there is little or no error checking done
- * anywhere in this program. Use at your own risk.
- */
-
-static void
-print_caller (PolKitTracker *pk_tracker, const char *dbus_name)
-{
-        DBusError error;
-        PolKitCaller *caller;
-
-        dbus_error_init (&error);
-
-        caller = polkit_tracker_get_caller_from_dbus_name (pk_tracker, 
-                                                           dbus_name,
-                                                           &error);
-        if (caller == NULL) {
-                g_warning ("Error getting PolKitCaller for '%s': %s: %s",
-                           dbus_name, error.name, error.message);
-                dbus_error_free (&error);
-        } else {
-                /* got it; print it to stdout */
-                printf ("\n");
-                polkit_caller_debug (caller);
-                polkit_caller_unref (caller);
-        }
-}
-
-static DBusHandlerResult
-filter (DBusConnection *connection, DBusMessage *message, void *user_data)
-{
-        PolKitTracker *pk_tracker = (PolKitTracker *) user_data;
-        char *name;
-        char *new_service_name;
-        char *old_service_name;
-
-        /*  pass NameOwnerChanged signals from the bus and ConsoleKit to PolKitTracker */
-        if (dbus_message_is_signal (message, DBUS_INTERFACE_DBUS, "NameOwnerChanged") ||
-            g_str_has_prefix (dbus_message_get_interface (message), "org.freedesktop.ConsoleKit")) {
-                polkit_tracker_dbus_func (pk_tracker, message);
-        }
-
-        /* handle calls into our test service */
-        if (dbus_message_is_method_call (message, "dk.fubar.PolKitTestService", "Test")) {
-                DBusMessage *reply;
-                const char *reply_str = "Right back at y'all!";
-
-                print_caller (pk_tracker, dbus_message_get_sender (message));
-
-                reply = dbus_message_new_method_return (message);
-                dbus_message_append_args (reply, 
-                                          DBUS_TYPE_STRING, &reply_str,
-                                          DBUS_TYPE_INVALID);
-                dbus_connection_send (connection, reply, NULL);
-                dbus_message_unref (reply);
-
-                /* this one we do handle */
-                return DBUS_HANDLER_RESULT_HANDLED;
-        }
-
-        /* other filters might want to process this message too */
-        return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
-}
-
-
-int
-main (int argc, char *argv[])
-{
-        DBusError error;
-        DBusConnection *con;
-        GMainLoop *loop;
-        PolKitTracker *pk_tracker;
-
-        /* This is needed to get something out of polkit_caller_debug() */
-        g_setenv ("POLKIT_DEBUG", "1", TRUE);
-
-        loop = g_main_loop_new (NULL, FALSE);
-
-        dbus_error_init (&error);
-        con = dbus_bus_get (DBUS_BUS_SYSTEM, &error);
-
-        pk_tracker = polkit_tracker_new ();
-        polkit_tracker_set_system_bus_connection (pk_tracker, con);
-        polkit_tracker_init (pk_tracker);
-
-        /* need to listen to NameOwnerChanged */
-	dbus_bus_add_match (con,
-			    "type='signal'"
-			    ",interface='"DBUS_INTERFACE_DBUS"'"
-			    ",sender='"DBUS_SERVICE_DBUS"'"
-			    ",member='NameOwnerChanged'",
-			    &error);
-
-        /* need to listen to ConsoleKit signals */
-	dbus_bus_add_match (con,
-			    "type='signal',sender='org.freedesktop.ConsoleKit'",
-			    &error);
-
-        /* own a simple service */
-        dbus_bus_request_name (con, "dk.fubar.PolKitTestService", DBUS_NAME_FLAG_REPLACE_EXISTING, &error);
-
-        dbus_connection_add_filter (con, filter, pk_tracker, NULL);
-        dbus_connection_setup_with_g_main (con, g_main_loop_get_context (loop));
-
-        g_main_loop_run (loop);
-        return 0;
-}
diff --git a/gtk-doc.make b/gtk-doc.make
deleted file mode 100644
index 3c3e39a..0000000
--- a/gtk-doc.make
+++ /dev/null
@@ -1,159 +0,0 @@
-# -*- mode: makefile -*-
-
-####################################
-# Everything below here is generic #
-####################################
-
-if GTK_DOC_USE_LIBTOOL
-GTKDOC_CC = $(LIBTOOL) --mode=compile $(CC) $(INCLUDES) $(AM_CFLAGS) $(CFLAGS)
-GTKDOC_LD = $(LIBTOOL) --mode=link $(CC) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS)
-else
-GTKDOC_CC = $(CC) $(INCLUDES) $(AM_CFLAGS) $(CFLAGS)
-GTKDOC_LD = $(CC) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS)
-endif
-
-# We set GPATH here; this gives us semantics for GNU make
-# which are more like other make's VPATH, when it comes to
-# whether a source that is a target of one rule is then
-# searched for in VPATH/GPATH.
-#
-GPATH = $(srcdir)
-
-TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
-
-EXTRA_DIST = 				\
-	$(content_files)		\
-	$(HTML_IMAGES)			\
-	$(DOC_MAIN_SGML_FILE)		\
-	$(DOC_MODULE)-sections.txt	\
-	$(DOC_MODULE)-overrides.txt
-
-DOC_STAMPS=scan-build.stamp tmpl-build.stamp sgml-build.stamp html-build.stamp \
-	   $(srcdir)/tmpl.stamp $(srcdir)/sgml.stamp $(srcdir)/html.stamp
-
-SCANOBJ_FILES = 		 \
-	$(DOC_MODULE).args 	 \
-	$(DOC_MODULE).hierarchy  \
-	$(DOC_MODULE).interfaces \
-	$(DOC_MODULE).prerequisites \
-	$(DOC_MODULE).signals
-
-CLEANFILES = $(SCANOBJ_FILES) $(DOC_MODULE)-unused.txt $(DOC_STAMPS)
-
-if ENABLE_GTK_DOC
-all-local: html-build.stamp
-else
-all-local:
-endif
-
-docs: html-build.stamp
-
-#### scan ####
-
-scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
-	@echo 'gtk-doc: Scanning header files'
-	@-chmod -R u+w $(srcdir)
-	cd $(srcdir) && \
-	  gtkdoc-scan --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --ignore-headers="$(IGNORE_HFILES)" $(SCAN_OPTIONS) $(EXTRA_HFILES)
-	if grep -l '^..*$$' $(srcdir)/$(DOC_MODULE).types > /dev/null 2>&1 ; then \
-	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" CFLAGS="$(GTKDOC_CFLAGS)" LDFLAGS="$(GTKDOC_LIBS)" gtkdoc-scangobj $(SCANGOBJ_OPTIONS) --module=$(DOC_MODULE) --output-dir=$(srcdir) ; \
-	else \
-	    cd $(srcdir) ; \
-	    for i in $(SCANOBJ_FILES) ; do \
-               test -f $$i || touch $$i ; \
-	    done \
-	fi
-	touch scan-build.stamp
-
-$(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt: scan-build.stamp
-	@true
-
-#### templates ####
-
-tmpl-build.stamp: $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt
-	@echo 'gtk-doc: Rebuilding template files'
-	@-chmod -R u+w $(srcdir)
-	cd $(srcdir) && gtkdoc-mktmpl --module=$(DOC_MODULE) $(MKTMPL_OPTIONS)
-	touch tmpl-build.stamp
-
-tmpl.stamp: tmpl-build.stamp
-	@true
-
-tmpl/*.sgml:
-	@true
-
-
-#### xml ####
-
-sgml-build.stamp: tmpl.stamp $(HFILE_GLOB) $(CFILE_GLOB) $(DOC_MODULE)-sections.txt $(srcdir)/tmpl/*.sgml $(expand_content_files)
-	@echo 'gtk-doc: Building XML'
-	@-chmod -R u+w $(srcdir)
-	cd $(srcdir) && \
-	gtkdoc-mkdb --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $(MKDB_OPTIONS)
-	touch sgml-build.stamp
-
-sgml.stamp: sgml-build.stamp
-	@true
-
-#### html ####
-
-html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
-	@echo 'gtk-doc: Building HTML'
-	@-chmod -R u+w $(srcdir)
-	rm -rf $(srcdir)/html 
-	mkdir $(srcdir)/html
-	cd $(srcdir)/html && gtkdoc-mkhtml $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
-	test "x$(HTML_IMAGES)" = "x" || ( cd $(srcdir) && cp $(HTML_IMAGES) html )
-	@echo 'gtk-doc: Fixing cross-references' 
-	cd $(srcdir) && gtkdoc-fixxref --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
-	touch html-build.stamp
-
-##############
-
-clean-local:
-	rm -f *~ *.bak
-	rm -rf .libs
-
-maintainer-clean-local: clean
-	cd $(srcdir) && rm -rf xml html $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
-
-install-data-local:
-	installfiles=`echo $(srcdir)/html/*`; \
-	if test "$$installfiles" = '$(srcdir)/html/*'; \
-	then echo '-- Nothing to install' ; \
-	else \
-	  $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR); \
-	  for i in $$installfiles; do \
-	    echo '-- Installing '$$i ; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
-	  done; \
-	  echo '-- Installing $(srcdir)/html/index.sgml' ; \
-	  $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR) || :; \
-	fi
-
-uninstall-local:
-	rm -f $(DESTDIR)$(TARGET_DIR)/*
-
-#
-# Require gtk-doc when making dist
-#
-if ENABLE_GTK_DOC
-dist-check-gtkdoc:
-else
-dist-check-gtkdoc:
-	@echo "*** gtk-doc must be installed and enabled in order to make dist"
-	@false
-endif
-
-dist-hook: dist-check-gtkdoc dist-hook-local
-	mkdir $(distdir)/tmpl
-	mkdir $(distdir)/xml
-	mkdir $(distdir)/html
-	-cp $(srcdir)/tmpl/*.sgml $(distdir)/tmpl
-	-cp $(srcdir)/xml/*.xml $(distdir)/xml
-	cp $(srcdir)/html/* $(distdir)/html
-	if test -f $(srcdir)/$(DOC_MODULE).types; then \
-	  cp $(srcdir)/$(DOC_MODULE).types $(distdir)/$(DOC_MODULE).types; \
-	fi
-
-.PHONY : dist-hook-local docs
diff --git a/mkinstalldirs b/mkinstalldirs
deleted file mode 100755
index d2d5f21..0000000
--- a/mkinstalldirs
+++ /dev/null
@@ -1,111 +0,0 @@
-#! /bin/sh
-# mkinstalldirs --- make directory hierarchy
-# Author: Noah Friedman <friedman at prep.ai.mit.edu>
-# Created: 1993-05-16
-# Public domain
-
-errstatus=0
-dirmode=""
-
-usage="\
-Usage: mkinstalldirs [-h] [--help] [-m mode] dir ..."
-
-# process command line arguments
-while test $# -gt 0 ; do
-  case $1 in
-    -h | --help | --h*)         # -h for help
-      echo "$usage" 1>&2
-      exit 0
-      ;;
-    -m)                         # -m PERM arg
-      shift
-      test $# -eq 0 && { echo "$usage" 1>&2; exit 1; }
-      dirmode=$1
-      shift
-      ;;
-    --)                         # stop option processing
-      shift
-      break
-      ;;
-    -*)                         # unknown option
-      echo "$usage" 1>&2
-      exit 1
-      ;;
-    *)                          # first non-opt arg
-      break
-      ;;
-  esac
-done
-
-for file
-do
-  if test -d "$file"; then
-    shift
-  else
-    break
-  fi
-done
-
-case $# in
-  0) exit 0 ;;
-esac
-
-case $dirmode in
-  '')
-    if mkdir -p -- . 2>/dev/null; then
-      echo "mkdir -p -- $*"
-      exec mkdir -p -- "$@"
-    fi
-    ;;
-  *)
-    if mkdir -m "$dirmode" -p -- . 2>/dev/null; then
-      echo "mkdir -m $dirmode -p -- $*"
-      exec mkdir -m "$dirmode" -p -- "$@"
-    fi
-    ;;
-esac
-
-for file
-do
-  set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
-  shift
-
-  pathcomp=
-  for d
-  do
-    pathcomp="$pathcomp$d"
-    case $pathcomp in
-      -*) pathcomp=./$pathcomp ;;
-    esac
-
-    if test ! -d "$pathcomp"; then
-      echo "mkdir $pathcomp"
-
-      mkdir "$pathcomp" || lasterr=$?
-
-      if test ! -d "$pathcomp"; then
-  	errstatus=$lasterr
-      else
-  	if test ! -z "$dirmode"; then
-	  echo "chmod $dirmode $pathcomp"
-    	  lasterr=""
-  	  chmod "$dirmode" "$pathcomp" || lasterr=$?
-
-  	  if test ! -z "$lasterr"; then
-  	    errstatus=$lasterr
-  	  fi
-  	fi
-      fi
-    fi
-
-    pathcomp="$pathcomp/"
-  done
-done
-
-exit $errstatus
-
-# Local Variables:
-# mode: shell-script
-# sh-indentation: 2
-# End:
-# mkinstalldirs ends here
diff --git a/po/ChangeLog b/po/ChangeLog
deleted file mode 100644
index e69de29..0000000
diff --git a/po/LINGUAS b/po/LINGUAS
deleted file mode 100644
index b72d517..0000000
--- a/po/LINGUAS
+++ /dev/null
@@ -1,4 +0,0 @@
-# please keep this list sorted alphabetically
-#
-
-
diff --git a/po/POTFILES.in b/po/POTFILES.in
deleted file mode 100644
index b93a173..0000000
--- a/po/POTFILES.in
+++ /dev/null
@@ -1,4 +0,0 @@
-# List of source files containing translatable strings.
-# Please keep this file sorted alphabetically.
-[encoding: UTF-8]
-policy/org.freedesktop.policykit.policy.in
diff --git a/policy/Makefile.am b/policy/Makefile.am
deleted file mode 100644
index d062a8e..0000000
--- a/policy/Makefile.am
+++ /dev/null
@@ -1,16 +0,0 @@
-
-polkit_actiondir = $(datadir)/polkit-1/actions
-
-dist_polkit_action_DATA = org.freedesktop.policykit.policy
-
- at INTLTOOL_POLICY_RULE@
-
-check:
-	$(top_builddir)/tools/polkit-policy-file-validate-1 $(top_srcdir)/policy/$(dist_polkit_action_DATA)
-
-clean-local :
-	rm -f *~
-
-DISTCLEANFILES = org.freedesktop.policykit.policy
-
-EXTRA_DIST = org.freedesktop.policykit.policy.in
diff --git a/policy/org.freedesktop.policykit.policy.in b/policy/org.freedesktop.policykit.policy.in
deleted file mode 100644
index c2e8652..0000000
--- a/policy/org.freedesktop.policykit.policy.in
+++ /dev/null
@@ -1,61 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-<!DOCTYPE policyconfig PUBLIC
- "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
- "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
-
-<!-- 
-Policy definitions for core PolicyKit actions
-
-Copyright (c) 2007 David Zeuthen <david at fubar.dk>
-
-NOTE: If you make changes to this file, make sure to validate the file
-using the polkit-policy-file-validate(1) tool. Changes made to this
-file are instantly applied.
--->
-
-<policyconfig>
-  <vendor>The PolicyKit Project</vendor>
-  <vendor_url>http://hal.freedesktop.org/docs/PolicyKit/</vendor_url>
-
-  <action id="org.freedesktop.policykit.read">
-    <_description>Read authorizations of other users</_description>
-    <_message>Authentication is required to read authorizations of other users</_message>
-    <defaults>
-      <allow_any>no</allow_any>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_admin_keep_always</allow_active>
-    </defaults>
-  </action>
-
-  <action id="org.freedesktop.policykit.revoke">
-    <_description>Revoke authorizations from other users</_description>
-    <_message>Authentication is required to revoke authorizations other users</_message>
-    <defaults>
-      <allow_any>no</allow_any>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_admin_keep_always</allow_active>
-    </defaults>
-  </action>
-
-  <action id="org.freedesktop.policykit.grant">
-    <_description>Grant authorizations to other users</_description>
-    <_message>Authentication is required to grant authorizations to other users</_message>
-    <defaults>
-      <allow_any>no</allow_any>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_admin_keep_always</allow_active>
-    </defaults>
-  </action>
-
-  <action id="org.freedesktop.policykit.modify-defaults">
-    <_description>Modify defaults for implicit authorizations</_description>
-    <_message>Authentication is required to modify the defaults for implicit authorizations</_message>
-    <defaults>
-      <allow_any>no</allow_any>
-      <allow_inactive>no</allow_inactive>
-      <allow_active>auth_admin_keep_always</allow_active>
-    </defaults>
-  </action>
-
-</policyconfig>
diff --git a/polkit-backendd/Makefile.am b/polkit-backendd/Makefile.am
deleted file mode 100644
index f35c178..0000000
--- a/polkit-backendd/Makefile.am
+++ /dev/null
@@ -1,63 +0,0 @@
-## Process this file with automake to produce Makefile.in
-
-INCLUDES = \
-	-I$(top_builddir)/src -I$(top_srcdir)/src \
-	-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-	-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
-	-DPACKAGE_DATA_DIR=\""$(datadir)"\" \
-	-DPACKAGE_BIN_DIR=\""$(bindir)"\" \
-	-DPACKAGE_LOCALSTATE_DIR=\""$(localstatedir)"\" \
-	-DPACKAGE_LOCALE_DIR=\""$(localedir)"\" \
-	-DPACKAGE_LIB_DIR=\""$(libdir)"\" \
-	-D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT	\
-	-DPOLKIT_COMPILATION \
-	$(DBUS_GLIB_CFLAGS) \
-	@GLIB_CFLAGS@
-
-BUILT_SOURCES =						\
-	polkit-daemon-backend-glue.h
-
-polkit-daemon-backend-glue.h: org.freedesktop.PolicyKit.Backend.xml Makefile.am
-	dbus-binding-tool --prefix=polkit_daemon_backend --mode=glib-server --output=polkit-daemon-backend-glue.h org.freedesktop.PolicyKit.Backend.xml
-
-libexec_PROGRAMS = polkit-backendd
-
-polkit_backendd_SOURCES = 						\
-	polkit-daemon-backend.h		polkit-daemon-backend.c		\
-	main.c								\
-	$(BUILT_SOURCES)
-
-polkit_backendd_CPPFLAGS = 					\
-	-I$(top_srcdir)/src					\
-	-DG_LOG_DOMAIN=\"polkit_backendd\"			\
-	-DDATADIR=\""$(pkgdatadir)"\"				\
-	-DGNOMELOCALEDIR=\""$(datadir)/locale"\"		\
-	$(DISABLE_DEPRECATED)					\
-	$(AM_CPPFLAGS)
-
-polkit_backendd_LDADD = 				        \
-	$(DBUS_GLIB_LIBS) 					\
-	$(top_builddir)/src/kit/libkit.la			\
-	$(top_builddir)/src/polkit/libpolkit-1.la
-
-
-servicedir       = $(datadir)/dbus-1/system-services
-service_in_files = org.freedesktop.PolicyKit.Backend.service.in
-service_DATA     = $(service_in_files:.service.in=.service)
-
-$(service_DATA): $(service_in_files) Makefile
-	@sed -e "s|\@libexecdir\@|$(libexecdir)|" $< > $@
-
-dbusconfdir = $(sysconfdir)/dbus-1/system.d
-dbusconf_in_files = org.freedesktop.PolicyKit.Backend.conf.in
-dbusconf_DATA = $(dbusconf_in_files:.conf.in=.conf)
-
-$(dbusconf_DATA): $(dbusconf_in_files) Makefile
-	@sed -e "s|\@polkituser\@|$(POLKIT_USER)|" $< > $@
-
-CLEANFILES = $(BUILT_SOURCES)
-
-EXTRA_DIST = org.freedesktop.PolicyKit.Backend.xml $(service_in_files) $(dbusconf_in_files)
-
-clean-local :
-	rm -f *~ $(service_DATA) $(dbusconf_DATA)
diff --git a/polkit-backendd/main.c b/polkit-backendd/main.c
deleted file mode 100644
index 67f6e15..0000000
--- a/polkit-backendd/main.c
+++ /dev/null
@@ -1,169 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*-
- *
- * Copyright (C) 2007 David Zeuthen <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- */
-
-#ifdef HAVE_CONFIG_H
-#  include "config.h"
-#endif
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <unistd.h>
-#include <signal.h>
-#include <errno.h>
-#include <string.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-#include <pwd.h>
-#include <grp.h>
-
-#include <glib.h>
-#include <glib/gi18n-lib.h>
-#include <glib-object.h>
-
-#define DBUS_API_SUBJECT_TO_CHANGE
-#include <dbus/dbus-glib.h>
-#include <dbus/dbus-glib-lowlevel.h>
-
-#include "polkit-daemon-backend.h"
-
-#define NAME_TO_CLAIM "org.freedesktop.PolicyKit.Backend"
-
-static gboolean
-acquire_name_on_proxy (DBusGProxy *bus_proxy)
-{
-        GError     *error;
-        guint       result;
-        gboolean    res;
-        gboolean    ret;
-
-        ret = FALSE;
-
-        if (bus_proxy == NULL) {
-                goto out;
-        }
-
-        error = NULL;
-	res = dbus_g_proxy_call (bus_proxy,
-                                 "RequestName",
-                                 &error,
-                                 G_TYPE_STRING, NAME_TO_CLAIM,
-                                 G_TYPE_UINT, 0,
-                                 G_TYPE_INVALID,
-                                 G_TYPE_UINT, &result,
-                                 G_TYPE_INVALID);
-        if (! res) {
-                if (error != NULL) {
-                        g_warning ("Failed to acquire %s: %s", NAME_TO_CLAIM, error->message);
-                        g_error_free (error);
-                } else {
-                        g_warning ("Failed to acquire %s", NAME_TO_CLAIM);
-                }
-                goto out;
-	}
-
- 	if (result != DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER) {
-                if (error != NULL) {
-                        g_warning ("Failed to acquire %s: %s", NAME_TO_CLAIM, error->message);
-                        g_error_free (error);
-                } else {
-                        g_warning ("Failed to acquire %s", NAME_TO_CLAIM);
-                }
-                goto out;
-        }
-
-        ret = TRUE;
-
- out:
-        return ret;
-}
-
-int
-main (int argc, char **argv)
-{
-        GError              *error;
-        GMainLoop           *loop;
-        PolKitDaemonBackend *daemon;
-        GOptionContext      *context;
-        DBusGProxy          *bus_proxy;
-        DBusGConnection     *bus;
-        int                  ret;
-        static gboolean     no_exit      = FALSE;
-        static GOptionEntry entries []   = {
-                { "no-exit", 0, 0, G_OPTION_ARG_NONE, &no_exit, "Don't exit after 30 seconds of inactivity", NULL },
-                { NULL }
-        };
-
-        ret = 1;
-
-        g_type_init ();
-
-        context = g_option_context_new ("PolicyKit backend daemon");
-        g_option_context_add_main_entries (context, entries, NULL);
-        g_option_context_parse (context, &argc, &argv, NULL);
-        g_option_context_free (context);
-
-        error = NULL;
-        bus = dbus_g_bus_get (DBUS_BUS_SYSTEM, &error);
-        if (bus == NULL) {
-                g_warning ("Couldn't connect to system bus: %s", error->message);
-                g_error_free (error);
-                goto out;
-        }
-
-	bus_proxy = dbus_g_proxy_new_for_name (bus,
-                                               DBUS_SERVICE_DBUS,
-                                               DBUS_PATH_DBUS,
-                                               DBUS_INTERFACE_DBUS);
-        if (bus_proxy == NULL) {
-                g_warning ("Could not construct bus_proxy object; bailing out");
-                goto out;
-        }
-
-        if (!acquire_name_on_proxy (bus_proxy) ) {
-                g_warning ("Could not acquire name; bailing out");
-                goto out;
-        }
-
-        g_debug ("Starting polkit-backendd version %s", VERSION);
-
-        daemon = polkit_daemon_backend_new (no_exit);
-
-        if (daemon == NULL) {
-                goto out;
-        }
-
-        loop = g_main_loop_new (NULL, FALSE);
-
-        g_main_loop_run (loop);
-
-        g_object_unref (daemon);
-        g_main_loop_unref (loop);
-        ret = 0;
-
-out:
-        return ret;
-}
diff --git a/polkit-backendd/org.freedesktop.PolicyKit.Backend.conf.in b/polkit-backendd/org.freedesktop.PolicyKit.Backend.conf.in
deleted file mode 100644
index 470c6a5..0000000
--- a/polkit-backendd/org.freedesktop.PolicyKit.Backend.conf.in
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?> <!-- -*- XML -*- -->
-
-<!DOCTYPE busconfig PUBLIC
- "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
- "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
-<busconfig>
-  <!-- Only @polkituser@ can own the service -->
-  <policy user="root">
-    <allow own="org.freedesktop.PolicyKit.Backend"/>
-  </policy>
-</busconfig>
diff --git a/polkit-backendd/org.freedesktop.PolicyKit.Backend.service.in b/polkit-backendd/org.freedesktop.PolicyKit.Backend.service.in
deleted file mode 100644
index 8769bd7..0000000
--- a/polkit-backendd/org.freedesktop.PolicyKit.Backend.service.in
+++ /dev/null
@@ -1,4 +0,0 @@
-[D-BUS Service]
-Name=org.freedesktop.PolicyKit.Backend
-Exec=@libexecdir@/polkit-backendd
-User=root
diff --git a/polkit-backendd/org.freedesktop.PolicyKit.Backend.xml b/polkit-backendd/org.freedesktop.PolicyKit.Backend.xml
deleted file mode 100644
index 017e9e3..0000000
--- a/polkit-backendd/org.freedesktop.PolicyKit.Backend.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN" "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
-<node name="/">
-
-  <interface name="org.freedesktop.PolicyKit.Backend">
-
-    <method name="Hello">
-      <annotation name="org.freedesktop.DBus.GLib.Async" value=""/>
-      <arg name="message" direction="in" type="s"/>
-      <arg name="result" direction="out" type="s"/>
-    </method>
-
-    <method name="GetPolicyEntries">
-      <annotation name="org.freedesktop.DBus.GLib.Async" value=""/>
-      <arg name="result" direction="out" type="as"/>
-    </method>
-
-  </interface>
-</node>
diff --git a/polkit-backendd/polkit-daemon-backend.c b/polkit-backendd/polkit-daemon-backend.c
deleted file mode 100644
index d0ad546..0000000
--- a/polkit-backendd/polkit-daemon-backend.c
+++ /dev/null
@@ -1,292 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*-
- *
- * Copyright (C) 2007 David Zeuthen <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- */
-
-#ifdef HAVE_CONFIG_H
-#  include "config.h"
-#endif
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <unistd.h>
-#include <signal.h>
-#include <errno.h>
-#include <string.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/time.h>
-#include <sys/resource.h>
-#include <fcntl.h>
-#include <signal.h>
-
-#include <glib.h>
-#include <glib/gi18n-lib.h>
-#include <glib-object.h>
-#include <dbus/dbus-glib.h>
-#include <dbus/dbus-glib-lowlevel.h>
-
-#include "polkit-daemon-backend.h"
-
-#include <polkit/polkit.h>
-#include <polkit/polkit-private.h>
-
-static gboolean no_exit = FALSE;
-
-/*--------------------------------------------------------------------------------------------------------------*/
-#include "polkit-daemon-backend-glue.h"
-
-static gboolean
-do_exit (gpointer user_data)
-{
-        g_debug ("Exiting due to inactivity");
-        exit (1);
-        return FALSE;
-}
-
-static void
-reset_killtimer (void)
-{
-        static guint timer_id = 0;
-
-        if (no_exit)
-                return;
-
-        if (timer_id > 0) {
-                g_source_remove (timer_id);
-        }
-        g_debug ("Setting killtimer to 30 seconds...");
-        timer_id = g_timeout_add (30 * 1000, do_exit, NULL);
-}
-
-struct PolKitDaemonBackendPrivate
-{
-        DBusGConnection *system_bus_connection;
-        DBusGProxy      *system_bus_proxy;
-        PolKitContext   *pk_context;
-        PolKitTracker   *pk_tracker;
-};
-
-static void     polkit_daemon_backend_class_init  (PolKitDaemonBackendClass *klass);
-static void     polkit_daemon_backend_init        (PolKitDaemonBackend      *seat);
-static void     polkit_daemon_backend_finalize    (GObject     *object);
-
-G_DEFINE_TYPE (PolKitDaemonBackend, polkit_daemon_backend, G_TYPE_OBJECT)
-
-#define POLKIT_DAEMON_BACKEND_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), POLKIT_TYPE_DAEMON_BACKEND, PolKitDaemonBackendPrivate))
-
-GQuark
-polkit_daemon_backend_error_quark (void)
-{
-        static GQuark ret = 0;
-
-        if (ret == 0) {
-                ret = g_quark_from_static_string ("polkit_daemon_backend_error");
-        }
-
-        return ret;
-}
-
-
-#define ENUM_ENTRY(NAME, DESC) { NAME, "" #NAME "", DESC }
-
-GType
-polkit_daemon_backend_error_get_type (void)
-{
-        static GType etype = 0;
-        
-        if (etype == 0)
-        {
-                static const GEnumValue values[] =
-                        {
-                                ENUM_ENTRY (POLKIT_DAEMON_BACKEND_ERROR_GENERAL, "GeneralError"),
-                                { 0, 0, 0 }
-                        };
-                
-                g_assert (POLKIT_DAEMON_BACKEND_NUM_ERRORS == G_N_ELEMENTS (values) - 1);
-                
-                etype = g_enum_register_static ("PolKitDaemonBackendError", values);
-        }
-        
-        return etype;
-}
-
-
-static GObject *
-polkit_daemon_backend_constructor (GType                  type,
-                                            guint                  n_construct_properties,
-                                            GObjectConstructParam *construct_properties)
-{
-        PolKitDaemonBackend      *daemon_backend;
-        PolKitDaemonBackendClass *klass;
-
-        klass = POLKIT_DAEMON_BACKEND_CLASS (g_type_class_peek (POLKIT_TYPE_DAEMON_BACKEND));
-
-        daemon_backend = POLKIT_DAEMON_BACKEND (
-                G_OBJECT_CLASS (polkit_daemon_backend_parent_class)->constructor (type,
-                                                                                           n_construct_properties,
-                                                                                           construct_properties));
-        
-        return G_OBJECT (daemon_backend);
-}
-
-static void
-polkit_daemon_backend_class_init (PolKitDaemonBackendClass *klass)
-{
-        GObjectClass   *object_class = G_OBJECT_CLASS (klass);
-
-        object_class->constructor = polkit_daemon_backend_constructor;
-        object_class->finalize = polkit_daemon_backend_finalize;
-
-        g_type_class_add_private (klass, sizeof (PolKitDaemonBackendPrivate));
-
-        dbus_g_object_type_install_info (POLKIT_TYPE_DAEMON_BACKEND, &dbus_glib_polkit_daemon_backend_object_info);
-
-        dbus_g_error_domain_register (POLKIT_DAEMON_BACKEND_ERROR, NULL, POLKIT_DAEMON_BACKEND_TYPE_ERROR);
-
-}
-
-static void
-polkit_daemon_backend_init (PolKitDaemonBackend *daemon_backend)
-{
-        daemon_backend->priv = POLKIT_DAEMON_BACKEND_GET_PRIVATE (daemon_backend);
-
-}
-
-static void
-polkit_daemon_backend_finalize (GObject *object)
-{
-        PolKitDaemonBackend *daemon_backend;
-
-        g_return_if_fail (object != NULL);
-        g_return_if_fail (POLKIT_IS_DAEMON_BACKEND (object));
-
-        daemon_backend = POLKIT_DAEMON_BACKEND (object);
-
-        g_return_if_fail (daemon_backend->priv != NULL);
-
-        g_object_unref (daemon_backend->priv->system_bus_proxy);
-
-        G_OBJECT_CLASS (polkit_daemon_backend_parent_class)->finalize (object);
-}
-
-static gboolean
-register_daemon_backend (PolKitDaemonBackend *daemon_backend)
-{
-        DBusConnection *connection;
-        GError *error = NULL;
-
-        error = NULL;
-        daemon_backend->priv->system_bus_connection = dbus_g_bus_get (DBUS_BUS_SYSTEM, &error);
-        if (daemon_backend->priv->system_bus_connection == NULL) {
-                if (error != NULL) {
-                        g_critical ("error getting system bus: %s", error->message);
-                        g_error_free (error);
-                }
-                goto error;
-        }
-        connection = dbus_g_connection_get_connection (daemon_backend->priv->system_bus_connection);
-
-        dbus_g_connection_register_g_object (daemon_backend->priv->system_bus_connection, "/", 
-                                             G_OBJECT (daemon_backend));
-
-        daemon_backend->priv->system_bus_proxy = dbus_g_proxy_new_for_name (daemon_backend->priv->system_bus_connection,
-                                                                      DBUS_SERVICE_DBUS,
-                                                                      DBUS_PATH_DBUS,
-                                                                      DBUS_INTERFACE_DBUS);
-
-        reset_killtimer ();
-
-        return TRUE;
-
-error:
-        return FALSE;
-}
-
-
-PolKitDaemonBackend *
-polkit_daemon_backend_new (gboolean _no_exit)
-{
-        GObject *object;
-        gboolean res;
-
-        no_exit = _no_exit;
-
-        object = g_object_new (POLKIT_TYPE_DAEMON_BACKEND, NULL);
-
-        res = register_daemon_backend (POLKIT_DAEMON_BACKEND (object));
-        if (! res) {
-                g_object_unref (object);
-                return NULL;
-        }
-
-        return POLKIT_DAEMON_BACKEND (object);
-}
-
-/*--------------------------------------------------------------------------------------------------------------*/
-/* exported methods */
-
-gboolean
-polkit_daemon_backend_hello (PolKitDaemonBackend   *daemon,
-                             const char            *message,
-                             DBusGMethodInvocation *context)
-{
-        char *s;
-
-        s = g_strdup_printf ("You said '%s'", message);
-        dbus_g_method_return (context, s);
-        g_free (s);
-
-        return TRUE;
-}
-
-/*--------------------------------------------------------------------------------------------------------------*/
-
-
-
-gboolean
-polkit_daemon_backend_get_policy_entries (PolKitDaemonBackend   *daemon,
-                                          DBusGMethodInvocation *context)
-{
-        GPtrArray *a;
-        PolKitPolicyCache *c;
-
-        c = _polkit_policy_cache_new (PACKAGE_DATA_DIR "polkit-1/actions", TRUE, NULL);
-        polkit_policy_cache_unref (c);
-
-        a = g_ptr_array_new ();
-        g_ptr_array_add (a, g_strdup ("foo"));
-        g_ptr_array_add (a, g_strdup ("bar"));
-        g_ptr_array_add (a, g_strdup ("baz"));
-
-        g_ptr_array_add (a, NULL);
-        dbus_g_method_return (context, a->pdata);
-
-        g_ptr_array_foreach (a, (GFunc) g_free, NULL);
-        g_ptr_array_free (a, TRUE);
-
-        return TRUE;
-}
-
-/*--------------------------------------------------------------------------------------------------------------*/
diff --git a/polkit-backendd/polkit-daemon-backend.h b/polkit-backendd/polkit-daemon-backend.h
deleted file mode 100644
index 65d0d1a..0000000
--- a/polkit-backendd/polkit-daemon-backend.h
+++ /dev/null
@@ -1,81 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*-
- *
- * Copyright (C) 2007 David Zeuthen <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- */
-
-#ifndef __POLKIT_DAEMON_BACKEND_H__
-#define __POLKIT_DAEMON_BACKEND_H__
-
-#include <glib-object.h>
-#include <polkit/polkit.h>
-
-G_BEGIN_DECLS
-
-#define POLKIT_TYPE_DAEMON_BACKEND         (polkit_daemon_backend_get_type ())
-#define POLKIT_DAEMON_BACKEND(o)           (G_TYPE_CHECK_INSTANCE_CAST ((o), POLKIT_TYPE_DAEMON_BACKEND, PolKitDaemonBackend))
-#define POLKIT_DAEMON_BACKEND_CLASS(k)     (G_TYPE_CHECK_CLASS_CAST((k), POLKIT_TYPE_DAEMON_BACKEND, PolKitDaemonBackendClass))
-#define POLKIT_IS_DAEMON_BACKEND(o)        (G_TYPE_CHECK_INSTANCE_TYPE ((o), POLKIT_TYPE_DAEMON_BACKEND))
-#define POLKIT_IS_DAEMON_BACKEND_CLASS(k)  (G_TYPE_CHECK_CLASS_TYPE ((k), POLKIT_TYPE_DAEMON_BACKEND))
-#define POLKIT_DAEMON_BACKEND_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), POLKIT_TYPE_DAEMON_BACKEND, PolKitDaemonBackendClass))
-
-typedef struct PolKitDaemonBackendPrivate PolKitDaemonBackendPrivate;
-
-typedef struct
-{
-        GObject        parent;
-        PolKitDaemonBackendPrivate *priv;
-} PolKitDaemonBackend;
-
-typedef struct
-{
-        GObjectClass   parent_class;
-} PolKitDaemonBackendClass;
-
-typedef enum
-{
-        POLKIT_DAEMON_BACKEND_ERROR_GENERAL,
-        POLKIT_DAEMON_BACKEND_NUM_ERRORS
-} PolKitDaemonBackendError;
-
-#define POLKIT_DAEMON_BACKEND_ERROR polkit_daemon_backend_error_quark ()
-
-GType polkit_daemon_backend_error_get_type (void);
-#define POLKIT_DAEMON_BACKEND_TYPE_ERROR (polkit_daemon_backend_error_get_type ())
-
-GQuark               polkit_daemon_backend_error_quark         (void);
-GType                polkit_daemon_backend_get_type            (void);
-PolKitDaemonBackend *polkit_daemon_backend_new                 (gboolean no_exit);
-
-/* exported methods */
-
-gboolean polkit_daemon_backend_hello (PolKitDaemonBackend   *daemon,
-                                      const char            *message,
-                                      DBusGMethodInvocation *context);
-
-gboolean polkit_daemon_backend_get_policy_entries (PolKitDaemonBackend   *daemon,
-                                                   DBusGMethodInvocation *context);
-
-G_END_DECLS
-
-#endif /* __POLKIT_DAEMON_BACKEND_H__ */
diff --git a/src/Makefile.am b/src/Makefile.am
deleted file mode 100644
index 5e2267f..0000000
--- a/src/Makefile.am
+++ /dev/null
@@ -1,5 +0,0 @@
-
-SUBDIRS = kit polkit polkit-grant
-
-clean-local :
-	rm -f *~
diff --git a/src/kit/Makefile.am b/src/kit/Makefile.am
deleted file mode 100644
index 824f48c..0000000
--- a/src/kit/Makefile.am
+++ /dev/null
@@ -1,79 +0,0 @@
-## Process this file with automake to produce Makefile.in
-
-NULL =
-
-INCLUDES = \
-	-I$(top_builddir)/src -I$(top_srcdir)/src \
-	-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-	-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
-	-DPACKAGE_DATA_DIR=\""$(datadir)"\" \
-	-DPACKAGE_BIN_DIR=\""$(bindir)"\" \
-	-DPACKAGE_LOCALSTATE_DIR=\""$(localstatedir)"\" \
-	-DPACKAGE_LOCALE_DIR=\""$(localedir)"\" \
-	-DPACKAGE_LIB_DIR=\""$(libdir)"\" \
-	-D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT	\
-	-DKIT_COMPILATION \
-	@GLIB_CFLAGS@
-
-noinst_LTLIBRARIES=libkit.la
-
-
-libkit_la_SOURCES =					\
-	kit.h						\
-	kit-test.h		kit-test.c		\
-	kit-memory.h		kit-memory.c		\
-	kit-string.h		kit-string.c		\
-	kit-lib.h		kit-lib.c		\
-	kit-list.h		kit-list.c		\
-	kit-hash.h		kit-hash.c		\
-	kit-file.h		kit-file.c		\
-	kit-spawn.h		kit-spawn.c		\
-	kit-message.h		kit-message.c		\
-	kit-entity.h		kit-entity.c		\
-	$(NULL)
-
-
-## note that TESTS has special meaning (stuff to use in make check)
-## so if adding tests not to be run in make check, don't add them to 
-## TESTS
-if KIT_BUILD_TESTS
-TESTS_ENVIRONMENT=
-TESTS=kit-test
-
-check_PROGRAMS=$(TESTS)
-
-kit_test_SOURCES=				\
-	kit-test-main.c
-
-kit_test_LDADD=$(top_builddir)/src/kit/libkit.la
-kit_test_LDFLAGS=@R_DYNAMIC_LDFLAG@
-
-if KIT_GCOV_ENABLED
-clean-gcov:
-	rm -f *.gcov .libs/*.gcda *.gcda
-
-.PHONY: coverage-report.txt covered-files.txt
-
-covered-files.txt :
-	echo $(addprefix src/kit/,$(filter %.c,$(libkit_la_SOURCES))) > covered-files.txt
-
-coverage-report.txt : covered-files.txt clean-gcov all check 
-	gcov $(filter %.c,$(libkit_la_SOURCES)) -o .libs/ > /dev/null
-	$(top_srcdir)/test/create-coverage-report.sh "module kit" `cat covered-files.txt` > coverage-report.txt
-
-check-coverage : coverage-report.txt
-	cat coverage-report.txt
-else
-coverage-report.txt:
-	@echo "Need to reconfigure with --enable-gcov"
-
-check-coverage:
-	@echo "Need to reconfigure with --enable-gcov"
-endif
-
-else
-TESTS=
-endif
-
-clean-local :
-	rm -f *~ *.bb *.bbg *.da *.gcov .libs/*.da .libs/*.bbg 
diff --git a/src/kit/kit-entity.c b/src/kit/kit-entity.c
deleted file mode 100644
index bbc2012..0000000
--- a/src/kit/kit-entity.c
+++ /dev/null
@@ -1,163 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-entity.c : Entity management
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <string.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-
-#ifdef BUILT_R_DYNAMIC
-#include <execinfo.h>
-#endif
-
-#include <kit/kit-entity.h>
-#include <kit/kit-test.h>
-
-/**
- * SECTION:kit-entity
- * @title: Entity management
- * @short_description: Entity management
- *
- * Functions used for entity management.
- **/
-
-#ifdef KIT_BUILD_TESTS
-
-/**
- * kit_getpwnam:
- * @username: user name to look up
- *
- * Like getpwnam(3) from the standard C library but tweaked for unit
- * testing. TODO: explain how.
- *
- * Returns: See getpwnam(3)
- */
-struct passwd *
-kit_getpwnam (const char *username)
-{
-        struct passwd *pw;
-        FILE *f;
-        const char *passwd_file;
-
-        f = NULL;
-        pw = NULL;
-
-        if ((passwd_file = getenv ("KIT_TEST_PASSWD_FILE")) == NULL)
-                return getpwnam (username);
-
-        f = fopen (passwd_file, "r");
-        if (f == NULL)
-                goto out;
-
-        while ((pw = fgetpwent (f)) != NULL) {
-                if (strcmp (pw->pw_name, username) == 0)
-                        goto out;
-        }
-
-out:
-        if (f != NULL)
-                fclose (f);
-        return pw;
-}
-
-/**
- * kit_getpwuid:
- * @uid: uid to look up
- *
- * Like getpwuid(3) from the standard C library but tweaked for unit
- * testing. TODO: explain how.
- *
- * Returns: See getpwuid(3)
- */
-struct passwd *
-kit_getpwuid (uid_t uid)
-{
-        struct passwd *pw;
-        FILE *f;
-        const char *passwd_file;
-
-        f = NULL;
-        pw = NULL;
-
-        if ((passwd_file = getenv ("KIT_TEST_PASSWD_FILE")) == NULL)
-                return getpwuid (uid);
-
-        f = fopen (passwd_file, "r");
-        if (f == NULL)
-                goto out;
-
-        while ((pw = fgetpwent (f)) != NULL) {
-                if (pw->pw_uid == uid)
-                        goto out;
-        }
-
-out:
-        if (f != NULL)
-                fclose (f);
-        return pw;
-}
-
-#else
-
-struct passwd *
-kit_getpwnam (const char *username)
-{
-        return getpwnam (username);
-}
-
-struct passwd *
-kit_getpwuid (uid_t uid)
-{
-        return getpwuid (uid);
-}
-#endif
-
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_run_test (void)
-{
-        return TRUE;
-}
-
-KitTest _test_entity = {
-        "kit_entity",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-entity.h b/src/kit/kit-entity.h
deleted file mode 100644
index 91b4e51..0000000
--- a/src/kit/kit-entity.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-entity.h : Entity management
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_ENTITY_H
-#define KIT_ENTITY_H
-
-#include <stdarg.h>
-#include <stdlib.h>
-#include <sys/types.h>
-#include <pwd.h>
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-struct passwd *kit_getpwnam (const char *username);
-struct passwd *kit_getpwuid (uid_t uid);
-
-KIT_END_DECLS
-
-#endif /* KIT_ENTITY_H */
-
-
diff --git a/src/kit/kit-file.c b/src/kit/kit-file.c
deleted file mode 100644
index 438f6c2..0000000
--- a/src/kit/kit-file.c
+++ /dev/null
@@ -1,367 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-file.c : File utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <sys/types.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <string.h>
-#include <dirent.h>
-
-#include <kit/kit.h>
-#include "kit-test.h"
-
-
-/**
- * SECTION:kit-file
- * @title: File utilities
- * @short_description: File utilities
- *
- * Various file utilities.
- **/
-
-#define BUF_SIZE 4096
-
-/**
- * kit_file_get_contents:
- * @path: path to file
- * @out_contents: Return location for allocated memory. Free with kit_free().
- * @out_contents_size: Return location for size of the file.
- * 
- * Reads an entire file into allocated memory.
- *
- * Returns: #TRUE if the file was read into memory; #FALSE if an error
- * occured and errno will be set. On OOM, errno will be set to
- * ENOMEM. If the file doesn't exist, errno will be set to ENOENT.
- */
-kit_bool_t
-kit_file_get_contents (const char *path, char **out_contents, size_t *out_contents_size)
-{
-        int fd;
-        kit_bool_t ret;
-        ssize_t num_read;
-        char *p;
-        char *q;
-        size_t total_allocated;
-        size_t total_size;
-        char buf[BUF_SIZE];
-
-        kit_return_val_if_fail (path != NULL, FALSE);
-        kit_return_val_if_fail (out_contents != NULL, FALSE);
-        kit_return_val_if_fail (out_contents_size != NULL, FALSE);
-
-        fd = -1;
-        ret = FALSE;
-        *out_contents = NULL;
-        p = NULL;
-
-        fd = open (path, O_RDONLY);
-        if (fd == -1)
-                goto out;
-
-        p = kit_malloc (BUF_SIZE);
-        if (p == NULL) {
-                errno = ENOMEM;
-                goto out;
-        }
-        total_allocated = BUF_SIZE;
-        total_size = 0;
-
-        do {
-        again:
-                num_read = read (fd, buf, BUF_SIZE);
-                if (num_read == -1) {
-                        if (errno == EINTR)
-                                goto again;
-                        else
-                                goto out;
-                }
-
-
-                if (total_size + num_read > total_allocated) {
-                        total_allocated += BUF_SIZE;
-                        q = kit_realloc (p, total_allocated);
-                        if (q == NULL) {
-                                errno = ENOMEM;
-                                goto out;
-                        }
-                        p = q;
-                }
-
-                memcpy (p + total_size, buf, num_read);
-                total_size += num_read;
-                
-        } while (num_read > 0);
-
-        /* add terminating zero */
-        if (total_size + 1 > total_allocated) {
-                total_allocated += BUF_SIZE;
-                q = kit_realloc (p, total_allocated);
-                if (q == NULL) {
-                        errno = ENOMEM;
-                        goto out;
-                }
-                p = q;
-        }
-        p[total_size] = '\0';
-
-        *out_contents = p;
-        *out_contents_size = total_size;
-        ret = TRUE;
-
-out:
-        if (fd >= 0) {
-        again2:
-                if (close (fd) != 0) {
-                        if (errno == EINTR)
-                                goto again2;
-                        else
-                                ret = FALSE;
-                }
-        }
-
-        if (!ret) {
-                kit_free (p);
-                *out_contents = NULL;
-        }
-
-        return ret;
-}
-
-static kit_bool_t
-_write_to_fd (int fd, const char *str, ssize_t str_len)
-{
-        kit_bool_t ret;
-        ssize_t written;
-
-        ret = FALSE;
-
-        written = 0;
-        while (written < str_len) {
-                ssize_t ret;
-                ret = write (fd, str + written, str_len - written);
-                if (ret < 0) {
-                        if (errno == EAGAIN || errno == EINTR) {
-                                continue;
-                        } else {
-                                goto out;
-                        }
-                }
-                written += ret;
-        }
-
-        ret = TRUE;
-
-out:
-        return ret;
-}
-
-/**
- * kit_file_set_contents:
- * @path: path to file
- * @mode: mode for file
- * @contents: contents to set
- * @contents_size: size of contents
- *
- * Writes all of contents to a file named @path, with good error
- * checking. If a file called @path already exists it will be
- * overwritten. This write is atomic in the sense that it is first
- * written to a temporary file which is then renamed to the final
- * name.
- *
- * If the file already exists hard links to @path will break. Also
- * since the file is recreated, existing permissions, access control
- * lists, metadata etc. may be lost. If @path is a symbolic link, the
- * link itself will be replaced, not the linked file.
- *
- * Returns: #TRUE if contents were set; #FALSE if an error occured and
- * errno will be set
- */
-kit_bool_t
-kit_file_set_contents (const char *path, mode_t mode, const char *contents, size_t contents_size)
-{
-        int fd;
-        char *path_tmp;
-        kit_bool_t ret;
-
-        path_tmp = NULL;
-        ret = FALSE;
-
-        kit_return_val_if_fail ((contents == NULL && contents_size == 0) || (contents != NULL), FALSE);
-        kit_return_val_if_fail (path != NULL, FALSE);
-
-        path_tmp = kit_strdup_printf ("%s.XXXXXX", path);
-        if (path_tmp == NULL) {
-                errno = ENOMEM;
-                goto out;
-        }
-
-        fd = mkstemp (path_tmp);
-        if (fd < 0) {
-                kit_warning ("Cannot create file '%s': %m", path_tmp);
-                goto out;
-        }
-        if (fchmod (fd, mode) != 0) {
-                kit_warning ("Cannot change mode for '%s' to 0%o: %m", path_tmp, mode);
-                close (fd);
-                unlink (path_tmp);
-                goto out;
-        }
-
-        if (contents_size > 0) {
-                if (!_write_to_fd (fd, contents, contents_size)) {
-                        kit_warning ("Cannot write to file %s: %m", path_tmp);
-                        close (fd);
-                        if (unlink (path_tmp) != 0) {
-                                kit_warning ("Cannot unlink %s: %m", path_tmp);
-                        }
-                        goto out;
-                }
-        }
-        close (fd);
-
-        if (rename (path_tmp, path) != 0) {
-                kit_warning ("Cannot rename %s to %s: %m", path_tmp, path);
-                if (unlink (path_tmp) != 0) {
-                        kit_warning ("Cannot unlink %s: %m", path_tmp);
-                }
-                goto out;
-        }
-
-        ret = TRUE;
-
-out:
-        if (path_tmp != NULL)
-                kit_free (path_tmp);
-
-        return ret;
-}
-
-/**
- * _kit_get_num_fd:
- *
- * Determines the number of open file descriptors
- *
- * Returns: Number of open file descriptors
- */
-size_t 
-_kit_get_num_fd (void)
-{
-        DIR *dir;
-        char buf[128];
-        ssize_t num;
-#ifdef HAVE_READDIR64
-        struct dirent64 *d;
-#else
-	struct dirent *d;
-#endif
-
-        num = -1;
-
-        snprintf (buf, sizeof (buf), "/proc/%d/fd", getpid ());
-
-        dir = opendir (buf);
-        if (dir == NULL) {
-                kit_warning ("error calling opendir on %s: %m\n", buf);
-                goto out;
-        }
-
-        num = -2;
-#ifdef HAVE_READDIR64
-        while ((d = readdir64 (dir)) != NULL) {
-#else
-	while ((d = readdir (dir)) != NULL) {
-#endif
-                if (d->d_name == NULL)
-                        continue;
-                num++;
-        }
-
-out:
-        if (dir != NULL)
-                closedir (dir);
-        return num;
-}
-
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_run_test (void)
-{
-        char path[] = "/tmp/kit-test";
-        char *buf;
-        size_t buf_size;
-        char *p;
-        size_t s;
-        unsigned int n;
-
-        buf_size = 3 * BUF_SIZE;
-        if ((buf = kit_malloc (buf_size)) == NULL)
-                goto out;
-
-        for (n = 0; n < buf_size; n++)
-                buf[n] = n;
-
-        if (!kit_file_set_contents (path, 0400, buf, buf_size)) {
-                kit_assert (errno == ENOMEM);
-        } else {
-                if (!kit_file_get_contents (path, &p, &s)) {
-                        kit_assert (errno == ENOMEM);
-                } else {
-                        kit_assert (s == buf_size && memcmp (p, buf, buf_size) == 0);
-                        kit_free (p);
-                }
-
-                kit_assert (unlink (path) == 0);
-
-                kit_assert (!kit_file_get_contents (path, &p, &s));
-        }
-
-        kit_free (buf);
-
-out:
-        return TRUE;
-}
-
-KitTest _test_file = {
-        "kit_file",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-file.h b/src/kit/kit-file.h
deleted file mode 100644
index 4fbd84d..0000000
--- a/src/kit/kit-file.h
+++ /dev/null
@@ -1,54 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-file.h : File utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_FILE_H
-#define KIT_FILE_H
-
-#include <sys/stat.h>
-#include <kit/kit.h>
-#ifdef HAVE_SOLARIS
-#include <sys/types.h>
-#endif
-
-KIT_BEGIN_DECLS
-
-kit_bool_t kit_file_get_contents (const char *path, char **out_contents, size_t *out_contents_size);
-kit_bool_t kit_file_set_contents (const char *path, mode_t mode, const char *contents, size_t contents_size);
-
-size_t _kit_get_num_fd (void);
-
-KIT_END_DECLS
-
-#endif /* KIT_FILE_H */
-
-
diff --git a/src/kit/kit-hash.c b/src/kit/kit-hash.c
deleted file mode 100644
index b4905e2..0000000
--- a/src/kit/kit-hash.c
+++ /dev/null
@@ -1,638 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-hash.c : Hash tables
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <kit/kit-memory.h>
-#include <kit/kit-hash.h>
-#include <kit/kit-test.h>
-
-/**
- * SECTION:kit-hash
- * @title: Hash tables
- * @short_description: Hash tables
- *
- * This class provides support for hash tables.
- **/
-
-struct _KitHashNode;
-
-typedef struct _KitHashNode {
-        void *key;
-        void *value;
-        struct _KitHashNode *next;
-} KitHashNode;
-
-
-/**
- * KitHash:
- *
- * The #KitHash structure not be accessed directly.
- */
-struct _KitHash
-{
-        int refcount;
-
-        int num_top_nodes;
-        KitHashNode **top_nodes;
-
-        KitHashFunc  hash_func;
-        KitEqualFunc key_equal_func;
-        KitCopyFunc  key_copy_func;
-        KitCopyFunc  value_copy_func;
-        KitFreeFunc  key_destroy_func;
-        KitFreeFunc  value_destroy_func;
-};
-
-/**
- * kit_hash_new:
- * @hash_func: The hash function to use
- * @key_equal_func: The function used to determine key equality
- * @key_copy_func: Function for copying keys or #NULL
- * @value_copy_func: Function for copying values or #NULL
- * @key_destroy_func: Function for freeing keys or #NULL
- * @value_destroy_func: Function for freeing values or #NULL
- *
- * Creates a new Hash Table.
- *
- * Returns: The new hash table. Returns #NULL on OOM.
- */
-KitHash *
-kit_hash_new (KitHashFunc  hash_func,
-              KitEqualFunc key_equal_func,
-              KitCopyFunc  key_copy_func,
-              KitCopyFunc  value_copy_func,
-              KitFreeFunc  key_destroy_func,
-              KitFreeFunc  value_destroy_func)
-{
-        KitHash *h;
-
-        kit_return_val_if_fail (hash_func != NULL, NULL);
-        kit_return_val_if_fail (key_equal_func != NULL, NULL);
-
-        h = kit_new0 (KitHash, 1);
-        if (h == NULL)
-                goto error;
-
-        h->refcount = 1;
-        h->hash_func = hash_func;
-        h->key_copy_func = key_copy_func;
-        h->value_copy_func = value_copy_func;
-        h->key_equal_func = key_equal_func;
-        h->key_destroy_func = key_destroy_func;
-        h->value_destroy_func = value_destroy_func;
-
-        h->num_top_nodes = 11; /* TODO: configurable? */
-        h->top_nodes = kit_new0 (KitHashNode*, h->num_top_nodes);
-        if (h->top_nodes == NULL)
-                goto error;
-
-        return h;
-error:
-        if (h != NULL)
-                kit_hash_unref (h);
-        return NULL;
-}
-
-/**
- * kit_hash_ref:
- * @hash: the hash table
- *
- * Increase reference count.
- *
- * Returns: the hash table
- */
-KitHash *
-kit_hash_ref (KitHash *hash)
-{
-        kit_return_val_if_fail (hash != NULL, hash);
-        hash->refcount++;
-        return hash;
-}
-
-/**
- * kit_hash_unref:
- * @hash: the hash table
- *
- * Decrease reference count. If reference count drop to zero the hash
- * table is freed.
- */
-void
-kit_hash_unref (KitHash *hash)
-{
-        kit_return_if_fail (hash != NULL);
-
-        hash->refcount--;
-        if (hash->refcount > 0) 
-                return;
-
-        if (hash->top_nodes != NULL) {
-                int n;
-
-                for (n = 0; n < hash->num_top_nodes; n++) {
-                        KitHashNode *node;
-                        KitHashNode *next;
-                        
-                        for (node = hash->top_nodes[n]; node != NULL; node = next) {
-                                if (hash->key_destroy_func != NULL)
-                                        hash->key_destroy_func (node->key);
-                                if (hash->value_destroy_func != NULL)
-                                        hash->value_destroy_func (node->value);
-                                next = node->next;
-                                kit_free (node);
-                        }
-                }
-        }
-
-        kit_free (hash->top_nodes);
-        kit_free (hash);
-}
-
-/**
- * kit_hash_insert:
- * @hash: the hash table
- * @key: key to insert
- * @value: value to insert
- *
- * Inserts a new key and value into a hash table. If the key already
- * exists in the hash table it's current value is replaced with the
- * new value.
- *
- * Returns: #TRUE unless OOM
- */
-kit_bool_t 
-kit_hash_insert (KitHash *hash,
-                 void *key,
-                 void *value)
-{
-        int bucket;
-        KitHashNode **nodep;
-        KitHashNode *node;
-        void *key_copy;
-        void *value_copy;
-
-        key_copy = NULL;
-        value_copy = NULL;
-        if (hash->key_copy_func != NULL) {
-                key_copy = hash->key_copy_func (key);
-                if (key_copy == NULL) {
-                        goto oom;
-                }
-        } else {
-                key_copy = key;
-        }
-        if (hash->value_copy_func != NULL) {
-                value_copy = hash->value_copy_func (value);
-                if (value_copy == NULL) {
-                        goto oom;
-                }
-        } else {
-                value_copy = value;
-        }
-
-        bucket = hash->hash_func (key) % hash->num_top_nodes;
-
-        nodep = & (hash->top_nodes [bucket]);
-        node = hash->top_nodes [bucket];
-        while (node != NULL) {
-                nodep = &(node->next);
-
-                if (hash->key_equal_func (key, node->key)) {
-                        /* replace the value */
-
-                        if (hash->key_destroy_func != NULL)
-                                hash->key_destroy_func (node->key);
-                        if (hash->value_destroy_func != NULL)
-                                hash->value_destroy_func (node->value);
-
-                        node->key = key_copy;
-                        node->value = value_copy;
-
-                        goto out;
-                } else {
-                        node = node->next;
-                }
-        }
-
-        node = kit_new0 (KitHashNode, 1);
-        if (node == NULL)
-                goto oom;
-
-        node->key = key_copy;
-        node->value = value_copy;
-        *nodep = node;
-
-out:
-        return TRUE;
-
-oom:
-        if (key_copy != NULL && hash->key_copy_func != NULL && hash->key_destroy_func != NULL)
-                hash->key_destroy_func (key_copy);
-
-        if (value_copy != NULL && hash->value_copy_func != NULL && hash->value_destroy_func != NULL)
-                hash->value_destroy_func (value_copy);
-
-        return FALSE;
-}
-
-/**
- * kit_hash_lookup:
- * @hash: the hash table
- * @key: key to look up
- * @found: if not #NULL, will return #TRUE only if the key was found in the hash table
- *
- * Look up a value in the hash table.
- *
- * Returns: the value; caller shall not free/unref this value
- */
-void *
-kit_hash_lookup (KitHash *hash, void *key, kit_bool_t *found)
-{
-        int bucket;
-        void *value;
-        KitHashNode *node;
-
-        value = NULL;
-        if (found != NULL)
-                *found = FALSE;
-
-        bucket = hash->hash_func (key) % hash->num_top_nodes;
-
-        node = hash->top_nodes [bucket];
-        while (node != NULL) {
-                if (hash->key_equal_func (key, node->key)) {
-                        /* got it */
-
-                        value = node->value;
-                        if (found != NULL)
-                                *found = TRUE;
-                        goto out;
-                } else {
-                        node = node->next;
-                }
-        }
-
-out:
-        return value;
-}
-
-
-/**
- * kit_hash_foreach:
- * @hash: the hash table
- * @cb: callback function
- * @user_data: user data
- *
- * Iterate over all elements in a hash table
- *
- * Returns: #TRUE only if the callback short-circuited the iteration
- */
-kit_bool_t
-kit_hash_foreach (KitHash *hash, KitHashForeachFunc cb, void *user_data)
-{
-        int n;
-
-        kit_return_val_if_fail (hash != NULL, FALSE);
-        kit_return_val_if_fail (cb != NULL, FALSE);
-
-        for (n = 0; n < hash->num_top_nodes; n++) {
-                KitHashNode *node;
-
-                for (node = hash->top_nodes[n]; node != NULL; node = node->next) {
-                        if (cb (node->key, node->value, user_data, hash))
-                                return TRUE;
-                }
-        }
-
-        return FALSE;
-}
-
-/**
- * kit_hash_foreach_remove:
- * @hash: the hash table
- * @cb: callback function
- * @user_data: user data
- *
- * Iterate over all elements in a hash table. If @cb returns %TRUE,
- * the element will be removed.
- *
- * Returns: Number of key/value pairs removed
- */
-size_t
-kit_hash_foreach_remove (KitHash *hash, KitHashForeachFunc cb, void *user_data)
-{
-        int n;
-        size_t num_rem;
-
-        kit_return_val_if_fail (hash != NULL, FALSE);
-        kit_return_val_if_fail (cb != NULL, FALSE);
-
-        num_rem = 0;
-
-        for (n = 0; n < hash->num_top_nodes; n++) {
-                KitHashNode *node;
-                KitHashNode *node_next;
-                KitHashNode **prev_node_next;
-
-                prev_node_next = &(hash->top_nodes[n]);
-
-                for (node = hash->top_nodes[n]; node != NULL; node = node_next) {
-                        node_next = node->next;
-
-                        if (cb (node->key, node->value, user_data, hash)) {
-
-                                if (hash->key_destroy_func != NULL)
-                                        hash->key_destroy_func (node->key);
-                                if (hash->value_destroy_func != NULL)
-                                        hash->value_destroy_func (node->value);
-                                kit_free (node);
-
-                                *prev_node_next = node_next;                                
-                                num_rem++;
-                        } else {
-                                prev_node_next = &(node->next);
-                        }
-                }
-        }
-
-        return num_rem;
-}
-
-
-/**
- * kit_hash_direct_hash_func:
- * @key: the key
- *
- * Converts a pointer to a hash value.
- *
- * Returns: a hash value corresponding to the key
- */
-uint32_t 
-kit_hash_direct_hash_func (const void *key)
-{
-        return (uint32_t) key;
-}
-
-/**
- * kit_hash_direct_equal_func:
- * @v1: first value
- * @v2: second value
- *
- * Compares two pointers and return #TRUE if they are equal (same address).
- *
- * Returns: #TRUE only if the values are equal
- */
-kit_bool_t
-kit_hash_direct_equal_func (const void *v1, const void *v2)
-{
-        return v1 == v2;
-}
-
-/**
- * kit_hash_str_hash_func:
- * @key: the key
- *
- * Converts a string to a hash value.
- *
- * Returns: a hash value corresponding to the key
- */
-uint32_t
-kit_hash_str_hash_func (const void *key)
-{
-        const char *p;
-        uint32_t hash;
-
-        hash = 0;
-        for (p = key; *p != '\0'; p++)
-                hash = hash * 617 ^ *p;
-
-        return hash;
-}
-
-/**
- * kit_hash_str_equal_func:
- * @v1: first value
- * @v2: second value
- *
- * Compares two strings and return #TRUE if they are equal.
- *
- * Returns: #TRUE only if the values are equal
- */
-kit_bool_t
-kit_hash_str_equal_func (const void *v1, const void *v2)
-{
-        return strcmp (v1, v2) == 0;
-}
-
-/**
- * kit_hash_str_copy:
- * @p: void pointer to string
- *
- * Similar to kit_strdup() except for types.
- *
- * Returns: a void pointer to a copy or #NULL on OOM
- */
-void *
-kit_hash_str_copy (const void *p)
-{
-        return (void *) kit_strdup ((const char *) p);
-}
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_it1 (void *key, void *value, void *user_data, KitHash *hash)
-{
-        int *count = (int *) user_data;
-        *count += 1;
-        return FALSE;
-}
-
-static kit_bool_t
-_it2 (void *key, void *value, void *user_data, KitHash *hash)
-{
-        int *count = (int *) user_data;
-        *count += 1;
-        return TRUE;
-}
-
-static kit_bool_t
-_it_sum (void *key, void *value, void *user_data, KitHash *hash)
-{
-        int *count = (int *) user_data;
-        *count += (int) value;
-        return FALSE;
-}
-
-static kit_bool_t
-_it_rem (void *key, void *value, void *user_data, KitHash *hash)
-{
-        if (strlen ((char *) key) > 4)
-                return TRUE;
-        else
-                return FALSE;
-}
-
-static kit_bool_t
-_run_test (void)
-{
-        int count;
-        KitHash *h;
-        kit_bool_t found;
-
-        /* string hash tables */
-        if ((h = kit_hash_new (kit_hash_str_hash_func, kit_hash_str_equal_func, 
-                                  kit_hash_str_copy, kit_hash_str_copy,
-                                  kit_free, kit_free)) != NULL) {
-                int n;
-                char *key;
-                char *value;
-                char *test_data[] = {"key1", "val1",
-                                     "key2", "val2",
-                                     "key3", "val3",
-                                     "key4", "val4",
-                                     "key5", "val5",
-                                     "key6", "val6",
-                                     "key7", "val7",
-                                     "key8", "val8",
-                                     "key9", "val9",
-                                     "key10", "val10",
-                                     "key11", "val11",
-                                     "key12", "val12",
-                                     NULL};
-
-                /* first insert the values */
-                for (n = 0; test_data [n*2] != NULL; n++) {
-                        if (!kit_hash_insert (h, test_data [n*2], test_data [n*2 + 1])) {
-                                goto oom;
-                        }
-                }
-
-                /* then check that we can look them up */
-                for (n = 0; test_data [n*2] != NULL; n++) {
-                        key = test_data [n*2];
-                        value = kit_hash_lookup (h, test_data[n*2], &found);
-
-                        kit_assert (found && strcmp (value, test_data[n*2 + 1]) == 0);
-                }
-
-                /* lookup unknown key */
-                kit_assert (kit_hash_lookup (h, "unknown", &found) == NULL && !found);
-
-                /* replace key */
-                if (key != NULL) {
-                        if (kit_hash_insert (h, "key1", "val1-replaced")) {
-                                /* check for replaced value */
-                                value = kit_hash_lookup (h, "key1", &found);
-                                kit_assert (found && value != NULL && strcmp (value, "val1-replaced") == 0);
-                        }
-                }
-
-                count = 0;
-                kit_assert (kit_hash_foreach (h, _it1, &count) == FALSE);
-                kit_assert (count == ((sizeof (test_data) / sizeof (char *) - 1) / 2));
-                count = 0;
-                kit_assert (kit_hash_foreach (h, _it2, &count) == TRUE);
-                kit_assert (count == 1);
-                
-                kit_hash_ref (h);
-                kit_hash_unref (h);
-        oom:
-
-                kit_hash_unref (h);
-        }
-
-        /* direct hash tables */
-        if ((h = kit_hash_new (kit_hash_direct_hash_func, kit_hash_direct_equal_func, 
-                                  NULL, NULL, 
-                                  NULL, NULL)) != NULL) {
-                if (kit_hash_insert (h, h, h)) {
-                        kit_assert ((kit_hash_lookup (h, h, &found) == h) && found);
-                        if (kit_hash_insert (h, h, NULL)) {
-                                kit_assert (kit_hash_lookup (h, h, &found) == NULL && found);
-                        }
-                }
-                kit_hash_unref (h);
-        }
-
-        /* remove */
-        if ((h = kit_hash_new (kit_hash_str_hash_func, 
-                               kit_hash_str_equal_func, 
-                               kit_hash_str_copy, 
-                               NULL,
-                               kit_free, 
-                               NULL)) != NULL) {        
-                char *test_data[] = {"key1",
-                                     "key2b",
-                                     "key3",
-                                     "key4",
-                                     "key5b",
-                                     "key6b",
-                                     "key7",
-                                     "key8",
-                                     NULL};
-                int n;
-                int count;
-
-                /* first insert the values */
-                for (n = 0; test_data [n] != NULL; n++) {
-                        if (!kit_hash_insert (h, test_data [n], (void *) (n + 1))) {
-                                goto oom;
-                        }
-                }
-
-                count = 0;
-                kit_assert (kit_hash_foreach (h, _it_sum, &count) == FALSE);
-                kit_assert (count == 1+2+3+4+5+6+7+8);
-
-                kit_assert (kit_hash_foreach_remove (h, _it_rem, &count) == 3);
-                count = 0;
-                kit_assert (kit_hash_foreach (h, _it_sum, &count) == FALSE);
-                kit_assert (count == 1+3+4+7+8);
-
-                kit_hash_unref (h);
-        }
-
-
-        return TRUE;
-}
-
-KitTest _test_hash = {
-        "kit_hash",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-hash.h b/src/kit/kit-hash.h
deleted file mode 100644
index 608c4d5..0000000
--- a/src/kit/kit-hash.h
+++ /dev/null
@@ -1,144 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-hash.h : Hash tables
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_HASH_H
-#define KIT_HASH_H
-
-#include <stdint.h>
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-struct _KitHash;
-typedef struct _KitHash KitHash;
-
-/**
- * KitHashFunc:
- * @key: a key
- *
- * The function is passed a key and should return a hash value. The
- * functions kit_hash_direct_hash_func() and
- * kit_hash_str_hash_func() provide hash functions which can be
- * used when the key is a pointer and an char* respectively.
- *
- * Returns: the hash value corresponding to the key
- */
-typedef uint32_t (*KitHashFunc) (const void *key);
-
-/**
- * KitEqualFunc:
- * @key1: first key
- * @key2: second key
- *
- * Determines if two keys are equal. The functions
- * kit_hash_direct_equal_func() and kit_hash_str_equal_func()
- * provide equality functions which can be used when the key is a
- * pointer and an char* respectively.
- *
- * Returns: #TRUE iff the keys are equal
- */
-typedef kit_bool_t (*KitEqualFunc) (const void *key1, const void *key2);
-
-/**
- * KitFreeFunc:
- * @p: pointer
- *
- * Specifies the type of function which is called when a data element
- * is destroyed. It is passed the pointer to the data element and
- * should free any memory and resources allocated for it. The function
- * p_free() or any of the object unref functions can be passed here.
- */
-typedef void (*KitFreeFunc) (void *p);
-
-/**
- * KitCopyFunc:
- * @p: pointer
- *
- * Specifies the type of function which is called when a data element
- * is to be cloned or reffed. It is passed the pointer to the data
- * element and should return a new pointer to a reffed or cloned
- * object. The function kit_hash_str_copy() or any of the object
- * ref functions can be passed here.
- *
- * Returns: A copy or ref of the object in question
- */
-typedef void *(*KitCopyFunc) (const void *p);
-
-/**
- * KitHashForeachFunc:
- * @key: key
- * @value: value
- * @user_data: user data passed to kit_hash_foreach()
- * @hash: the hash table
- *
- * Type signature for callback function used in kit_hash_foreach().
- *
- * Returns: Return #TRUE to short-circuit, e.g. stop the iteration.
- */
-typedef kit_bool_t (*KitHashForeachFunc) (void *key,
-                                          void *value,
-                                          void *user_data,
-                                          KitHash *hash);
-
-
-KitHash *kit_hash_new (KitHashFunc  hash_func,
-                       KitEqualFunc key_equal_func,
-                       KitCopyFunc  key_copy_func,
-                       KitCopyFunc  value_copy_func,
-                       KitFreeFunc  key_destroy_func,
-                       KitFreeFunc  value_destroy_func);
-
-KitHash    *kit_hash_ref   (KitHash *hash);
-void       kit_hash_unref (KitHash *hash);
-
-kit_bool_t  kit_hash_insert (KitHash *hash, void *key, void *value);
-
-void       *kit_hash_lookup (KitHash *hash, void *key, kit_bool_t *found);
-
-kit_bool_t  kit_hash_foreach (KitHash *hash, KitHashForeachFunc cb, void *user_data);
-
-size_t      kit_hash_foreach_remove (KitHash *hash, KitHashForeachFunc cb, void *user_data);
-
-
-uint32_t     kit_hash_direct_hash_func  (const void *key);
-kit_bool_t   kit_hash_direct_equal_func (const void *v1, const void *v2);
-
-uint32_t     kit_hash_str_hash_func     (const void *key);
-kit_bool_t   kit_hash_str_equal_func    (const void *v1, const void *v2);
-void        *kit_hash_str_copy          (const void *p);
-
-KIT_END_DECLS
-
-#endif /* KIT_HASH_H */
-
-
diff --git a/src/kit/kit-lib.c b/src/kit/kit-lib.c
deleted file mode 100644
index a05cc11..0000000
--- a/src/kit/kit-lib.c
+++ /dev/null
@@ -1,136 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-lib.c : General utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-
-#include <kit/kit.h>
-#include "kit-test.h"
-
-#ifndef HAVE_GETLINE
-ssize_t
-kit_getline (char **lineptr, size_t *n, FILE *stream)
-{
-  char *line, *p;
-  long size, copy;
-
-  if (lineptr == NULL || n == NULL) {
-          errno = EINVAL;
-          return (ssize_t) -1;
-  }
-
-  if (ferror (stream))
-          return (ssize_t) -1;
-
-  /* Make sure we have a line buffer to start with.  */
-  if (*lineptr == NULL || *n < 2) /* !seen and no buf yet need 2 chars.  */ {
-#ifndef        MAX_CANON
-#define        MAX_CANON        256
-#endif
-          if (!*lineptr)
-                  line = (char *) malloc (MAX_CANON);
-          else
-                  line = (char *) realloc (*lineptr, MAX_CANON);
-          if (line == NULL)
-                  return (ssize_t) -1;
-          *lineptr = line;
-          *n = MAX_CANON;
-  }
-
-  line = *lineptr;
-  size = *n;
-
-  copy = size;
-  p = line;
-
-  while (1) {
-          long len;
-
-          while (--copy > 0) {
-                  int c = getc (stream);
-
-                  if (c == EOF)
-                          goto lose;
-                  else if ((*p++ = c) == '\n')
-                          goto win;
-          }
-
-          /* Need to enlarge the line buffer.  */
-          len = p - line;
-          size *= 2;
-          line = (char *) realloc (line, size);
-          if (line == NULL)
-                  goto lose;
-          *lineptr = line;
-          *n = size;
-          p = line + len;
-          copy = size - len;
-  }
-
-lose:
-  if (p == *lineptr)
-          return (ssize_t) -1;
-
-  /* Return a partial line since we got an error in the middle.  */
-win:
-  *p = '\0';
-  return p - *lineptr;
-}
-#else
-ssize_t
-kit_getline (char **lineptr, size_t *n, FILE *f)
-{
-        return getline (lineptr, n, f);
-}
-#endif
-
-#ifndef HAVE_CLEARENV
-extern char **environ;
-
-int
-kit_clearenv (void)
-{
-        if (environ != NULL)
-                environ[0] = NULL;
-        return 0;
-}
-#else
-int
-kit_clearenv (void)
-{
-        return clearenv ();
-}
-#endif
diff --git a/src/kit/kit-lib.h b/src/kit/kit-lib.h
deleted file mode 100644
index 523e096..0000000
--- a/src/kit/kit-lib.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-string.h : General utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_LIB_H
-#define KIT_LIB_H
-
-#include <sys/types.h>
-#include <stdio.h>
-
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-ssize_t kit_getline 	(char **lineptr, size_t *n, FILE *f);
-
-int kit_clearenv 	(void);
-
-KIT_END_DECLS
-
-#endif /* KIT_LIB_H */
-
-
diff --git a/src/kit/kit-list.c b/src/kit/kit-list.c
deleted file mode 100644
index d3d5367..0000000
--- a/src/kit/kit-list.c
+++ /dev/null
@@ -1,348 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-list.c : Doubly-linked lists
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <kit/kit.h>
-#include "kit-test.h"
-
-/**
- * SECTION:kit-list
- * @title: Doubly-linked lists
- * @short_description: Doubly-linked lists
- *
- * This class provides support for doubly-linked lists.
- **/
-
-/**
- * kit_list_append:
- * @list: existing list or #NULL to create a new list
- * @data: data to append to the list
- *
- * Append an entry to a list.
- *
- * Returns: the head of the new list or #NULL on OOM
- */
-KitList *
-kit_list_append (KitList *list, void *data)
-{
-        KitList *l;
-        KitList *j;
-        
-        for (j = list; j != NULL && j->next != NULL; j = j->next)
-                ;
-        
-        l = kit_new0 (KitList, 1);
-        if (l == NULL)
-                goto oom;
-
-        l->data = data;
-        l->prev = j;
-        
-        if (j != NULL) {
-                j->next = l;
-        } else {
-                list = l;
-        }
-
-        return list;
-oom:
-        return NULL;
-}
-
-/**
- * kit_list_copy:
- * @list: existing list
- *
- * Makes a copy of a list. It is not a deep copy.
- *
- * Returns: A copy of the new list or #NULL on OOM. Free with kit_list_free().
- **/
-KitList *
-kit_list_copy (KitList *list)
-{
-        KitList *l;
-        KitList *l2;
-        KitList *j;
-
-        l = NULL;
-        for (j = list; j != NULL; j = j->next) {
-                /* TODO: prepend, then reverse */
-                l2 = kit_list_append (l, j->data);
-                if (l2 == NULL)
-                        goto oom;
-                l = l2;
-        }
-
-        return l;
-oom:
-        kit_list_free (l);
-        return NULL;
-}
-
-/**
- * kit_list_prepend:
- * @list: existing list or #NULL to create a new list
- * @data: data to prepend to the list
- *
- * Prepend an entry to a list.
- *
- * Returns: the head of the new list or #NULL on OOM
- */
-KitList *
-kit_list_prepend (KitList *list, void *data)
-{
-        KitList *l;
-
-        l = kit_new0 (KitList, 1);
-        if (l == NULL)
-                goto oom;
-
-        l->next = list;
-        l->data = data;
-        if (list != NULL) {
-                list->prev = l;
-        }
-
-oom:
-        return l;
-}
-
-/**
- * kit_list_delete_link:
- * @list: existing list, cannot be #NULL
- * @link: link to delete, cannot be #NULL
- *
- * Delete a link from a list.
- *
- * Returns: the new head of the list or #NULL if the list is empty after deletion.
- */
-KitList *
-kit_list_delete_link (KitList *list, KitList *link)
-{
-        KitList *ret;
-
-        kit_return_val_if_fail (list != NULL, NULL);
-        kit_return_val_if_fail (link != NULL, NULL);
-
-        if (list == link)
-                ret = link->next;
-        else
-                ret = list;
-
-        if (link->prev != NULL) {
-                link->prev->next = link->next;
-        }
-
-        if (link->next != NULL) {
-                link->next->prev = link->prev;
-        }
-
-        kit_free (link);
-
-        return ret;
-}
-
-/**
- * kit_list_free:
- * @list: the list
- *
- * Frees all links in a list
- */
-void
-kit_list_free (KitList *list)
-{
-        KitList *l;
-        KitList *j;
-
-        for (l = list; l != NULL; l = j) {
-                j = l->next;
-                kit_free (l);
-        }
-}
-
-/**
- * kit_list_length:
- * @list: the list
- *
- * Compute the length of a list.
- *
- * Returns: Number of entries in list
- */
-size_t
-kit_list_length (KitList *list)
-{
-        ssize_t n;
-        KitList *l;
-
-        n = 0;
-        for (l = list; l != NULL; l = l->next)
-                n++;
-
-        return n;
-}
-
-/**
- * kit_list_foreach:
- * @list: the list
- * @func: callback function
- * @user_data: user data to pass to callback
- *
- * Iterate over all entries in a list.
- *
- * Returns: #TRUE only if the callback short-circuited the iteration
- */
-kit_bool_t 
-kit_list_foreach (KitList *list, KitListForeachFunc func, void *user_data)
-{
-        KitList *l;
-
-        kit_return_val_if_fail (list != NULL, FALSE);
-        kit_return_val_if_fail (func != NULL, FALSE);
-
-        for (l = list; l != NULL; l = l->next) {
-                if (func (l->data, user_data, list))
-                        return TRUE;
-        }
-        
-        return FALSE;
-}
-
-
-#ifdef KIT_BUILD_TESTS
-
-typedef struct {
-        int num;
-        int result;
-} _Closure;
-
-static kit_bool_t 
-_sum (void *data, void *user_data, KitList *list)
-{
-        _Closure *c = (_Closure*) user_data;
-
-        c->result += ((int) data) * (c->num + 1);
-        c->num += 1;
-
-        return FALSE;
-}
-
-static kit_bool_t 
-_sum2 (void *data, void *user_data, KitList *list)
-{
-        _Closure *c = (_Closure*) user_data;
-
-        if (c->num == 2)
-                return TRUE;
-
-        c->result += ((int) data) * (c->num + 1);
-        c->num += 1;
-
-        return FALSE;
-}
-
-static kit_bool_t
-_run_test (void)
-{
-        _Closure c;
-        int items[] = {1, 2, 3, 4, 5};
-        unsigned int num_items = sizeof (items) / sizeof (int);
-        unsigned int n;
-        KitList *l;
-        KitList *j;
-
-        l = NULL;
-        for (n = 0; n < num_items; n++) {
-                j = l;
-                l = kit_list_prepend (l, (void *) items[n]);
-                if (l == NULL)
-                        goto oom;
-        }
-
-        kit_assert (kit_list_length (l) == num_items);
-        c.num = 0;
-        c.result = 0;
-        kit_list_foreach (l, _sum, &c);
-        kit_assert (c.result == 1*5 + 2*4 + 3*3 + 4*2 + 5*1);
-
-        c.num = 0;
-        c.result = 0;
-        kit_list_foreach (l, _sum2, &c);
-        kit_assert (c.result == 1*5 + 2*4);
-
-        l = kit_list_delete_link (l, l);
-        kit_assert (kit_list_length (l) == num_items - 1);
-        c.num = 0;
-        c.result = 0;
-        kit_list_foreach (l, _sum, &c);
-        kit_assert (c.result == 1*4 + 2*3 + 3*2 + 4*1);
-
-        l = kit_list_delete_link (l, l->next);
-        kit_assert (kit_list_length (l) == num_items - 2);
-        c.num = 0;
-        c.result = 0;
-        kit_list_foreach (l, _sum, &c);
-        kit_assert (c.result == 1*4 + 2*2 + 3*1);
-
-        kit_list_free (l);
-
-        l = NULL;
-        for (n = 0; n < num_items; n++) {
-                j = l;
-                l = kit_list_append (l, (void *) items[n]);
-                if (l == NULL)
-                        goto oom;
-        }
-
-        c.num = 0;
-        c.result = 0;
-        kit_list_foreach (l, _sum, &c);
-        kit_assert (c.result == 1*1 + 2*2 + 3*3 + 4*4 + 5*5);
-
-        kit_list_free (l);
-
-        return TRUE;
-oom:
-        kit_list_free (j);
-        return TRUE;
-}
-
-KitTest _test_list = {
-        "kit_list",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-list.h b/src/kit/kit-list.h
deleted file mode 100644
index 1b22ae2..0000000
--- a/src/kit/kit-list.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-list.h : Doubly-linked list
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_LIST_H
-#define KIT_LIST_H
-
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-struct _KitList;
-typedef struct _KitList KitList;
-
-/**
- * KitList:
- * @data: the value passed in kit_list_append() and kit_list_prepend()
- * @next: the next element in the list or #NULL if this is the last element
- * @prev: the previous element in the list or #NULL if this is the last element
- *
- * Public members of the #KitList data structure
- */
-struct _KitList {
-        void *data;
-        KitList *next;
-        KitList *prev;
-};
-
-/**
- * KitListForeachFunc:
- * @data: data of link entry
- * @user_data: user data passed to kit_list_foreach()
- * @list: the list
- *
- * Type signature for callback function used in kit_list_foreach().
- *
- * Returns: Return #TRUE to short-circuit, e.g. stop the iteration.
- */
-typedef kit_bool_t (*KitListForeachFunc) (void *data,
-                                          void *user_data,
-                                          KitList *list);
-
-KitList    *kit_list_append      (KitList *list, void *data);
-KitList    *kit_list_prepend     (KitList *list, void *data);
-void        kit_list_free        (KitList *list);
-KitList    *kit_list_delete_link (KitList *list, KitList *link);
-
-size_t      kit_list_length      (KitList *list);
-kit_bool_t  kit_list_foreach     (KitList *list, KitListForeachFunc func, void *user_data);
-KitList    *kit_list_copy        (KitList *list);
-
-
-KIT_END_DECLS
-
-#endif /* KIT_LIST_H */
-
-
diff --git a/src/kit/kit-memory.c b/src/kit/kit-memory.c
deleted file mode 100644
index bf79fea..0000000
--- a/src/kit/kit-memory.c
+++ /dev/null
@@ -1,422 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-memory.c : Memory management
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <string.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-
-#ifdef BUILT_R_DYNAMIC
-#include <execinfo.h>
-#endif
-
-#include <kit/kit-memory.h>
-#include <kit/kit-test.h>
-
-/**
- * SECTION:kit-memory
- * @title: Memory management
- * @short_description: Memory management
- *
- * Functions used for memory management.
- **/
-
-#ifdef KIT_BUILD_TESTS
-
-static int _cur_allocs = 0;
-static int _total_allocs = 0;
-static int _fail_nth = -1;
-
-
-#if defined(KIT_BUILD_TESTS) && defined(BUILT_R_DYNAMIC)
-typedef struct _KitAllocationEntry {
-        const void *memory;
-        void *backtrace[100];
-        int backtrace_size;
-        struct _KitAllocationEntry *next;
-} KitAllocationEntry;
-
-static KitAllocationEntry *alloc_list_head = NULL;
-#endif
-
-void 
-_kit_memory_reset (void)
-{
-        _cur_allocs = 0;
-        _total_allocs = 0;
-        _fail_nth = -1;
-
-#if defined(KIT_BUILD_TESTS) && defined(BUILT_R_DYNAMIC)
-        /* TODO: free existing allocs */
-        alloc_list_head = NULL;
-#endif
-}
-
-int 
-_kit_memory_get_current_allocations (void)
-{
-        return _cur_allocs;
-}
-
-int 
-_kit_memory_get_total_allocations (void)
-{
-        return _total_allocs;
-}
-
-void 
-_kit_memory_fail_nth_alloc (int number)
-{
-        _fail_nth = number;
-}
-
-static inline void
-_alloc_add (const void *memory)
-{
-#if defined(KIT_BUILD_TESTS) && defined(BUILT_R_DYNAMIC)
-        KitAllocationEntry *entry;
-
-        entry = malloc (sizeof (KitAllocationEntry));
-        entry->memory = memory;
-        entry->backtrace_size = backtrace (entry->backtrace, 100);
-        entry->next = alloc_list_head;
-
-        alloc_list_head = entry;
-#endif
-}
-
-static inline void
-_alloc_remove (const void *memory)
-{
-#if defined(KIT_BUILD_TESTS) && defined(BUILT_R_DYNAMIC)
-        KitAllocationEntry *l;
-        KitAllocationEntry **prev;
-
-        prev = &alloc_list_head;
-        for (l = alloc_list_head; l != NULL; l = l->next) {
-                if (l->memory == memory) {
-                        *prev = l->next;
-                        free (l);
-                        break;
-                }
-
-                prev = &(l->next);
-        }
-#endif
-}
-
-void
-_kit_memory_print_outstanding_allocations (void)
-{
-#if defined(KIT_BUILD_TESTS) && defined(BUILT_R_DYNAMIC)
-        KitAllocationEntry *l;
-        for (l = alloc_list_head; l != NULL; l = l->next) {
-                int i;
-                char **syms;
-
-                syms = backtrace_symbols (l->backtrace, l->backtrace_size);
-
-                i = 0;
-                while (i < l->backtrace_size)
-                {
-                        fprintf (stderr, "  %s\n", syms[i]);
-                        ++i;
-                }
-                fprintf (stderr, "\n");
-                fflush (stderr);
-
-                free (syms);
-        }
-#endif
-}
-
-
-/**
- * kit_malloc:
- * @bytes: number of 8-bit bytes to allocate
- *
- * Allocate memory
- *
- * Returns: memory location or #NULL on OOM. Free with kit_free().
- */
-void *
-kit_malloc (size_t bytes)
-{
-        void *p;
-
-        if (_fail_nth != -1 && _total_allocs == _fail_nth) {
-                errno = ENOMEM;
-                _total_allocs++;
-
-                //fprintf (stderr, "  Failing alloc @\n");
-                //kit_print_backtrace ();
-
-                return NULL;
-        }
-
-        p = malloc (bytes);
-
-        if (p != NULL)  {
-                _cur_allocs++;
-                _total_allocs++;
-                _alloc_add (p);
-        }
-
-        return p;
-}
-
-/**
- * kit_malloc0:
- * @bytes: number of 8-bit bytes to allocate
- *
- * Allocate memory and zero it.
- *
- * Returns: memory location or #NULL on OOM. Free with kit_free().
- */
-void *
-kit_malloc0 (size_t bytes)
-{
-        void *p;
-
-        if (_fail_nth != -1 && _total_allocs == _fail_nth) {
-                errno = ENOMEM;
-                return NULL;
-        }
-
-        p = calloc (1, bytes);
-
-        if (p != NULL)  {
-                _cur_allocs++;
-                _total_allocs++;
-                _alloc_add (p);
-        }
-
-        return p;
-}
-
-/**
- * kit_realloc:
- * @memory: memory previously allocated
- * @bytes: new size
- *
- * Reallocate memory; like realloc(3).
- *
- * Returns: memory location or #NULL on OOM. Free with kit_free().
- */
-void *
-kit_realloc (void *memory, size_t bytes)
-{
-        void *p;
-
-        if (memory == NULL)
-                return kit_malloc (bytes);
-
-        if (bytes == 0) {
-                kit_free (memory);
-                return memory;
-        }
-
-        if (_fail_nth != -1 && _total_allocs == _fail_nth) {
-                errno = ENOMEM;
-                return NULL;
-        }
-
-        _alloc_remove (p);
-        p = realloc (memory, bytes);
-        if (p != NULL)
-                _alloc_add (p);
-
-        return p;
-}
-
-/**
- * kit_free:
- * @memory: pointer to memory allocated with kit_malloc() + friends
- *
- * Free memory allocated by kit_malloc() + friends.
- */
-void
-kit_free (void *memory)
-{
-        free (memory);
-        if (memory != NULL) {
-                _alloc_remove (memory);
-                _cur_allocs--;
-        }
-}
-
-/*--------------------------------------------------------------------------------------------------------------*/
-#else
-/*--------------------------------------------------------------------------------------------------------------*/
-
-void *
-kit_malloc (size_t bytes)
-{
-        return malloc (bytes);
-}
-
-void *
-kit_malloc0 (size_t bytes)
-{
-        return calloc (1, bytes);
-}
-
-void *
-kit_realloc (void *memory, size_t bytes)
-{
-        return realloc (memory, bytes);
-}
-
-void
-kit_free (void *memory)
-{
-        free (memory);
-}
-
-void 
-_kit_memory_reset (void)
-{
-}
-
-int 
-_kit_memory_get_current_allocations (void)
-{
-        return -1;
-}
-
-int 
-_kit_memory_get_total_allocations (void)
-{
-        return -1;
-}
-
-void 
-_kit_memory_fail_nth_alloc (int number)
-{
-}
-
-void
-_kit_memory_print_outstanding_allocations (void)
-{
-}
-
-#endif /* KIT_BUILD_TESTS */
-
-/* There's probably a better place for this function ... */
-
-/**
- * kit_print_backtrace:
- *
- * Print a back trace if built with -rdynamic or similar.
- */
-void 
-kit_print_backtrace (void)
-{
-#ifdef BUILT_R_DYNAMIC
-        void *bt[500];
-        int bt_size;
-        int i;
-        char **syms;
-        
-        bt_size = backtrace (bt, 500);
-        
-        syms = backtrace_symbols (bt, bt_size);
-        
-        i = 0;
-        while (i < bt_size)
-        {
-                fprintf (stderr, "  %s\n", syms[i]);
-                ++i;
-        }
-        fprintf (stderr, "\n");
-        fflush (stderr);
-
-        free (syms);
-#else
-        fprintf (stderr, " Not built with -rdynamic so unable to print a backtrace\n");
-#endif
-}
-
-
-
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_run_test (void)
-{
-        int n;
-        char *p;
-        char *p2;
-
-        if ((p = kit_malloc (1000)) != NULL) {
-                for (n = 0; n < 1000; n++)
-                        p[n] = n;
-
-                p2 = kit_realloc (p, 2000);
-                if (p2 != NULL) {
-                        p = p2;
-
-                        for (n = 0; n < 2000; n++)
-                                p[n] = n;
-                }
-
-                kit_free (p);
-        }
-
-        if ((p = kit_realloc (NULL, 1000)) != NULL) {
-                for (n = 0; n < 1000; n++)
-                        p[n] = n;
-
-                kit_realloc (p, 0);
-        }
-
-        if ((p = kit_malloc0 (1000)) != NULL) {
-                for (n = 0; n < 1000; n++)
-                        kit_assert (p[n] == '\0');
-                kit_free (p);
-        }
-        
-        return TRUE;
-}
-
-KitTest _test_memory = {
-        "kit_memory",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-memory.h b/src/kit/kit-memory.h
deleted file mode 100644
index fae2da1..0000000
--- a/src/kit/kit-memory.h
+++ /dev/null
@@ -1,80 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-memory.h : Memory management
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_MEMORY_H
-#define KIT_MEMORY_H
-
-#include <stdarg.h>
-#include <stdlib.h>
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-void *kit_malloc  (size_t bytes);
-void *kit_malloc0 (size_t bytes);
-void *kit_realloc (void *memory, size_t bytes);
-void  kit_free    (void *memory);
-
-/**
- * kit_new:
- * @type: the type of object to allocate
- * @count: number of objects to allocate
- *
- * Allocate memory for @count structures of type @type.
- *
- * Returns: Allocated memory, cast to a pointer of #type or #NULL on OOM.
- */
-#define kit_new(type, count)  ((type*)kit_malloc (sizeof (type) * (count)));
-
-/**
- * kit_new0:
- * @type: the type of object to allocate
- * @count: number of objects to allocate
- *
- * Allocate zeroed memory for @count structures of type @type.
- *
- * Returns: Allocated memory, cast to a pointer of #type or #NULL on OOM.
- */
-#define kit_new0(type, count) ((type*)kit_malloc0 (sizeof (type) * (count)));
-
-void  _kit_memory_reset (void);
-int   _kit_memory_get_current_allocations (void);
-int   _kit_memory_get_total_allocations (void);
-void  _kit_memory_fail_nth_alloc (int number);
-void  _kit_memory_print_outstanding_allocations (void);
-
-KIT_END_DECLS
-
-#endif /* KIT_MEMORY_H */
-
-
diff --git a/src/kit/kit-message.c b/src/kit/kit-message.c
deleted file mode 100644
index ad09039..0000000
--- a/src/kit/kit-message.c
+++ /dev/null
@@ -1,113 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-message.c : Message utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <sys/types.h>
-#include <unistd.h>
-
-#include <kit/kit.h>
-#include "kit-test.h"
-
-/**
- * SECTION:kit-message
- * @title: Message utilities
- * @short_description: Message utilities
- *
- * Various message and logging utilities.
- **/
-
-/**
- * kit_debug:
- * @format: printf(3) style format string
- * @...: the parameters to insert into @format
- *
- * Outputs a debug message on stdout.
- */
-void 
-kit_debug (const char *format, ...)
-{
-        va_list args;
-        char buf[1024];
-
-        kit_return_if_fail (format != NULL);
-
-        va_start (args, format);
-        vsnprintf (buf, sizeof (buf), format, args);
-        va_end (args);
-
-        printf ("[INFO %5d] %s\n", getpid (), buf);
-}
-
-/**
- * kit_warning:
- * @format: printf(3) style format string
- * @...: the parameters to insert into @format
- *
- * Outputs a warning message on stderr.
- */
-void 
-kit_warning (const char *format, ...)
-{
-        va_list args;
-        char buf[1024];
-
-        kit_return_if_fail (format != NULL);
-
-        va_start (args, format);
-        vsnprintf (buf, sizeof (buf), format, args);
-        va_end (args);
-
-        fprintf (stderr, "[WARN %5d] %s\n", getpid (), buf);
-}
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_run_test (void)
-{
-        kit_debug ("Debug %d", 42);
-        kit_warning ("Warning %d %s", 42, "foo");
-        return TRUE;
-}
-
-KitTest _test_message = {
-        "kit_message",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-message.h b/src/kit/kit-message.h
deleted file mode 100644
index 7d363b5..0000000
--- a/src/kit/kit-message.h
+++ /dev/null
@@ -1,53 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-message.h : Message utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_MESSAGE_H
-#define KIT_MESSAGE_H
-
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-#ifdef __sun
-void kit_debug   (const char *format, ...);
-void kit_warning (const char *format, ...);
-#else
-void kit_debug   (const char *format, ...) __attribute__((__format__ (__printf__, 1, 2)));
-void kit_warning (const char *format, ...) __attribute__((__format__ (__printf__, 1, 2)));
-#endif
-
-KIT_END_DECLS
-
-#endif /* KIT_MESSAGE_H */
-
-
diff --git a/src/kit/kit-spawn.c b/src/kit/kit-spawn.c
deleted file mode 100644
index 080a1bc..0000000
--- a/src/kit/kit-spawn.c
+++ /dev/null
@@ -1,675 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-spawn.c : Spawn utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <sys/types.h>
-#include <sys/wait.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <signal.h>
-
-#include <kit/kit.h>
-#include "kit-test.h"
-
-
-/**
- * SECTION:kit-spawn
- * @title: Spawn utilities
- * @short_description: Spawn utilities
- *
- * Various spawn utilities.
- **/
-
-static kit_bool_t
-set_close_on_exec (int fd, void *data)
-{
-        if (fd >= (int) data) {
-                if (fcntl (fd, F_SETFD, FD_CLOEXEC) != 0 && errno != EBADF) {
-                        return FALSE;
-                }
-        }
-
-        return TRUE;
-}
-
-static kit_bool_t
-_fdwalk (kit_bool_t (*callback)(int fd, void *user_data), void *user_data)
-{
-        int fd;
-        int max_fd;
-
-        kit_return_val_if_fail (callback != NULL, FALSE);
-
-        max_fd = sysconf (_SC_OPEN_MAX);
-        for (fd = 0; fd < max_fd; fd++) {
-                if (!callback (fd, user_data))
-                        return FALSE;
-        }
-
-        return TRUE;
-}
-
-static int
-_sane_dup2 (int fd1, int fd2)
-{
-        int ret;
-        
-again:
-        ret = dup2 (fd1, fd2);
-        if (ret < 0 && errno == EINTR)
-                goto again;
-        
-        return ret;
-}
-
-static ssize_t
-_read_from (int fd, char **out_string)
-{
-        char buf[4096];
-        ssize_t num_read;
-
-again:
-        num_read = read (fd, buf, sizeof (buf) - 1);
-        if (num_read == -1) {
-                if (errno == EINTR)
-                        goto again;
-                else
-                        goto out;
-        }
-
-        if (num_read > 0) {
-                char *s;
-
-                buf[num_read] = '\0';
-
-                s = kit_str_append (*out_string, buf);
-                if (s == NULL) {
-                        errno = ENOMEM;
-                        num_read = -1;
-                        goto out;
-                }
-                *out_string = s;
-
-                //kit_debug ("fd=%d read %d bytes: '%s'", fd, num_read, buf);
-        }
-
-out:
-        return num_read;
-}
-
-static ssize_t
-_write_to (int fd, char *str)
-{
-        ssize_t num_written;
-
-again:
-        num_written = write (fd, str, strlen (str));
-        if (num_written == -1) {
-                if (errno == EINTR)
-                        goto again;
-                else
-                        goto out;
-        }
-
-        //kit_debug ("Wrote %d bytes from '%s'", num_written, str);
-
-out:
-        return num_written;
-}
-
-/**
- * kit_spawn_sync:
- * @working_directory: Working directory for child or #NULL to inherit parents
- * @flags: A combination of flags from #KitSpawnFlags
- * @argv: #NULL terminated argument vector
- * @envp: #NULL terminated environment or #NULL to inherit parents;
- * @stdinp: String to write to stdin of child or #NULL
- * @stdoutp: Return location for stdout from child or #NULL. Free with kit_free().
- * @stderrp: Return location for stderr from child or #NULL. Free with kit_free().
- * @out_exit_status: Return location for exit status
- *
- * Executes a child process and waits for the child process to exit
- * before returning. The exit status of the child is stored in
- * @out_exit_status as it would be returned by waitpid(); standard
- * UNIX macros such as WIFEXITED() and WEXITSTATUS() must be used to
- * evaluate the exit status.
- *
- * Returns: #TRUE if the child was executed; #FALSE if an error
- * occured and errno will be set.
- */
-kit_bool_t
-kit_spawn_sync (const char     *working_directory,
-                KitSpawnFlags   flags,
-                char          **argv,
-                char          **envp,
-                char           *stdinp,
-                char          **stdoutp,
-                char          **stderrp,
-                int            *out_exit_status)
-{
-        kit_bool_t ret;
-        pid_t pid;
-        int stdin_pipe[2] = {-1, -1};
-        int stdout_pipe[2] = {-1, -1};
-        int stderr_pipe[2] = {-1, -1};
-
-        ret = FALSE;
-        pid = -1;
-
-        kit_return_val_if_fail (argv != NULL, FALSE);
-        kit_return_val_if_fail (out_exit_status != NULL, FALSE);
-        kit_return_val_if_fail (! ((flags & KIT_SPAWN_CHILD_INHERITS_STDIN) && stdinp != NULL), FALSE);
-        kit_return_val_if_fail (! ((flags & KIT_SPAWN_STDOUT_TO_DEV_NULL) && stdoutp != NULL), FALSE);
-        kit_return_val_if_fail (! ((flags & KIT_SPAWN_STDERR_TO_DEV_NULL) && stderrp != NULL), FALSE);
-
-        if (stdoutp != NULL)
-                *stdoutp = NULL;
-        if (stderrp != NULL)
-                *stderrp = NULL;
-
-        if (stdinp != NULL) {
-                if (pipe (stdin_pipe) != 0) {
-                        goto out;
-                }
-        }
-
-        if (stdoutp != NULL) {
-                if (pipe (stdout_pipe) != 0) {
-                        goto out;
-                }
-        }
-
-        if (stderrp != NULL) {
-                if (pipe (stderr_pipe) != 0) {
-                        goto out;
-                }
-        }
-
-        pid = fork ();
-        if (pid == -1) {
-                goto out;
-        }
-
-        if (pid == 0) {
-                int fd_null = -1;
-
-                /* child */
-
-                if ( (!(flags & KIT_SPAWN_CHILD_INHERITS_STDIN)) ||
-                     (flags & KIT_SPAWN_STDOUT_TO_DEV_NULL) ||
-                     (flags & KIT_SPAWN_STDERR_TO_DEV_NULL)) {
-                        fd_null = open ("/dev/null", O_RDONLY);
-                        if (fd_null < 0) {
-                                exit (128 + errno);
-                        }
-                }
-
-                signal (SIGPIPE, SIG_DFL);
-
-                /* close unused ends */
-                if (stdin_pipe[1] != -1) {
-                        close (stdin_pipe[1]);
-                }
-                if (stdout_pipe[0] != -1) {
-                        close (stdout_pipe[0]);
-                }
-                if (stderr_pipe[0] != -1) {
-                        close (stderr_pipe[0]);
-                }
-
-                /* close all open file descriptors of child except stdin, stdout, stderr */
-                _fdwalk (set_close_on_exec, (void *) 3);
-                
-                /* change working directory */
-                if (working_directory != NULL) {
-                        if (chdir (working_directory) != 0) {
-                                exit (128 + errno);
-                        }
-                }
-
-                /* set stdinp, stdoutp and stderrp */
-
-                if (stdinp != NULL) {
-                        if (_sane_dup2 (stdin_pipe[0], 0) < 0) {
-                                exit (128 + errno);
-                        }
-                } else if (! (flags & KIT_SPAWN_CHILD_INHERITS_STDIN)) {
-                        if (_sane_dup2 (fd_null, 0) < 0) {
-                                exit (128 + errno);
-                        }
-                }
-
-                if (stdoutp != NULL) {
-                        if (_sane_dup2 (stdout_pipe[1], 1) < 0) {
-                                exit (128 + errno);
-                        }
-                } else if (flags & KIT_SPAWN_STDOUT_TO_DEV_NULL) {
-                        if (_sane_dup2 (fd_null, 1) < 0) {
-                                exit (128 + errno);
-                        }
-                }
-
-                if (stderrp != NULL) {
-                        if (_sane_dup2 (stderr_pipe[1], 2) < 0) {
-                                exit (128 + errno);
-                        }
-                } else if (flags & KIT_SPAWN_STDERR_TO_DEV_NULL) {
-                        if (_sane_dup2 (fd_null, 2) < 0) {
-                                exit (128 + errno);
-                        }
-                }
-
-                if (fd_null != -1)
-                        close (fd_null);
-
-                /* finally, execute the child */
-                if (envp != NULL) {
-                        if (execve (argv[0], argv, envp) == -1) {
-                                exit (128 + errno);
-                        }
-                } else {
-                        if (execv (argv[0], argv) == -1) {
-                                exit (128 + errno);
-                        }
-                }
-
-        } else {
-                char *wp;
-
-                /* parent */
-
-                /* closed unused ends */
-                if (stdin_pipe[0] != -1) {
-                        close (stdin_pipe[0]);
-                }
-                if (stdout_pipe[1] != -1) {
-                        close (stdout_pipe[1]);
-                }
-                if (stderr_pipe[1] != -1) {
-                        close (stderr_pipe[1]);
-                }
-
-                wp = stdinp;
-
-                while (stdin_pipe[1] != -1 || stdout_pipe[0] != -1 || stderr_pipe[0] != -1) {
-                        int ret;
-                        ssize_t num_read;
-                        ssize_t num_written;
-                        int max;
-                        fd_set read_fds;
-                        fd_set write_fds;
-                        
-                        FD_ZERO (&read_fds);
-                        FD_ZERO (&write_fds);
-                        if (stdin_pipe[1] != -1) {
-                                FD_SET (stdin_pipe[1], &write_fds);
-                        }
-                        if (stdout_pipe[0] != -1) {
-                                FD_SET (stdout_pipe[0], &read_fds);
-                        }
-                        if (stderr_pipe[0] != -1) {
-                                FD_SET (stderr_pipe[0], &read_fds);
-                        }
-                        
-                        max = stdin_pipe[1];
-                        if (stdout_pipe[0] > max)
-                                max = stdout_pipe[0];
-                        if (stderr_pipe[0] > max)
-                                max = stderr_pipe[0];
-                        
-                        ret = select (max + 1, 
-                                      &read_fds, 
-                                      &write_fds, 
-                                      NULL, 
-                                      NULL);
-                        
-                        if (ret < 0 && errno != EINTR) {
-                                goto out;
-                        }
-                        
-                        if (stdin_pipe[1] != -1) {
-                                num_written = _write_to (stdin_pipe[1], wp);
-                                
-                                if (num_written == -1)  {
-                                        goto out;
-                                }
-                                
-                                wp += num_written;
-                                if (*wp == '\0') {
-                                        close (stdin_pipe[1]);
-                                        stdin_pipe[1] = -1;
-                                }
-                        }
-                        
-                        if (stdout_pipe[0] != -1) {
-                                num_read = _read_from (stdout_pipe[0], stdoutp);
-                                if (num_read == 0) {
-                                        close (stdout_pipe[0]);
-                                        stdout_pipe[0] = -1;
-                                } else if (num_read == -1)  {
-                                        goto out;
-                                }
-                        }
-                        
-                        if (stderr_pipe[0] != -1) {
-                                num_read = _read_from (stderr_pipe[0], stderrp);
-                                if (num_read == 0) {
-                                        close (stderr_pipe[0]);
-                                        stderr_pipe[0] = -1;
-                                } else if (num_read == -1)  {
-                                        goto out;
-                                }
-                        }
-                }
-
-                if (waitpid (pid, out_exit_status, 0) == -1) {
-                        goto out;
-                }
-                pid = -1;
-        }
-
-        //kit_debug ("exit %d", WEXITSTATUS (*out_exit_status));
-
-        if (WEXITSTATUS (*out_exit_status) < 128) {
-                ret = TRUE;
-        } else {
-                ret = FALSE;
-                errno = WEXITSTATUS (*out_exit_status) - 128;
-        }
-
-out:
-        if (pid != -1) {
-                kill (pid, SIGKILL);
-                waitpid (pid, out_exit_status, 0);                
-        }
-
-        if (stdin_pipe[1] != -1)
-                close (stdin_pipe[1]);
-        if (stdout_pipe[0] != -1)
-                close (stdout_pipe[0]);
-        if (stderr_pipe[0] != -1)
-                close (stderr_pipe[0]);
-
-        if (!ret) {
-                if (stdoutp != NULL) {
-                        kit_free (*stdoutp);
-                        *stdoutp = NULL;
-                }
-                if (stderrp != NULL) {
-                        kit_free (*stderrp);
-                        *stderrp = NULL;
-                }
-        }
-
-        return ret;
-
-}
-
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_run_test (void)
-{
-        char path[] = "/tmp/kit-spawn-test";
-        char *script1 = 
-                "#!/bin/sh"                      "\n"
-                "echo \"Hello World\""           "\n"
-                "echo \"Goodbye World\" 1>&2"    "\n"
-                "exit 42"                        "\n";
-        char *script2 = 
-                "#!/bin/sh"  "\n"
-                "exit 43"    "\n";
-        char *script3 = 
-                "#!/bin/sh"                       "\n"
-                "echo -n \"$KIT_TEST_VAR\""       "\n"
-                "exit 0"                          "\n";
-        char *script4 = 
-                "#!/bin/sh"                                "\n"
-                "if [ \"x$KIT_TEST_VAR\" = \"x\" ] ; then" "\n"
-                "  exit 0"                                 "\n"
-                "fi"                                       "\n"
-                "exit 1"                                   "\n";
-        char *script4b = 
-                "#!/bin/sh"                                "\n"
-                "/bin/env > /tmp/food2"                     "\n"
-                "if [ \"x$KIT_TEST_VAR\" = \"xfoobar2\" ] ; then" "\n"
-                "  exit 0"                                 "\n"
-                "fi"                                       "\n"
-                "exit 1"                                   "\n";
-        char *script5 = 
-                "#!/bin/sh"                                "\n"
-                "pwd"                                      "\n"
-                "exit 0"                                   "\n";
-        char *script6 = 
-                "#!/bin/sh"                                "\n"
-                "read value"                               "\n"
-                "echo -n \"$value\""                       "\n"
-                "echo -n \" \""                            "\n"
-                "read value"                               "\n"
-                "echo -n \"$value\""                       "\n"
-                "exit 0"                                   "\n";
-        char *argv[] = {"/tmp/kit-spawn-test", NULL};
-        char *stdoutp;
-        char *stderrp;
-        int exit_status;
-        struct stat statbuf;
-
-        /* script echoing to stdout and stderr */
-        if (kit_file_set_contents (path, 0700, script1, strlen (script1))) {
-                if (kit_spawn_sync ("/",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    &stdoutp,
-                                    &stderrp,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 42);
-                        kit_assert (stdoutp != NULL && strcmp (stdoutp, "Hello World\n") == 0);
-                        kit_assert (stderrp != NULL && strcmp (stderrp, "Goodbye World\n") == 0);
-                        kit_free (stdoutp);
-                        kit_free (stderrp);
-                }
-
-                if (kit_spawn_sync ("/",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 42);
-                }
-
-                kit_assert (unlink (path) == 0);
-        }
-
-        /* silent script */
-        if (kit_file_set_contents (path, 0700, script2, strlen (script2))) {
-                if (kit_spawn_sync ("/",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    &stdoutp,
-                                    &stderrp,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 43);
-                        kit_assert (stdoutp == NULL);
-                        kit_assert (stderrp == NULL);
-                }
-
-                kit_assert (unlink (path) == 0);
-        }
-
-        /* check environment is set */
-        if (kit_file_set_contents (path, 0700, script3, strlen (script3))) {
-                char *envp[] = {"KIT_TEST_VAR=some_value", NULL};
-
-                if (kit_spawn_sync ("/",
-                                    0,
-                                    argv,
-                                    envp,
-                                    NULL,
-                                    &stdoutp,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 0);
-                        kit_assert (stdoutp != NULL && strcmp (stdoutp, "some_value") == 0);
-                        kit_free (stdoutp);
-                }
-
-                kit_assert (unlink (path) == 0);
-        }
-
-        /* check environment is replaced */
-        if (kit_file_set_contents (path, 0700, script4, strlen (script4))) {
-                char *envp[] = {NULL};
-
-                kit_assert (setenv ("KIT_TEST_VAR", "foobar", 1) == 0);
-
-                if (kit_spawn_sync ("/",
-                                    0,
-                                    argv,
-                                    envp,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 0);
-                }
-
-                kit_assert (unlink (path) == 0);
-                kit_assert (unsetenv ("KIT_TEST_VAR") == 0);
-        }
-
-        /* check environment is inherited */
-        if (kit_file_set_contents (path, 0700, script4b, strlen (script4b))) {
-
-                kit_assert (setenv ("KIT_TEST_VAR", "foobar2", 1) == 0);
-
-                if (kit_spawn_sync ("/",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 0);
-                }
-
-                kit_assert (unlink (path) == 0);
-                kit_assert (unsetenv ("KIT_TEST_VAR") == 0);
-        }
-
-        /* check working directory */
-        if (kit_file_set_contents (path, 0700, script5, strlen (script5))) {
-                kit_assert (stat ("/tmp", &statbuf) == 0 && S_ISDIR (statbuf.st_mode));
-                if (kit_spawn_sync ("/tmp",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    &stdoutp,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 0);
-                        kit_assert (stdoutp != NULL && strcmp (stdoutp, "/tmp\n") == 0);
-                        kit_free (stdoutp);
-                }
-
-                kit_assert (stat ("/usr", &statbuf) == 0 && S_ISDIR (statbuf.st_mode));
-                if (kit_spawn_sync ("/usr",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    &stdoutp,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 0);
-                        kit_assert (stdoutp != NULL && strcmp (stdoutp, "/usr\n") == 0);
-                        kit_free (stdoutp);
-                }
-
-                kit_assert (unlink (path) == 0);
-        }
-
-        /* check bogus working directory */
-        kit_assert (stat ("/org/freedesktop/PolicyKit/bogus-fs-path", &statbuf) != 0);
-        kit_assert (kit_spawn_sync ("/org/freedesktop/PolicyKit/bogus-fs-path",
-                                    0,
-                                    argv,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    NULL,
-                                    &exit_status) == FALSE && 
-                    (errno == ENOENT || errno == ENOMEM));
-
-        /* check for writing to stdin */
-        if (kit_file_set_contents (path, 0700, script6, strlen (script6))) {
-                if (kit_spawn_sync (NULL,
-                                    0,
-                                    argv,
-                                    NULL,
-                                    "foobar0\nfoobar1",
-                                    &stdoutp,
-                                    NULL,
-                                    &exit_status)) {
-                        kit_assert (WEXITSTATUS (exit_status) == 0);
-                        kit_assert (stdoutp != NULL && strcmp (stdoutp, "foobar0 foobar1") == 0);
-                        kit_free (stdoutp);
-                }
-
-                kit_assert (unlink (path) == 0);
-        }
-
-        return TRUE;
-}
-
-KitTest _test_spawn = {
-        "kit_spawn",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-spawn.h b/src/kit/kit-spawn.h
deleted file mode 100644
index 6f40dd9..0000000
--- a/src/kit/kit-spawn.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-spawn.h : Spawn utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_SPAWN_H
-#define KIT_SPAWN_H
-
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-/**
- * KitSpawnFlags:
- * @KIT_SPAWN_CHILD_INHERITS_STDIN: If not set, child's stdin will be attached to <literal>/dev/null</literal>
- * @KIT_SPAWN_STDOUT_TO_DEV_NULL: If set childs output will be sent to <literal>/dev/null</literal>
- * @KIT_SPAWN_STDERR_TO_DEV_NULL: If set childs error output will be sent to <literal>/dev/null</literal>
- *
- * Flags passed to kit_spawn_sync().
- */
-typedef enum {
-        KIT_SPAWN_CHILD_INHERITS_STDIN = 1 << 0,
-        KIT_SPAWN_STDOUT_TO_DEV_NULL   = 1 << 1,
-        KIT_SPAWN_STDERR_TO_DEV_NULL   = 1 << 2,
-} KitSpawnFlags;
-
-
-kit_bool_t kit_spawn_sync (const char     *working_directory,
-                           KitSpawnFlags   flags,
-                           char          **argv,
-                           char          **envp,
-                           char           *stdinp,
-                           char          **stdoutp,
-                           char          **stderrp,
-                           int            *out_exit_status);
-
-KIT_END_DECLS
-
-#endif /* KIT_SPAWN_H */
-
-
diff --git a/src/kit/kit-string.c b/src/kit/kit-string.c
deleted file mode 100644
index 13a563d..0000000
--- a/src/kit/kit-string.c
+++ /dev/null
@@ -1,1204 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-string.c : String utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-
-#include <kit/kit.h>
-#include "kit-test.h"
-
-
-/**
- * SECTION:kit-string
- * @title: String utilities
- * @short_description: String utilities
- *
- * Various string utilities.
- **/
-
-#ifdef KIT_BUILD_TESTS
-
-/**
- * kit_strdup:
- * @s: string
- *
- * Duplicate a string. Similar to strdup(3).
- *
- * Returns: Allocated memory or #NULL on OOM. Free with kit_free().
- */
-char *
-kit_strdup (const char *s)
-{
-        char *p;
-        size_t len;
-
-        len = strlen (s);
-
-        p = kit_malloc (len + 1);
-        if (p == NULL)
-                goto out;
-
-        memcpy (p, s, len);
-        p[len] = '\0';
-
-out:
-        return p;
-}
-
-/**
- * kit_strndup:
- * @s: string
- * @n: size
- *
- * Duplicate a string but copy at most @n characters. If @s is longer
- * than @n, only @n characters are copied, and a terminating null byte
- * is added. Similar to strndup(3).
- *
- * Returns: Allocated memory or #NULL on OOM. Free with kit_free().
- */
-char *
-kit_strndup (const char *s, size_t n)
-{
-        char *p;
-        size_t len;
-
-        for (len = 0; len < n; len++) {
-                if (s[len] == '\0')
-                        break;
-        }
-
-
-        p = kit_malloc (len + 1);
-        if (p == NULL)
-                goto out;
-
-        memcpy (p, s, len);
-        p[len] = '\0';
-out:
-        return p;
-}
-
-#else
-
-#ifndef HAVE_STRNDUP
-static char
-*strndup ( const char *s, size_t n)
-{
-        size_t nAvail;
-        char *p;
-
-        if ( !s )
-                return NULL;
-
-        if ( strlen(s) > n )
-                nAvail = n + 1;
-        else
-                nAvail = strlen(s) + 1;
-        p = malloc ( nAvail );
-        memcpy ( p, s, nAvail );
-        p[nAvail - 1] = '\0';
-
-        return p;
-}
-#endif
-
-char *
-kit_strdup (const char *s)
-{
-        return strdup (s);
-}
-
-char *
-kit_strndup (const char *s, size_t n)
-{
-        return strndup (s, n);
-}
-
-#endif /* KIT_BUILD_TESTS */
-
-#ifdef HAVE_SOLARIS
-int vasprintf(char **strp, const char *fmt, va_list ap)
-{
-        int size;
-        va_list ap2;
-        char s;
-
-        *strp = NULL;
-        va_copy(ap2, ap);
-        size = vsnprintf(&s, 1, fmt, ap2);
-        va_end(ap2);
-        *strp = malloc(size + 1);
-        if (!*strp)
-                return -1;
-        vsnprintf(*strp, size + 1, fmt, ap);
-
-        return size;
-}
-#endif
-
-/**
- * kit_strdup_printf:
- * @format: sprintf(3) format string
- * @...:  the parameters to insert into the format string.
- * 
- * Similar to the standard C sprintf(3) function but safer, since it
- * calculates the maximum space required and allocates memory to hold
- * the result. The returned string should be freed when no longer
- * needed.
- *
- * Returns: A newly allocated string or #NULL on OOM. Free with kit_free().
- */
-char* 
-kit_strdup_printf (const char *format, ...)
-{
-        char *s;
-        va_list args;
-
-        va_start (args, format);
-        s = kit_strdup_vprintf (format, args);
-        va_end (args);
-
-        return s;
-}
-
-/**
- * kit_strdup_vprintf:
- * @format: printf(3) format string
- * @args: list of parameters to insert
- * 
- * Similar to the standard C vsprintf(3) function but safer, since it
- * calculates the maximum space required and allocates memory to hold
- * the result. The returned string should be freed when no longer
- * needed.
- *
- * Returns: A newly allocated string or #NULL on OOM. Free with kit_free().
- */
-char* 
-kit_strdup_vprintf (const char *format, va_list args)
-{
-        char *s;
-
-#ifdef KIT_BUILD_TESTS
-        char *p;
-        vasprintf (&p, format, args);
-        s = kit_strdup (p);
-        free (p);
-#else
-        if (vasprintf (&s, format, args) == -1) {
-                s = NULL;
-        }
-#endif
-        return s;
-}
-
-
-/**
- * kit_str_has_prefix:
- * @s: string to check
- * @prefix: prefix to check for
- *
- * Determines if a string has a given prefix.
- *
- * Returns: #TRUE only if @s starts with @prefix
- */
-kit_bool_t
-kit_str_has_prefix (const char *s, const char *prefix)
-{
-        size_t s_len;
-        size_t prefix_len;
-
-        kit_return_val_if_fail (s != NULL, FALSE);
-        kit_return_val_if_fail (prefix != NULL, FALSE);
-
-        s_len = strlen (s);
-        prefix_len = strlen (prefix);
-        if (prefix_len > s_len)
-                return FALSE;
-
-        return strncmp (s, prefix, prefix_len) == 0;
-}
-
-/**
- * kit_str_has_suffix:
- * @s: string to check
- * @suffix: suffix to check for
- *
- * Determines if a string has a given suffix.
- *
- * Returns: #TRUE only if @s ends with @suffix
- */
-kit_bool_t
-kit_str_has_suffix (const char *s, const char *suffix)
-{
-        size_t s_len;
-        size_t suffix_len;
-
-        kit_return_val_if_fail (s != NULL, FALSE);
-        kit_return_val_if_fail (suffix != NULL, FALSE);
-
-        s_len = strlen (s);
-        suffix_len = strlen (suffix);
-        if (suffix_len > s_len)
-                return FALSE;
-
-        return strncmp (s + s_len - suffix_len, suffix, suffix_len) == 0;
-}
-
-/**
- * kit_strsplit:
- * @s: string to split
- * @delim: delimiter used for splitting
- * @num_tokens: return location for number of elements or #NULL
- *
- * Split a given string into components given a delimiter.
- *
- * Returns: A #NULL terminated array of strings. Free with kit_strfreev(). Returns #NULL on OOM.
- */
-char **
-kit_strsplit (const char *s, char delim, size_t *num_tokens)
-{
-        int n;
-        int m;
-        int num;
-        char **result;
-
-        kit_return_val_if_fail (s != NULL, NULL);
-
-        result = NULL;
-
-        num = 0;
-        for (n = 0; s[n] != '\0'; n++) {
-                if (s[n] == delim) {
-                        num++;
-                }
-        }
-        num++;
-
-        result = kit_new0 (char*, num + 1);
-        if (result == NULL)
-                goto oom;
-
-        m = 0;
-        for (n = 0; n < num; n++) {
-                int begin;
-
-                begin = m;
-
-                while (s[m] != delim && s[m] != '\0') {
-                        m++;
-                }
-
-                result[n] = kit_strndup (s + begin, m - begin);
-                if (result[n] == NULL)
-                        goto oom;
-
-                m++;
-        }
-        result[n] = NULL;
-
-        if (num_tokens != NULL)
-                *num_tokens = num;
-
-        return result;
-oom:
-        kit_strfreev (result);
-        return NULL;
-}
-
-/**
- * kit_strfreev:
- * @str_array: string array
- *
- * Free a #NULL terminated string array.
- */
-void
-kit_strfreev (char **str_array)
-{
-        int n;
-
-        if (str_array == NULL)
-                return;
-
-        for (n = 0; str_array[n] != NULL; n++)
-                kit_free (str_array[n]);
-
-        kit_free (str_array);
-}
-
-/**
- * kit_strv_length:
- * @str_array: string array
- *
- * Compute number of elements in a #NULL terminated string array.
- *
- * Returns: Number of elements not including the terminating #NULL
- */
-size_t
-kit_strv_length (char **str_array)
-{
-        int n;
-
-        kit_return_val_if_fail (str_array != NULL, 0);
-
-        for (n = 0; str_array[n] != NULL; n++)
-                ;
-
-        return n;
-}
-
-/**
- * kit_str_append:
- * @s: either %NULL or a string previously allocated on the heap
- * @s2: string to append
- *
- * Append a string to an existing string.
- *
- * Returns: %NULL on OOM or the new string; possibly at the same
- * location as @s.
- */
-char *
-kit_str_append (char *s, const char *s2)
-{
-        char *p;
-        size_t s_len;
-        size_t s2_len;
-
-        kit_return_val_if_fail (s2 != NULL, NULL);
-
-        if (s != NULL)
-                s_len = strlen (s);
-        else
-                s_len = 0;
-        s2_len = strlen (s2);
-        p = (char *) kit_realloc ((void *) s, s_len + s2_len + 1);
-        if (p == NULL)
-                goto oom;
-        s = p;
-        memcpy ((void *) (s + s_len), s2, s2_len);
-        s[s_len + s2_len] = '\0';
-
-        return s;
-oom:
-        return NULL;
-}
-
-static kit_bool_t
-_is_reserved (char c)
-{
-        unsigned int n;
-        char reserved[] = " !*'();:@&=+$,/?%#[]\n\r\t";
-
-        for (n = 0; n < sizeof (reserved); n++) {
-                if (reserved[n] == c)
-                        return TRUE;
-        }
-
-        return FALSE;
-}
-
-static char
-_to_hex (unsigned int nibble)
-{
-        if (nibble < 10)
-                return nibble + '0';
-        else
-                return nibble - 10 + 'A';
-}
-
-/**
- * kit_string_percent_encode:
- * @buf: return location for output
- * @buf_size: size of buffer
- * @s: string to encode
- *
- * Percent encodes a string; each occurence of an ASCII characters in
- * the set <literal>" !*'();:@&=+$,/?%#[]\n\r\t"</literal> will be
- * replaced by a three character sequence started by the percent sign
- * "%" and then the hexidecimal representation of the ASCII character
- * in question.
- *
- * Returns: This function do not write more than @buf_size bytes
- * (including the trailing zero). If the output was truncated due to
- * this limit then the return value is the number of characters (not
- * including the trailing zero) which would have been written to the
- * final string if enough space had been available. Thus, a return
- * value of @buf_size or more means that the output was truncated.
- */
-size_t
-kit_string_percent_encode (char *buf, size_t buf_size, const char *s)
-{
-        size_t len;
-        unsigned int n;
-        unsigned int m;
-
-        kit_return_val_if_fail (buf != NULL, 0);
-        kit_return_val_if_fail (s != NULL, 0);
-
-        len = strlen (s);
-
-        for (n = 0, m = 0; n < len; n++) {
-                int c = s[n];
-
-                if (_is_reserved (c)) {
-                        if (m < buf_size)
-                                buf[m] = '%';
-                        m++;
-                        if (m < buf_size)
-                                buf[m] = _to_hex (c >> 4);
-                        m++;
-                        if (m < buf_size)
-                                buf[m] = _to_hex (c & 0x0f);
-                        m++;
-                } else {
-                        if (m < buf_size)
-                                buf[m] = c;
-                        m++;
-                }
-        }
-        if (m < buf_size)
-                buf[m] = '\0';
-
-        return m;
-}
-
-/**
- * kit_string_percent_decode:
- * @s: string to modify in place
- *
- * Percent-decodes a string in place. See kit_string_percent_encode()
- * for details on the encoding format.
- *
- * Returns: %FALSE if string is not properly encoded (and errno will be set to EINVAL)
- */
-kit_bool_t
-kit_string_percent_decode (char *s)
-{
-        kit_bool_t ret;
-        unsigned int n;
-        unsigned int m;
-        size_t len;
-
-        kit_return_val_if_fail (s != NULL, FALSE);
-
-        ret = FALSE;
-
-        len = strlen (s);
-
-        for (n = 0, m = 0; n < len; n++) {
-                int c = s[n];
-
-                if (c != '%') {
-                        if (_is_reserved (c)) {
-                                errno = EINVAL;
-                                goto out;
-                        }
-                        s[m++] = s[n];
-                } else {
-                        int nibble1;
-                        int nibble2;
-
-                        if (n + 2 >= len) {
-                                errno = EINVAL;
-                                goto out;
-                        }
-
-                        nibble1 = s[n + 1];
-                        nibble2 = s[n + 2];
-                        n += 2;
-
-                        if (nibble1 >= '0' && nibble1 <= '9') {
-                                nibble1 -= '0';
-                        } else if (nibble1 >= 'A' && nibble1 <= 'F') {
-                                nibble1 -= 'A' - 10;
-                        } else {
-                                errno = EINVAL;
-                                goto out;
-                        }
-
-                        if (nibble2 >= '0' && nibble2 <= '9') {
-                                nibble2 -= '0';
-                        } else if (nibble2 >= 'A' && nibble2 <= 'F') {
-                                nibble2 -= 'A' - 10;
-                        } else {
-                                errno = EINVAL;
-                                goto out;
-                        }
-
-                        s[m++] = (nibble1 << 4) | nibble2;
-                }
-        }
-        s[m] = '\0';
-
-        ret = TRUE;
-out:
-        return ret;
-}
-
-
-/**
- * kit_string_entry_parse:
- * @entry: line to parse
- * @func: callback function
- * @user_data: user data to pass to @func
- *
- * Parse a line of the form
- * <literal>key1=val1:key2=val2:key3=val3</literal>. 
- *
- * The given @entry is said not to be wellformed if a) it doesn't
- * follow this structure (for example
- * <literal>key1=val1:key2:key3=val3</literal> is not well-formed
- * because it's missing the '=' character) or the extracted key and
- * value strings are not properly percent encoded.
- *
- * Both the key and value values are run through the
- * kit_string_percent_decode() function prior to being passed to
- * @func. Normally this function is used to decode strings produced
- * with kit_string_entry_create().
- *
- * Returns: %TRUE if the line is wellformed and the callback didn't
- * short-circuit the iteration. Returns %FALSE on OOM (and errno will
- * be set to ENOMEM) or if @entry is not wellformed (and errno will
- * be set to EINVAL).
- */
-kit_bool_t
-kit_string_entry_parse (const char *entry, KitStringEntryParseFunc func, void *user_data)
-{
-        unsigned int n;
-        kit_bool_t ret;
-        char **tokens;
-        size_t num_tokens;
-
-        kit_return_val_if_fail (entry != NULL, FALSE);
-        kit_return_val_if_fail (func != NULL, FALSE);
-
-        ret = FALSE;
-        tokens = NULL;
-
-        tokens = kit_strsplit (entry, ':', &num_tokens);
-        if (tokens == NULL) {
-                errno = ENOMEM;
-                goto out;
-        }
-
-        for (n = 0; n < num_tokens; n++) {
-                char *token;
-                char *p;
-
-                token = tokens[n];
-
-                p = strchr (token, '=');
-                if (p == NULL) {
-                        errno = EINVAL;
-                        goto out;
-                }
-
-                token [p - token] = '\0';
-
-                p++;
-
-                if (!kit_string_percent_decode (token))
-                        goto out;
-
-                if (!kit_string_percent_decode (p))
-                        goto out;
-
-                if (!func (token, p, user_data)) {
-                        goto out;
-                }
-        }
-
-        ret = TRUE;
-
-out:
-        if (tokens != NULL)
-                kit_strfreev (tokens);
-        return ret;
-}
-
-/**
- * kit_string_entry_createv:
- * @buf: return location for output
- * @buf_size: size of buffer
- * @kv_pairs: %NULL terminated array of key/value pairs.
- *
- * Takes an array of key/value pairs and generates a string
- * <literal>"k1=v1:k2=v2:...:k_n=v_n"</literal> where
- * <literal>k_i</literal> and <literal>v_i</literal> are percent
- * encoded representations of the given key/value pairs.
- *
- * The string can later be parsed with kit_string_entry_parse() to get
- * the exact same list of key/value pairs back.
- *
- * Returns: This function do not write more than @buf_size bytes
- * (including the trailing zero). If the output was truncated due to
- * this limit then the return value is the number of characters (not
- * including the trailing zero) which would have been written to the
- * final string if enough space had been available. Thus, a return
- * value of @buf_size or more means that the output was truncated.
- *
- * If an uneven number of strings are given, this function will return
- * zero and errno will be set to EINVAL.
- */
-size_t
-kit_string_entry_createv (char *buf, size_t buf_size, const char *kv_pairs[])
-{
-        int n;
-        unsigned int m;
-
-        for (n = 0, m = 0; kv_pairs[n] != NULL; n+= 2) {
-                const char *key;
-                const char *value;
-
-                if (kv_pairs[n + 1] == NULL) {
-                        m = 0;
-                        errno = EINVAL;
-                        goto out;
-                }
-
-                key = kv_pairs[n];
-                value = kv_pairs[n + 1];
-
-                if (n > 0) {
-                        if (m < buf_size)
-                                buf[m] = ':';
-                        m++;
-                }
-
-                m += kit_string_percent_encode (buf + m, buf_size - m > 0 ? buf_size - m : 0, key);
-
-                if (m < buf_size)
-                        buf[m] = '=';
-                m++;
-
-                m += kit_string_percent_encode (buf + m, buf_size - m > 0 ? buf_size - m : 0, value);
-        }
-
-out:
-        if (m < buf_size)
-                buf[m] = '\0';
-
-        return m;
-}
-
-/**
- * kit_string_entry_create:
- * @buf: return location for output
- * @buf_size: size of buffer
- * @...: %NULL terminated array of key/value pairs.
- *
- * See kit_string_entry_create().
- *
- * Returns: See kit_string_entry_create(). Up to 64 pairs can be
- * passed; if there are more pairs, this function will return zero and
- * errno will be set to EOVERFLOW.
- */
-size_t
-kit_string_entry_create (char *buf, size_t buf_size, ...)
-{
-        int n;
-        va_list args;
-        const char *val;
-        const char *kv_pairs[64 * 2 + 1];
-        size_t ret;
-
-        /* TODO: get rid of the 64 limit... */
-
-        ret = 0;
-
-        n = 0;
-        va_start (args, buf_size);
-        while ((val = va_arg (args, const char *)) != NULL) {
-                if (n == 64 * 2) {
-                        errno = EOVERFLOW;
-                        goto out;
-                }
-                kv_pairs[n++] = val;
-        }
-        va_end (args);
-        kv_pairs[n] = NULL;
-
-        ret = kit_string_entry_createv (buf, buf_size, kv_pairs);
-out:
-        return ret;
-}
-
-/**
- * KitString:
- *
- * String buffer that grows automatically as text is added.
- */
-struct _KitString {
-        char *buf;
-        size_t cur_len;
-        size_t buf_len;
-};
-
-/**
- * kit_string_free:
- * @s: the #KitString object
- * @free_segment: whether to free the string data itself
- * @out_segment_size: return location for size of string or %NULL
- *
- * Free resources used by a #KitString object
- *
- * Returns: If @free_segment is %TRUE, returns the segment (will
- * always be zero terminated), must be freed with kit_free(),
- * otherwise %NULL
- */
-char *
-kit_string_free (KitString *s, kit_bool_t free_segment, size_t *out_segment_size)
-{
-        char *ret;
-
-        kit_return_val_if_fail (s != NULL, NULL);
-
-        if (out_segment_size != NULL) {
-                *out_segment_size = s->cur_len;
-        }
-
-        if (free_segment) {
-                kit_free (s->buf);
-                ret = NULL;
-        } else {
-                ret = s->buf;
-        }
-        kit_free (s);
-
-        return ret;
-}
-
-#define KIT_STRING_BLOCK_SIZE 256
-
-/**
- * kit_string_new:
- * @init: String to initialize with or %NULL
- * @len: Initial size of buffer; pass zero to use the default size
- *
- * Initialize a new #KitString object.
- *
- * Returns: The new object or %NULL on OOM
- */
-KitString *
-kit_string_new (const char *init, size_t len)
-{
-        KitString *s;
-
-        s = kit_new0 (KitString, 1);
-        if (s == NULL)
-                goto oom;
-
-        if (len == 0)
-                len = KIT_STRING_BLOCK_SIZE;
-        s->buf_len = len;
-
-        if (init == NULL) {
-                s->buf = kit_new0 (char, s->buf_len);
-                if (s->buf == NULL)
-                        goto oom;
-                s->cur_len = 0;
-        } else {
-                size_t init_len;
-
-                init_len = strlen (init);
-                if (init_len + 1 > s->buf_len)
-                        s->buf_len = init_len + 1;
-                s->buf = kit_new0 (char, s->buf_len);
-                if (s->buf == NULL)
-                        goto oom;
-                strncpy (s->buf, init, init_len);
-                s->cur_len = init_len;
-        }
-
-        return s;
-oom:
-        if (s != NULL)
-                kit_string_free (s, TRUE, NULL);
-        return NULL;
-}
-
-/**
- * kit_string_ensure_size:
- * @s: String object
- * @new_size: The size to check for.
- *
- * Ensure that the given #KitString object can hold at least @new_size
- * characters.
- *
- * Returns: %TRUE if the given #KitString object can hold at least
- * @new_size characters. %FALSE if OOM.
- */
-kit_bool_t
-kit_string_ensure_size (KitString *s, size_t new_size)
-{
-        kit_return_val_if_fail (s != NULL, FALSE);
-
-        if (new_size > s->buf_len - 1) {
-                char *p;
-                size_t grow_to;
-
-                grow_to = ((new_size / KIT_STRING_BLOCK_SIZE) + 1) * KIT_STRING_BLOCK_SIZE;
-
-                p = kit_realloc (s->buf, grow_to);
-                if (p == NULL)
-                        goto oom;
-                /* zero the new block we got */
-                s->buf = p;
-                memset (s->buf + s->buf_len, 0, grow_to - s->buf_len);
-                s->buf_len = grow_to;
-        }
-
-        return TRUE;
-oom:
-        return FALSE;
-}
-
-/**
- * kit_string_append_c:
- * @s: the #KitString object
- * @c: character to append
- *
- * Append a character to a #KitString object.
- *
- * Returns: %TRUE unless OOM
- */
-kit_bool_t
-kit_string_append_c (KitString *s, char c)
-{
-        kit_return_val_if_fail (s != NULL, FALSE);
-
-        if (!kit_string_ensure_size (s, s->cur_len + 1))
-                goto oom;
-
-        s->buf[s->cur_len] = c;
-        s->cur_len += 1;
-        return TRUE;
-oom:
-        return FALSE;
-}
-
-/**
- * kit_string_append:
- * @s: the #KitString object
- * @str: string to append
- *
- * Append a string to a #KitString object.
- *
- * Returns: %TRUE unless OOM
- */
-kit_bool_t
-kit_string_append (KitString *s, const char *str)
-{
-        size_t str_len;
-
-        kit_return_val_if_fail (s != NULL, FALSE);
-
-        str_len = strlen (str);
-
-        if (!kit_string_ensure_size (s, s->cur_len + str_len))
-                goto oom;
-
-        strncpy (s->buf + s->cur_len, str, str_len);
-        s->cur_len += str_len;
-        return TRUE;
-oom:
-        return FALSE;
-}
-
-
-#ifdef KIT_BUILD_TESTS
-
-static kit_bool_t
-_ep1 (const char *key, const char *value, void *user_data)
-{
-        int *n = (int *) user_data;
-
-        if (strcmp (key, "a") == 0 && strcmp (value, "aval") == 0)
-                *n += 1;
-        if (strcmp (key, "a") == 0 && strcmp (value, "aval2") == 0)
-                *n += 1;
-        if (strcmp (key, "b") == 0 && strcmp (value, "bval") == 0)
-                *n += 1;
-        if (strcmp (key, "c") == 0 && strcmp (value, "cval") == 0)
-                *n += 1;
-        if (strcmp (key, "some_other_key") == 0 && strcmp (value, "some_value") == 0)
-                *n += 1;
-        if (strcmp (key, "escaped;here:right=") == 0 && strcmp (value, "yes! it's ==:crazy!") == 0)
-                *n += 1;
-
-        return TRUE;
-}
-
-static kit_bool_t
-_ep2 (const char *key, const char *value, void *user_data)
-{
-        int *n = (int *) user_data;
-
-        if (strcmp (key, "b") == 0)
-                return FALSE;
-
-        *n += 1;
-
-        return TRUE;
-}
-
-static kit_bool_t
-_run_test (void)
-{
-        int num;
-        char str[] = "Hello world";
-        char *p;
-        char *p2;
-        char **tokens;
-        size_t num_tokens;
-        unsigned int n;
-        char *bad_strings[] = {"bad:",
-                               "bad=",
-                               "bad%",
-                               "bad%1",
-                               "bad%xy",
-                               "bad%1x",
-                               "bad%Ax",
-                               "bad%2a"};
-        char buf[256];
-        KitString *s;
-
-        if ((s = kit_string_new (NULL, 3)) != NULL) {
-                for (n = 0; n < 8; n++) {
-                        if (!kit_string_append_c (s, 'd'))
-                                break;
-                }
-                p = kit_string_free (s, FALSE, NULL);
-                if (n == 8) {
-                        kit_assert (strcmp ("dddddddd", p) == 0);
-                }
-                kit_free (p);
-        }
-
-        /* KitString always makes place for the terminating zero, hence allocate one more byte */
-        if ((s = kit_string_new (NULL, 101)) != NULL) {
-                size_t segment_size;
-                for (n = 0; n < 100; n++) {
-                        kit_assert (kit_string_append_c (s, n));
-                }
-                p = kit_string_free (s, FALSE, &segment_size);
-                kit_assert (segment_size == 100);
-                for (n = 0; n < 100; n++) {
-                        kit_assert (p[n] == (char) n);
-                }
-                kit_assert (p[100] == 0);
-                kit_free (p);
-        }
-
-        if ((s = kit_string_new (NULL, 0)) != NULL) {
-                for (n = 0; n < 100; n++) {
-                        if (!kit_string_append (s, "foobar"))
-                                break;
-                }
-                p = kit_string_free (s, FALSE, NULL);
-                if (n == 100) {
-                        kit_assert (strlen (p) == 600);
-                        for (n = 0; n < 100; n++) {
-                                kit_assert (strncmp ("foobar", p + n * 6, 6) == 0);
-                        }
-                }
-                kit_free (p);
-        }
-
-        if ((s = kit_string_new ("fooobar", 3)) != NULL) {
-                p = kit_string_free (s, FALSE, NULL);
-                kit_assert (strcmp ("fooobar", p) == 0);
-                kit_free (p);
-        }
-
-        if ((s = kit_string_new ("fooobar2", 100)) != NULL) {
-                p = kit_string_free (s, FALSE, NULL);
-                kit_assert (strcmp ("fooobar2", p) == 0);
-                kit_free (p);
-        }
-
-
-        kit_assert (kit_string_percent_encode (buf, sizeof (buf), "Hello World; Nice day!") < sizeof (buf));
-        kit_assert (strcmp (buf, "Hello%20World%3B%20Nice%20day%21") == 0);
-        kit_assert (kit_string_percent_decode (buf));
-        kit_assert (strcmp (buf, "Hello World; Nice day!") == 0);
-
-        for (n = 0; n < sizeof (bad_strings) / sizeof (char *); n++) {
-                if ((p = kit_strdup (bad_strings[n])) != NULL) {
-                        kit_assert (!kit_string_percent_decode (p) && errno == EINVAL);
-                        kit_free (p);
-                }
-        }
-
-        kit_assert (kit_string_entry_create (buf, sizeof (buf), 
-                                             "key1", "val1",
-                                             "key2", "val2",
-                                             "key3", "val3",
-                                             NULL) < sizeof (buf) &&
-                    strcmp (buf, "key1=val1:key2=val2:key3=val3") == 0);
-
-        kit_assert (kit_string_entry_create (buf, sizeof (buf), 
-                                             "key1;", "val1=val1x",
-                                             "key2%", "val2!",
-                                             NULL) < sizeof (buf) &&
-                    strcmp (buf, "key1%3B=val1%3Dval1x:key2%25=val2%21") == 0);
-
-        kit_assert (kit_string_entry_create (buf, sizeof (buf), 
-                                             "key1", "val1",
-                                             "key2", NULL) == 0 && errno == EINVAL);
-
-        kit_assert (kit_string_entry_create (buf, 3, 
-                                             "key1", "val1",
-                                             "key2", "val2", NULL) > 3);
-
-        kit_assert (kit_string_entry_create (buf, sizeof (buf), 
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "a","a","a","a","a","a","a","a","a","a","a","a","a","a","a","a",
-                                             "b", "c", NULL) == 0 && errno == EOVERFLOW);
-
-        kit_assert (!kit_string_entry_parse ("key=val:invalidkeyval:key2=val2", _ep1, &num) && 
-                    (errno == EINVAL || errno == ENOMEM));
-        kit_assert (!kit_string_entry_parse ("key;=val:key2=val2", _ep1, &num) && 
-                    (errno == EINVAL || errno == ENOMEM));
-        kit_assert (!kit_string_entry_parse ("key=val:key2=val2;", _ep1, &num) && 
-                    (errno == EINVAL || errno == ENOMEM));
-
-        kit_assert (kit_string_entry_create (buf, sizeof (buf), 
-                                             "a", "aval",
-                                             "a", "aval2",
-                                             "b", "bval",
-                                             "c", "cval",
-                                             "some_other_key", "some_value",
-                                             "escaped;here:right=", "yes! it's ==:crazy!",
-                                             NULL) < sizeof (buf));
-        num = 0;
-        if (kit_string_entry_parse (buf, _ep1, &num)) {
-                kit_assert (num == 6);
-        } else {
-                kit_assert (errno == ENOMEM);
-        }
-
-        num = 0; 
-        errno = 0;
-        kit_assert (!kit_string_entry_parse ("a=0:b=1:c=2", _ep2, &num));
-        if (num > 0)
-                kit_assert (errno == 0);
-        else
-                kit_assert (errno == ENOMEM);
-
-
-        if ((p = kit_strdup (str)) != NULL) {
-                kit_assert (strcmp (p, "Hello world") == 0);
-                kit_free (p);
-        }
-
-        if ((p = kit_strndup (str, 5)) != NULL) {
-                kit_assert (strcmp (p, "Hello") == 0);
-                kit_free (p);
-        }
-
-        if ((p = kit_strndup (str, 100)) != NULL) {
-                kit_assert (strcmp (p, "Hello world") == 0);
-                kit_free (p);
-        }
-
-        if ((p = kit_strdup_printf ("Hello %d", 5)) != NULL) {
-                kit_assert (strcmp (p, "Hello 5") == 0);
-                kit_free (p);
-        }
-
-        kit_assert ( kit_str_has_suffix ("12345", "45"));
-        kit_assert ( kit_str_has_suffix ("12345", "12345"));
-        kit_assert (!kit_str_has_suffix ("12345", "123456"));
-
-        kit_assert ( kit_str_has_prefix ("12345", "12"));
-        kit_assert ( kit_str_has_prefix ("12345", "12345"));
-        kit_assert (!kit_str_has_prefix ("12345", "123456"));
-
-        if ((tokens = kit_strsplit ("abc:012:xyz", ':', &num_tokens)) != NULL)  {
-                kit_assert (num_tokens == 3);
-                kit_assert (kit_strv_length (tokens) == 3);
-                kit_assert (strcmp (tokens[0], "abc") == 0);
-                kit_assert (strcmp (tokens[1], "012") == 0);
-                kit_assert (strcmp (tokens[2], "xyz") == 0);
-                kit_strfreev (tokens);
-        }
-
-        if ((tokens = kit_strsplit ("abc012xyz", ':', &num_tokens)) != NULL)  {
-                kit_assert (num_tokens == 1);
-                kit_assert (kit_strv_length (tokens) == 1);
-                kit_assert (strcmp (tokens[0], "abc012xyz") == 0);
-                kit_strfreev (tokens);
-        }
-
-        if ((tokens = kit_strsplit ("", ':', &num_tokens)) != NULL)  {
-                kit_assert (num_tokens == 1);
-                kit_assert (kit_strv_length (tokens) == 1);
-                kit_assert (strcmp (tokens[0], "") == 0);
-                kit_strfreev (tokens);
-        }
-
-        if ((p = kit_strdup ("foobar")) != NULL) {
-                if ((p2 = kit_str_append (p, "_cool")) != NULL) {
-                        p = p2;
-
-                        kit_assert (strcmp (p, "foobar_cool") == 0);
-                }
-
-                kit_free (p);
-        }
-
-        if ((p = kit_str_append (NULL, "baz")) != NULL) {
-                kit_assert (strcmp (p, "baz") == 0);
-                kit_free (p);
-        }
-
-        return TRUE;
-}
-
-KitTest _test_string = {
-        "kit_string",
-        NULL,
-        NULL,
-        _run_test
-};
-
-#endif /* KIT_BUILD_TESTS */
diff --git a/src/kit/kit-string.h b/src/kit/kit-string.h
deleted file mode 100644
index 3f58e21..0000000
--- a/src/kit/kit-string.h
+++ /dev/null
@@ -1,94 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-string.h : String utilities
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_STRING_H
-#define KIT_STRING_H
-
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-char *kit_strdup         (const char *s);
-char *kit_strndup        (const char *s, size_t n);
-#ifdef __sun
-char *kit_strdup_printf  (const char *format, ...);
-#else
-char *kit_strdup_printf  (const char *format, ...) __attribute__((__format__ (__printf__, 1, 2)));
-#endif
-char *kit_strdup_vprintf (const char *format, va_list args);
-char *kit_str_append     (char *s, const char *s2);
-
-kit_bool_t kit_str_has_prefix (const char *s, const char *prefix);
-kit_bool_t kit_str_has_suffix (const char *s, const char *suffix);
-
-char **kit_strsplit (const char *s, char delim, size_t *num_tokens);
-
-void kit_strfreev (char **str_array);
-size_t kit_strv_length (char **str_array);
-
-/**
- * KitStringEntryParseFunc:
- * @key: key of one of the entries
- * @value: value of one of the entries
- * @user_data: user data passed to kit_string_entry_parse()
- *
- * Type of callback function to use in kit_string_entry_parse()
- *
- * Returns: If %FALSE is returned the parsing will be aborted and
- * kit_string_entry_parse() will return FALSE.
- */
-typedef kit_bool_t (*KitStringEntryParseFunc) (const char *key, const char *value, void *user_data);
-
-kit_bool_t kit_string_entry_parse (const char *entry, KitStringEntryParseFunc func, void *user_data);
-
-kit_bool_t  kit_string_percent_decode (char *s);
-size_t      kit_string_percent_encode (char *buf, size_t buf_size, const char *s);
-
-size_t      kit_string_entry_create (char *buf, size_t buf_size, ...);
-size_t      kit_string_entry_createv (char *buf, size_t buf_size, const char *kv_pairs[]);
-
-
-struct _KitString;
-typedef struct _KitString KitString;
-
-KitString   *kit_string_new         (const char *init, size_t len);
-char        *kit_string_free        (KitString *s, kit_bool_t free_segment, size_t *out_segment_size);
-kit_bool_t   kit_string_ensure_size (KitString *s, size_t new_size);
-kit_bool_t   kit_string_append_c    (KitString *s, char c);
-kit_bool_t   kit_string_append      (KitString *s, const char *str);
-
-KIT_END_DECLS
-
-#endif /* KIT_STRING_H */
-
-
diff --git a/src/kit/kit-test-main.c b/src/kit/kit-test-main.c
deleted file mode 100644
index ccdcf79..0000000
--- a/src/kit/kit-test-main.c
+++ /dev/null
@@ -1,52 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-test-main.c : Run test suites for libkit
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <kit/kit-test.h>
-
-static KitTest *tests[] = {
-        &_test_message,
-        &_test_memory,
-        &_test_string,
-        &_test_list,
-        &_test_hash,
-        &_test_file,
-        &_test_spawn,
-        &_test_entity,
-};
-
-int 
-main (int argc, char *argv[])
-{
-        if (kit_test_run (tests, sizeof (tests) / sizeof (KitTest*)))
-                return 0;
-        else
-                return 1;
-}
diff --git a/src/kit/kit-test.c b/src/kit/kit-test.c
deleted file mode 100644
index 3f8718f..0000000
--- a/src/kit/kit-test.c
+++ /dev/null
@@ -1,142 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-test.c : PolicyKit test
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-#ifdef HAVE_SOLARIS
-#include <sys/types.h>
-#endif
-#include <kit/kit-test.h>
-#include <kit/kit-memory.h>
-
-/**
- * SECTION:kit-test
- * @title: Unit testing
- * @short_description: Unit testing
- *
- * Functions used for unit testing.
- */
-
-/**
- * kit_test_run:
- * @tests: array of #KitTest objects
- * @num_tests: size of @tests array
- *
- * Runs a number of tests simulating Out Of Memory. Checks for both
- * memory and file descriptor leaks. 
- *
- * This function is only available if libkit have been built with
- * KIT_BUILD_TESTS.
- *
- * Returns: %TRUE only if all tests succeed without memory or file descriptor leaks
- */
-kit_bool_t
-kit_test_run (KitTest **tests, size_t num_tests)
-{
-        kit_bool_t ret;
-        unsigned int n;
-
-        /* be optimistic! */
-        ret = TRUE;
-
-        printf ("Running %d unit tests\n", num_tests);
-        for (n = 0; n < num_tests; n++) {
-                int m;
-                int total_allocs;
-                int delta;
-                int num_fd;
-                int num_fd_after;
-                KitTest *test = tests[n];
-
-                _kit_memory_reset ();
-
-                if (test->setup != NULL)
-                        test->setup ();
-
-                num_fd = _kit_get_num_fd ();
-                printf ("Running: %s\n", test->name);
-                if (!test->run ()) {
-                        printf ("Failed\n");
-                        ret = FALSE;
-                        goto test_done;
-                }
-                num_fd_after = _kit_get_num_fd ();
-
-                total_allocs = _kit_memory_get_total_allocations ();
-                printf ("  Unit test made %d allocations in total\n", total_allocs);
-                
-                delta = _kit_memory_get_current_allocations ();
-                if (delta != 0) {
-                        printf ("  Unit test leaked %d allocations\n", delta);
-                        _kit_memory_print_outstanding_allocations ();
-                        ret = FALSE;
-                }
-                if (num_fd != num_fd_after) {
-                        printf ("  Unit test leaked %d file descriptors\n", num_fd_after - num_fd);
-                        ret = FALSE;
-                }
-                
-                for (m = 0; m < total_allocs; m++) {
-                        printf ("  Failing allocation %d of %d\n", m + 1, total_allocs);
-                        
-                        _kit_memory_reset ();
-                        _kit_memory_fail_nth_alloc (m);
-
-                        num_fd = _kit_get_num_fd ();
-                        if (!test->run ()) {
-                                printf ("  Failed\n");
-                                ret = FALSE;
-                                continue;
-                        }
-                        num_fd_after = _kit_get_num_fd ();
-                        
-                        delta = _kit_memory_get_current_allocations ();
-                        if (delta != 0) {
-                                printf ("  Unit test leaked %d allocations:\n", delta);
-                                _kit_memory_print_outstanding_allocations ();
-                                ret = FALSE;
-                        }
-                        if (num_fd != num_fd_after) {
-                                printf ("  Unit test leaked %d file descriptors\n", num_fd_after - num_fd);
-                                ret = FALSE;
-                        }
-
-                }
-
-        test_done:
-                if (test->teardown != NULL)
-                        test->teardown ();
-        }
-
-        return ret;
-}
diff --git a/src/kit/kit-test.h b/src/kit/kit-test.h
deleted file mode 100644
index a3869c4..0000000
--- a/src/kit/kit-test.h
+++ /dev/null
@@ -1,72 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit-test.h : PolicyKit test
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#if !defined (KIT_COMPILATION) && !defined(_KIT_INSIDE_KIT_H)
-#error "Only <kit/kit.h> can be included directly, this file may disappear or change contents."
-#endif
-
-#ifndef KIT_TEST_H
-#define KIT_TEST_H
-
-#include <kit/kit.h>
-
-KIT_BEGIN_DECLS
-
-/**
- * KitTest:
- * @name: name of the unit test
- * @setup: setup function
- * @teardown: teardown function
- * @run: actual test function.
- *
- * Test suite abstraction. See kit_test_run() for details.
- */
-typedef struct {
-        const char *name;
-        void (*setup) (void);
-        void (*teardown) (void);
-        kit_bool_t (*run) (void);
-} KitTest;
-
-kit_bool_t kit_test_run (KitTest **tests, size_t num_tests);
-
-extern KitTest _test_memory;
-extern KitTest _test_string;
-extern KitTest _test_hash;
-extern KitTest _test_list;
-extern KitTest _test_file;
-extern KitTest _test_spawn;
-extern KitTest _test_message;
-extern KitTest _test_entity;
-
-KIT_END_DECLS
-
-#endif /* KIT_TEST_H */
-
-
diff --git a/src/kit/kit.h b/src/kit/kit.h
deleted file mode 100644
index 1457acf..0000000
--- a/src/kit/kit.h
+++ /dev/null
@@ -1,164 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * kit.h : OOM-safe utility library
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifndef KIT_H
-#define KIT_H
-
-/**
- * SECTION:kit
- * @title: Macros
- * @short_description: Macros
- *
- * Various low-level macros.
- **/
-
-#ifdef __cplusplus
-#  define KIT_BEGIN_DECLS extern "C" {
-#  define KIT_END_DECLS }
-#else
-/**
- * KIT_BEGIN_DECLS:
- *
- * C++ include header guard.
- */
-#  define KIT_BEGIN_DECLS
-/**
- * KIT_END_DECLS:
- *
- * C++ include header guard.
- */
-#  define KIT_END_DECLS
-#endif
-
-/**
- * kit_bool_t:
- *
- * A boolean, valid values are #TRUE and #FALSE.
- */
-typedef int kit_bool_t;
-
-#ifndef TRUE
-#  define TRUE 1
-#endif
-#ifndef FALSE
-#  define FALSE 0
-#endif
-
-void kit_print_backtrace (void);
-
-#ifdef HAVE_SOLARIS
-#define __PRETTY_FUNCTION__ __func__
-#endif
-/**
- * kit_assert:
- * @expr: expression
- *
- * Debugging macro to terminate the application if the assertion
- * fails. If the assertion fails (i.e. the expression is not true), an
- * error message is logged and the application is terminated.
- */
-#define kit_assert(expr)                                                                        \
-do {                                                                                            \
-        if (expr) {                                                                             \
-                ;                                                                               \
-        } else {                                                                                \
-                kit_warning ("%s:%d:%s(): %s", __FILE__, __LINE__, __PRETTY_FUNCTION__, #expr); \
-                kit_print_backtrace ();                                                         \
-                exit (1);                                                                       \
-        }                                                                                       \
-} while (0)
-
-/**
- * kit_return_if_fail:
- * @expr: expression
- *
- * Returns from the current function if the expression is not true. If
- * the expression evaluates to #FALSE, an error message is logged and
- * the function returns. This can only be used in functions which do
- * not return a value.
- *
- * Returns: nothing
- */
-#define kit_return_if_fail(expr)                                                                \
-do {                                                                                            \
-        if (expr) {                                                                             \
-                ;                                                                               \
-        } else {                                                                                \
-                kit_warning ("%s:%d:%s(): %s", __FILE__, __LINE__, __PRETTY_FUNCTION__, #expr); \
-                kit_print_backtrace ();                                                         \
-                return;                                                                         \
-        }                                                                                       \
-} while (0)
-
-/**
- * kit_return_val_if_fail:
- * @expr: expression
- * @val: the value to return if the expression evaluates does not
- * evaluate to #TRUE
- *
- * Returns from the current function, returning the value @val, if the
- * expression is not true. If the expression evaluates to #FALSE, an
- * error message is logged and val is returned.
- *
- * Returns: nothing
- */
-#define kit_return_val_if_fail(expr,val)                                                        \
-do {                                                                                            \
-        if (expr) {                                                                             \
-                ;                                                                               \
-        } else {                                                                                \
-                kit_warning ("%s:%d:%s(): %s", __FILE__, __LINE__, __PRETTY_FUNCTION__, #expr); \
-                kit_print_backtrace ();                                                         \
-                return val;                                                                     \
-        }                                                                                       \
-} while (0)
-
-
-
-#define _KIT_INSIDE_KIT_H 1
-
-#ifdef HAVE_SOLARIS
-#include <sys/types.h>
-#endif
-#include <kit/kit-memory.h>
-#include <kit/kit-string.h>
-#include <kit/kit-lib.h>
-#include <kit/kit-list.h>
-#include <kit/kit-hash.h>
-#include <kit/kit-file.h>
-#include <kit/kit-spawn.h>
-#include <kit/kit-message.h>
-#include <kit/kit-test.h>
-#include <kit/kit-entity.h>
-
-#undef _KIT_INSIDE_KIT_H
-
-#endif /* KIT_H */
-
-
diff --git a/src/polkit-grant/Makefile.am b/src/polkit-grant/Makefile.am
deleted file mode 100644
index 87c821b..0000000
--- a/src/polkit-grant/Makefile.am
+++ /dev/null
@@ -1,183 +0,0 @@
-## Process this file with automake to produce Makefile.in
-
-INCLUDES = \
-	-I$(top_builddir)/src -I$(top_srcdir)/src \
-	-DPACKAGE_LIBEXEC_DIR=\""$(libexecdir)"\" \
-	-DPACKAGE_SYSCONF_DIR=\""$(sysconfdir)"\" \
-	-DPACKAGE_DATA_DIR=\""$(datadir)"\" \
-	-DPACKAGE_BIN_DIR=\""$(bindir)"\" \
-	-DPACKAGE_LOCALSTATE_DIR=\""$(localstatedir)"\" \
-	-DPACKAGE_LOCALE_DIR=\""$(localedir)"\" \
-	-DPACKAGE_LIB_DIR=\""$(libdir)"\" \
-	-D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT	\
-	-DPOLKIT_COMPILATION \
-	@GLIB_CFLAGS@ @DBUS_CFLAGS@
-
-lib_LTLIBRARIES=libpolkit-grant-1.la
-
-libpolkit_grant_1includedir=$(includedir)/polkit-1/polkit-grant
-
-libpolkit_grant_1include_HEADERS =              				\
-	polkit-grant.h
-
-libpolkit_grant_1_la_SOURCES =      					\
-	polkit-grant.h		polkit-grant.c
-
-
-if POLKIT_AUTHDB_DUMMY
-libpolkit_grant_1_la_SOURCES += polkit-authorization-db-dummy-write.c
-endif
-
-if POLKIT_AUTHDB_DEFAULT
-libpolkit_grant_1_la_SOURCES += polkit-authorization-db-write.c
-endif
-
-libpolkit_grant_1_la_LIBADD = @GLIB_LIBS@ @DBUS_LIBS@ $(top_builddir)/src/kit/libkit.la $(top_builddir)/src/polkit/libpolkit-1.la
-
-
-if POLKIT_BUILD_TESTS
-libpolkit_grant_1_la_LDFLAGS = -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) @R_DYNAMIC_LDFLAG@
-else
-libpolkit_grant_1_la_LDFLAGS = -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) @R_DYNAMIC_LDFLAG@ \
-                             -export-dynamic -no-undefined -export-symbols-regex '(^polkit_.*|_polkit_authorization_db_auth_file_add)'
-endif
-
-
-# Only if the authdb backend has the capability POLKIT_AUTHORIZATION_DB_CAPABILITY_CAN_OBTAIN
-# then the backend must supply the /usr/libexec/polkit-grant-helper program.. also remember to
-# adjust the PAM stuff in data/Makefile.am
-#
-if POLKIT_AUTHDB_DEFAULT
-libexec_PROGRAMS = polkit-grant-helper-1
-
-if POLKIT_AUTHFW_PAM
-libexec_PROGRAMS += polkit-grant-helper-pam-1
-endif
-
-if POLKIT_AUTHFW_SHADOW
-libexec_PROGRAMS += polkit-grant-helper-shadow-1
-endif
-
-libexec_PROGRAMS += polkit-explicit-grant-helper-1 polkit-revoke-helper-1
-
-polkit_grant_helper_1_SOURCES = polkit-grant-helper.c
-polkit_grant_helper_1_LDADD = @GLIB_LIBS@ @DBUS_LIBS@ $(top_builddir)/src/kit/libkit.la $(top_builddir)/src/polkit/libpolkit-1.la libpolkit-grant-1.la
-
-if POLKIT_AUTHFW_PAM
-polkit_grant_helper_pam_1_SOURCES = polkit-grant-helper-pam.c
-polkit_grant_helper_pam_1_LDADD = @AUTH_LIBS@ $(top_builddir)/src/kit/libkit.la $(top_builddir)/src/polkit/libpolkit-1.la
-endif
-
-if POLKIT_AUTHFW_SHADOW
-polkit_grant_helper_shadow_1_SOURCES = polkit-grant-helper-shadow.c
-polkit_grant_helper_shadow_1_LDADD = @AUTH_LIBS@
-endif
-
-polkit_explicit_grant_helper_1_SOURCES = polkit-explicit-grant-helper.c
-polkit_explicit_grant_helper_1_CFLAGS = @DBUS_CFLAGS@
-polkit_explicit_grant_helper_1_LDADD = $(top_builddir)/src/kit/libkit.la $(top_builddir)/src/polkit/libpolkit-1.la libpolkit-grant-1.la
-
-polkit_revoke_helper_1_SOURCES = polkit-revoke-helper.c
-polkit_revoke_helper_1_CFLAGS = @DBUS_CFLAGS@
-polkit_revoke_helper_1_LDADD = $(top_builddir)/src/kit/libkit.la $(top_builddir)/src/polkit/libpolkit-1.la
-
-# polkit-grant-helper needs to be setgid polkituser to be able to
-# write cookies to /var/lib/PolicyKit and /var/run/PolicyKit
-#
-# polkit-grant-helper-* need to be setuid root because it's used to
-# authenticate not only the invoking user, but possibly also root
-# and/or other users. As only polkit-grant-helper will invoke it we
-# make it owned by the polkitiuser group and non-executable to the
-# world
-#
-# polkit-explicit-grant-helper needs to be setgid $POLKIT_GROUP to be
-# able to edit authorization files in /var/lib/PolicyKit and
-# /var/run/PolicyKit
-#
-# polkit-revoke-helper needs to be setgid $POLKIT_GROUP to be able to
-# edit authorization files in /var/lib/PolicyKit and
-# /var/run/PolicyKit
-#
-install-exec-hook:
-	-chgrp $(POLKIT_GROUP) $(DESTDIR)$(libexecdir)/polkit-grant-helper-1
-	-chmod 2755 $(DESTDIR)$(libexecdir)/polkit-grant-helper-1
-if POLKIT_AUTHFW_PAM
-	-chgrp $(POLKIT_GROUP) $(DESTDIR)$(libexecdir)/polkit-grant-helper-pam-1
-	-chmod 4754 $(DESTDIR)$(libexecdir)/polkit-grant-helper-pam-1
-endif
-if POLKIT_AUTHFW_SHADOW
-	-chgrp $(POLKIT_GROUP) $(DESTDIR)$(libexecdir)/polkit-grant-helper-shadow-1
-	-chmod 4750 $(DESTDIR)$(libexecdir)/polkit-grant-helper-shadow-1
-endif
-	-chgrp $(POLKIT_GROUP) $(DESTDIR)$(libexecdir)/polkit-explicit-grant-helper-1
-	-chmod 2755 $(DESTDIR)$(libexecdir)/polkit-explicit-grant-helper-1
-	-chgrp $(POLKIT_GROUP) $(DESTDIR)$(libexecdir)/polkit-revoke-helper-1
-	-chmod 2755 $(DESTDIR)$(libexecdir)/polkit-revoke-helper-1
-endif
-
-## note that TESTS has special meaning (stuff to use in make check)
-## so if adding tests not to be run in make check, don't add them to 
-## TESTS
-if KIT_BUILD_TESTS
-TESTS_ENVIRONMENT=
-TESTS=polkit-grant-test
-
-check_PROGRAMS=$(TESTS)
-
-polkit_grant_test_SOURCES=				\
-	polkit-grant-test.h	polkit-grant-test.c
-
-polkit_grant_test_LDADD=$(top_builddir)/src/polkit-grant/libpolkit-grant-1.la
-polkit_grant_test_LDFLAGS=
-
-if KIT_GCOV_ENABLED
-clean-gcov:
-	rm -f *.gcov .libs/*.gcda
-
-.PHONY: coverage-report.txt covered-files.txt
-
-covered-files.txt :
-	echo $(addprefix src/polkit-grant/,$(filter %.c,$(libpolkit_grant_1_la_SOURCES))) > covered-files.txt
-if POLKIT_AUTHDB_DEFAULT
-	echo src/polkit-grant/polkit-explicit-grant-helper.c >> covered-files.txt
-	echo src/polkit-grant/polkit-grant-helper.c >> covered-files.txt
-if POLKIT_AUTHFW_PAM
-	echo src/polkit-grant/polkit-grant-helper-pam.c >> covered-files.txt
-endif
-if POLKIT_AUTHFW_SHADOW
-	echo src/polkit-grant/polkit-grant-helper-shadow.c >> covered-files.txt
-endif
-	echo src/polkit-grant/polkit-revoke-helper.c >> covered-files.txt
-endif
-
-coverage-report.txt : covered-files.txt clean-gcov all check 
-	gcov $(filter %.c,$(libpolkit_grant_1_la_SOURCES)) -o .libs/ > /dev/null
-if POLKIT_AUTHDB_DEFAULT
-	gcov polkit-explicit-grant-helper.c -o .libs/ > /dev/null
-	gcov polkit-grant-helper.c -o .libs/ > /dev/null
-if POLKIT_AUTHFW_PAM
-	gcov polkit-grant-helper-pam.c -o .libs/ > /dev/null
-endif
-if POLKIT_AUTHFW_SHADOW
-	gcov polkit-grant-helper-shadow.c -o .libs/ > /dev/null
-endif
-	gcov polkit-revoke-helper.c -o .libs/ > /dev/null
-endif
-	$(top_srcdir)/test/create-coverage-report.sh "module polkit-grant" `cat covered-files.txt` > coverage-report.txt
-
-check-coverage : coverage-report.txt
-	cat coverage-report.txt
-else
-coverage-report.txt:
-	@echo "Need to reconfigure with --enable-gcov"
-
-check-coverage:
-	@echo "Need to reconfigure with --enable-gcov"
-endif
-
-else
-TESTS=
-endif
-
-clean-local :
-	rm -f *~ *.bb *.bbg *.da *.gcov .libs/*.da .libs/*.bbg 
diff --git a/src/polkit-grant/polkit-authorization-db-dummy-write.c b/src/polkit-grant/polkit-authorization-db-dummy-write.c
deleted file mode 100644
index ac1fcc5..0000000
--- a/src/polkit-grant/polkit-authorization-db-dummy-write.c
+++ /dev/null
@@ -1,111 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * polkit-authorization-db.c : Dummy authorization database
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <sys/stat.h>
-#include <sys/types.h>
-#include <sys/time.h>
-#include <sys/wait.h>
-#include <errno.h>
-#include <string.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <pwd.h>
-
-#include <glib.h>
-
-#include <polkit/polkit-debug.h>
-#include <polkit/polkit-authorization-db.h>
-#include <polkit/polkit-utils.h>
-#include <polkit/polkit-private.h>
-
-/* PolKitAuthorizationDB structure is defined in polkit/polkit-private.h */
-
-polkit_bool_t
-polkit_authorization_db_add_entry_process_one_shot (PolKitAuthorizationDB *authdb,
-                                                    PolKitAction          *action,
-                                                    PolKitCaller          *caller,
-                                                    uid_t                  user_authenticated_as)
-{
-        return FALSE;
-}
-
-polkit_bool_t
-polkit_authorization_db_add_entry_process          (PolKitAuthorizationDB *authdb,
-                                                    PolKitAction          *action,
-                                                    PolKitCaller          *caller,
-                                                    uid_t                  user_authenticated_as)
-{
-        return FALSE;
-}
-
-polkit_bool_t
-polkit_authorization_db_add_entry_session          (PolKitAuthorizationDB *authdb,
-                                                    PolKitAction          *action,
-                                                    PolKitCaller          *caller,
-                                                    uid_t                  user_authenticated_as)
-{
-        return FALSE;
-}
-
-polkit_bool_t
-polkit_authorization_db_add_entry_always           (PolKitAuthorizationDB *authdb,
-                                                    PolKitAction          *action,
-                                                    PolKitCaller          *caller,
-                                                    uid_t                  user_authenticated_as)
-{
-        return FALSE;
-}
-
-polkit_bool_t
-polkit_authorization_db_grant_to_uid           (PolKitAuthorizationDB          *authdb,
-                                                PolKitAction                   *action,
-                                                uid_t                           uid,
-                                                PolKitAuthorizationConstraint **constraints,
-                                                PolKitError                   **error)
-{
-        polkit_error_set_error (error, POLKIT_ERROR_NOT_SUPPORTED, "Not supported");
-        return FALSE;
-}
-
-polkit_bool_t
-polkit_authorization_db_grant_negative_to_uid           (PolKitAuthorizationDB          *authdb,
-                                                         PolKitAction                   *action,
-                                                         uid_t                           uid,
-                                                         PolKitAuthorizationConstraint **constraints,
-                                                         PolKitError                   **error)
-{
-        polkit_error_set_error (error, POLKIT_ERROR_NOT_SUPPORTED, "Not supported");
-        return FALSE;
-}
diff --git a/src/polkit-grant/polkit-authorization-db-write.c b/src/polkit-grant/polkit-authorization-db-write.c
deleted file mode 100644
index fec91a1..0000000
--- a/src/polkit-grant/polkit-authorization-db-write.c
+++ /dev/null
@@ -1,922 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
-/***************************************************************************
- *
- * polkit-authorization-db.c : Represents the authorization database
- *
- * Copyright (C) 2007 David Zeuthen, <david at fubar.dk>
- *
- * Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use, copy,
- * modify, merge, publish, distribute, sublicense, and/or sell copies
- * of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *
- **************************************************************************/
-
-#ifdef HAVE_CONFIG_H
-#  include <config.h>
-#endif
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <sys/stat.h>
-#include <sys/types.h>
-#include <sys/time.h>
-#include <sys/wait.h>
-#include <errno.h>
-#include <string.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <pwd.h>
-
-#include <glib.h>
-
-#include <polkit/polkit-debug.h>
-#include <polkit/polkit-authorization-db.h>
-#include <polkit/polkit-utils.h>
-#include <polkit/polkit-private.h>
-
-/**
- * SECTION:polkit-authorization-db
- **/
-
-
-static polkit_bool_t
-_write_to_fd (int fd, const char *str, ssize_t str_len)
-{
-        polkit_bool_t ret;
-        ssize_t written;
-
-        ret = FALSE;
-
-        written = 0;
-        while (written < str_len) {
-                ssize_t ret;
-                ret = write (fd, str + written, str_len - written);
-                if (ret < 0) {
-                        if (errno == EAGAIN || errno == EINTR) {
-                                continue;
-                        } else {
-                                goto out;
-                        }
-                }
-                written += ret;
-        }
-
-        ret = TRUE;
-
-out:
-        return ret;
-}
-
-polkit_bool_t 
-_polkit_authorization_db_auth_file_add (polkit_bool_t transient, uid_t uid, char *str_to_add)
-{
-        int fd;
-        char *contents;
-        gsize contents_size;
-        char *path;
-        char *path_tmp;
-        GError *error;
-        polkit_bool_t ret;
-        struct stat statbuf;
-        struct passwd *pw;
-        const char *root;
-        char *newline = "\n";
-
-        if (transient)
-                root = PACKAGE_LOCALSTATE_DIR "/run/polkit-1";
-        else
-                root = PACKAGE_LOCALSTATE_DIR "/lib/polkit-1";
-
-        ret = FALSE;
-        path = NULL;
-        path_tmp = NULL;
-        contents = NULL;
-
-        pw = getpwuid (uid);
-        if (pw == NULL) {
-                g_warning ("cannot lookup user name for uid %d\n", uid);
-                goto out;
-        }
-
-        path = g_strdup_printf ("%s/user-%s.auths", root, pw->pw_name);
-        path_tmp = g_strdup_printf ("%s.XXXXXX", path);
-
-        if (stat (path, &statbuf) != 0 && errno == ENOENT) {
-                //fprintf (stderr, "path=%s does not exist (egid=%d): %m!\n", path, getegid ());
-
-                g_free (path_tmp);
-                path_tmp = path;
-                path = NULL;
-
-                /* Write a nice blurb if we're creating the file for the first time */
-
-                contents = g_strdup_printf (
-                        "# This file lists authorizations for user %s\n"
-                        "%s"
-                        "# \n"
-                        "# File format may change at any time; do not rely on it. To manage\n"
-                        "# authorizations use polkit-auth(1) instead.\n"
-                        "\n",
-                        pw->pw_name,
-                        transient ? "# (these are temporary a