[PackageKit-commit] packagekit: Branch 'master' - 21 commits
Richard Hughes
hughsient at kemper.freedesktop.org
Tue Apr 22 18:47:24 PDT 2008
backends/alpm/pk-backend-alpm.c | 1346 +++++++++++++++++-----------
backends/box/pk-backend-box.c | 2
backends/conary/pk-backend-conary.c | 2
backends/dummy/pk-backend-dummy.c | 2
backends/pisi/helpers/install-file.py | 5
backends/pisi/helpers/pisiBackend.py | 2
backends/pisi/pk-backend-pisi.c | 4
backends/smart/helpers/install-file.py | 5
backends/smart/helpers/smartBackend.py | 2
backends/smart/pk-backend-smart.c | 4
backends/test/pk-backend-test-fail.c | 2
backends/test/pk-backend-test-succeed.c | 2
backends/yum/helpers/install-file.py | 7
backends/yum/helpers/yumBackend.py | 25
backends/yum/pk-backend-yum.c | 4
backends/yum2/pk-backend-yum2.c | 4
backends/zypp/pk-backend-zypp.cpp | 2
client/pk-console.c | 50 +
contrib/udev/Makefile.am | 2
docs/spec/Makefile.am | 7
docs/spec/pk-concepts.xml | 79 +
docs/spec/pk-transactions-failure.png |binary
docs/spec/pk-transactions-sig-install.png |binary
docs/spec/pk-transactions-success.png |binary
docs/spec/pk-transactions-trusted.png |binary
docs/spec/pk-transactions.svg | 1275 ++++++++++++++++++++++++++
libpackagekit/pk-client.c | 14
libpackagekit/pk-client.h | 1
policy/org.freedesktop.packagekit.policy.in | 15
python/packagekit/backend.py | 2
python/packagekit/daemonBackend.py | 2
src/pk-backend-dbus.c | 3
src/pk-backend-dbus.h | 1
src/pk-backend.h | 1
src/pk-interface-transaction.xml | 1
src/pk-security-dummy.c | 2
src/pk-security-polkit.c | 18
src/pk-security.h | 1
src/pk-transaction.c | 36
src/pk-transaction.h | 1
40 files changed, 2341 insertions(+), 590 deletions(-)
New commits:
commit 126eb66e7a3a1fccf0a7e6c73de6617f9d40403e
Merge: c5890fb... c38a176...
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 02:12:29 2008 +0100
Merge branch 'master' into secure
commit c38a17688905ba83c131bd458c2b127e26755887
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 01:32:20 2008 +0100
trailing backspace whore
diff --git a/docs/spec/pk-concepts.xml b/docs/spec/pk-concepts.xml
index 73c4cad..5d4b533 100644
--- a/docs/spec/pk-concepts.xml
+++ b/docs/spec/pk-concepts.xml
@@ -538,7 +538,7 @@
This will fail if the package does not have a valid GPG key, and ordinarily the transaction
would fail. What the client can do, e.g. using <literal>gnome-packagekit</literal>, is
to re-request the <literal>InstallFile</literal> with <literal>non-trusted</literal>.
- This will use a different PolicyKit authentication, and allow the file to succeed.
+ This will use a different PolicyKit authentication, and allow the file to succeed.
</para>
<para>
So why do we bother calling <literal>trusted</literal> in the first place?
commit 5e16ca083789501f044c7d76b94ea556a218215b
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 00:25:21 2008 +0100
add some diagrams to show client<->server interactions
diff --git a/docs/spec/Makefile.am b/docs/spec/Makefile.am
index 407012b..ccb8818 100644
--- a/docs/spec/Makefile.am
+++ b/docs/spec/Makefile.am
@@ -1,6 +1,11 @@
IMAGE_FILES = \
pk-structure.png \
- pk-structure.svg
+ pk-structure.svg \
+ pk-transactions.svg \
+ pk-transactions-failure.png \
+ pk-transactions-sig-install.png \
+ pk-transactions-success.png \
+ pk-transactions-trusted.png
SPEC_XML_FILES = \
pk-backend-compiled.xml \
diff --git a/docs/spec/pk-concepts.xml b/docs/spec/pk-concepts.xml
index 1f294c0..73c4cad 100644
--- a/docs/spec/pk-concepts.xml
+++ b/docs/spec/pk-concepts.xml
@@ -496,8 +496,85 @@
</itemizedlist>
</sect1>
+ <sect1 id="introduction-ideas-transactions">
+ <title>Transactions</title>
+ <para>
+ PackageKit does not ask the user questions when the transaction is running.
+ It also supports a fire-and-forget method invocation, which means that transactions will
+ have one calling method, and have many signals going back to the caller.
+ </para>
+ <para>
+ Each transaction is a new path on the <literal>org.freedesktop.PackageKit</literal>
+ service, and to create a path you have to call <literal>GetTid</literal> on the base
+ interface which creates the new DBUS path, and returns the new path for you to connect to.
+ In the libpackagekit binding, <literal>PkControl</literal> handles the base interface,
+ whilst <literal>PkClient</literal> handles all the transaction interface stuff.
+ The <literal>org.freedesktop.PackageKit.Transaction</literal> interface can be used
+ on the newly created path, but only used once.
+ New methods require a new transaction path (i.e. another call to <literal>GetTid</literal>)
+ which is synchronous and thus very fast.
+ </para>
+ <para>
+ A typical successful transaction can be seen below.
+ </para>
+ <mediaobject id="pk-transactions-success">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-success.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ A typical simple transaction failure case can be seen below.
+ The user is not given the change to requeue the transaction as it is a fatal error.
+ </para>
+ <mediaobject id="pk-transactions-failure">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-failure.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ In this non-trivial example, a local file install is being attempted.
+ First the <literal>InstallFile</literal> is called with the <literal>trusted</literal>
+ flag set.
+ This will fail if the package does not have a valid GPG key, and ordinarily the transaction
+ would fail. What the client can do, e.g. using <literal>gnome-packagekit</literal>, is
+ to re-request the <literal>InstallFile</literal> with <literal>non-trusted</literal>.
+ This will use a different PolicyKit authentication, and allow the file to succeed.
+ </para>
+ <para>
+ So why do we bother calling <literal>trusted</literal> in the first place?
+ Well, the trusted PolicyKit role can be saved in the gnome-keyring, or could be
+ set to the users password as the GPG key is already trusted by the user.
+ The <literal>non-trusted</literal> action would likely ask for the administrator password,
+ and not allowed to be saved. This gives the user the benifit of installing trusted local
+ files without a password (common case) but requiring something stronger for untrusted or
+ unsigned files.
+ </para>
+ <mediaobject id="pk-transactions-trusted">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-trusted.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ If the package is signed, and a valid GPG signature is available, then we need to ask the
+ user to import the key, and re-run the transaction.
+ This is done as three transactions, as other transactions may be queued and have a higher
+ priority, and to make sure that the transaction object is not reused.
+ </para>
+ <mediaobject id="pk-transactions-sig-install">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-sig-install.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ If the package is signed, and a valid GPG signature is available, then we need to ask the
+ user to import the key, and re-run the transaction.
+ This is done as three transactions, as other transactions may be queued and have a higher
+ priority, and to make sure that the transaction object is not reused.
+ </para>
+ </sect1>
+
<sect1 id="introduction-ideas-transactionid">
- <title>Transaction ID</title>
+ <title>Transaction IDs</title>
<para>
A <literal>transaction_id</literal> is a unique identifier that
identifies the present or past transaction.
diff --git a/docs/spec/pk-transactions-failure.png b/docs/spec/pk-transactions-failure.png
new file mode 100644
index 0000000..a038ea3
Binary files /dev/null and b/docs/spec/pk-transactions-failure.png differ
diff --git a/docs/spec/pk-transactions-sig-install.png b/docs/spec/pk-transactions-sig-install.png
new file mode 100644
index 0000000..27949fc
Binary files /dev/null and b/docs/spec/pk-transactions-sig-install.png differ
diff --git a/docs/spec/pk-transactions-success.png b/docs/spec/pk-transactions-success.png
new file mode 100644
index 0000000..b299bfb
Binary files /dev/null and b/docs/spec/pk-transactions-success.png differ
diff --git a/docs/spec/pk-transactions-trusted.png b/docs/spec/pk-transactions-trusted.png
new file mode 100644
index 0000000..4085e8a
Binary files /dev/null and b/docs/spec/pk-transactions-trusted.png differ
diff --git a/docs/spec/pk-transactions.svg b/docs/spec/pk-transactions.svg
new file mode 100644
index 0000000..954e540
--- /dev/null
+++ b/docs/spec/pk-transactions.svg
@@ -0,0 +1,1275 @@
+<?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://creativecommons.org/ns#"
+ 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: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.46"
+ sodipodi:docname="pk-transactions.svg"
+ inkscape:output_extension="org.inkscape.output.svg.inkscape">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Mstart"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow2Mstart"
+ style="overflow:visible">
+ <path
+ id="path3246"
+ style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+ transform="scale(0.6) translate(0,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow2Lend"
+ style="overflow:visible;">
+ <path
+ id="path3243"
+ style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;"
+ d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+ transform="scale(1.1) rotate(180) translate(1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow2Lstart"
+ style="overflow:visible">
+ <path
+ id="path3240"
+ style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+ transform="scale(1.1) translate(1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow1Lstart"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow1Lstart"
+ style="overflow:visible">
+ <path
+ id="path3222"
+ 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>
+ <inkscape:perspective
+ sodipodi:type="inkscape:persp3d"
+ inkscape:vp_x="0 : 526.18109 : 1"
+ inkscape:vp_y="0 : 1000 : 0"
+ inkscape:vp_z="744.09448 : 526.18109 : 1"
+ inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
+ id="perspective10" />
+ </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="277.52317"
+ inkscape:cy="649.44446"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer1"
+ showgrid="true"
+ borderlayer="true"
+ inkscape:showpageshadow="false"
+ inkscape:window-width="1280"
+ inkscape:window-height="951"
+ inkscape:window-x="0"
+ inkscape:window-y="25">
+ <inkscape:grid
+ type="xygrid"
+ id="grid2403"
+ visible="true"
+ enabled="true"
+ color="#0000ff"
+ opacity="0.03137255"
+ empcolor="#0000ff"
+ empopacity="0.05882353" />
+ </sodipodi:namedview>
+ <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:none;fill-opacity:1;stroke:#000000;stroke-width:0.45442721;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6509"
+ width="475.04556"
+ height="189.96553"
+ x="30.451931"
+ y="862.33252"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:1;fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6507"
+ width="475"
+ height="230"
+ x="30.474718"
+ y="622.35529"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:1;fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6505"
+ width="475"
+ height="335"
+ x="30.597656"
+ y="277.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:1;fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.50000000000000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6503"
+ width="475"
+ height="255"
+ x="30"
+ y="12.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#8d5fd3;fill-opacity:1"
+ id="rect6269"
+ width="35"
+ height="105"
+ x="465"
+ y="37.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#ff8080;fill-opacity:1"
+ id="rect2405"
+ width="35"
+ height="245"
+ x="250"
+ y="17.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#5fd38d;fill-opacity:1"
+ id="rect2407"
+ width="35"
+ height="245"
+ x="35"
+ y="17.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#8d5fd3;fill-opacity:1"
+ id="rect2411"
+ width="35"
+ height="110"
+ x="465"
+ y="152.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-128.495"
+ y="60"
+ id="text2413"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan2415"
+ x="-128.495"
+ y="60"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-88.182495"
+ y="490"
+ id="text2417"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan2419"
+ x="-88.182495"
+ y="490"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-128.41687"
+ y="275"
+ id="text2421"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan2423"
+ x="-128.41687"
+ y="275"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 459.94306,52.36218 L 285,52.36218"
+ id="path6109"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75,32.36218 L 249.87185,32.36218"
+ id="path6113"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.33984"
+ y="27.362183"
+ id="text6115"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6117"
+ x="164.33984"
+ y="27.362183"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 244.97015,42.36906 L 119.58222,42.36906 L 109.94012,32.33406"
+ id="path6119"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.33984"
+ y="47.362183"
+ id="text6121"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6123"
+ x="370.33984"
+ y="47.362183"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallFile(trusted, f)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.05694,92.36218 L 465,92.36218"
+ id="path6125"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.17969"
+ y="87.362183"
+ id="text6127"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6129"
+ x="381.17969"
+ y="87.362183"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::ErrorCode(no-sig)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 459.53741,172.36218 L 284.59435,172.36218"
+ id="path6131"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="362.90131"
+ y="167.36218"
+ id="text6133"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6135"
+ x="362.90131"
+ y="167.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallFile(untrusted, f)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 289.53741,212.36218 L 464.48047,212.36218"
+ id="path6159"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="380.66016"
+ y="207.36218"
+ id="text6161"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6163"
+ x="380.66016"
+ y="207.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::StatusChanged(inst)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 289.53741,252.36218 L 464.48047,252.36218"
+ id="path6165"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="380.66016"
+ y="247.36218"
+ id="text6167"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6169"
+ x="380.66016"
+ y="247.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#ff8080;fill-opacity:1"
+ id="rect6171"
+ width="35"
+ height="325"
+ x="250.65753"
+ y="282.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#5fd38d;fill-opacity:1"
+ id="rect6173"
+ width="35"
+ height="325"
+ x="35.657532"
+ y="282.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-448.495"
+ y="60.597656"
+ id="text6177"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6179"
+ x="-448.495"
+ y="60.597656"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-423.41687"
+ y="275.59766"
+ id="text6185"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6187"
+ x="-423.41687"
+ y="275.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.6006,317.3903 L 285.65754,317.3903"
+ id="path6195"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.657536,297.3903 L 250.52939,297.3903"
+ id="path6199"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.99738"
+ y="292.39032"
+ id="text6201"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6203"
+ x="164.99738"
+ y="292.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.62769,307.39718 L 120.23976,307.39718 L 110.59766,297.36218"
+ id="path6205"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.99738"
+ y="312.39032"
+ id="text6207"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6209"
+ x="370.99738"
+ y="312.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.71448,357.3903 L 465.65754,357.3903"
+ id="path6211"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.83722"
+ y="352.39032"
+ id="text6213"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6215"
+ x="381.83722"
+ y="352.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::RepoSigRequired(key)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 461.25227,437.36216 L 286.30921,437.36216"
+ id="path6217"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="364.61615"
+ y="432.36218"
+ id="text6219"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6221"
+ x="364.61615"
+ y="432.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallSignature(key)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.6546,557.36218 L 465.59766,557.36218"
+ id="path6225"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.77734"
+ y="552.36218"
+ id="text6227"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6229"
+ x="381.77734"
+ y="552.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::StatusChanged(inst)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 291.25227,477.36216 L 466.19533,477.36216"
+ id="path6231"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="382.375"
+ y="472.36218"
+ id="text6233"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6235"
+ x="382.375"
+ y="472.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290,132.36218 L 464.94306,132.36218"
+ id="path6239"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.12274"
+ y="127.36218"
+ id="text6241"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6243"
+ x="381.12274"
+ y="127.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(failure)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.6546,397.36218 L 465.59766,397.36218"
+ id="path6247"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.77734"
+ y="392.36224"
+ id="text6249"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6251"
+ x="381.77734"
+ y="392.36224"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(key-required)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75,152.36218 L 249.87185,152.36218"
+ id="path6253"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.33984"
+ y="147.36218"
+ id="text6255"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6257"
+ x="164.33984"
+ y="147.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 244.97015,162.36906 L 119.58222,162.36906 L 109.94012,152.33406"
+ id="path6259"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-213.1825"
+ y="490"
+ id="text6265"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6267"
+ x="-213.1825"
+ y="490"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #2</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 76.015436,417.3553 L 250.88729,417.3553"
+ id="path6271"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="165.35527"
+ y="412.35529"
+ id="text6273"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6275"
+ x="165.35527"
+ y="412.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.98559,427.36218 L 120.59766,427.36218 L 110.95556,417.32718"
+ id="path6277"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6279"
+ width="35"
+ height="110"
+ x="465.59766"
+ y="302.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6281"
+ width="35"
+ height="70"
+ x="465.59766"
+ y="422.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-363.1825"
+ y="490.59766"
+ id="text6283"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6285"
+ x="-363.1825"
+ y="490.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-457.65515"
+ y="490.59766"
+ id="text6287"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6289"
+ x="-457.65515"
+ y="490.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">#2</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6291"
+ width="35"
+ height="100"
+ x="465.59766"
+ y="507.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-558.1825"
+ y="490.59766"
+ id="text6293"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6295"
+ x="-558.1825"
+ y="490.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #3</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 76.015436,492.3553 L 250.88729,492.3553"
+ id="path6297"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="165.35529"
+ y="487.35535"
+ id="text6299"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6301"
+ x="165.35529"
+ y="487.35535"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.98559,502.36218 L 120.59766,502.36218 L 110.95556,492.32718"
+ id="path6303"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.54072,517.36218 L 285.59766,517.36218"
+ id="path6305"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.9375"
+ y="512.36224"
+ id="text6307"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6309"
+ x="370.9375"
+ y="512.36224"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.6546,597.36218 L 465.59766,597.36218"
+ id="path6311"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.77734"
+ y="592.36218"
+ id="text6313"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6315"
+ x="381.77734"
+ y="592.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#ff8080;fill-opacity:1"
+ id="rect6317"
+ width="35"
+ height="219.96503"
+ x="250.24495"
+ y="627.39026"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#5fd38d;fill-opacity:1"
+ id="rect6319"
+ width="35"
+ height="219.96503"
+ x="35.244976"
+ y="627.39026"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-738.41687"
+ y="275"
+ id="text6325"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6327"
+ x="-738.41687"
+ y="275"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.244969,647.39028 L 250.11682,647.39028"
+ id="path6329"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="167.53403"
+ y="642.39026"
+ id="text6331"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6333"
+ x="167.53403"
+ y="642.39026"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetActions()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.18803,717.39028 L 285.24497,717.39028"
+ id="path6335"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.21512,657.39718 L 119.82719,657.39718 L 110.18509,647.36216"
+ id="path6337"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.244969,697.39028 L 250.11682,697.39028"
+ id="path6339"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.58481"
+ y="692.39032"
+ id="text6341"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6343"
+ x="164.58481"
+ y="692.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.21512,707.39718 L 119.82719,707.39718 L 110.18509,697.36218"
+ id="path6345"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.58481"
+ y="712.39032"
+ id="text6347"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6349"
+ x="370.58481"
+ y="712.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.30191,757.3903 L 465.24497,757.3903"
+ id="path6351"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.42465"
+ y="752.39032"
+ id="text6353"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6355"
+ x="381.42465"
+ y="752.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Progress(%)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.53166,797.3553 L 465.47472,797.3553"
+ id="path6365"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.65442"
+ y="792.35529"
+ id="text6367"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6369"
+ x="381.65442"
+ y="792.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::StatusChanged(inst)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6391"
+ width="35"
+ height="144.99316"
+ x="465.18506"
+ y="702.36212"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-778.1825"
+ y="490"
+ id="text6395"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6397"
+ x="-778.1825"
+ y="490"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.53166,837.3553 L 465.47472,837.3553"
+ id="path6423"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.65442"
+ y="832.35529"
+ id="text6425"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6427"
+ x="381.65442"
+ y="832.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#ff8080;fill-opacity:1"
+ id="rect6429"
+ width="35"
+ height="180.00696"
+ x="250.41777"
+ y="867.35522"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#5fd38d;fill-opacity:1"
+ id="rect6431"
+ width="35"
+ height="180.00696"
+ x="35.417786"
+ y="867.35522"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-953.41687"
+ y="275"
+ id="text6433"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6435"
+ x="-953.41687"
+ y="275"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.417779,887.35528 L 250.28963,887.35528"
+ id="path6437"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="167.70683"
+ y="882.35522"
+ id="text6439"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6441"
+ x="167.70683"
+ y="882.35522"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetActions()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.36084,957.3553 L 285.41778,957.3553"
+ id="path6443"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.38793,897.36218 L 120,897.36218 L 110.3579,887.32718"
+ id="path6445"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.417779,937.3553 L 250.28963,937.3553"
+ id="path6447"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.75761"
+ y="932.35529"
+ id="text6449"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6451"
+ x="164.75761"
+ y="932.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.38793,947.3622 L 120,947.3622 L 110.3579,937.3272"
+ id="path6453"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.75763"
+ y="952.35529"
+ id="text6455"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6457"
+ x="370.75763"
+ y="952.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.47472,997.3553 L 465.41778,997.3553"
+ id="path6459"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.59747"
+ y="992.35529"
+ id="text6461"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6463"
+ x="381.59747"
+ y="992.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::ErrorCode(NoNetwork)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6473"
+ width="35"
+ height="105.03503"
+ x="465.35788"
+ y="942.32709"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-993.18243"
+ y="490.38794"
+ id="text6475"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6477"
+ x="-993.18243"
+ y="490.38794"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.44487,1037.3622 L 465.38793,1037.3622"
+ id="path6479"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.56763"
+ y="1032.3621"
+ id="text6481"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6483"
+ x="381.56763"
+ y="1032.3621"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(failed)</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-738.4881"
+ y="60.47472"
+ id="text6485"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6487"
+ x="-738.4881"
+ y="60.47472"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-958.495"
+ y="60"
+ id="text6489"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6491"
+ x="-958.495"
+ y="60"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ </g>
+</svg>
commit c5890fb8d380ae2b2d48f7fa2bc72d9e88118c43
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 02:07:17 2008 +0100
keep the old version of the wording to not upset the translators
diff --git a/policy/org.freedesktop.packagekit.policy.in b/policy/org.freedesktop.packagekit.policy.in
index 3f0083b..32efce7 100644
--- a/policy/org.freedesktop.packagekit.policy.in
+++ b/policy/org.freedesktop.packagekit.policy.in
@@ -36,8 +36,8 @@
</action>
<action id="org.freedesktop.packagekit.localinstall-trusted">
- <_description>Install trusted local file</_description>
- <_message>Authentication is required to install a trusted local file</_message>
+ <_description>Install local file</_description>
+ <_message>Authentication is required to install a local file</_message>
<icon_name>pk-package-add</icon_name>
<vendor_url>http://www.packagekit.org/pk-reference.html#methods-install-file</vendor_url>
<defaults>
commit c039f2da465abbc5d01426125c96544472143073
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 02:04:26 2008 +0100
yum: add a warning when we are installing remote unsigned files
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index 0c2f72d..9ea100c 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -881,10 +881,16 @@ class PackageKitYumBackend(PackageKitBaseBackend):
self.allow_cancel(False)
self.percentage(0)
self.status(STATUS_RUNNING)
+
txmbrs = []
+ already_warned = False
for package in packages:
pkg,inst = self._findPackage(package)
if pkg and not inst:
+ repo = self.yumbase.repos.getRepo(pkg.repoid)
+ if not already_warned and not repo.gpgcheck:
+ self.message(MESSAGE_WARNING,"The package %s was installed untrusted from %s." % (pkg.name, repo))
+ already_warned = True
txmbr = self.yumbase.install(name=pkg.name)
txmbrs.extend(txmbr)
if txmbrs:
commit 1767299bf66249bf591639600b446e6a3db2f576
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 01:46:41 2008 +0100
fix make distcheck
diff --git a/contrib/udev/Makefile.am b/contrib/udev/Makefile.am
index 3dcd7f6..9a32f19 100644
--- a/contrib/udev/Makefile.am
+++ b/contrib/udev/Makefile.am
@@ -4,7 +4,7 @@ dist_udevrules_DATA = 51-packagekit-firmware.rules
install-data-hook:
if test -w $(DESTDIR)/; then \
mkdir -p $(DESTDIR)/lib/udev; \
- cp packagekit-firmware.sh $(DESTDIR)/lib/udev; \
+ cp $(top_srcdir)/contrib/udev/packagekit-firmware.sh $(DESTDIR)/lib/udev; \
fi
EXTRA_DIST = packagekit-firmware.sh
commit a37ecf2f2a6bd661f54855373a2b7a4eb63eab4a
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 01:32:20 2008 +0100
trailing backspace whore
diff --git a/docs/spec/pk-concepts.xml b/docs/spec/pk-concepts.xml
index 73c4cad..5d4b533 100644
--- a/docs/spec/pk-concepts.xml
+++ b/docs/spec/pk-concepts.xml
@@ -538,7 +538,7 @@
This will fail if the package does not have a valid GPG key, and ordinarily the transaction
would fail. What the client can do, e.g. using <literal>gnome-packagekit</literal>, is
to re-request the <literal>InstallFile</literal> with <literal>non-trusted</literal>.
- This will use a different PolicyKit authentication, and allow the file to succeed.
+ This will use a different PolicyKit authentication, and allow the file to succeed.
</para>
<para>
So why do we bother calling <literal>trusted</literal> in the first place?
commit 32979e5388b20f787bd974d5f84b6fd0ab1db740
Merge: 55f5713... 27e6c64...
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 01:30:37 2008 +0100
Merge branch 'master' into secure
diff --cc backends/alpm/pk-backend-alpm.c
index d30f75d,d9bca1b..91a4178
--- a/backends/alpm/pk-backend-alpm.c
+++ b/backends/alpm/pk-backend-alpm.c
@@@ -709,47 -1000,46 +1000,46 @@@ backend_get_filters (PkBackend *backend
}
static void
-backend_install_file (PkBackend *backend, const gchar *path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *path)
{
- g_return_if_fail (backend != NULL);
- alpm_list_t *problems = NULL;
- if (alpm_trans_init (PM_TRANS_TYPE_ADD, 0,
- trans_event_cb, trans_conv_cb,
- trans_prog_cb) == -1)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- return;
+ g_return_if_fail (backend != NULL);
+
+ alpm_list_t *problems = NULL;
+ if (alpm_trans_init (PM_TRANS_TYPE_ADD, 0, trans_event_cb, trans_conv_cb, trans_prog_cb) == -1) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ return;
}
- alpm_trans_addtarget ((char *)path);
+ alpm_trans_addtarget ((char *) path);
- if (alpm_trans_prepare (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- return;
+ if (alpm_trans_prepare (&problems) != 0) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_trans_release ();
+ return;
}
- if (alpm_trans_commit (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- return;
+ if (alpm_trans_commit (&problems) != 0) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_trans_release ();
+ return;
}
- alpm_trans_release ();
- pk_backend_finished (backend);
+ alpm_trans_release ();
+ pk_backend_finished (backend);
}
+ /**
+ * backend_get_repo_list:
+ */
void
backend_get_repo_list (PkBackend *backend, PkFilterEnum filters)
{
commit 55f5713da9b12f3c306b90f35bf884a3a3e432ef
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 01:26:54 2008 +0100
enable pkcon to do the trusted->untrusted dance
diff --git a/client/pk-console.c b/client/pk-console.c
index f725f49..0d71bf9 100644
--- a/client/pk-console.c
+++ b/client/pk-console.c
@@ -47,11 +47,14 @@ static gboolean has_output_bar = FALSE;
static gboolean need_requeue = FALSE;
static gboolean nowait = FALSE;
static gboolean awaiting_space = FALSE;
+static gboolean trusted = TRUE;
static guint timer_id = 0;
static guint percentage_last = 0;
+static gchar *filename = NULL;
static PkControl *control = NULL;
static PkClient *client = NULL;
static PkClient *client_task = NULL;
+static PkClient *client_install_file = NULL;
static PkClient *client_signature = NULL;
typedef struct {
@@ -363,6 +366,15 @@ pk_console_signature_finished_cb (PkClient *client_signature, PkExitEnum exit, g
}
/**
+ * pk_console_install_file_finished_cb:
+ **/
+static void
+pk_console_install_file_finished_cb (PkClient *client_signature, PkExitEnum exit, guint runtime, gpointer data)
+{
+ g_main_loop_quit (loop);
+}
+
+/**
* pk_console_finished_cb:
**/
static void
@@ -404,6 +416,12 @@ pk_console_finished_cb (PkClient *client, PkExitEnum exit, guint runtime, gpoint
g_print ("%s\n", _("An application restart is required"));
}
+ if (role == PK_ROLE_ENUM_INSTALL_FILE &&
+ exit == PK_EXIT_ENUM_FAILED && need_requeue) {
+ pk_warning ("waiting for second install file to finish");
+ return;
+ }
+
/* have we failed to install, and the gpg key is now installed */
if (exit == PK_EXIT_ENUM_KEY_REQUIRED && need_requeue) {
pk_debug ("key now installed");
@@ -788,6 +806,12 @@ pk_console_get_update_detail (PkClient *client, const gchar *package, GError **e
static void
pk_console_error_code_cb (PkClient *client, PkErrorCodeEnum error_code, const gchar *details, gpointer data)
{
+ gboolean ret;
+ PkRoleEnum role;
+ GError *error = NULL;
+
+ pk_client_get_role (client, &role, NULL, NULL);
+
/* handled */
if (need_requeue) {
if (error_code == PK_ERROR_ENUM_GPG_FAILURE ||
@@ -797,6 +821,20 @@ pk_console_error_code_cb (PkClient *client, PkErrorCodeEnum error_code, const gc
}
pk_warning ("set requeue, but did not handle error");
}
+
+ /* do we need to do the untrusted action */
+ if (role == PK_ROLE_ENUM_INSTALL_FILE &&
+ error_code == PK_ERROR_ENUM_MISSING_GPG_SIGNATURE && trusted) {
+ pk_debug ("need to try again with trusted FALSE");
+ trusted = FALSE;
+ ret = pk_client_install_file (client_install_file, trusted, filename, &error);
+ /* we succeeded, so wait for the requeue */
+ if (!ret) {
+ pk_warning ("failed to install file second time: %s", error->message);
+ g_error_free (error);
+ }
+ need_requeue = ret;
+ }
if (awaiting_space) {
g_print ("\n");
}
@@ -1205,6 +1243,12 @@ main (int argc, char *argv[])
g_signal_connect (client_task, "finished",
G_CALLBACK (pk_console_finished_cb), NULL);
+ client_install_file = pk_client_new ();
+ g_signal_connect (client_install_file, "finished",
+ G_CALLBACK (pk_console_install_file_finished_cb), NULL);
+ g_signal_connect (client_install_file, "error-code",
+ G_CALLBACK (pk_console_error_code_cb), NULL);
+
client_signature = pk_client_new ();
g_signal_connect (client_signature, "finished",
G_CALLBACK (pk_console_signature_finished_cb), NULL);
@@ -1270,7 +1314,9 @@ main (int argc, char *argv[])
/* is it a local file? */
ret = g_file_test (value, G_FILE_TEST_EXISTS);
if (ret) {
- ret = pk_client_install_file (client, TRUE, value, &error);
+ ret = pk_client_install_file (client, trusted, value, &error);
+ /* we need this for the untrusted try */
+ filename = g_strdup (value);
} else {
ret = pk_console_install_package (client, value, &error);
}
@@ -1463,9 +1509,11 @@ out:
g_free (options_help);
g_free (filter);
g_free (summary);
+ g_free (filename);
g_object_unref (control);
g_object_unref (client);
g_object_unref (client_task);
+ g_object_unref (client_install_file);
g_object_unref (client_signature);
return 0;
commit 27e6c646f61eb5615779261b0e824621d1c05c37
Merge: 111a150... e487118...
Author: Valeriy Lyasotskiy <onestep at ukr.net>
Date: Wed Apr 23 02:53:40 2008 +0300
fix conflicts
commit 111a15049f5c9dc8d4a4e5e15b64917d0547d39f
Author: Valeriy Lyasotskiy <onestep at ukr.net>
Date: Wed Apr 23 02:25:55 2008 +0300
reformatted, finished parse_config, added resolve method for local dbs, fixed repo-list
diff --git a/backends/alpm/pk-backend-alpm.c b/backends/alpm/pk-backend-alpm.c
index 6746a28..d9bca1b 100644
--- a/backends/alpm/pk-backend-alpm.c
+++ b/backends/alpm/pk-backend-alpm.c
@@ -28,310 +28,325 @@
#include <pk-backend.h>
#include <pk-debug.h>
#include <pk-package-ids.h>
+#include <pk-network.h>
#include <alpm.h>
#include <alpm_list.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+
static int progress_percentage;
static int subprogress_percentage;
PkBackend *install_backend = NULL;
+static PkNetwork *network;
+
typedef struct _PackageSource
{
- pmpkg_t *pkg;
- gchar *repo;
- guint installed;
+ pmpkg_t *pkg;
+ gchar *repo;
+ guint installed;
} PackageSource;
void
package_source_free (PackageSource *source)
{
- alpm_pkg_free (source->pkg);
+ alpm_pkg_free (source->pkg);
}
void
trans_event_cb (pmtransevt_t event, void *data1, void *data2)
{
+ // TODO: Add code here
}
void
-trans_conv_cb (pmtransconv_t conv,
- void *data1, void *data2, void *data3,
- int *response)
+trans_conv_cb (pmtransconv_t conv, void *data1, void *data2, void *data3, int *response)
{
+ // TODO: Add code here
}
void
-trans_prog_cb (pmtransprog_t prog, const char *pkgname, int percent,
- int n, int remain)
+trans_prog_cb (pmtransprog_t prog, const char *pkgname, int percent, int n, int remain)
{
- pk_debug ("Percentage is %i", percent);
- subprogress_percentage = percent;
- pk_backend_set_percentage ((PkBackend *)install_backend, subprogress_percentage);
+ pk_debug ("Percentage is %i", percent);
+ subprogress_percentage = percent;
+ pk_backend_set_percentage ((PkBackend *) install_backend, subprogress_percentage);
}
gboolean
update_subprogress (void *data)
{
- if (subprogress_percentage == -1)
- return FALSE;
+ if (subprogress_percentage == -1)
+ return FALSE;
- pk_debug ("alpm: subprogress is %i", subprogress_percentage);
+ pk_debug ("alpm: subprogress is %i", subprogress_percentage);
- pk_backend_set_percentage ((PkBackend *)data, subprogress_percentage);
- return TRUE;
+ pk_backend_set_percentage ((PkBackend *) data, subprogress_percentage);
+ return TRUE;
}
gboolean
update_progress (void *data)
{
- if (progress_percentage == -1)
- return FALSE;
+ if (progress_percentage == -1)
+ return FALSE;
- pk_backend_set_percentage ((PkBackend *)data, progress_percentage);
- return TRUE;
+ pk_backend_set_percentage ((PkBackend *) data, progress_percentage);
+ return TRUE;
}
gpointer
state_notify (void *backend)
{
- g_timeout_add (300, update_subprogress, backend);
- return backend;
+ g_timeout_add (300, update_subprogress, backend);
+ return backend;
}
alpm_list_t *
my_list_mmerge (alpm_list_t *left, alpm_list_t *right, alpm_list_fn_cmp fn)
{
- alpm_list_t *newlist, *lp;
-
- if (left == NULL && right == NULL)
- return NULL;
-
- if (left == NULL)
- return right;
- if (right == NULL)
- return left;
-
- if (fn(left->data, right->data) <= 0) {
- newlist = left;
- left = left->next;
- }
- else {
- newlist = right;
- right = right->next;
- }
- newlist->prev = NULL;
- newlist->next = NULL;
- lp = newlist;
-
- while ((left != NULL) && (right != NULL)) {
- if (fn(left->data, right->data) <= 0) {
- lp->next = left;
- left->prev = lp;
- left = left->next;
- }
- else {
- lp->next = right;
- right->prev = lp;
- right = right->next;
- }
- lp = lp->next;
- lp->next = NULL;
- }
- if (left != NULL) {
- lp->next = left;
- left->prev = lp;
- }
- else if (right != NULL) {
- lp->next = right;
- right->prev = lp;
- }
- return(newlist);
+ alpm_list_t *newlist, *lp;
+
+ if (left == NULL && right == NULL)
+ return NULL;
+
+ if (left == NULL)
+ return right;
+ if (right == NULL)
+ return left;
+
+ if (fn (left->data, right->data) <= 0) {
+ newlist = left;
+ left = left->next;
+ } else {
+ newlist = right;
+ right = right->next;
+ }
+
+ newlist->prev = NULL;
+ newlist->next = NULL;
+ lp = newlist;
+
+ while ((left != NULL) && (right != NULL)) {
+ if (fn (left->data, right->data) <= 0) {
+ lp->next = left;
+ left->prev = lp;
+ left = left->next;
+ } else {
+ lp->next = right;
+ right->prev = lp;
+ right = right->next;
+ }
+ lp = lp->next;
+ lp->next = NULL;
+ }
+
+ if (left != NULL) {
+ lp->next = left;
+ left->prev = lp;
+ } else if (right != NULL) {
+ lp->next = right;
+ right->prev = lp;
+ }
+ return(newlist);
+}
+
+alpm_list_t *
+my_list_remove_node (alpm_list_t *node)
+{
+ if (!node)
+ return (NULL);
+
+ alpm_list_t *ret = NULL;
+
+ if (node->prev) {
+ node->prev->next = node->next;
+ ret = node->prev;
+ //node->prev = NULL;
+ }
+
+ if (node->next) {
+ node->next->prev = node->prev;
+ ret = node->next;
+ node->next = NULL;
+ }
+
+ return (ret);
}
gboolean
pkg_equal (pmpkg_t *p1, pmpkg_t *p2)
{
- /*pk_debug (alpm_pkg_get_name (p1));
- pk_debug (alpm_pkg_get_name (p2));*/
- if (strcmp (alpm_pkg_get_name (p1), alpm_pkg_get_name (p2)) != 0)
- return FALSE;
- if (strcmp (alpm_pkg_get_version (p1), alpm_pkg_get_version (p2)) != 0)
- return FALSE;
- return TRUE;
+/*
+ pk_debug (alpm_pkg_get_name (p1));
+ pk_debug (alpm_pkg_get_name (p2));
+*/
+ if (strcmp (alpm_pkg_get_name (p1), alpm_pkg_get_name (p2)) != 0)
+ return FALSE;
+ if (strcmp (alpm_pkg_get_version (p1), alpm_pkg_get_version (p2)) != 0)
+ return FALSE;
+ return TRUE;
}
gboolean
pkg_equals_to (pmpkg_t *pkg, const gchar *name, const gchar *version)
{
- if (strcmp (alpm_pkg_get_name (pkg), name) != 0)
- return FALSE;
- if (version != NULL)
- if (strcmp (alpm_pkg_get_version (pkg), version) != 0)
- return FALSE;
- return TRUE;
+ if (strcmp (alpm_pkg_get_name (pkg), name) != 0)
+ return FALSE;
+ if (version != NULL)
+ if (strcmp (alpm_pkg_get_version (pkg), version) != 0)
+ return FALSE;
+ return TRUE;
}
-alpm_list_t *
-my_list_remove_node (alpm_list_t *node)
-{
- if(!node) return(NULL);
-
- alpm_list_t *ret = NULL;
-
- if(node->prev) {
- node->prev->next = node->next;
- ret = node->prev;
- //node->prev = NULL;
- }
- if(node->next) {
- node->next->prev = node->prev;
- ret = node->next;
- node->next = NULL;
- }
-
- return(ret);
-}
-
static int
list_cmp_fn (const void *n1, const void *n2)
{
- return 0;
+ return 0;
}
static void
add_package (PkBackend *backend, PackageSource *package)
{
- PkInfoEnum info;
- gchar *pkg_string;
- gchar *arch = (gchar *)alpm_pkg_get_arch (package->pkg);
+ PkInfoEnum info;
+ gchar *pkg_string;
+ gchar *arch = (gchar *) alpm_pkg_get_arch (package->pkg);
- if (arch == NULL) arch = "lala";
+ if (arch == NULL)
+ arch = "unknown";
- pkg_string = pk_package_id_build(alpm_pkg_get_name (package->pkg),
- alpm_pkg_get_version (package->pkg),
- arch,
- package->repo);
- if (package->installed)
- info = PK_INFO_ENUM_INSTALLED;
- else
- info = PK_INFO_ENUM_AVAILABLE;
- pk_backend_package (backend, info, pkg_string, alpm_pkg_get_desc (package->pkg));
+ pkg_string = pk_package_id_build (alpm_pkg_get_name (package->pkg), alpm_pkg_get_version (package->pkg), arch, package->repo);
+ if (package->installed)
+ info = PK_INFO_ENUM_INSTALLED;
+ else
+ info = PK_INFO_ENUM_AVAILABLE;
+ pk_backend_package (backend, info, pkg_string, alpm_pkg_get_desc (package->pkg));
- g_free(pkg_string);
+ g_free(pkg_string);
}
static void
add_packages_from_list (PkBackend *backend, alpm_list_t *list)
{
- PackageSource *package = NULL;
- alpm_list_t *li = NULL;
+ PackageSource *package = NULL;
+ alpm_list_t *li = NULL;
- for (li = list; li != NULL; li = alpm_list_next (li)) {
- package = (PackageSource *)li->data;
- add_package (backend, package);
- }
+ for (li = list; li != NULL; li = alpm_list_next (li)) {
+ package = (PackageSource *) li->data;
+ add_package (backend, package);
+ }
}
alpm_list_t *
-find_packages ( const gchar *name, pmdb_t *db)
+find_packages_by_desc (const gchar *name, pmdb_t *db)
{
- if (db == NULL || name == NULL) return NULL;
+ if (db == NULL || name == NULL)
+ return NULL;
- alpm_list_t *needle = NULL;
- alpm_list_t *result = NULL;
- alpm_list_t *localresult = NULL;
- pmdb_t *localdb = NULL;
- const gchar *dbname = NULL;
+ alpm_list_t *needle = NULL;
+ alpm_list_t *result = NULL;
+ alpm_list_t *localresult = NULL;
+ pmdb_t *localdb = NULL;
+ const gchar *dbname = NULL;
- needle = alpm_list_add (needle, (gchar *)name);
- dbname = alpm_db_get_name (db);
- result = alpm_db_search (db, needle);
- localdb = alpm_option_get_localdb ();
+ needle = alpm_list_add (needle, (gchar *) name);
+ dbname = alpm_db_get_name (db);
+ localdb = alpm_option_get_localdb ();
- alpm_list_t *i = NULL;
+ alpm_list_t *i = NULL;
- if (db != localdb)
- {
- if (localdb != NULL)
- localresult = alpm_db_search (localdb, needle);
+ if (db != localdb) {
+ if (localdb != NULL)
+ localresult = alpm_db_search (localdb, needle);
}
- for (i = result; i; i = alpm_list_next (i))
- {
- PackageSource *source = g_malloc (sizeof (PackageSource));
-
- source->pkg = (pmpkg_t *)i->data;
- source->repo = (gchar *)dbname;
-
- if (localresult != NULL)
- {
- alpm_list_t *icmp = NULL;
- for (icmp = localresult; icmp; icmp = alpm_list_next (icmp))
- if (pkg_equal ((pmpkg_t *)icmp->data, (pmpkg_t *)i->data))
- source->installed = TRUE;
- else source->installed = FALSE;
- }
- else if (localdb == db) source->installed = TRUE;
- else source->installed = FALSE;
+ result = alpm_db_search (db, needle);
+ for (i = result; i; i = alpm_list_next (i)) {
+ PackageSource *source = g_malloc (sizeof (PackageSource));
+
+ source->pkg = (pmpkg_t *) i->data;
+ source->repo = (gchar *) dbname;
+
+ if (localresult != NULL) {
+ alpm_list_t *icmp = NULL;
+ for (icmp = localresult; icmp; icmp = alpm_list_next (icmp))
+ if (pkg_equal ((pmpkg_t *) icmp->data, (pmpkg_t *) i->data))
+ source->installed = TRUE;
+ else
+ source->installed = FALSE;
+ } else if (localdb == db)
+ source->installed = TRUE;
+ else
+ source->installed = FALSE;
+
+ i->data = source;
+ }
- i->data = source;
+ alpm_list_free (needle);
+ if (localresult != NULL) {
+ // alpm_list_free_inner (localresult, (alpm_list_fn_free) alpm_pkg_free);
+ alpm_list_free(localresult);
}
- alpm_list_free (needle);
- if (localresult != NULL);
- //alpm_list_free_inner (localresult, (alpm_list_fn_free)alpm_pkg_free);
- return result;
+ return result;
}
gboolean
pkg_is_installed (const gchar *name, const gchar *version)
{
- pmdb_t *localdb = NULL;
- alpm_list_t *result = NULL;
+ pmdb_t *localdb = NULL;
+ alpm_list_t *result = NULL;
- if (name == NULL) return FALSE;
- localdb = alpm_option_get_localdb ();
- if (localdb == NULL) return FALSE;
+ if (name == NULL)
+ return FALSE;
+ localdb = alpm_option_get_localdb ();
+ if (localdb == NULL)
+ return FALSE;
- result = find_packages (name, localdb);
- if (result == NULL) return FALSE;
- if (!alpm_list_count (result)) return FALSE;
+ result = find_packages_by_desc (name, localdb);
+ if (result == NULL)
+ return FALSE;
+ if (!alpm_list_count (result))
+ return FALSE;
- if (version == NULL)
- return TRUE;
+ if (version == NULL)
+ return TRUE;
- alpm_list_t *icmp = NULL;
- for (icmp = result; icmp; icmp = alpm_list_next (icmp))
- if (strcmp (alpm_pkg_get_version ((pmpkg_t *)icmp->data), version) == 0)
- return TRUE;
+ alpm_list_t *icmp = NULL;
+ for (icmp = result; icmp; icmp = alpm_list_next (icmp))
+ if (strcmp (alpm_pkg_get_version ((pmpkg_t *) icmp->data), version) == 0)
+ return TRUE;
- return FALSE;
+ return FALSE;
}
static void
filter_packages_installed (alpm_list_t *packages, gboolean filter)
{
- alpm_list_t *i;
- for (i = packages; i; )
- {
- if (((PackageSource *)i->data)->installed == filter)
- {
- alpm_list_t *temp = i;
- i = alpm_list_next (i);
- package_source_free ((PackageSource *)temp->data);
- my_list_remove_node (temp);
- continue;
+ alpm_list_t *i;
+ for (i = packages; i; ) {
+ if (((PackageSource *) i->data)->installed == filter) {
+ alpm_list_t *temp = i;
+ i = alpm_list_next (i);
+ package_source_free ((PackageSource *) temp->data);
+ my_list_remove_node (temp);
+ continue;
}
- i = alpm_list_next (i);
+ i = alpm_list_next (i);
}
}
-/*static void
+/*
+static void
filter_packages_multiavail (alpm_list_t *packages, gboolean)
-{*/
-
+{
+}
+*/
/**
* backend_destroy:
@@ -339,11 +354,277 @@ filter_packages_multiavail (alpm_list_t *packages, gboolean)
static void
backend_destroy (PkBackend *backend)
{
- g_return_if_fail (backend != NULL);
- if (alpm_release () == -1)
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_FAILED_FINALISE,
- "Failed to release control");
+ g_return_if_fail (backend != NULL);
+
+ if (alpm_release () == -1)
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_FAILED_FINALISE,
+ "Failed to release control");
+}
+
+/**
+ * strtrim:
+ * Trim whitespaces and newlines from a string
+ */
+char *
+strtrim (char *str)
+{
+ char *pch = str;
+
+ if (str == NULL || *str == '\0')
+ /* string is empty, so we're done. */
+ return (str);
+
+ while (isspace (*pch))
+ pch++;
+
+ if (pch != str)
+ memmove (str, pch, (strlen (pch) + 1));
+
+ /* check if there wasn't anything but whitespace in the string. */
+ if (*str == '\0')
+ return (str);
+
+ pch = (str + (strlen (str) - 1));
+
+ while (isspace (*pch))
+ pch--;
+
+ *++pch = '\0';
+
+ return (str);
+}
+
+/**
+ * _strnadd:
+ * Helper function for strreplace
+ */
+static void
+_strnadd(char **str, const char *append, unsigned int count)
+{
+ if (*str)
+ *str = realloc (*str, strlen (*str) + count + 1);
+ else
+ *str = calloc (sizeof (char), count + 1);
+
+ strncat(*str, append, count);
+}
+
+/**
+ * strreplace:
+ * Replace all occurences of 'needle' with 'replace' in 'str', returning
+ * a new string (must be free'd)
+ */
+char *
+strreplace(const char *str, const char *needle, const char *replace)
+{
+ const char *p, *q;
+ p = q = str;
+
+ char *newstr = NULL;
+ unsigned int needlesz = strlen (needle), replacesz = strlen (replace);
+
+ while (1) {
+ q = strstr(p, needle);
+ if (!q) {
+ /* not found */
+ if (*p) /* add the rest of 'p' */
+ _strnadd(&newstr, p, strlen(p));
+
+ break;
+ } else { /* found match */
+ if (q > p) /* add chars between this occurance and last occurance, if any */
+ _strnadd(&newstr, p, q - p);
+
+ _strnadd(&newstr, replace, replacesz);
+ p = q + needlesz;
+ }
+ }
+
+ return newstr;
+}
+
+/** Add repeating options such as NoExtract, NoUpgrade, etc to alpm settings.
+ * @param ptr a pointer to the start of the multiple options
+ * @param option the string (friendly) name of the option, used for messages
+ * @param optionfunc a function pointer to an alpm_option_add_* function
+ */
+static void
+set_repeating_option(const char *ptr, const char *option, void (*optionfunc) (const char*))
+{
+ char *p = (char*) ptr;
+ char *q;
+
+ while ((q = strchr(p, ' '))) {
+ *q = '\0';
+ (*optionfunc) (p);
+ pk_debug("config: %s: %s", option, p);
+ p = q;
+ p++;
+ }
+ (*optionfunc) (p);
+ pk_debug("config: %s: %s", option, p);
+}
+
+/**
+ * parse_config:
+ * Parse config file and set all the needed options
+ * Based heavily on the pacman source code
+ */
+static int
+parse_config (const char *file, const char *givensection, pmdb_t * const givendb)
+{
+ FILE *fp = NULL;
+ char line[PATH_MAX + 1];
+ int linenum = 0;
+ char *ptr, *section = NULL;
+ pmdb_t *db = NULL;
+
+ /* set default options */
+ alpm_option_set_root ("/");
+ alpm_option_set_dbpath ("/var/lib/pacman");
+ alpm_option_add_cachedir ("/var/cache/pacman/pkg");
+ alpm_option_set_logfile ("/var/log/pacman.log");
+ alpm_option_set_xfercommand ("/usr/bin/wget --passive-ftp -c -O %%o %%u");
+
+ fp = fopen(file, "r");
+ if (fp == NULL) {
+ pk_error ("config file %s could not be read", file);
+ return (1);
+ }
+
+ /* if we are passed a section, use it as our starting point */
+ if (givensection != NULL) {
+ section = strdup (givensection);
+ }
+ /* if we are passed a db, use it as our starting point */
+ if (givendb != NULL) {
+ db = givendb;
+ }
+
+ while (fgets (line, PATH_MAX, fp))
+ {
+ linenum++;
+ strtrim(line);
+
+ if (strlen (line) == 0 || line[0] == '#')
+ continue;
+
+ if ((ptr = strchr (line, '#')))
+ *ptr = '\0';
+
+ if (line[0] == '[' && line[strlen (line) - 1] == ']') {
+ /* new config section, skip the '[' */
+ ptr = line;
+ ptr++;
+ if (section)
+ free (section);
+
+ section = strdup (ptr);
+ section[strlen (section) - 1] = '\0';
+ pk_debug ("config: new section '%s'", section);
+ if (!strlen (section)) {
+ pk_debug ("config file %s, line %d: bad section name", file, linenum);
+ return (1);
+ }
+
+ /* if we are not looking at the options section, register a db */
+ if (strcmp (section, "options") != 0)
+ db = alpm_db_register_sync (section);
+ } else {
+ /* directive */
+ char *key;
+ key = line;
+ ptr = line;
+ /* strsep modifies the 'line' string: 'key \0 ptr' */
+ strsep (&ptr, "=");
+ strtrim (key);
+ strtrim (ptr);
+
+ if (key == NULL) {
+ pk_error ("config file %s, line %d: syntax error in config file - missing key.", file, linenum);
+ return (1);
+ }
+ if (section == NULL) {
+ pk_error ("config file %s, line %d: all directives must belong to a section.", file, linenum);
+ return (1);
+ }
+
+ if (ptr == NULL && strcmp (section, "options") == 0) {
+ /* directives without settings, all in [options] */
+ if (strcmp (key, "NoPassiveFTP") == 0) {
+ alpm_option_set_nopassiveftp (1);
+ pk_debug ("config: nopassiveftp");
+ } else if (strcmp (key, "UseSyslog") == 0) {
+ alpm_option_set_usesyslog (1);
+ pk_debug ("config: usesyslog");
+ } else if (strcmp (key, "UseDelta") == 0) {
+ alpm_option_set_usedelta (1);
+ pk_debug ("config: usedelta");
+ } else {
+ pk_error ("config file %s, line %d: directive '%s' not recognized.", file, linenum, key);
+ return(1);
+ }
+ } else {
+ /* directives with settings */
+ if (strcmp (key, "Include") == 0) {
+ pk_debug ("config: including %s", ptr);
+ parse_config(ptr, section, db);
+ /* Ignore include failures... assume non-critical */
+ } else if (strcmp (section, "options") == 0) {
+ if (strcmp (key, "NoUpgrade") == 0) {
+ set_repeating_option (ptr, "NoUpgrade", alpm_option_add_noupgrade);
+ } else if (strcmp (key, "NoExtract") == 0) {
+ set_repeating_option (ptr, "NoExtract", alpm_option_add_noextract);
+ } else if (strcmp (key, "IgnorePkg") == 0) {
+ set_repeating_option (ptr, "IgnorePkg", alpm_option_add_ignorepkg);
+ } else if (strcmp (key, "IgnoreGroup") == 0) {
+ set_repeating_option (ptr, "IgnoreGroup", alpm_option_add_ignoregrp);
+ } else if (strcmp (key, "HoldPkg") == 0) {
+ set_repeating_option (ptr, "HoldPkg", alpm_option_add_holdpkg);
+ } else if (strcmp (key, "DBPath") == 0) {
+ alpm_option_set_dbpath (ptr);
+ } else if (strcmp (key, "CacheDir") == 0) {
+ if (alpm_option_add_cachedir(ptr) != 0) {
+ pk_error ("problem adding cachedir '%s' (%s)", ptr, alpm_strerrorlast ());
+ return (1);
+ }
+ pk_debug ("config: cachedir: %s", ptr);
+ } else if (strcmp (key, "RootDir") == 0) {
+ alpm_option_set_root (ptr);
+ pk_debug ("config: rootdir: %s", ptr);
+ } else if (strcmp (key, "LogFile") == 0) {
+ alpm_option_set_logfile (ptr);
+ pk_debug ("config: logfile: %s", ptr);
+ } else if (strcmp (key, "XferCommand") == 0) {
+ alpm_option_set_xfercommand (ptr);
+ pk_debug ("config: xfercommand: %s", ptr);
+ } else {
+ pk_error ("config file %s, line %d: directive '%s' not recognized.", file, linenum, key);
+ return (1);
+ }
+ } else if (strcmp (key, "Server") == 0) {
+ /* let's attempt a replacement for the current repo */
+ char *server = strreplace (ptr, "$repo", section);
+ if (alpm_db_setserver (db, server) != 0) {
+ /* pm_errno is set by alpm_db_setserver */
+ return (1);
+ }
+ free (server);
+ } else {
+ pk_error ("config file %s, line %d: directive '%s' not recognized.", file, linenum, key);
+ return (1);
+ }
+ }
+ }
+ }
+
+ fclose (fp);
+ if (section)
+ free (section);
+
+ pk_debug ("config: finished parsing %s", file);
+ return 0;
}
/**
@@ -352,48 +633,41 @@ backend_destroy (PkBackend *backend)
static void
backend_initialize (PkBackend *backend)
{
- g_return_if_fail (backend != NULL);
- progress_percentage = -1;
- subprogress_percentage = -1;
- pk_debug ("alpm: hi!");
+ g_return_if_fail (backend != NULL);
+ progress_percentage = -1;
+ subprogress_percentage = -1;
+ pk_debug ("alpm: hi!");
- if (alpm_initialize () == -1)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_FAILED_INITIALIZATION,
- "Failed to initialize package manager");
- pk_debug ("alpm: %s", alpm_strerror (pm_errno));
- //return;
- }
+ if (alpm_initialize () == -1)
+ {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_FAILED_INITIALIZATION,
+ "Failed to initialize package manager");
+ pk_debug ("alpm: %s", alpm_strerror (pm_errno));
+ //return;
+ }
-/*
- if (alpm_parse_config ("/etc/pacman.conf", NULL, "") != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_FAILED_CONFIG_PARSING,
- "Failed to parse config file");
- pk_debug ("alpm: %s", alpm_strerror (pm_errno));
- backend_destroy (backend);
- return;
- }
-*/
+ // Read options from config file
+ if (parse_config (ALPM_CONFIG_PATH, NULL, NULL) != 0)
+ {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_FAILED_CONFIG_PARSING,
+ "Failed to parse config file");
+ backend_destroy (backend);
+ return;
+ }
- // These are defaults
- // TODO: Get real options from /etc/pacman.conf
- alpm_option_set_root("/");
- alpm_option_set_dbpath("/var/lib/pacman");
- alpm_option_add_cachedir("/var/cache/pacman/pkg");
- alpm_option_set_logfile("/var/log/pacman.log");
-
- if (alpm_db_register_local () == NULL)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_FAILED_CONFIG_PARSING,
- "Failed to load local database");
- backend_destroy (backend);
- return;
- }
- pk_debug ("alpm: ready to go");
+ if (alpm_db_register_local () == NULL)
+ {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_FAILED_CONFIG_PARSING,
+ "Failed to load local database");
+ backend_destroy (backend);
+ return;
+ }
+ pk_debug ("alpm: ready to go");
+
+ network = pk_network_new();
}
/**
@@ -402,103 +676,96 @@ backend_initialize (PkBackend *backend)
static void
backend_install_package (PkBackend *backend, const gchar *package_id)
{
- pk_debug ("hello %i", GPOINTER_TO_INT (backend));
- g_return_if_fail (backend != NULL);
- //alpm_list_t *syncdbs = alpm_option_get_syncdbs ();
- alpm_list_t *result = NULL;
- alpm_list_t *problems = NULL;
- PkPackageId *id = pk_package_id_new_from_string (package_id);
- pmtransflag_t flags = 0;
- GThread *progress = NULL;
+ pk_debug ("hello %i", GPOINTER_TO_INT (backend));
+ g_return_if_fail (backend != NULL);
+/*
+ alpm_list_t *syncdbs = alpm_option_get_syncdbs ();
+*/
+ alpm_list_t *result = NULL;
+ alpm_list_t *problems = NULL;
+ PkPackageId *id = pk_package_id_new_from_string (package_id);
+ pmtransflag_t flags = 0;
+ GThread *progress = NULL;
- flags |= PM_TRANS_FLAG_NODEPS;
+ flags |= PM_TRANS_FLAG_NODEPS;
- // Next generation code?
- /*for (; syncdbs; syncdbs = alpm_list_next (syncdbs))
- result = my_list_mmerge (result, find_packages (id->name, (pmdb_t *)syncdbs->data), list_cmp_fn);
+ // Next generation code?
+/*
+ for (; syncdbs; syncdbs = alpm_list_next (syncdbs))
+ result = my_list_mmerge (result, find_packages_by_desc (id->name, (pmdb_t *) syncdbs->data), list_cmp_fn);
- if (result == NULL)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_PACKAGE_ID_INVALID,
- "Package not found");
- pk_backend_finished (backend);
- alpm_list_free (result);
- alpm_list_free (syncdbs);
- pk_package_id_free (id);
- return;
+ if (result == NULL) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_PACKAGE_ID_INVALID,
+ "Package not found");
+ pk_backend_finished (backend);
+ alpm_list_free (result);
+ alpm_list_free (syncdbs);
+ pk_package_id_free (id);
+ return;
}
- for (; result; result = alpm_list_next (result))
- if (pkg_equals_to ((pmpkg_t *)result->data, id->name, id->version))
- break;
+ for (; result; result = alpm_list_next (result))
+ if (pkg_equals_to ((pmpkg_t *) result->data, id->name, id->version))
+ break;
- if (!result)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_PACKAGE_ID_INVALID,
- "Package not found");
- pk_backend_finished (backend);
- alpm_list_free (result);
- alpm_list_free (syncdbs);
- pk_package_id_free (id);
- return;
- }*/
-
- if (alpm_trans_init (PM_TRANS_TYPE_SYNC, flags,
- trans_event_cb, trans_conv_cb,
- trans_prog_cb) == -1)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_list_free (result);
- pk_package_id_free (id);
- return;
+ if (!result) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_PACKAGE_ID_INVALID,
+ "Package not found");
+ pk_backend_finished (backend);
+ alpm_list_free (result);
+ alpm_list_free (syncdbs);
+ pk_package_id_free (id);
+ return;
}
- pk_debug ("init");
+*/
- alpm_trans_addtarget (id->name);
+ if (alpm_trans_init (PM_TRANS_TYPE_SYNC, flags, trans_event_cb, trans_conv_cb, trans_prog_cb) == -1) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_list_free (result);
+ pk_package_id_free (id);
+ return;
+ }
- if (alpm_trans_prepare (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- alpm_list_free (result);
- pk_package_id_free (id);
- return;
- }
-
- pk_backend_package (backend, PK_INFO_ENUM_DOWNLOADING,
- package_id,
- "An HTML widget for GTK+ 2.0");
-
- progress = g_thread_create (state_notify,
- (void *)backend,
- TRUE,
- NULL);
- install_backend = backend;
-
- if (alpm_trans_commit (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- alpm_list_free (result);
- pk_package_id_free (id);
- return;
+ pk_debug ("init");
+
+ alpm_trans_addtarget (id->name);
+
+ if (alpm_trans_prepare (&problems) != 0) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_trans_release ();
+ alpm_list_free (result);
+ pk_package_id_free (id);
+ return;
+ }
+
+ pk_backend_package (backend, PK_INFO_ENUM_DOWNLOADING, package_id, "An HTML widget for GTK+ 2.0");
+
+ progress = g_thread_create (state_notify, (void *) backend, TRUE, NULL);
+ install_backend = backend;
+
+ if (alpm_trans_commit (&problems) != 0) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_trans_release ();
+ alpm_list_free (result);
+ pk_package_id_free (id);
+ return;
}
- alpm_trans_release ();
- alpm_list_free (result);
- pk_package_id_free (id);
- pk_backend_finished (backend);
+ alpm_trans_release ();
+ alpm_list_free (result);
+ pk_package_id_free (id);
+ pk_backend_finished (backend);
}
/**
@@ -507,8 +774,8 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
static void
backend_update_packages (PkBackend *backend, gchar **package_ids)
{
- /* TODO: process the entire list */
- backend_install_package (backend, package_ids[0]);
+ /* TODO: process the entire list */
+ backend_install_package (backend, package_ids[0]);
}
/**
@@ -517,51 +784,92 @@ backend_update_packages (PkBackend *backend, gchar **package_ids)
static void
backend_refresh_cache (PkBackend *backend, gboolean force)
{
- g_return_if_fail (backend != NULL);
- alpm_list_t *dbs = alpm_option_get_syncdbs ();
- //alpm_list_t *problems = NULL;
-
- if (alpm_trans_init (PM_TRANS_TYPE_SYNC, 0,
- trans_event_cb, trans_conv_cb,
- trans_prog_cb) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- return;
- }
+ g_return_if_fail (backend != NULL);
+
+ if (pk_network_is_online (network) == FALSE) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_NO_NETWORK, "Cannot refresh cache whilst offline");
+ pk_backend_finished (backend);
+ return;
+ }
- pk_debug ("alpm: %s", "transaction initialized");
+ alpm_list_t *dbs = alpm_option_get_syncdbs ();
+/*
+ alpm_list_t *problems = NULL;
+*/
-/* if (alpm_trans_prepare (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
+ if (alpm_trans_init (PM_TRANS_TYPE_SYNC, 0, trans_event_cb, trans_conv_cb, trans_prog_cb) != 0) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_TRANSACTION_ERROR, alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ return;
+ }
+
+ pk_debug ("alpm: %s", "transaction initialized");
+
+/*
+ if (alpm_trans_prepare (&problems) != 0) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_TRANSACTION_ERROR, alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ return;
+ }
+*/
+
+ alpm_list_t *i = NULL;
+ pk_backend_set_status (backend, PK_STATUS_ENUM_REFRESH_CACHE);
+ g_timeout_add (ALPM_PROGRESS_UPDATE_INTERVAL, update_subprogress, backend);
+
+ for (i = dbs; i; i = alpm_list_next (i)) {
+ if (alpm_db_update (force, (pmdb_t *) i->data)) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_TRANSACTION_ERROR, alpm_strerror (pm_errno));
+ alpm_list_free (dbs);
pk_backend_finished (backend);
- return;
- }*/
-
- alpm_list_t *i = NULL;
- pk_backend_set_status (backend, PK_STATUS_ENUM_REFRESH_CACHE);
- g_timeout_add (ALPM_PROGRESS_UPDATE_INTERVAL, update_subprogress, backend);
- for (i = dbs; i; i = alpm_list_next (i))
- {
- if (alpm_db_update (force, (pmdb_t *)i->data))
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- alpm_list_free (dbs);
- pk_backend_finished (backend);
- subprogress_percentage = -1;
- return;
- }
subprogress_percentage = -1;
- }
+ return;
+ }
+ subprogress_percentage = -1;
+ }
+
+ pk_backend_finished (backend);
+}
+/**
+ * backend_resolve:
+ * Currently works only for local packages
+ */
+static void
+backend_resolve (PkBackend *backend, PkFilterEnum filters, const gchar *package)
+{
+ g_return_if_fail (backend != NULL);
+
+ pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+
+ pmdb_t *localdb = alpm_option_get_localdb ();
+ // result will be the list of PackageSource
+ alpm_list_t *result = find_packages_by_desc (package, localdb);
+
+ if (result != NULL)
+ pk_debug ("alpm: package %s found, trying to resolve...", package);
+
+ if (result == NULL) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_PACKAGE_NOT_INSTALLED, "Package is not installed");
+ pk_backend_finished (backend);
+ return;
+ } else if (alpm_list_count (result) != 1 || strcmp (alpm_pkg_get_name (((PackageSource *) result->data)->pkg), package) != 0) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_PACKAGE_NOT_INSTALLED, "Package is not installed");
pk_backend_finished (backend);
+ alpm_list_free_inner (result, (alpm_list_fn_free) package_source_free);
+ alpm_list_free (result);
+ return;
+ }
+
+ pmpkg_t *pkg = ((PackageSource *) result->data)->pkg;
+ // l is for "local"
+ pk_backend_package (backend, PK_INFO_ENUM_INSTALLED,
+ pk_package_id_build (alpm_pkg_get_name (pkg), alpm_pkg_get_version (pkg), alpm_pkg_get_arch (pkg), "l"),
+ alpm_pkg_get_desc (pkg));
+
+ alpm_list_free_inner (result, (alpm_list_fn_free) package_source_free);
+ alpm_list_free (result);
+ pk_backend_finished (backend);
}
/**
@@ -570,80 +878,43 @@ backend_refresh_cache (PkBackend *backend, gboolean force)
static void
backend_remove_package (PkBackend *backend, const gchar *package_id, gboolean allow_deps, gboolean autoremove)
{
- g_return_if_fail (backend != NULL);
- PkPackageId *id = pk_package_id_new_from_string (package_id);
- pmdb_t *localdb = alpm_option_get_localdb ();
- alpm_list_t *result = find_packages (id->name, localdb);
- pmtransflag_t flags = 0;
- alpm_list_t *problems = NULL;
-
- if (result == NULL)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_PACKAGE_NOT_INSTALLED,
- "Package is not installed");
- pk_backend_finished (backend);
- pk_package_id_free (id);
- return;
- }
- else if (alpm_list_count (result) != 1 ||
- strcmp (alpm_pkg_get_name(((PackageSource *)result->data)->pkg), id->name) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_PACKAGE_NOT_INSTALLED,
- "Package is not installed");
- alpm_list_free_inner (result, (alpm_list_fn_free)package_source_free);
- pk_backend_finished (backend);
- pk_package_id_free (id);
- alpm_list_free (result);
- return;
- }
+ g_return_if_fail (backend != NULL);
- if (allow_deps) flags |= PM_TRANS_FLAG_CASCADE;
-
- if (alpm_trans_init (PM_TRANS_TYPE_REMOVE, flags,
- trans_event_cb, trans_conv_cb,
- trans_prog_cb) == -1)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_list_free (result);
- pk_package_id_free (id);
- return;
- }
+ PkPackageId *id = pk_package_id_new_from_string (package_id);
+ pmtransflag_t flags = 0;
+ alpm_list_t *problems = NULL;
- alpm_trans_addtarget (id->name);
+ if (allow_deps)
+ flags |= PM_TRANS_FLAG_CASCADE;
- if (alpm_trans_prepare (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- alpm_list_free (result);
- pk_package_id_free (id);
- return;
- }
+ if (alpm_trans_init (PM_TRANS_TYPE_REMOVE, flags, trans_event_cb, trans_conv_cb, trans_prog_cb) == -1) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_TRANSACTION_ERROR, alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ pk_package_id_free (id);
+ return;
+ }
- if (alpm_trans_commit (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- alpm_list_free (result);
- pk_package_id_free (id);
- return;
- }
+ alpm_trans_addtarget (id->name);
- alpm_list_free (result);
- pk_package_id_free (id);
+ if (alpm_trans_prepare (&problems) != 0) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_TRANSACTION_ERROR, alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
alpm_trans_release ();
+ pk_package_id_free (id);
+ return;
+ }
+
+ if (alpm_trans_commit (&problems) != 0) {
+ pk_backend_error_code (backend, PK_ERROR_ENUM_TRANSACTION_ERROR, alpm_strerror (pm_errno));
pk_backend_finished (backend);
+ alpm_trans_release ();
+ pk_package_id_free (id);
+ return;
+ }
+
+ pk_package_id_free (id);
+ alpm_trans_release ();
+ pk_backend_finished (backend);
}
/**
@@ -652,132 +923,157 @@ backend_remove_package (PkBackend *backend, const gchar *package_id, gboolean al
static void
backend_search_name (PkBackend *backend, PkFilterEnum filters, const gchar *search)
{
- g_return_if_fail (backend != NULL);
- alpm_list_t *result = NULL;
- alpm_list_t *localresult = NULL;
- alpm_list_t *dbs = NULL;
-
- installed = pk_enums_contain (filters, PK_FILTER_ENUM_INSTALLED);
- ninstalled = pk_enums_contain (filters, PK_FILTER_ENUM_NOT_INSTALLED);
-
- pk_debug ("alpm: searching for \"%s\" - searching in installed: %i, ~installed: %i",
- search, installed, ninstalled);
-
- if (installed && !ninstalled) dbs = alpm_list_add (dbs, alpm_option_get_localdb ());
- if (ninstalled) dbs = my_list_mmerge (dbs, alpm_option_get_syncdbs (), list_cmp_fn);
-
- for (; dbs; dbs = alpm_list_next (dbs))
- result = my_list_mmerge (result, find_packages (search, (pmdb_t *)dbs->data), list_cmp_fn);
-
- if (ninstalled && installed)
- {
- pmdb_t *localdb = alpm_option_get_localdb ();
- if (localdb != NULL)
- {
- localresult = find_packages (search, localdb);
- alpm_list_t *i = NULL;
- for (i = alpm_list_first (result); i; i = alpm_list_next (i))
- {
- alpm_list_t *icmp = NULL;
- for (icmp = localresult; icmp; )
- if (pkg_equal ((pmpkg_t *)icmp->data, (pmpkg_t *)i->data))
- {
- alpm_list_t *tmp = icmp;
- icmp = alpm_list_next (icmp);
- my_list_remove_node (tmp);
- }
- else icmp = alpm_list_next (icmp);
- }
- }
- else pk_backend_error_code (backend, PK_ERROR_ENUM_INTERNAL_ERROR,
- "Could not find local db");
- result = my_list_mmerge (result, localresult, list_cmp_fn);
- }
-
- if (!installed) filter_packages_installed (result, TRUE);
- if (!ninstalled) filter_packages_installed (result, FALSE);
-
- add_packages_from_list (backend, alpm_list_first (result));
- pk_backend_finished (backend);
+ g_return_if_fail (backend != NULL);
+
+ alpm_list_t *result = NULL;
+ alpm_list_t *localresult = NULL;
+ alpm_list_t *dbs = NULL;
+
+ gboolean installed = pk_enums_contain (filters, PK_FILTER_ENUM_INSTALLED);
+ gboolean ninstalled = pk_enums_contain (filters, PK_FILTER_ENUM_NOT_INSTALLED);
+
+ pk_debug ("alpm: searching for \"%s\" - searching in installed: %i, ~installed: %i",
+ search, installed, ninstalled);
+
+ if (installed && !ninstalled)
+ dbs = alpm_list_add (dbs, alpm_option_get_localdb ());
+ if (ninstalled)
+ dbs = my_list_mmerge (dbs, alpm_option_get_syncdbs (), list_cmp_fn);
+
+ for (; dbs; dbs = alpm_list_next (dbs))
+ result = my_list_mmerge (result,
+ find_packages_by_desc (search, (pmdb_t *) dbs->data), list_cmp_fn);
+
+ if (ninstalled && installed) {
+ pmdb_t *localdb = alpm_option_get_localdb ();
+ if (localdb != NULL) {
+ localresult = find_packages_by_desc (search, localdb);
+
+ alpm_list_t *i = NULL;
+ for (i = alpm_list_first (result); i; i = alpm_list_next (i)) {
+ alpm_list_t *icmp = NULL;
+ for (icmp = localresult; icmp; )
+ if (pkg_equal ((pmpkg_t *) icmp->data, (pmpkg_t *) i->data)) {
+ alpm_list_t *tmp = icmp;
+ icmp = alpm_list_next (icmp);
+ my_list_remove_node (tmp);
+ } else
+ icmp = alpm_list_next (icmp);
+ }
+ } else
+ pk_backend_error_code (backend, PK_ERROR_ENUM_INTERNAL_ERROR,
+ "Could not find local db");
+
+ result = my_list_mmerge (result, localresult, list_cmp_fn);
+ }
+
+ if (!installed)
+ filter_packages_installed (result, TRUE);
+ if (!ninstalled)
+ filter_packages_installed (result, FALSE);
+
+ add_packages_from_list (backend, alpm_list_first (result));
+ pk_backend_finished (backend);
+}
+
+/**
+ * backend_get_groups:
+ */
+static PkGroupEnum
+backend_get_groups (PkBackend *backend)
+{
+ g_return_val_if_fail (backend != NULL, PK_GROUP_ENUM_UNKNOWN);
+
+ // TODO: Provide support for groups in alpm
+ return PK_GROUP_ENUM_UNKNOWN;
}
+/**
+ * backend_get_filters:
+ */
static PkFilterEnum
backend_get_filters (PkBackend *backend)
{
- g_return_val_if_fail (backend != NULL, PK_FILTER_ENUM_UNKNOWN);
- return PK_FILTER_ENUM_INSTALLED;
+ g_return_val_if_fail (backend != NULL, PK_FILTER_ENUM_UNKNOWN);
+
+ return PK_FILTER_ENUM_INSTALLED;
}
static void
backend_install_file (PkBackend *backend, const gchar *path)
{
- g_return_if_fail (backend != NULL);
- alpm_list_t *problems = NULL;
- if (alpm_trans_init (PM_TRANS_TYPE_ADD, 0,
- trans_event_cb, trans_conv_cb,
- trans_prog_cb) == -1)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- return;
+ g_return_if_fail (backend != NULL);
+
+ alpm_list_t *problems = NULL;
+ if (alpm_trans_init (PM_TRANS_TYPE_ADD, 0, trans_event_cb, trans_conv_cb, trans_prog_cb) == -1) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ return;
}
- alpm_trans_addtarget ((char *)path);
+ alpm_trans_addtarget ((char *) path);
- if (alpm_trans_prepare (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- return;
+ if (alpm_trans_prepare (&problems) != 0) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_trans_release ();
+ return;
}
- if (alpm_trans_commit (&problems) != 0)
- {
- pk_backend_error_code (backend,
- PK_ERROR_ENUM_TRANSACTION_ERROR,
- alpm_strerror (pm_errno));
- pk_backend_finished (backend);
- alpm_trans_release ();
- return;
+ if (alpm_trans_commit (&problems) != 0) {
+ pk_backend_error_code (backend,
+ PK_ERROR_ENUM_TRANSACTION_ERROR,
+ alpm_strerror (pm_errno));
+ pk_backend_finished (backend);
+ alpm_trans_release ();
+ return;
}
- alpm_trans_release ();
- pk_backend_finished (backend);
+ alpm_trans_release ();
+ pk_backend_finished (backend);
}
+/**
+ * backend_get_repo_list:
+ */
void
backend_get_repo_list (PkBackend *backend, PkFilterEnum filters)
{
- g_return_if_fail (backend != NULL);
- backend_initialize (backend);
- alpm_list_t *repos = alpm_option_get_syncdbs ();
- if (repos == NULL)
- pk_backend_error_code (backend, PK_ERROR_ENUM_INTERNAL_ERROR,
- alpm_strerror (pm_errno));
- for (; repos; repos = alpm_list_next (repos))
- {
- pk_backend_repo_detail (backend, alpm_db_get_name ((pmdb_t *)repos),
- /*alpm_db_get_url ((pmdb_t *)repos)*/ NULL, TRUE);
+ g_return_if_fail (backend != NULL);
+
+ pk_backend_set_status (backend, PK_STATUS_ENUM_QUERY);
+
+ alpm_list_t *repos = alpm_option_get_syncdbs ();
+
+ if (repos == NULL)
+ pk_backend_error_code (backend, PK_ERROR_ENUM_INTERNAL_ERROR, alpm_strerror (pm_errno));
+
+ // Iterate on repository list
+ repos = alpm_list_first (repos);
+ while (repos != NULL) {
+ pmdb_t *db = alpm_list_getdata (repos);
+ pk_backend_repo_detail (backend, alpm_db_get_name (db),
+ alpm_db_get_url (db), TRUE);
+ repos = alpm_list_next (repos);
}
- alpm_list_free (repos);
- pk_backend_finished (backend);
+
+ alpm_list_free (repos);
+ pk_backend_finished (backend);
}
-
-
PK_BACKEND_OPTIONS (
"alpm", /* description */
"Andreas Obergrusberger <tradiaz at yahoo.de>", /* author */
backend_initialize, /* initialize */
backend_destroy, /* destroy */
+ backend_get_groups, /* get_groups */
backend_get_filters, /* get_filters */
NULL, /* cancel */
- NULL, /* get_depends */
+ NULL, /* get_depends */
NULL, /* get_description */
NULL, /* get_files */
NULL, /* get_packages */
@@ -792,7 +1088,7 @@ PK_BACKEND_OPTIONS (
backend_remove_package, /* remove_package */
NULL, /* repo_enable */
NULL, /* repo_set_data */
- NULL, /* resolve */
+ backend_resolve, /* resolve */
NULL, /* rollback */
NULL, /* search_details */
NULL, /* search_file */
@@ -803,4 +1099,3 @@ PK_BACKEND_OPTIONS (
NULL, /* update_system */
NULL /* what_provides */
);
-
commit 90ea25595ce3498daeacfd1634d93984ef0741d5
Author: Richard Hughes <richard at hughsie.com>
Date: Wed Apr 23 00:25:21 2008 +0100
add some diagrams to show client<->server interactions
diff --git a/docs/spec/Makefile.am b/docs/spec/Makefile.am
index 407012b..ccb8818 100644
--- a/docs/spec/Makefile.am
+++ b/docs/spec/Makefile.am
@@ -1,6 +1,11 @@
IMAGE_FILES = \
pk-structure.png \
- pk-structure.svg
+ pk-structure.svg \
+ pk-transactions.svg \
+ pk-transactions-failure.png \
+ pk-transactions-sig-install.png \
+ pk-transactions-success.png \
+ pk-transactions-trusted.png
SPEC_XML_FILES = \
pk-backend-compiled.xml \
diff --git a/docs/spec/pk-concepts.xml b/docs/spec/pk-concepts.xml
index 1f294c0..73c4cad 100644
--- a/docs/spec/pk-concepts.xml
+++ b/docs/spec/pk-concepts.xml
@@ -496,8 +496,85 @@
</itemizedlist>
</sect1>
+ <sect1 id="introduction-ideas-transactions">
+ <title>Transactions</title>
+ <para>
+ PackageKit does not ask the user questions when the transaction is running.
+ It also supports a fire-and-forget method invocation, which means that transactions will
+ have one calling method, and have many signals going back to the caller.
+ </para>
+ <para>
+ Each transaction is a new path on the <literal>org.freedesktop.PackageKit</literal>
+ service, and to create a path you have to call <literal>GetTid</literal> on the base
+ interface which creates the new DBUS path, and returns the new path for you to connect to.
+ In the libpackagekit binding, <literal>PkControl</literal> handles the base interface,
+ whilst <literal>PkClient</literal> handles all the transaction interface stuff.
+ The <literal>org.freedesktop.PackageKit.Transaction</literal> interface can be used
+ on the newly created path, but only used once.
+ New methods require a new transaction path (i.e. another call to <literal>GetTid</literal>)
+ which is synchronous and thus very fast.
+ </para>
+ <para>
+ A typical successful transaction can be seen below.
+ </para>
+ <mediaobject id="pk-transactions-success">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-success.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ A typical simple transaction failure case can be seen below.
+ The user is not given the change to requeue the transaction as it is a fatal error.
+ </para>
+ <mediaobject id="pk-transactions-failure">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-failure.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ In this non-trivial example, a local file install is being attempted.
+ First the <literal>InstallFile</literal> is called with the <literal>trusted</literal>
+ flag set.
+ This will fail if the package does not have a valid GPG key, and ordinarily the transaction
+ would fail. What the client can do, e.g. using <literal>gnome-packagekit</literal>, is
+ to re-request the <literal>InstallFile</literal> with <literal>non-trusted</literal>.
+ This will use a different PolicyKit authentication, and allow the file to succeed.
+ </para>
+ <para>
+ So why do we bother calling <literal>trusted</literal> in the first place?
+ Well, the trusted PolicyKit role can be saved in the gnome-keyring, or could be
+ set to the users password as the GPG key is already trusted by the user.
+ The <literal>non-trusted</literal> action would likely ask for the administrator password,
+ and not allowed to be saved. This gives the user the benifit of installing trusted local
+ files without a password (common case) but requiring something stronger for untrusted or
+ unsigned files.
+ </para>
+ <mediaobject id="pk-transactions-trusted">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-trusted.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ If the package is signed, and a valid GPG signature is available, then we need to ask the
+ user to import the key, and re-run the transaction.
+ This is done as three transactions, as other transactions may be queued and have a higher
+ priority, and to make sure that the transaction object is not reused.
+ </para>
+ <mediaobject id="pk-transactions-sig-install">
+ <imageobject>
+ <imagedata format="PNG" fileref="pk-transactions-sig-install.png" align="center"/>
+ </imageobject>
+ </mediaobject>
+ <para>
+ If the package is signed, and a valid GPG signature is available, then we need to ask the
+ user to import the key, and re-run the transaction.
+ This is done as three transactions, as other transactions may be queued and have a higher
+ priority, and to make sure that the transaction object is not reused.
+ </para>
+ </sect1>
+
<sect1 id="introduction-ideas-transactionid">
- <title>Transaction ID</title>
+ <title>Transaction IDs</title>
<para>
A <literal>transaction_id</literal> is a unique identifier that
identifies the present or past transaction.
diff --git a/docs/spec/pk-transactions-failure.png b/docs/spec/pk-transactions-failure.png
new file mode 100644
index 0000000..a038ea3
Binary files /dev/null and b/docs/spec/pk-transactions-failure.png differ
diff --git a/docs/spec/pk-transactions-sig-install.png b/docs/spec/pk-transactions-sig-install.png
new file mode 100644
index 0000000..27949fc
Binary files /dev/null and b/docs/spec/pk-transactions-sig-install.png differ
diff --git a/docs/spec/pk-transactions-success.png b/docs/spec/pk-transactions-success.png
new file mode 100644
index 0000000..b299bfb
Binary files /dev/null and b/docs/spec/pk-transactions-success.png differ
diff --git a/docs/spec/pk-transactions-trusted.png b/docs/spec/pk-transactions-trusted.png
new file mode 100644
index 0000000..4085e8a
Binary files /dev/null and b/docs/spec/pk-transactions-trusted.png differ
diff --git a/docs/spec/pk-transactions.svg b/docs/spec/pk-transactions.svg
new file mode 100644
index 0000000..954e540
--- /dev/null
+++ b/docs/spec/pk-transactions.svg
@@ -0,0 +1,1275 @@
+<?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://creativecommons.org/ns#"
+ 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: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.46"
+ sodipodi:docname="pk-transactions.svg"
+ inkscape:output_extension="org.inkscape.output.svg.inkscape">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Mstart"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow2Mstart"
+ style="overflow:visible">
+ <path
+ id="path3246"
+ style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+ transform="scale(0.6) translate(0,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow2Lend"
+ style="overflow:visible;">
+ <path
+ id="path3243"
+ style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;"
+ d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+ transform="scale(1.1) rotate(180) translate(1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow2Lstart"
+ style="overflow:visible">
+ <path
+ id="path3240"
+ style="font-size:12.0;fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+ transform="scale(1.1) translate(1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow1Lstart"
+ orient="auto"
+ refY="0.0"
+ refX="0.0"
+ id="Arrow1Lstart"
+ style="overflow:visible">
+ <path
+ id="path3222"
+ 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>
+ <inkscape:perspective
+ sodipodi:type="inkscape:persp3d"
+ inkscape:vp_x="0 : 526.18109 : 1"
+ inkscape:vp_y="0 : 1000 : 0"
+ inkscape:vp_z="744.09448 : 526.18109 : 1"
+ inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
+ id="perspective10" />
+ </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="277.52317"
+ inkscape:cy="649.44446"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer1"
+ showgrid="true"
+ borderlayer="true"
+ inkscape:showpageshadow="false"
+ inkscape:window-width="1280"
+ inkscape:window-height="951"
+ inkscape:window-x="0"
+ inkscape:window-y="25">
+ <inkscape:grid
+ type="xygrid"
+ id="grid2403"
+ visible="true"
+ enabled="true"
+ color="#0000ff"
+ opacity="0.03137255"
+ empcolor="#0000ff"
+ empopacity="0.05882353" />
+ </sodipodi:namedview>
+ <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:none;fill-opacity:1;stroke:#000000;stroke-width:0.45442721;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6509"
+ width="475.04556"
+ height="189.96553"
+ x="30.451931"
+ y="862.33252"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:1;fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6507"
+ width="475"
+ height="230"
+ x="30.474718"
+ y="622.35529"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:1;fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6505"
+ width="475"
+ height="335"
+ x="30.597656"
+ y="277.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:1;fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.50000000000000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect6503"
+ width="475"
+ height="255"
+ x="30"
+ y="12.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#8d5fd3;fill-opacity:1"
+ id="rect6269"
+ width="35"
+ height="105"
+ x="465"
+ y="37.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#ff8080;fill-opacity:1"
+ id="rect2405"
+ width="35"
+ height="245"
+ x="250"
+ y="17.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#5fd38d;fill-opacity:1"
+ id="rect2407"
+ width="35"
+ height="245"
+ x="35"
+ y="17.362183"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146784999999984;fill:#8d5fd3;fill-opacity:1"
+ id="rect2411"
+ width="35"
+ height="110"
+ x="465"
+ y="152.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-128.495"
+ y="60"
+ id="text2413"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan2415"
+ x="-128.495"
+ y="60"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-88.182495"
+ y="490"
+ id="text2417"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan2419"
+ x="-88.182495"
+ y="490"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-128.41687"
+ y="275"
+ id="text2421"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan2423"
+ x="-128.41687"
+ y="275"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 459.94306,52.36218 L 285,52.36218"
+ id="path6109"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75,32.36218 L 249.87185,32.36218"
+ id="path6113"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.33984"
+ y="27.362183"
+ id="text6115"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6117"
+ x="164.33984"
+ y="27.362183"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 244.97015,42.36906 L 119.58222,42.36906 L 109.94012,32.33406"
+ id="path6119"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.33984"
+ y="47.362183"
+ id="text6121"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6123"
+ x="370.33984"
+ y="47.362183"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallFile(trusted, f)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.05694,92.36218 L 465,92.36218"
+ id="path6125"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.17969"
+ y="87.362183"
+ id="text6127"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6129"
+ x="381.17969"
+ y="87.362183"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::ErrorCode(no-sig)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 459.53741,172.36218 L 284.59435,172.36218"
+ id="path6131"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="362.90131"
+ y="167.36218"
+ id="text6133"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6135"
+ x="362.90131"
+ y="167.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallFile(untrusted, f)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 289.53741,212.36218 L 464.48047,212.36218"
+ id="path6159"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="380.66016"
+ y="207.36218"
+ id="text6161"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6163"
+ x="380.66016"
+ y="207.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::StatusChanged(inst)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 289.53741,252.36218 L 464.48047,252.36218"
+ id="path6165"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="380.66016"
+ y="247.36218"
+ id="text6167"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6169"
+ x="380.66016"
+ y="247.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#ff8080;fill-opacity:1"
+ id="rect6171"
+ width="35"
+ height="325"
+ x="250.65753"
+ y="282.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#5fd38d;fill-opacity:1"
+ id="rect6173"
+ width="35"
+ height="325"
+ x="35.657532"
+ y="282.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-448.495"
+ y="60.597656"
+ id="text6177"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6179"
+ x="-448.495"
+ y="60.597656"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-423.41687"
+ y="275.59766"
+ id="text6185"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6187"
+ x="-423.41687"
+ y="275.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.6006,317.3903 L 285.65754,317.3903"
+ id="path6195"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.657536,297.3903 L 250.52939,297.3903"
+ id="path6199"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.99738"
+ y="292.39032"
+ id="text6201"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6203"
+ x="164.99738"
+ y="292.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.62769,307.39718 L 120.23976,307.39718 L 110.59766,297.36218"
+ id="path6205"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.99738"
+ y="312.39032"
+ id="text6207"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6209"
+ x="370.99738"
+ y="312.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.71448,357.3903 L 465.65754,357.3903"
+ id="path6211"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.83722"
+ y="352.39032"
+ id="text6213"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6215"
+ x="381.83722"
+ y="352.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::RepoSigRequired(key)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 461.25227,437.36216 L 286.30921,437.36216"
+ id="path6217"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="364.61615"
+ y="432.36218"
+ id="text6219"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6221"
+ x="364.61615"
+ y="432.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallSignature(key)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.6546,557.36218 L 465.59766,557.36218"
+ id="path6225"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.77734"
+ y="552.36218"
+ id="text6227"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6229"
+ x="381.77734"
+ y="552.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::StatusChanged(inst)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 291.25227,477.36216 L 466.19533,477.36216"
+ id="path6231"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="382.375"
+ y="472.36218"
+ id="text6233"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6235"
+ x="382.375"
+ y="472.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290,132.36218 L 464.94306,132.36218"
+ id="path6239"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.12274"
+ y="127.36218"
+ id="text6241"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6243"
+ x="381.12274"
+ y="127.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(failure)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.6546,397.36218 L 465.59766,397.36218"
+ id="path6247"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.77734"
+ y="392.36224"
+ id="text6249"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6251"
+ x="381.77734"
+ y="392.36224"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(key-required)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75,152.36218 L 249.87185,152.36218"
+ id="path6253"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.33984"
+ y="147.36218"
+ id="text6255"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6257"
+ x="164.33984"
+ y="147.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 244.97015,162.36906 L 119.58222,162.36906 L 109.94012,152.33406"
+ id="path6259"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-213.1825"
+ y="490"
+ id="text6265"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-trusted.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6267"
+ x="-213.1825"
+ y="490"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #2</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 76.015436,417.3553 L 250.88729,417.3553"
+ id="path6271"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="165.35527"
+ y="412.35529"
+ id="text6273"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6275"
+ x="165.35527"
+ y="412.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.98559,427.36218 L 120.59766,427.36218 L 110.95556,417.32718"
+ id="path6277"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6279"
+ width="35"
+ height="110"
+ x="465.59766"
+ y="302.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6281"
+ width="35"
+ height="70"
+ x="465.59766"
+ y="422.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-363.1825"
+ y="490.59766"
+ id="text6283"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6285"
+ x="-363.1825"
+ y="490.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-457.65515"
+ y="490.59766"
+ id="text6287"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6289"
+ x="-457.65515"
+ y="490.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">#2</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6291"
+ width="35"
+ height="100"
+ x="465.59766"
+ y="507.36218"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-558.1825"
+ y="490.59766"
+ id="text6293"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6295"
+ x="-558.1825"
+ y="490.59766"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #3</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 76.015436,492.3553 L 250.88729,492.3553"
+ id="path6297"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="165.35529"
+ y="487.35535"
+ id="text6299"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6301"
+ x="165.35529"
+ y="487.35535"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.98559,502.36218 L 120.59766,502.36218 L 110.95556,492.32718"
+ id="path6303"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.54072,517.36218 L 285.59766,517.36218"
+ id="path6305"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.9375"
+ y="512.36224"
+ id="text6307"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6309"
+ x="370.9375"
+ y="512.36224"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.6546,597.36218 L 465.59766,597.36218"
+ id="path6311"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.77734"
+ y="592.36218"
+ id="text6313"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-sig-install.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6315"
+ x="381.77734"
+ y="592.36218"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#ff8080;fill-opacity:1"
+ id="rect6317"
+ width="35"
+ height="219.96503"
+ x="250.24495"
+ y="627.39026"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#5fd38d;fill-opacity:1"
+ id="rect6319"
+ width="35"
+ height="219.96503"
+ x="35.244976"
+ y="627.39026"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-738.41687"
+ y="275"
+ id="text6325"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6327"
+ x="-738.41687"
+ y="275"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.244969,647.39028 L 250.11682,647.39028"
+ id="path6329"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="167.53403"
+ y="642.39026"
+ id="text6331"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6333"
+ x="167.53403"
+ y="642.39026"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetActions()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.18803,717.39028 L 285.24497,717.39028"
+ id="path6335"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.21512,657.39718 L 119.82719,657.39718 L 110.18509,647.36216"
+ id="path6337"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.244969,697.39028 L 250.11682,697.39028"
+ id="path6339"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.58481"
+ y="692.39032"
+ id="text6341"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6343"
+ x="164.58481"
+ y="692.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.21512,707.39718 L 119.82719,707.39718 L 110.18509,697.36218"
+ id="path6345"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.58481"
+ y="712.39032"
+ id="text6347"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6349"
+ x="370.58481"
+ y="712.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.30191,757.3903 L 465.24497,757.3903"
+ id="path6351"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.42465"
+ y="752.39032"
+ id="text6353"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6355"
+ x="381.42465"
+ y="752.39032"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Progress(%)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.53166,797.3553 L 465.47472,797.3553"
+ id="path6365"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.65442"
+ y="792.35529"
+ id="text6367"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6369"
+ x="381.65442"
+ y="792.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::StatusChanged(inst)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6391"
+ width="35"
+ height="144.99316"
+ x="465.18506"
+ y="702.36212"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-778.1825"
+ y="490"
+ id="text6395"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6397"
+ x="-778.1825"
+ y="490"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.53166,837.3553 L 465.47472,837.3553"
+ id="path6423"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.65442"
+ y="832.35529"
+ id="text6425"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6427"
+ x="381.65442"
+ y="832.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(success)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#ff8080;fill-opacity:1"
+ id="rect6429"
+ width="35"
+ height="180.00696"
+ x="250.41777"
+ y="867.35522"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <rect
+ style="opacity:0.76146785;fill:#5fd38d;fill-opacity:1"
+ id="rect6431"
+ width="35"
+ height="180.00696"
+ x="35.417786"
+ y="867.35522"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-953.41687"
+ y="275"
+ id="text6433"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6435"
+ x="-953.41687"
+ y="275"
+ style="font-size:20px;text-align:center;text-anchor:middle">Client</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.417779,887.35528 L 250.28963,887.35528"
+ id="path6437"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="167.70683"
+ y="882.35522"
+ id="text6439"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6441"
+ x="167.70683"
+ y="882.35522"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetActions()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 460.36084,957.3553 L 285.41778,957.3553"
+ id="path6443"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.38793,897.36218 L 120,897.36218 L 110.3579,887.32718"
+ id="path6445"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.75172305;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 75.417779,937.3553 L 250.28963,937.3553"
+ id="path6447"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="164.75761"
+ y="932.35529"
+ id="text6449"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6451"
+ x="164.75761"
+ y="932.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">GetTid()</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.39060569;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 245.38793,947.3622 L 120,947.3622 L 110.3579,937.3272"
+ id="path6453"
+ sodipodi:nodetypes="ccc"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="370.75763"
+ y="952.35529"
+ id="text6455"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6457"
+ x="370.75763"
+ y="952.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">InstallPackage(p)</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.47472,997.3553 L 465.41778,997.3553"
+ id="path6459"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.59747"
+ y="992.35529"
+ id="text6461"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6463"
+ x="381.59747"
+ y="992.35529"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::ErrorCode(NoNetwork)</tspan></text>
+ <rect
+ style="opacity:0.76146785;fill:#8d5fd3;fill-opacity:1"
+ id="rect6473"
+ width="35"
+ height="105.03503"
+ x="465.35788"
+ y="942.32709"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-993.18243"
+ y="490.38794"
+ id="text6475"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6477"
+ x="-993.18243"
+ y="490.38794"
+ style="font-size:20px;text-align:center;text-anchor:middle">Tran #1</tspan></text>
+ <path
+ style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:3.7523787;stroke-linecap:butt;stroke-linejoin:miter;marker-start:url(#Arrow2Mstart);stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ d="M 290.44487,1037.3622 L 465.38793,1037.3622"
+ id="path6479"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180" />
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="381.56763"
+ y="1032.3621"
+ id="text6481"
+ sodipodi:linespacing="125%"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6483"
+ x="381.56763"
+ y="1032.3621"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;font-family:Sans;-inkscape-font-specification:Sans">::Finished(failed)</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-738.4881"
+ y="60.47472"
+ id="text6485"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-success.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6487"
+ x="-738.4881"
+ y="60.47472"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;font-family:Sans;-inkscape-font-specification:Sans"
+ x="-958.495"
+ y="60"
+ id="text6489"
+ transform="matrix(0,-1,1,0,0,0)"
+ inkscape:export-filename="/home/hughsie/Code/PackageKit/docs/spec/pk-transactions-failure.png"
+ inkscape:export-xdpi="180"
+ inkscape:export-ydpi="180"><tspan
+ sodipodi:role="line"
+ id="tspan6491"
+ x="-958.495"
+ y="60"
+ style="font-size:20px;text-align:center;text-anchor:middle">Manager</tspan></text>
+ </g>
+</svg>
commit 45e88b8b47cc12cb200d0e164bd138fd2ec25354
Merge: c9c3de8... e487118...
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 23:08:04 2008 +0100
Merge branch 'master' into secure
diff --cc backends/yum/helpers/yumBackend.py
index e64693f,8da06df..0c2f72d
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@@ -914,24 -914,10 +914,25 @@@ class PackageKitYumBackend(PackageKitBa
self.status(STATUS_RUNNING)
pkgs_to_inst = []
- self.yumbase.conf.gpgcheck=0
+
+ # If trusted is true, it means that we will only install trusted files
+ if trusted == 'yes':
+ # disregard the default
+ self.yumbase.conf.gpgcheck=1
+
+ # self.yumbase.installLocal fails for unsigned packages when self.yumbase.conf.gpgcheck=1
+ # This means we don't run runYumTransaction, and don't get the GPG failure in
+ # PackageKitYumBase(_checkSignatures) -- so we check here
+ po = YumLocalPackage(ts=self.yumbase.rpmdb.readOnlyTS(), filename=inst_file)
+ try:
+ self.yumbase._checkSignatures([po], None)
+ except yum.Errors.YumGPGCheckError,e:
+ self.error(ERROR_MISSING_GPG_SIGNATURE,str(e))
+ else:
+ self.yumbase.conf.gpgcheck=0
try:
+ self._check_local_file(inst_file)
txmbr = self.yumbase.installLocal(inst_file)
if txmbr:
self._checkForNewer(txmbr[0].po)
commit c9c3de80a9684df227607c21dcad7e518059fea5
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 19:08:09 2008 +0100
correct a couple of PolicyKit role descriptions
diff --git a/policy/org.freedesktop.packagekit.policy.in b/policy/org.freedesktop.packagekit.policy.in
index c69518d..3f0083b 100644
--- a/policy/org.freedesktop.packagekit.policy.in
+++ b/policy/org.freedesktop.packagekit.policy.in
@@ -25,8 +25,8 @@
</action>
<action id="org.freedesktop.packagekit.localinstall-untrusted">
- <_description>Install local file</_description>
- <_message>Authentication is required to install an untrusted local file</_message>
+ <_description>Install untrusted local file</_description>
+ <_message>Further authentication is required to install an untrusted local file</_message>
<icon_name>pk-package-add</icon_name>
<vendor_url>http://www.packagekit.org/pk-reference.html#methods-install-file</vendor_url>
<defaults>
@@ -36,7 +36,7 @@
</action>
<action id="org.freedesktop.packagekit.localinstall-trusted">
- <_description>Install local file</_description>
+ <_description>Install trusted local file</_description>
<_message>Authentication is required to install a trusted local file</_message>
<icon_name>pk-package-add</icon_name>
<vendor_url>http://www.packagekit.org/pk-reference.html#methods-install-file</vendor_url>
commit b0f3883bdc090809978458e2c0c50b03c294835b
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 17:19:45 2008 +0100
use the new erorr enum when we try to install an unsigned file when trusted
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index 8408065..e64693f 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -927,7 +927,7 @@ class PackageKitYumBackend(PackageKitBaseBackend):
try:
self.yumbase._checkSignatures([po], None)
except yum.Errors.YumGPGCheckError,e:
- self.error(ERROR_UNKNOWN,str(e))
+ self.error(ERROR_MISSING_GPG_SIGNATURE,str(e))
else:
self.yumbase.conf.gpgcheck=0
commit f9d9ca8ce1595440edc2fa4d11cf5288c20b4efe
Merge: 926bd61... 6423f34...
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 17:05:33 2008 +0100
Merge branch 'master' into secure
commit 926bd61204a342475950fad1d9ae3de0447cc73f
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 16:56:41 2008 +0100
check for unsigned packages when we do self.yumbase.conf.gpgcheck=1
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index ad7f560..006d52f 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -913,9 +913,20 @@ class PackageKitYumBackend(PackageKitBaseBackend):
self.status(STATUS_RUNNING)
pkgs_to_inst = []
+
# If trusted is true, it means that we will only install trusted files
if trusted == 'yes':
+ # disregard the default
self.yumbase.conf.gpgcheck=1
+
+ # self.yumbase.installLocal fails for unsigned packages when self.yumbase.conf.gpgcheck=1
+ # This means we don't run runYumTransaction, and don't get the GPG failure in
+ # PackageKitYumBase(_checkSignatures) -- so we check here
+ po = YumLocalPackage(ts=self.yumbase.rpmdb.readOnlyTS(), filename=inst_file)
+ try:
+ self.yumbase._checkSignatures([po], None)
+ except yum.Errors.YumGPGCheckError,e:
+ self.error(ERROR_UNKNOWN,str(e))
else:
self.yumbase.conf.gpgcheck=0
commit f1e45029eec8a3b585b4d3833c7ac8790c5db2d5
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 15:20:40 2008 +0100
another trivial fix to match on the right thing
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index f481388..ad7f560 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -914,7 +914,7 @@ class PackageKitYumBackend(PackageKitBaseBackend):
pkgs_to_inst = []
# If trusted is true, it means that we will only install trusted files
- if trusted == 'true':
+ if trusted == 'yes':
self.yumbase.conf.gpgcheck=1
else:
self.yumbase.conf.gpgcheck=0
commit 81401c0b7db9477080993cd498d2b46b72fb672f
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 15:02:34 2008 +0100
some fixes to the yumBackend.py trusted code
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index a314a2a..f481388 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -913,9 +913,10 @@ class PackageKitYumBackend(PackageKitBaseBackend):
self.status(STATUS_RUNNING)
pkgs_to_inst = []
- if trusted:
+ # If trusted is true, it means that we will only install trusted files
+ if trusted == 'true':
self.yumbase.conf.gpgcheck=1
- else
+ else:
self.yumbase.conf.gpgcheck=0
try:
commit 2bdd3a3b131db5366f950d8230fa60f8985f8a1b
Merge: 2df0a1f... f6caf8c...
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 14:42:27 2008 +0100
Merge branch 'master' into secure
commit 2df0a1fd652da2973e6d1cfd40ab85014dc1ff86
Author: Richard Hughes <richard at hughsie.com>
Date: Tue Apr 22 14:14:53 2008 +0100
seporate the PolicyKit roles into trusted and untrused for local file installs
diff --git a/backends/alpm/pk-backend-alpm.c b/backends/alpm/pk-backend-alpm.c
index 10bec06..d30f75d 100644
--- a/backends/alpm/pk-backend-alpm.c
+++ b/backends/alpm/pk-backend-alpm.c
@@ -709,7 +709,7 @@ backend_get_filters (PkBackend *backend)
}
static void
-backend_install_file (PkBackend *backend, const gchar *path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *path)
{
g_return_if_fail (backend != NULL);
alpm_list_t *problems = NULL;
diff --git a/backends/box/pk-backend-box.c b/backends/box/pk-backend-box.c
index 73680d4..07e5a97 100644
--- a/backends/box/pk-backend-box.c
+++ b/backends/box/pk-backend-box.c
@@ -666,7 +666,7 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *file)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *file)
{
ThreadData *data = g_new0(ThreadData, 1);
diff --git a/backends/conary/pk-backend-conary.c b/backends/conary/pk-backend-conary.c
index 0797aec..01d21d3 100644
--- a/backends/conary/pk-backend-conary.c
+++ b/backends/conary/pk-backend-conary.c
@@ -182,7 +182,7 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
*/
/**
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
g_return_if_fail (spawn != NULL);
diff --git a/backends/dummy/pk-backend-dummy.c b/backends/dummy/pk-backend-dummy.c
index b9f983b..854f3ee 100644
--- a/backends/dummy/pk-backend-dummy.c
+++ b/backends/dummy/pk-backend-dummy.c
@@ -384,7 +384,7 @@ backend_install_signature (PkBackend *backend, PkSigTypeEnum type,
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
pk_backend_finished (backend);
diff --git a/backends/pisi/helpers/install-file.py b/backends/pisi/helpers/install-file.py
index c44c45c..a4811e0 100644
--- a/backends/pisi/helpers/install-file.py
+++ b/backends/pisi/helpers/install-file.py
@@ -11,9 +11,12 @@
# (at your option) any later version.
import sys
+
import pisiBackend
+trusted = sys.argv[1]
+file_to_inst = sys.argv[2]
backend = pisiBackend.PackageKitPisiBackend(sys.argv[1:])
-backend.install_file(sys.argv[1])
+backend.install_file(trusted, file_to_inst)
sys.exit()
diff --git a/backends/pisi/helpers/pisiBackend.py b/backends/pisi/helpers/pisiBackend.py
index ddffc8d..7210889 100644
--- a/backends/pisi/helpers/pisiBackend.py
+++ b/backends/pisi/helpers/pisiBackend.py
@@ -243,7 +243,7 @@ class PackageKitPisiBackend(PackageKitBaseBackend):
else:
self.package(id, INFO_NORMAL, pkg.summary)
- def install_file(self, file):
+ def install_file(self, trusted, file):
""" Installs given package into system"""
# FIXME: install progress
self.allow_cancel(False);
diff --git a/backends/pisi/pk-backend-pisi.c b/backends/pisi/pk-backend-pisi.c
index d9fb100..d83cf19 100644
--- a/backends/pisi/pk-backend-pisi.c
+++ b/backends/pisi/pk-backend-pisi.c
@@ -207,11 +207,11 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
g_return_if_fail (spawn != NULL);
- pk_backend_spawn_helper (spawn, "install-file.py", full_path, NULL);
+ pk_backend_spawn_helper (spawn, "install-file.py", pk_backend_bool_to_text (trusted), full_path, NULL);
}
/**
diff --git a/backends/smart/helpers/install-file.py b/backends/smart/helpers/install-file.py
index 0cf1d2a..f2ae068 100755
--- a/backends/smart/helpers/install-file.py
+++ b/backends/smart/helpers/install-file.py
@@ -14,7 +14,8 @@ import sys
from smartBackend import PackageKitSmartBackend
-file_to_inst = sys.argv[1]
+trusted = sys.argv[1]
+file_to_inst = sys.argv[2]
backend = PackageKitSmartBackend(sys.argv[1:])
-backend.install_file(file_to_inst)
+backend.install_file(trusted, file_to_inst)
sys.exit(0)
diff --git a/backends/smart/helpers/smartBackend.py b/backends/smart/helpers/smartBackend.py
index feb15a1..538c01e 100644
--- a/backends/smart/helpers/smartBackend.py
+++ b/backends/smart/helpers/smartBackend.py
@@ -63,7 +63,7 @@ class PackageKitSmartBackend(PackageKitBaseBackend):
self.ctrl.commitTransaction(trans, confirm=False)
@needs_cache
- def install_file(self, path):
+ def install_file(self, trusted, path):
self.ctrl.addFileChannel(path)
self.ctrl.reloadChannels()
trans = smart.transaction.Transaction(self.ctrl.getCache(),
diff --git a/backends/smart/pk-backend-smart.c b/backends/smart/pk-backend-smart.c
index 87981d5..ef86a16 100644
--- a/backends/smart/pk-backend-smart.c
+++ b/backends/smart/pk-backend-smart.c
@@ -131,11 +131,11 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
g_return_if_fail (spawn != NULL);
- pk_backend_spawn_helper (spawn, "install-file.py", full_path, NULL);
+ pk_backend_spawn_helper (spawn, "install-file.py", pk_backend_bool_to_text (trusted), full_path, NULL);
}
/**
diff --git a/backends/test/pk-backend-test-fail.c b/backends/test/pk-backend-test-fail.c
index 18b8fb4..75702ac 100644
--- a/backends/test/pk-backend-test-fail.c
+++ b/backends/test/pk-backend-test-fail.c
@@ -154,7 +154,7 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
pk_backend_finished (backend);
diff --git a/backends/test/pk-backend-test-succeed.c b/backends/test/pk-backend-test-succeed.c
index 0097ffb..76f997e 100644
--- a/backends/test/pk-backend-test-succeed.c
+++ b/backends/test/pk-backend-test-succeed.c
@@ -162,7 +162,7 @@ backend_install_signature (PkBackend *backend, PkSigTypeEnum type,
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
pk_backend_finished (backend);
diff --git a/backends/yum/helpers/install-file.py b/backends/yum/helpers/install-file.py
index 6c25fc3..506ce5a 100755
--- a/backends/yum/helpers/install-file.py
+++ b/backends/yum/helpers/install-file.py
@@ -14,7 +14,8 @@ import sys
from yumBackend import PackageKitYumBackend
-file_to_inst = sys.argv[1]
+trusted = sys.argv[1]
+file_to_inst = sys.argv[2]
backend = PackageKitYumBackend(sys.argv[1:])
-backend.install_file(file_to_inst)
-sys.exit(0)
\ No newline at end of file
+backend.install_file(trusted, file_to_inst)
+sys.exit(0)
diff --git a/backends/yum/helpers/yumBackend.py b/backends/yum/helpers/yumBackend.py
index 4f4eecc..a314a2a 100644
--- a/backends/yum/helpers/yumBackend.py
+++ b/backends/yum/helpers/yumBackend.py
@@ -898,7 +898,7 @@ class PackageKitYumBackend(PackageKitBaseBackend):
if newest.EVR > po.EVR:
self.message(MESSAGE_WARNING,"A newer version of %s is available online." % po.name)
- def install_file (self,inst_file):
+ def install_file (self,trusted,inst_file):
'''
Implement the {backend}-install_file functionality
Install the package containing the inst_file file
@@ -913,7 +913,10 @@ class PackageKitYumBackend(PackageKitBaseBackend):
self.status(STATUS_RUNNING)
pkgs_to_inst = []
- self.yumbase.conf.gpgcheck=0
+ if trusted:
+ self.yumbase.conf.gpgcheck=1
+ else
+ self.yumbase.conf.gpgcheck=0
try:
txmbr = self.yumbase.installLocal(inst_file)
diff --git a/backends/yum/pk-backend-yum.c b/backends/yum/pk-backend-yum.c
index 15923d2..f1f4de5 100644
--- a/backends/yum/pk-backend-yum.c
+++ b/backends/yum/pk-backend-yum.c
@@ -234,11 +234,11 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
g_return_if_fail (spawn != NULL);
- pk_backend_spawn_helper (spawn, "install-file.py", full_path, NULL);
+ pk_backend_spawn_helper (spawn, "install-file.py", pk_backend_bool_to_text (trusted), full_path, NULL);
}
/**
diff --git a/backends/yum2/pk-backend-yum2.c b/backends/yum2/pk-backend-yum2.c
index f5358ea..39d450b 100644
--- a/backends/yum2/pk-backend-yum2.c
+++ b/backends/yum2/pk-backend-yum2.c
@@ -199,11 +199,11 @@ backend_install_package (PkBackend *backend, const gchar *package_id)
* backend_install_file:
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
g_return_if_fail (dbus != NULL);
- pk_backend_dbus_install_file (dbus, full_path);
+ pk_backend_dbus_install_file (dbus, trusted, full_path);
}
/**
diff --git a/backends/zypp/pk-backend-zypp.cpp b/backends/zypp/pk-backend-zypp.cpp
index 821fd91..07c5b84 100644
--- a/backends/zypp/pk-backend-zypp.cpp
+++ b/backends/zypp/pk-backend-zypp.cpp
@@ -922,7 +922,7 @@ backend_install_file_thread (PkBackendThread *thread, gpointer data)
* backend_install_file
*/
static void
-backend_install_file (PkBackend *backend, const gchar *full_path)
+backend_install_file (PkBackend *backend, gboolean trusted, const gchar *full_path)
{
g_return_if_fail (backend != NULL);
InstFileData *data = g_new0(InstFileData, 1);
diff --git a/client/pk-console.c b/client/pk-console.c
index d7907e0..f725f49 100644
--- a/client/pk-console.c
+++ b/client/pk-console.c
@@ -1270,7 +1270,7 @@ main (int argc, char *argv[])
/* is it a local file? */
ret = g_file_test (value, G_FILE_TEST_EXISTS);
if (ret) {
- ret = pk_client_install_file (client, value, &error);
+ ret = pk_client_install_file (client, TRUE, value, &error);
} else {
ret = pk_console_install_package (client, value, &error);
}
diff --git a/libpackagekit/pk-client.c b/libpackagekit/pk-client.c
index 8a0eaef..f6166c8 100644
--- a/libpackagekit/pk-client.c
+++ b/libpackagekit/pk-client.c
@@ -84,6 +84,7 @@ struct _PkClientPrivate
gboolean cached_force;
gboolean cached_allow_deps;
gboolean cached_autoremove;
+ gboolean cached_trusted;
gchar *cached_package_id;
gchar **cached_package_ids;
gchar *cached_transaction_id;
@@ -2384,7 +2385,7 @@ pk_client_update_package (PkClient *client, const gchar *package_id, GError **er
* pk_client_install_file_action:
**/
static gboolean
-pk_client_install_file_action (PkClient *client, const gchar *file, GError **error)
+pk_client_install_file_action (PkClient *client, gboolean trusted, const gchar *file, GError **error)
{
gboolean ret;
@@ -2397,6 +2398,7 @@ pk_client_install_file_action (PkClient *client, const gchar *file, GError **err
return FALSE;
}
ret = dbus_g_proxy_call (client->priv->proxy, "InstallFile", error,
+ G_TYPE_BOOLEAN, trusted,
G_TYPE_STRING, file,
G_TYPE_INVALID, G_TYPE_INVALID);
return ret;
@@ -2432,6 +2434,7 @@ pk_resolve_local_path (const gchar *rel_path)
/**
* pk_client_install_file:
* @client: a valid #PkClient instance
+ * @trusted: if untrused actions should be allowed
* @file_rel: a file such as "/home/hughsie/Desktop/hal-devel-0.10.0.rpm"
* @error: a %GError to put the error code and message in, or %NULL
*
@@ -2441,7 +2444,7 @@ pk_resolve_local_path (const gchar *rel_path)
* Return value: %TRUE if the daemon queued the transaction
**/
gboolean
-pk_client_install_file (PkClient *client, const gchar *file_rel, GError **error)
+pk_client_install_file (PkClient *client, gboolean trusted, const gchar *file_rel, GError **error)
{
gboolean ret;
gchar *file;
@@ -2462,10 +2465,11 @@ pk_client_install_file (PkClient *client, const gchar *file_rel, GError **error)
/* save this so we can re-issue it */
client->priv->role = PK_ROLE_ENUM_INSTALL_FILE;
+ client->priv->cached_trusted = trusted;
client->priv->cached_full_path = g_strdup (file);
/* hopefully do the operation first time */
- ret = pk_client_install_file_action (client, file, &error_pk);
+ ret = pk_client_install_file_action (client, trusted, file, &error_pk);
/* we were refused by policy */
if (!ret && pk_polkit_client_error_denied_by_policy (error_pk)) {
@@ -2474,7 +2478,7 @@ pk_client_install_file (PkClient *client, const gchar *file_rel, GError **error)
/* clear old error */
g_clear_error (&error_pk);
/* retry the action now we have got auth */
- ret = pk_client_install_file_action (client, file, &error_pk);
+ ret = pk_client_install_file_action (client, trusted, file, &error_pk);
}
}
/* we failed one of these, return the error to the user */
@@ -2945,7 +2949,7 @@ pk_client_requeue (PkClient *client, GError **error)
} else if (priv->role == PK_ROLE_ENUM_INSTALL_PACKAGE) {
ret = pk_client_install_package (client, priv->cached_package_id, error);
} else if (priv->role == PK_ROLE_ENUM_INSTALL_FILE) {
- ret = pk_client_install_file (client, priv->cached_full_path, error);
+ ret = pk_client_install_file (client, priv->cached_trusted, priv->cached_full_path, error);
} else if (priv->role == PK_ROLE_ENUM_INSTALL_SIGNATURE) {
ret = pk_client_install_signature (client, PK_SIGTYPE_ENUM_GPG, priv->cached_key_id, priv->cached_package_id, error);
} else if (priv->role == PK_ROLE_ENUM_REFRESH_CACHE) {
diff --git a/libpackagekit/pk-client.h b/libpackagekit/pk-client.h
index 2a19112..af8d471 100644
--- a/libpackagekit/pk-client.h
+++ b/libpackagekit/pk-client.h
@@ -292,6 +292,7 @@ gboolean pk_client_update_packages_strv (PkClient *client,
GError **error)
G_GNUC_WARN_UNUSED_RESULT;
gboolean pk_client_install_file (PkClient *client,
+ gboolean trusted,
const gchar *file_rel,
GError **error)
G_GNUC_WARN_UNUSED_RESULT;
diff --git a/policy/org.freedesktop.packagekit.policy.in b/policy/org.freedesktop.packagekit.policy.in
index 6b9b43e..c69518d 100644
--- a/policy/org.freedesktop.packagekit.policy.in
+++ b/policy/org.freedesktop.packagekit.policy.in
@@ -24,9 +24,9 @@
</defaults>
</action>
- <action id="org.freedesktop.packagekit.localinstall">
+ <action id="org.freedesktop.packagekit.localinstall-untrusted">
<_description>Install local file</_description>
- <_message>Authentication is required to install a local file</_message>
+ <_message>Authentication is required to install an untrusted local file</_message>
<icon_name>pk-package-add</icon_name>
<vendor_url>http://www.packagekit.org/pk-reference.html#methods-install-file</vendor_url>
<defaults>
@@ -35,6 +35,17 @@
</defaults>
</action>
+ <action id="org.freedesktop.packagekit.localinstall-trusted">
+ <_description>Install local file</_description>
+ <_message>Authentication is required to install a trusted local file</_message>
+ <icon_name>pk-package-add</icon_name>
+ <vendor_url>http://www.packagekit.org/pk-reference.html#methods-install-file</vendor_url>
+ <defaults>
+ <allow_inactive>no</allow_inactive>
+ <allow_active>auth_admin_keep_always</allow_active>
+ </defaults>
+ </action>
+
<action id="org.freedesktop.packagekit.install-signature">
<_description>Install security signature</_description>
<_message>Authentication is required to install a security signature</_message>
diff --git a/python/packagekit/backend.py b/python/packagekit/backend.py
index 712b2ef..40f20b5 100644
--- a/python/packagekit/backend.py
+++ b/python/packagekit/backend.py
@@ -360,7 +360,7 @@ class PackageKitBaseBackend:
'''
self.error(ERROR_NOT_SUPPORTED,"This function is not implemented in this backend")
- def install_file (self, inst_file):
+ def install_file (self, trusted, inst_file):
'''
Implement the {backend}-install_file functionality
Install the package containing the inst_file file
diff --git a/python/packagekit/daemonBackend.py b/python/packagekit/daemonBackend.py
index 5382361..c576178 100644
--- a/python/packagekit/daemonBackend.py
+++ b/python/packagekit/daemonBackend.py
@@ -596,7 +596,7 @@ class PackageKitBaseBackend(dbus.service.Object):
@dbus.service.method(PACKAGEKIT_DBUS_INTERFACE,
in_signature='s', out_signature='')
- def InstallFile (self, inst_file):
+ def InstallFile (self, trusted, inst_file):
'''
Implement the {backend}-install_file functionality
Install the package containing the inst_file file
diff --git a/src/pk-backend-dbus.c b/src/pk-backend-dbus.c
index 456a1df..2fb1e6a 100644
--- a/src/pk-backend-dbus.c
+++ b/src/pk-backend-dbus.c
@@ -1202,7 +1202,7 @@ pk_backend_dbus_update_packages (PkBackendDbus *backend_dbus, gchar **package_id
* pk_backend_dbus_install_file:
**/
gboolean
-pk_backend_dbus_install_file (PkBackendDbus *backend_dbus, const gchar *full_path)
+pk_backend_dbus_install_file (PkBackendDbus *backend_dbus, gboolean trusted, const gchar *full_path)
{
gboolean ret;
GError *error = NULL;
@@ -1214,6 +1214,7 @@ pk_backend_dbus_install_file (PkBackendDbus *backend_dbus, const gchar *full_pat
/* new sync method call */
pk_backend_dbus_time_reset (backend_dbus);
ret = dbus_g_proxy_call (backend_dbus->priv->proxy, "InstallFile", &error,
+ G_TYPE_BOOLEAN, trusted,
G_TYPE_STRING, full_path,
G_TYPE_INVALID, G_TYPE_INVALID);
if (error != NULL) {
diff --git a/src/pk-backend-dbus.h b/src/pk-backend-dbus.h
index 88d946c..700bde9 100644
--- a/src/pk-backend-dbus.h
+++ b/src/pk-backend-dbus.h
@@ -108,6 +108,7 @@ gboolean pk_backend_dbus_install_package (PkBackendDbus *backend_dbus,
gboolean pk_backend_dbus_update_packages (PkBackendDbus *backend_dbus,
gchar **package_ids);
gboolean pk_backend_dbus_install_file (PkBackendDbus *backend_dbus,
+ gboolean trusted,
const gchar *full_path);
gboolean pk_backend_dbus_service_pack (PkBackendDbus *backend_dbus,
const gchar *location,
diff --git a/src/pk-backend.h b/src/pk-backend.h
index 20fa743..65db1c0 100644
--- a/src/pk-backend.h
+++ b/src/pk-backend.h
@@ -164,6 +164,7 @@ typedef struct {
void (*get_updates) (PkBackend *backend,
PkFilterEnum filters);
void (*install_file) (PkBackend *backend,
+ gboolean trusted,
const gchar *full_path);
void (*install_package) (PkBackend *backend,
const gchar *package_id);
diff --git a/src/pk-interface-transaction.xml b/src/pk-interface-transaction.xml
index 131eff8..4565d81 100644
--- a/src/pk-interface-transaction.xml
+++ b/src/pk-interface-transaction.xml
@@ -70,6 +70,7 @@
</method>
<method name="InstallFile">
<annotation name="org.freedesktop.DBus.GLib.Async" value=""/>
+ <arg type="b" name="trusted" direction="in"/>
<arg type="s" name="full_path" direction="in"/>
</method>
<method name="InstallPackage">
diff --git a/src/pk-security-dummy.c b/src/pk-security-dummy.c
index cf33fc3..0c47305 100644
--- a/src/pk-security-dummy.c
+++ b/src/pk-security-dummy.c
@@ -52,7 +52,7 @@ G_DEFINE_TYPE (PkSecurity, pk_security, G_TYPE_OBJECT)
**/
G_GNUC_WARN_UNUSED_RESULT gboolean
pk_security_action_is_allowed (PkSecurity *security, const gchar *dbus_sender,
- PkRoleEnum role, gchar **error_detail)
+ gboolean trusted, PkRoleEnum role, gchar **error_detail)
{
g_return_val_if_fail (PK_IS_SECURITY (security), FALSE);
return TRUE;
diff --git a/src/pk-security-polkit.c b/src/pk-security-polkit.c
index 242de66..c0613d1 100644
--- a/src/pk-security-polkit.c
+++ b/src/pk-security-polkit.c
@@ -98,7 +98,7 @@ pk_security_can_do_action (PkSecurity *security, const gchar *dbus_sender, const
* pk_security_role_to_action:
**/
static const gchar *
-pk_security_role_to_action (PkSecurity *security, PkRoleEnum role)
+pk_security_role_to_action (PkSecurity *security, gboolean trusted, PkRoleEnum role)
{
const gchar *policy = NULL;
@@ -113,8 +113,10 @@ pk_security_role_to_action (PkSecurity *security, PkRoleEnum role)
policy = "org.freedesktop.packagekit.remove";
} else if (role == PK_ROLE_ENUM_INSTALL_PACKAGE) {
policy = "org.freedesktop.packagekit.install";
- } else if (role == PK_ROLE_ENUM_INSTALL_FILE) {
- policy = "org.freedesktop.packagekit.localinstall";
+ } else if (role == PK_ROLE_ENUM_INSTALL_FILE && trusted) {
+ policy = "org.freedesktop.packagekit.localinstall-trusted";
+ } else if (role == PK_ROLE_ENUM_INSTALL_FILE && !trusted) {
+ policy = "org.freedesktop.packagekit.localinstall-untrusted";
} else if (role == PK_ROLE_ENUM_INSTALL_SIGNATURE) {
policy = "org.freedesktop.packagekit.install-signature";
} else if (role == PK_ROLE_ENUM_ACCEPT_EULA) {
@@ -138,7 +140,7 @@ pk_security_role_to_action (PkSecurity *security, PkRoleEnum role)
**/
gboolean
pk_security_action_is_allowed (PkSecurity *security, const gchar *dbus_sender,
- PkRoleEnum role, gchar **error_detail)
+ gboolean trusted, PkRoleEnum role, gchar **error_detail)
{
PolKitResult pk_result;
const gchar *policy;
@@ -147,7 +149,7 @@ pk_security_action_is_allowed (PkSecurity *security, const gchar *dbus_sender,
g_return_val_if_fail (dbus_sender != NULL, FALSE);
/* map the roles to policykit rules */
- policy = pk_security_role_to_action (security, role);
+ policy = pk_security_role_to_action (security, trusted, role);
if (policy == NULL) {
pk_warning ("policykit type required for '%s'", pk_role_enum_to_text (role));
return FALSE;
@@ -339,7 +341,7 @@ libst_security (LibSelfTest *test)
/************************************************************/
libst_title (test, "map valid role to action");
- action = pk_security_role_to_action (security, PK_ROLE_ENUM_UPDATE_PACKAGES);
+ action = pk_security_role_to_action (security, FALSE, PK_ROLE_ENUM_UPDATE_PACKAGES);
if (pk_strequal (action, "org.freedesktop.packagekit.update-package")) {
libst_success (test, NULL, error);
} else {
@@ -348,7 +350,7 @@ libst_security (LibSelfTest *test)
/************************************************************/
libst_title (test, "map invalid role to action");
- action = pk_security_role_to_action (security, PK_ROLE_ENUM_SEARCH_NAME);
+ action = pk_security_role_to_action (security, FALSE, PK_ROLE_ENUM_SEARCH_NAME);
if (action == NULL) {
libst_success (test, NULL, error);
} else {
@@ -358,7 +360,7 @@ libst_security (LibSelfTest *test)
/************************************************************/
libst_title (test, "get the default backend");
error = NULL;
- ret = pk_security_action_is_allowed (security, ":0", PK_ROLE_ENUM_UPDATE_PACKAGES, &error);
+ ret = pk_security_action_is_allowed (security, ":0", FALSE, PK_ROLE_ENUM_UPDATE_PACKAGES, &error);
if (ret == FALSE) {
libst_success (test, "did not authenticate update-package, error '%s'", error);
} else {
diff --git a/src/pk-security.h b/src/pk-security.h
index 24191da..3432095 100644
--- a/src/pk-security.h
+++ b/src/pk-security.h
@@ -52,6 +52,7 @@ PkSecurity *pk_security_new (void);
gboolean pk_security_action_is_allowed (PkSecurity *security,
const gchar *dbus_sender,
+ gboolean trusted,
PkRoleEnum role,
gchar **error_detail)
G_GNUC_WARN_UNUSED_RESULT;
diff --git a/src/pk-transaction.c b/src/pk-transaction.c
index 72c53c4..60c924c 100644
--- a/src/pk-transaction.c
+++ b/src/pk-transaction.c
@@ -94,6 +94,7 @@ struct PkTransactionPrivate
gboolean cached_allow_deps;
gboolean cached_autoremove;
gboolean cached_enabled;
+ gboolean cached_trusted;
gchar *cached_package_id;
gchar **cached_package_ids;
gchar *cached_transaction_id;
@@ -822,7 +823,7 @@ pk_transaction_set_running (PkTransaction *transaction)
} else if (priv->role == PK_ROLE_ENUM_INSTALL_PACKAGE) {
desc->install_package (priv->backend, priv->cached_package_id);
} else if (priv->role == PK_ROLE_ENUM_INSTALL_FILE) {
- desc->install_file (priv->backend, priv->cached_full_path);
+ desc->install_file (priv->backend, priv->cached_trusted, priv->cached_full_path);
} else if (priv->role == PK_ROLE_ENUM_INSTALL_SIGNATURE) {
desc->install_signature (priv->backend, PK_SIGTYPE_ENUM_GPG, priv->cached_key_id, priv->cached_package_id);
} else if (priv->role == PK_ROLE_ENUM_SERVICE_PACK) {
@@ -1038,13 +1039,13 @@ out:
**/
static gboolean
pk_transaction_action_is_allowed (PkTransaction *transaction, const gchar *dbus_sender,
- PkRoleEnum role, GError **error)
+ gboolean trusted, PkRoleEnum role, GError **error)
{
gboolean ret;
gchar *error_detail;
/* use security model to get auth */
- ret = pk_security_action_is_allowed (transaction->priv->security, dbus_sender, role, &error_detail);
+ ret = pk_security_action_is_allowed (transaction->priv->security, dbus_sender, trusted, role, &error_detail);
if (!ret) {
*error = g_error_new (PK_TRANSACTION_ERROR, PK_TRANSACTION_ERROR_REFUSED_BY_POLICY, "%s", error_detail);
return FALSE;
@@ -1093,7 +1094,7 @@ pk_transaction_accept_eula (PkTransaction *transaction, const gchar *eula_id, DB
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_ACCEPT_EULA, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_ACCEPT_EULA, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -1810,8 +1811,8 @@ pk_transaction_get_updates (PkTransaction *transaction, const gchar *filter, DBu
* pk_transaction_install_file:
**/
void
-pk_transaction_install_file (PkTransaction *transaction, const gchar *full_path,
- DBusGMethodInvocation *context)
+pk_transaction_install_file (PkTransaction *transaction, gboolean trusted,
+ const gchar *full_path, DBusGMethodInvocation *context)
{
gboolean ret;
GError *error;
@@ -1820,7 +1821,7 @@ pk_transaction_install_file (PkTransaction *transaction, const gchar *full_path,
g_return_if_fail (PK_IS_TRANSACTION (transaction));
g_return_if_fail (transaction->priv->tid != NULL);
- pk_debug ("InstallFile method called: %s", full_path);
+ pk_debug ("InstallFile method called: %s (trusted %i)", full_path, trusted);
/* not implemented yet */
if (transaction->priv->backend->desc->install_file == NULL) {
@@ -1842,7 +1843,7 @@ pk_transaction_install_file (PkTransaction *transaction, const gchar *full_path,
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_INSTALL_FILE, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, trusted, PK_ROLE_ENUM_INSTALL_FILE, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -1853,6 +1854,7 @@ pk_transaction_install_file (PkTransaction *transaction, const gchar *full_path,
pk_transaction_set_dbus_name (transaction, dbus_g_method_get_sender (context));
/* save so we can run later */
+ transaction->priv->cached_trusted = trusted;
transaction->priv->cached_full_path = g_strdup (full_path);
transaction->priv->status = PK_STATUS_ENUM_WAIT;
pk_transaction_set_role (transaction, PK_ROLE_ENUM_INSTALL_FILE);
@@ -1915,7 +1917,7 @@ pk_transaction_install_package (PkTransaction *transaction, const gchar *package
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_INSTALL_PACKAGE, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_INSTALL_PACKAGE, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -1989,7 +1991,7 @@ pk_transaction_install_signature (PkTransaction *transaction, const gchar *sig_t
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_INSTALL_SIGNATURE, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_INSTALL_SIGNATURE, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2059,7 +2061,7 @@ pk_transaction_refresh_cache (PkTransaction *transaction, gboolean force, DBusGM
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_REFRESH_CACHE, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_REFRESH_CACHE, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2136,7 +2138,7 @@ pk_transaction_remove_package (PkTransaction *transaction, const gchar *package_
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_REMOVE_PACKAGE, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_REMOVE_PACKAGE, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2201,7 +2203,7 @@ pk_transaction_repo_enable (PkTransaction *transaction, const gchar *repo_id, gb
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_REPO_ENABLE, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_REPO_ENABLE, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2268,7 +2270,7 @@ pk_transaction_repo_set_data (PkTransaction *transaction, const gchar *repo_id,
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_REPO_SET_DATA, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_REPO_SET_DATA, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2396,7 +2398,7 @@ pk_transaction_rollback (PkTransaction *transaction, const gchar *transaction_id
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_ROLLBACK, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_ROLLBACK, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2724,7 +2726,7 @@ pk_transaction_update_packages (PkTransaction *transaction, gchar **package_ids,
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_UPDATE_PACKAGES, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_UPDATE_PACKAGES, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
@@ -2778,7 +2780,7 @@ pk_transaction_update_system (PkTransaction *transaction, DBusGMethodInvocation
/* check if the action is allowed from this client - if not, set an error */
sender = dbus_g_method_get_sender (context);
- ret = pk_transaction_action_is_allowed (transaction, sender, PK_ROLE_ENUM_UPDATE_SYSTEM, &error);
+ ret = pk_transaction_action_is_allowed (transaction, sender, FALSE, PK_ROLE_ENUM_UPDATE_SYSTEM, &error);
g_free (sender);
if (!ret) {
dbus_g_method_return_error (context, error);
diff --git a/src/pk-transaction.h b/src/pk-transaction.h
index a3c50e2..8d9200c 100644
--- a/src/pk-transaction.h
+++ b/src/pk-transaction.h
@@ -151,6 +151,7 @@ void pk_transaction_get_updates (PkTransaction *transaction,
const gchar *filter,
DBusGMethodInvocation *context);
void pk_transaction_install_file (PkTransaction *transaction,
+ gboolean trusted,
const gchar *full_path,
DBusGMethodInvocation *context);
void pk_transaction_install_package (PkTransaction *transaction,
More information about the PackageKit-commit
mailing list