[gnome-keyring/dbus-api] Add a rough draft of the secrets interfaces.



commit 176b91af8700e65a54c92c7d6b81fef2a8e558c8
Author: Stef Walter <stef memberwebs com>
Date:   Fri Jun 19 20:28:14 2009 +0000

    Add a rough draft of the secrets interfaces.
    
    These are not usable yet, but imported them into this
    branch, so we can make progress here.

 .../api/org.freedesktop.Secrets.Collection.xml     |   71 +++++++++++++++++
 .../secrets/api/org.freedesktop.Secrets.Item.xml   |   35 +++++++++
 .../api/org.freedesktop.Secrets.Service.xml        |   80 ++++++++++++++++++++
 .../api/org.freedesktop.Secrets.Session.xml        |   24 ++++++
 4 files changed, 210 insertions(+), 0 deletions(-)
---
diff --git a/daemon/secrets/api/org.freedesktop.Secrets.Collection.xml b/daemon/secrets/api/org.freedesktop.Secrets.Collection.xml
new file mode 100644
index 0000000..927034f
--- /dev/null
+++ b/daemon/secrets/api/org.freedesktop.Secrets.Collection.xml
@@ -0,0 +1,71 @@
+<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
+ "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd";>
+
+<!-- 
+/org/freedesktop/secrets/default
+/org/freedesktop/secrets/login
+/org/freedesktop/secrets/<collection>
+-->
+
+<node name="/org/freedesktop/secrets/collection/xxxx">
+	<interface name="org.freedesktop.Secrets.Collection">
+
+		<<< created signal >>>
+		<<< deleted signal >>>
+
+		<!-- 
+		 * The displayable label of the collection. 
+		-->
+		<property name="Label" type="s" access="readwrite"/>
+
+		<!--
+		 * Whether the correction is locked or not.
+		-->
+		<property name="Locked" type="s" access="read"/>
+
+		<!--
+		 * Lock this collection.
+		-->
+		<method name="Lock">
+		</method>
+
+		<!--
+		 * Unlock the collection. This method may block for 
+		 * an indeterminate amount of time while authenticating.
+		-->
+		<method name="Unlock">
+		</method>
+
+		<!--
+		 * Delete this collection.
+		-->
+		<method name="Delete">
+		</method>
+
+		<!--
+		 * List the object paths of all items in this collection
+		 * If fields contains values then items returned will be 
+		 * restricted by those.
+		-->
+		<method name="ListItems">
+			<arg name="fields" type="e{ss}" direction="in"/>
+			<arg name="results" type="ao" direction="out"/>
+		</method>
+
+		<!--
+		 * Create an item with the given fields, secret and label.
+		 * If replace is set, then it replaces an item already
+		 * present with the same fields.
+		 *
+		-->
+		<method name="CreateItem">
+			<arg name="fields" type="e{ss}" direction="in"/>
+			<arg name="secret" type="(ss)" direction="in"/>
+			<arg name="label" type="s" direction="in"/>
+			<arg name="replace" type="b" direction="in"/>
+			<arg name="result" type="o" direction="out"/>
+		</method>
+
+	</interface>
+</node>
+
diff --git a/daemon/secrets/api/org.freedesktop.Secrets.Item.xml b/daemon/secrets/api/org.freedesktop.Secrets.Item.xml
new file mode 100644
index 0000000..d4b7c27
--- /dev/null
+++ b/daemon/secrets/api/org.freedesktop.Secrets.Item.xml
@@ -0,0 +1,35 @@
+<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
+ "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd";>
+
+<!-- 
+
+-->
+
+<node name="/org/freedesktop/secrets/collection/xxxx/xxxx">
+	<interface name="org.freedesktop.Secrets.Item">
+
+		<<< changed signal >>>
+
+		<!-- 
+		 * The lookup fields for this item.
+		-->
+		<property name="Fields" type="e{ss}" access="readwrite"/>
+
+		<!-- 
+		 * The displayable label for this item. 
+		-->
+		<property name="Label" type="s" access="readwrite"/>
+
+		<!-- 
+		 * The secret, usually transferred encrypted.
+		-->
+		<property name="Secret" type="(ss)" access="readwrite"/>
+
+		<!--
+		 * Delete this item.
+		-->
+		<method name="Delete"/>
+
+	</interface>
+</node>
+
diff --git a/daemon/secrets/api/org.freedesktop.Secrets.Service.xml b/daemon/secrets/api/org.freedesktop.Secrets.Service.xml
new file mode 100644
index 0000000..2cdee95
--- /dev/null
+++ b/daemon/secrets/api/org.freedesktop.Secrets.Service.xml
@@ -0,0 +1,80 @@
+<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
+ "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd";>
+
+<!-- 
+ * This is the well known dbus service name for controlling the 
+ * entire daemon. The services manages collections of secrets. These
+ * are analogous to the gnome-keyring 'keyrings'.
+-->
+
+<node name="/org/freedesktop/secrets">
+	<interface name="org.freedesktop.Secrets.Service">
+
+		<method name="CreateSession">
+			<annotation name="org.gtk.EggDBus.DocString" 
+			            value="Create a unique session for the caller application."/>
+			              
+			<arg name="result" type="o" direction="out">
+				<annotation name="org.gtk.EggDBus.DocString"
+				            value="The object path of the session."/>
+			</arg>
+		</method>
+		
+		<method name="ListCollections">
+			<annotation name="org.gtk.EggDBus.DocString"
+			            value="List the object paths of all collections (ie: keyrings)"/>
+			            
+			<arg name="result" type="ao" direction="out">
+				<annotation name="org.gtk.EggDBus.DocString"
+				            value="An array of object paths"/>
+			</arg>
+		</method>
+
+		<method name="CreateCollection">
+			<annotation name="org.gtk.EggDBus.DocString"
+			            value="Create a new collection with the specified access attributes"/>
+			            
+			<arg name="display_name" type="s" direction="in">
+				<annotation name="org.gtk.EggDBus.DocString"
+				            value="The display name of the new collection"/>
+			</arg>
+			
+			<!-- TODO: Access rules need more thought. Unimplemented -->
+			<arg name="access_rules" type="as" direction="in">
+				<annotation name="org.gtk.EggDBus.DocString"
+				            value="The access rules of the new collection"/>
+			</arg>
+		</method>
+
+		<property name="DefaultCollection" type="o" access="readwrite">
+			<annotation name="org.gtk.EggDBus.DocString"
+			            value="The object path of the default collection."/>
+		</property>
+		
+		<method name="LockService">
+			<annotation name="org.gtk.EggDBus.DocString"
+			            value="Lock down the entire service. Remove secrets from memory, lock all collections etc..."/>
+		</method>
+
+		<method name="FindSecrets">
+			<annotation name="org.gtk.EggDBus.DocString"
+			            value="Find secrets in any collection."/>
+			            
+			<arg name="fields" type="a{ss}" direction="in">
+			</arg>
+			
+			<arg name="results" type="a{os}" direction="out">
+			</arg>
+		</method>
+		
+		<signal name="CollectionCreated">
+			<arg name="collection" type="o"/>
+		</signal>
+		
+		<signal name="CollectionDeleted">
+			<arg name="collection" type="o"/>
+		</signal>
+
+	</interface>
+</node>
+
diff --git a/daemon/secrets/api/org.freedesktop.Secrets.Session.xml b/daemon/secrets/api/org.freedesktop.Secrets.Session.xml
new file mode 100644
index 0000000..b956e2a
--- /dev/null
+++ b/daemon/secrets/api/org.freedesktop.Secrets.Session.xml
@@ -0,0 +1,24 @@
+<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
+"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd";>
+
+
+	<!--
+	 * Negotiate key agreement and encryption.
+	-->
+	<method name="Negotiate">
+		<arg name="algorithms" type="s" direction="in"/>
+		<arg name="input" type="ay" direction="in"/>
+		<arg name="output" type="ay" direction="out"/>
+	</method>
+
+	<method name="BeginAuthenticate">
+		object
+		window-id
+	</method>
+	
+	<method name="CompleteAuthenticate">
+		object
+	</method>
+	
+	<signal name="Authenticated">
+	
\ No newline at end of file



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]