summaryrefslogtreecommitdiff
path: root/data/org.freedesktop.PolicyKit1.Authority.xml
blob: 06018ee00fd0347774a1280a61faca0bd92e5c5f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN"
"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node>

  <interface name="org.freedesktop.PolicyKit1.Authority">
    <annotation name="org.gtk.EggDBus.DocString.Summary" value="Authority Interface"/>
    <annotation name="org.gtk.EggDBus.DocString" value="This D-Bus interface is implemented by the <literal>/org/freedesktop/PoliycKit1/Authority</literal> object on the well-known name <literal>org.freedesktop.PolicyKit1</literal> on the system message bus."/>

    <!-- Subject struct -->
    <annotation name="org.gtk.EggDBus.DeclareStruct" value="Subject">

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:subject_kind">
        <annotation name="org.gtk.EggDBus.DocString" value="Kind of subject"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="a{sv}:subject_details">
        <annotation name="org.gtk.EggDBus.DocString" value="Details about the subject"/>
      </annotation>

      <!-- TODO: document values in hash map for each subject type-->

    </annotation>

    <!-- Identity struct -->
    <annotation name="org.gtk.EggDBus.DeclareStruct" value="Identity">

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:identity_kind">
        <annotation name="org.gtk.EggDBus.DocString" value="Kind of identity"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="a{sv}:identity_details">
        <annotation name="org.gtk.EggDBus.DocString" value="Details about the identity"/>
      </annotation>

      <!-- TODO: document values in hash map for each identity type-->

    </annotation>

    <!-- ActionDescription struct -->
    <annotation name="org.gtk.EggDBus.DeclareStruct" value="ActionDescription">

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:action_id">
        <annotation name="org.gtk.EggDBus.DocString" value="Action Identifier"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:description">
        <annotation name="org.gtk.EggDBus.DocString" value="Action Description"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:message">
        <annotation name="org.gtk.EggDBus.DocString" value="Action Message"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:vendor_name">
        <annotation name="org.gtk.EggDBus.DocString" value="Vendor Name"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:vendor_url">
        <annotation name="org.gtk.EggDBus.DocString" value="Vendor URL"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="s:icon_name">
        <annotation name="org.gtk.EggDBus.DocString" value="Icon Name"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="i:implicit_any">
        <annotation name="org.gtk.EggDBus.EnumType" value="ImplicitAuthorization"/>
        <annotation name="org.gtk.EggDBus.DocString" value="Defaults for any kind of subject"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="i:implicit_inactive">
        <annotation name="org.gtk.EggDBus.EnumType" value="ImplicitAuthorization"/>
        <annotation name="org.gtk.EggDBus.DocString" value="Defaults for subjects in local inactive sessions"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="i:implicit_active">
        <annotation name="org.gtk.EggDBus.EnumType" value="ImplicitAuthorization"/>
        <annotation name="org.gtk.EggDBus.DocString" value="Defaults for subjects in local active sessions"/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Struct.Member"  value="a{ss}:annotations">
        <annotation name="org.gtk.EggDBus.DocString" value="Annotations"/>
      </annotation>

    </annotation>

    <!-- Flags used for checking authorizations -->
    <annotation name="org.gtk.EggDBus.DeclareFlags" value="CheckAuthorizationFlags">
      <annotation name="org.gtk.EggDBus.Flags.Member" value="AllowUserInteraction">
        <annotation name="org.gtk.EggDBus.DocString" value="If the subject can obtain the authorization through authentication, and an authentication agent is available, then attempt to do so. Note, this means that the #CheckAuthorization() method is likely to block for a long time."/>
      </annotation>
    </annotation>

    <!-- An enumeration for results when checking for an authorization -->
    <annotation name="org.gtk.EggDBus.DeclareEnum" value="AuthorizationResult">
      <annotation name="org.gtk.EggDBus.Enum.Member" value="NotAuthorized">
        <annotation name="org.gtk.EggDBus.DocString" value="The subject is not authorized for the specified action"/>
      </annotation>
      <annotation name="org.gtk.EggDBus.Enum.Member" value="Authorized">
        <annotation name="org.gtk.EggDBus.DocString" value="The subject is authorized for the specified action"/>
      </annotation>
      <annotation name="org.gtk.EggDBus.Enum.Member" value="Challenge">
        <annotation name="org.gtk.EggDBus.DocString" value="The subject is authorized if more information is provided"/>
      </annotation>
    </annotation>

    <!-- An enumeration for implicit authorizations -->
    <annotation name="org.gtk.EggDBus.DeclareEnum" value="ImplicitAuthorization">

      <annotation name="org.gtk.EggDBus.Enum.Member" value="NotAuthorized">
        <annotation name="org.gtk.EggDBus.DocString" value="Subject is not authorized."/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Enum.Member" value="AuthenticationRequired">
        <annotation name="org.gtk.EggDBus.DocString" value="Authentication is required."/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Enum.Member" value="AdministratorAuthenticationRequired">
        <annotation name="org.gtk.EggDBus.DocString" value="Authentication as an administrator is required."/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Enum.Member" value="AuthenticationRequiredRetained">
        <annotation name="org.gtk.EggDBus.DocString" value="Authentication is required. If the authorization is obtained, it is retained."/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Enum.Member" value="AdministratorAuthenticationRequiredRetained">
        <annotation name="org.gtk.EggDBus.DocString" value="Authentication as an administrator is required. If the authorization is obtained, it is retained."/>
      </annotation>

      <annotation name="org.gtk.EggDBus.Enum.Member" value="Authorized">
        <annotation name="org.gtk.EggDBus.DocString" value="The subject is authorized"/>
      </annotation>

    </annotation>

    <!-- The error domain used for reporting errors -->
    <annotation name="org.gtk.EggDBus.DeclareErrorDomain" value="Error">
      <annotation name="org.gtk.EggDBus.ErrorDomain.Member" value="org.freedesktop.PolicyKit1.Error.Failed">
        <annotation name="org.gtk.EggDBus.DocString" value="The operation failed"/>
      </annotation>
      <annotation name="org.gtk.EggDBus.ErrorDomain.Member" value="org.freedesktop.PolicyKit1.Error.NotSupported">
        <annotation name="org.gtk.EggDBus.DocString" value="Operation is not supported"/>
      </annotation>
      <annotation name="org.gtk.EggDBus.ErrorDomain.Member" value="org.freedesktop.PolicyKit1.Error.NotAuthorized">
        <annotation name="org.gtk.EggDBus.DocString" value="Not authorized to perform operation"/>
      </annotation>
    </annotation>

    <method name="EnumerateActions">
      <annotation name="org.gtk.EggDBus.DocString" value="Enumerates all registered PolicyKit actions."/>

      <arg name="locale" direction="in" type="s">
        <annotation name="org.gtk.EggDBus.DocString" value="The locale to get descriptions in or the blank string to use the system locale."/>
      </arg>

      <arg name="action_descriptions" direction="out" type="a(ssssssiiia{ss})">
        <annotation name="org.gtk.EggDBus.DocString" value="An array of action description structs."/>
        <annotation name="org.gtk.EggDBus.StructType" value="ActionDescription"/>
      </arg>
    </method>

    <method name="CheckAuthorization">
      <annotation name="org.gtk.EggDBus.DocString" value="Checks if @subject is authorized to perform the action with identifier @action_id."/>

      <arg name="subject" direction="in" type="(sa{sv})">
        <annotation name="org.gtk.EggDBus.DocString" value="The subject in question."/>
        <annotation name="org.gtk.EggDBus.StructType" value="Subject"/>
      </arg>

      <arg name="action_id" direction="in" type="s">
        <annotation name="org.gtk.EggDBus.DocString" value="Identifier for the action that @subject is attempting to do."/>
      </arg>

      <arg name="flags" direction="in" type="i">
        <annotation name="org.gtk.EggDBus.DocString" value="A set of #CheckAuthorizationFlags."/>
        <annotation name="org.gtk.EggDBus.FlagsType" value="CheckAuthorizationFlags"/>
      </arg>

      <arg name="result" direction="out" type="i">
        <annotation name="org.gtk.EggDBus.DocString" value="The result of the authorization check."/>
        <annotation name="org.gtk.EggDBus.EnumType" value="AuthorizationResult"/>
      </arg>
    </method>

    <method name="RegisterAuthenticationAgent">
      <annotation name="org.gtk.EggDBus.DocString" value="Register an authentication agent."/>

      <arg name="object_path" direction="in" type="s">
        <annotation name="org.gtk.EggDBus.DocString" value="The object path of authentication agent object on the unique name of the caller."/>
      </arg>
    </method>

    <method name="UnregisterAuthenticationAgent">
      <annotation name="org.gtk.EggDBus.DocString" value="Unregister an authentication agent."/>

      <arg name="object_path" direction="in" type="s">
        <annotation name="org.gtk.EggDBus.DocString" value="The object path of authentication agent object on the unique name of the caller."/>
      </arg>
    </method>

    <method name="AuthenticationAgentResponse">
      <annotation name="org.gtk.EggDBus.DocString" value="Method for authentication agents to invoke on successful authentication. This method will fail unless a sufficiently privileged caller invokes it."/>

      <arg name="cookie" direction="in" type="s">
        <annotation name="org.gtk.EggDBus.DocString" value="The cookie identifying the authentication request that was passed to the authentication agent."/>
      </arg>

      <arg name="identity" direction="in" type="(sa{sv})">
        <annotation name="org.gtk.EggDBus.StructType" value="Identity"/>
        <annotation name="org.gtk.EggDBus.DocString" value="The identity that was authenticated."/>
      </arg>
    </method>

    <signal name="Changed">
      <annotation name="org.gtk.EggDBus.DocString" value="Emitted when actions and/or authorizations change"/>
    </signal>

  </interface>
</node>