Project

General

Profile

Add-on System » History » Version 9

Hans-Martin Haase, 08/18/2015 12:16 PM
Add details about actions and config entries.

1 4 Hans-Martin Haase
{{toc}}
2
3 1 Dirk Petrautzki
h1. Add-on System
4 4 Hans-Martin Haase
5
On this wiki page you'll find detailed information about the add-on development like the different kinds of add-ons and how they are enabled to communicate with core application.
6
7
h2. Definition of Add-on in the Open eCard context
8
9
_Add-on_ is the generic term for a component that enhances the functionality of the Open eCard App.
10
11
_Extensions_ are independent from the context. Moreover, they are included directly into the user interface and can be executed by the user. For instance, an add-on that provides a PIN change functionality for smart cards is classified as an _extension_.
12
13
_Plug-ins_ depend on the context in which the user uses the application. Performing an authentication to a service using a particular smart card, for instance, requires a _plug-in_ which is capable of providing such functionality. Subsequently, _plug-ins_ require a communication with bindings to interact with external applications and services. Furthermore, we distinguish between IFD, SAL, and application plug-ins.
14
15
h2. Add-on Types
16
17
h3. IFD Plug-ins
18
19 8 Hans-Martin Haase
An IFD Plug-in represents a protocol which is used to extend the IFD. The protocol implementation may enable the IFD to perform a special user authentication method or establish a secure channel between a card and card reader to protect the communication from being eavesdropped. Each protocol must have a unique identifier in form of a URI. The URI must be associated with the actual implementation as described in the [[Add-on System#IFD protocol implementation details|IFD protocol implementation details]]. In addition, each protocol plug-in must implement the IFD Protocol Interface and must define protocol-specific _AuthenticationProtocolData_ used in the _EstablishChannel_ call and corresponding response message. An example for an IFD Plugin is the Password Authenticated Connection Establishment (PACE) protocol which is executed by the IFD. It is included as integrated add-on in the Open eCard App.
20 5 Hans-Martin Haase
21 4 Hans-Martin Haase
h3. SAL Plug-ins
22
23 5 Hans-Martin Haase
The SAL provides generic interfaces to common smart card services like Crypto services or differential identity services. The SAL can be extended by plug-ins, which provide implementations of protocols for the Crypto Services and the Differential Identity Services as required for the use of specific signature cards and electronic identity cards for example. The plugin concept is quite similar to the one used for the IFD. There is also an unique identifier necessary in the protocol implementation but an SAL protocol may have multiple steps and allows the definition more sophisticated user interfaces including a sequence of interaction steps to represent information dialogues and general user consents. For example the already included Extended Access Control (EAC) protocol is one of this kind. The protocol is used while authentication process with German eID card.
24
25
26 4 Hans-Martin Haase
h3. Application Plug-ins
27
28 5 Hans-Martin Haase
Application plug-ins provide a mechanism to add additional functionality to the eID application with which external applications can communicate. Depending on the type of the underlying binding, this could be a browser, a PKCS#11 module or even a remote application. Protocol bindings realize the connection to the external world. While a broad variety of transport protocols could be supported, the most obvious choices are HTTP and SOAP,
29 6 Hans-Martin Haase
as they are stipulated by for example. Given the properties of the activation mechanism, HTTP and SOAP, as well as similar transport protocols, the abstract requirements for a protocol binding are given as follows: A protocol binding must support 
30 5 Hans-Martin Haase
31
# a request-response semantic,
32
# a mapping mechanism to identify the appropriate plug-in for a request,
33
# messages comprising a body, named parameters and attachments,
34
# an error delivery mechanism, and
35
# a redirect semantic.
36
37 4 Hans-Martin Haase
h3. Application Extensions
38
39 5 Hans-Martin Haase
Extensions enhance – similar to plug-ins – the basic eID platform and provide additional functionality, but they do not depend on the context in which the eID application is used. Further, extensions are included into the user interface and can be started directly by the user. Similar to application plug-ins, the _AppExtensionAction_ interface contains an execute function. However, this function does not have any parameters nor does it have a result. Therefore, it cannot be used with a binding and only be triggered manually.
40
41
42 4 Hans-Martin Haase
h2. Architecture of an Add-on package
43
44
h3. General architecture
45
46 7 Hans-Martin Haase
An Add-on package is an Java archive (JAR) file which bundles all requires resources like libraries etc. The recognition in the base application is done with via an add-on manifest file located in the _META-INF_ directory. The manifest file has to have the name _addon.xml_ else the archive is not recognized as add-on. This file describes the data model of the add-on you'll find it below. The data model is an XML structure containing general information such as the name, the textual description and configuration entries for changeable settings of the add-on. Furthermore actions are contained which represent the different add-on types from above. The settings are stored in an add-on specific directory and are loaded as Java Properties by the ad-on framework.
47
48
p=. !{width:70%; height:70%}description.png(Add-on manifest data model in UML)!
49
50 4 Hans-Martin Haase
h3. The Add-on Manifest
51 7 Hans-Martin Haase
52
This section shows all possible entries for an add-on manifest file and explain there meaning. The manifest is more or less divided into two parts the first one states the general information about the add-on and the second one contains the description of the add-on classes and configuration. So lets start with the general information section.
53
54
<pre>
55
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
56
<AddonSpecification>
57
    <ID>123</ID>
58
    <Version>1.0-SNAPSHOT</Version>
59
    <License>WTFPL</License>
60
    <LicenseText xml:lang="EN">
61
        <![CDATA[<center><b>DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE</b>
62
        <br><br>
63
        Version 2, December 2004
64
        <br><br>
65
        Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
66
        </center>
67
        <br><br>
68
        Everyone is permitted to copy and distribute verbatim or modified
69
        copies of this license document, and changing it is allowed as long
70
        as the name is changed.
71
        <br><br>
72
        DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
73
        TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
74
        <br><br>
75
        0. You just DO WHAT THE FUCK YOU WANT TO.]]>
76
    </LicenseText>
77
    <LocalizedName xml:lang="DE">DummyAddon</LocalizedName>
78
    <LocalizedName xml:lang="EN">DummyAddon</LocalizedName>
79
    <LocalizedDescription xml:lang="EN">Dummy addon which prints some text to standard output and log file.</LocalizedDescription>
80
    <LocalizedDescription xml:lang="DE">Dummy Addon, das nur etwas Text auf der Standardausgabe ausgibt und in die Logdatei schreibt.</LocalizedDescription>
81
    <About xml:lang="EN">
82
        <![CDATA[About:
83
84
        This plugin is just for testing purpose of the Open eCard Addons about dialog. It follows some dummy text to check formatting and wrapping. Lorem ipsum dolor 
85
        sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et
86
        accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit met. Lorem ipsum dolor sit amet,
87
        consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et
88
        justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur 
89
        adipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo 
90
        olores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing 
91
        elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea
92
        rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.]]>
93
    </About>
94
    <Logo>DummyLogo.gif</Logo>
95
    <ConfigDescription>
96
        <Entries>
97
            <EnumListEntry>
98
                <Key>Animal_key</Key>
99
                <Value>Dog</Value>
100
                <Value>Cat</Value>
101
                <Value>Mouse</Value>
102
                <Value>Elephant</Value>
103
                <Value>Donkey</Value>
104
                <LocalizedName xml:lang="DE">Tier-ConfigurationEntry</LocalizedName>
105
                <LocalizedName xml:lang="EN">Animal configuration entry</LocalizedName>
106
                <LocalizedDescription xml:lang="DE">Beschreibung des Tier-ConfigurationEntry</LocalizedDescription>
107
                <LocalizedDescription xml:lang="EN">Description of the animal configuration entry</LocalizedDescription>
108
            </EnumListEntry>
109
            <EnumEntry>
110
                <Key>Kitchen_key</Key>
111
                <Value>Spoon</Value>
112
                <Value>Fork</Value>
113
                <Value>Knife</Value>
114
                <Value>Cup</Value>
115
                <Value>Mug</Value>
116
                <LocalizedName xml:lang="DE">Küchen-ConfigurationEntry</LocalizedName>
117
                <LocalizedName xml:lang="EN">Kitchen configuration entry</LocalizedName>
118
                <LocalizedDescription xml:lang="DE">Beschreibung des Küchen-ConfigurationEntry</LocalizedDescription>
119
                <LocalizedDescription xml:lang="EN">Description of the Kitchen configuation entry</LocalizedDescription>
120
            </EnumEntry>
121
        </Entries>
122
    </ConfigDescription>
123
    [...]
124
</AddonSpecification>
125
</pre>
126
127
As you can see the manifest starts with the @<AddonSpecification>@ tag which covers the complete description. Every add-on requires at least the elements @<ID>@, @<Version>@, @<License>@, @<Logo>@ and a @<ConfigDescription>@ which are explained below. 
128
129 9 Hans-Martin Haase
|@<ID>@                |A unique identifier for the add-on package.                                                                                                                         |
130
|@<Version>@           |The version number of the add-on. This number is used to select an add-on in case there are several versions available.                                             |
131
|@<License>@           |This element is expected to contain the name of the license of the add-on. For instance _LGPL Version 3_ or _Proprietary_ are such names but in case of a custom or proprietary license you should state the text of the license in the optional element @<LicenseText>@ field.                                                                                 |
132
|@<Logo>@              |This element states a name of a logo file contained in the add-on package. This logo is displayed in the GUI in case there are configuration options for your add-on.                                                                                                                                                                                     |
133
|@<ConfigDescription>@ |The element is used to state configuration entries which are used by all parts of the addon. For complete description of the @<ConfigDescription>@ see the next section. If there are no such configuration entries the element may be set to empty witht the element tag @<ConfigDescription/>@. A detailed description of this element is available [[Add-on System#Types available in the configuration|here]].                                                                                                                                |
134 7 Hans-Martin Haase
135
The optional elements of this first section are @<LicenseText>@, @<LocalizedName>@, @<LocalizedDescription>@ and @<About>@.
136 1 Dirk Petrautzki
137 9 Hans-Martin Haase
|@<About>@                |Localized string containing the typical information state in an about dialog. The elements may appear several times for different languages. |
138
|@<LicenseText>@          |Localized string containing the license text of the add-on. The element may appear several times for different languages.                    |
139
|@<LocalizedDescription>@ |Localized string containing a description of the add-on. The element may appear several times for different languages.                       |
140
|@<LocalizedName>@        |Localized string containing the name of the add-on. The element may appear several times for different languages.                            |
141 1 Dirk Petrautzki
142
*Note:* The elements @<About>@ and @<LicenseText>@ may contain a @CDATA@ block containing basic HTML code to format the text. This feature heavily depends on the UI implementation. For example the richclient which uses the Swing Framework supports just HTML in version 3.2. Other gui implementations may support higher versions and so more tags.
143 7 Hans-Martin Haase
&nbsp;
144 8 Hans-Martin Haase
&nbsp;
145 9 Hans-Martin Haase
Now we have the general part of the add-on so let's go on with the second part. The second part contains the descriptions of the available actions which have to appear in the following order @<BindingActions>@, @<ApplicationActions>@, @<IFDActions>@ and @<SALActions>@.
146
147
* *BindingActions* contain the descriptions of Application Plugin
148
* *ApplicationActions* contain the descriptions of Application Extensions
149
* *IFDActions* contain the descriptions of IFD Plugins
150
* *SALActions* contain the descriptions of SAL Plugins
151
152
Every *Actions element may contain zero or more elements which describe the actions. An example of the second part is below but note there don't have to be all actions available it's just an example non relevant actions do not have to appear or may be stated as empty.
153
154 1 Dirk Petrautzki
<pre>
155
    <AddonSpecification>
156
        [...]
157 9 Hans-Martin Haase
        <BindingActions>
158
            <AppPluginSpecification>
159
                <ClassName>package.path.to.my.class</ClassName>
160
                <LoadOnStartup>true</LoadOnStartup>
161
                <LocalizedName xml:lang="EN">Test class</LocalizedName>
162
                <LocalizedDescription xml:lang="EN">Test descriptions</LocalizedDescription>
163
                <ResourceName>/test</ResourceName>
164
                <ConfigDescription/>
165
                <Parameters>
166
                    <Name>Foo</Name>
167
                    <Value>Bar</Value>
168
                </Parameters>
169
                <Body>
170
                    <MimeType>text/html</MimeType>
171
                    <Node><![CDATA[<html><head></head><body>test</body></html>]]></Node>
172
                </Body>
173
                <Attachments>
174
                    <MimeType>application/octet-stream</MimeType>
175
                    <Name>signature.asc</Name>
176
                </Attachments>
177
            </AppPluginSpecification>
178
        </BindingActions>
179 1 Dirk Petrautzki
        <ApplicationActions>
180
            <AppExtensionSpecification>
181
                <ID>123</ID>
182
                <ClassName>org.openecard.addon.openecarddummyaddon.DummyAddonStep</ClassName>
183 7 Hans-Martin Haase
                <LoadOnStartup>true</LoadOnStartup>
184
                <LocalizedName xml:lang="DE">Test-ExtensionAction</LocalizedName>
185
                <LocalizedName xml:lang="EN">Test extension action</LocalizedName>
186
                <LocalizedDescription xml:lang="DE">Testbeschreibung</LocalizedDescription>
187
                <LocalizedDescription xml:lang="EN">test description</LocalizedDescription>
188
                <ConfigDescription>
189
                    <Entries>
190
                        <EnumEntry>
191
                            <Key>Foo</Key>
192
                            <Value>bar</Value>
193
                            <LocalizedName xml:lang="DE">Test-ConfigurationEntry</LocalizedName>
194
                            <LocalizedName xml:lang="EN">Test configuration entry</LocalizedName>
195
                            <LocalizedDescription xml:lang="DE">Testbeschreibung</LocalizedDescription>
196
                            <LocalizedDescription xml:lang="EN">test description</LocalizedDescription>
197
                        </EnumEntry>
198
                    </Entries>
199
                </ConfigDescription>
200
            </AppExtensionSpecification>
201
        </ApplicationActions>
202 9 Hans-Martin Haase
        <IFDActions>
203
            <ProtocolPluginSpecification>
204
                <URI>urn:uri:1.2.3</URI>
205
                <ClassName>package.path.to.protocol.class</ClassName>
206
                <LoadOnStartup>false</LoadOnStartup>
207
                <LocalizedName xml:lang="EN">Test Protocol</LocalizedName>
208
                <LocalizedDescription xml:lang="EN">Description of test protocol</LocalizedDescription>
209
                <ConfigDescription/>
210
            </ProtocolPluginSpecification>
211
        </IFDActions>
212
        <SALActions/>
213 7 Hans-Martin Haase
    </AddonSpecification>
214
</pre>
215
216 9 Hans-Martin Haase
An entry for the SALActions is omitted in example because the definition is the same in XML both are _ProtocolPluginSpecifications_. As you may have noticed there are entries in every specification which are the same. They are discussed following and after that the elements which are not unique for a specification are clarified.
217 7 Hans-Martin Haase
218 9 Hans-Martin Haase
|@<ClassName>@|States the name of the class which implements the the interface specific for the action. The field is required in an valid description.|
219
|@<LoadOnStartup>@|States whether the add-on shall be initialized on start of the core application. The element is not required and defaults to *false* if it is not given. |
220
|@<LocalizedName>@|States the name of the action. The elements is optional and may appear several times for different languages.|
221
|@<LocalizedDescription>@|Here you may provide an optional description of what the action does. The number of this element is not limited so several languages can be supported.|
222
|@<ConfigDescription>@|Description of the configuration options which are changeable by the user. The element is required but it may be empty. A detail discussion about this element is in an extra section [[Add-on System#Types available in the configuration|here]].|
223 7 Hans-Martin Haase
224 9 Hans-Martin Haase
*Application Plugin specific elements*
225
|@<Parameter>@||
226
|@<ResourceName>@|Name of the resource where the action shall be available. The default address of the HTTP Binding is http://localhost:24727/ the resourece name needs to be relativ to this address. E.g. the integrated status add-on is available unter http://localhost:24727/getStatus.|
227
|@<Body>@||
228
|@<Attachment>@||
229 7 Hans-Martin Haase
230 9 Hans-Martin Haase
*Application Extension specific elements*
231
|@<ID>@|A unique ID for the action which is used to query the add-on in the registry. The element is required.|
232 7 Hans-Martin Haase
233 9 Hans-Martin Haase
*Protocol plugin specific elements*
234
Both, SAL and IFD plugin, are represented by an protocol plugin.
235
|@<URI>@|A unique uri which represents the plugin. The selection of the protocol is performed by the evaluation of this element. The element is required.|
236 7 Hans-Martin Haase
237
238 9 Hans-Martin Haase
h3. Types available in the configuration
239 7 Hans-Martin Haase
240 9 Hans-Martin Haase
The _ConfigDescription_ element used in the actions and in the general description of the add-on represent always configuration options which are changeable by the user. Configuration entries which are not connected with a user decision should be placed into a separate configuration. This means every entry in the _ConfigDescription_ has an representation as an UI element so the support of an entry type depends on the UI implementation. The Swing implementation implements all options the other GUI implementations are currently not complete.
241
_ConfigDescription_ elements may contain the following entry types: EnumEntry, EnumListEntry, FileEntry, FileListEntry, ScalarEntry and ScalarListEntry. They are mapped to the following UI elements:
242 4 Hans-Martin Haase
243 9 Hans-Martin Haase
|EnumEntry|The localized name is displayed as label (fallback key name) and the values are represented as checkboxes.|
244
|EnumListEntry|A list with fixed size containing the values. The UI element is an drop down box.|
245
|FileEntry|A entry which allows the user to select a file. A file selection dialog represents the entry.|
246
|FileListEntry|Dynamic list of _FileEntry_'s which are displayed as multiple file selection dialogs.|
247
|ScalarEntry|The representation depends on the type of the scalar. Availble types are BOOLEAN, BIGDECIMAL, BIGINTEGER and STRING. The BOOLEAN type is represented by a single checkbox, the BIGDECIMAL and BIGINTEGER are represented by text field with a spin button and the STRING type is displayed as single text field.|
248
|ScalarListEntry||
249 5 Hans-Martin Haase
250 9 Hans-Martin Haase
251 1 Dirk Petrautzki
252
h3. Configuration of an Add-on in the client
253
254
h2. Add-on Implementation
255
256
h3. IFD protocol implementation details
257
258
259
This section describes the add-on system from the perspective of a developer.
260
The implementation of the add-on system is located in the maven module with the group Id *org.openecard* and the artifact Id *addon*.
261
All classes are in a sub namespace of *org.openecard.addon*. The module is divided into the following five packages:
262
* *org.openecard.addon*
263
In this package are the main classes of the add-on system, for example the AddonManager or the different AddonRegistries.
264
* *org.openecard.addon.bind*
265
This package includes all classes representing the interface between an addon and a specific binding. That is to say, here are the classes needed to convert a specific request, for example a HTTP request that arrives via the localhost binding, into a generic request, which is independent from binding and vice versa for the response.
266
* *org.openecard.addon.ifd*
267 2 Dirk Petrautzki
In here are the classes that specify the interface for an IFD protocol and the factory to instantiate such a protocol.
268
* *org.openecard.addon.manifest*
269
This package accumulates all classes needed to convert (automatically) between the XML represantation of the add-on description and it's java object pendants.
270
* *org.openecard.addon.sal*
271
In here are the classes that specify the interface for an SAL protocol and the factory to instantiate such a protocol.
272
273
h1. Types of add-ons
274
275
In the context of Open eCard App, the terms add-on, plug-in and extension are defined as follows.
276
277
Add-on is the generic term for a component that enhances the functionality of the Open eCard App.
278
279
Extensions are independent from the context. Moreover, they are included directly into
280
the user interface and can be executed by the user. For instance, an add-on that provides a
281 1 Dirk Petrautzki
PIN change functionality for smart cards is classified as an extension.
282
283
Plug-ins depend on the context in which the user uses the application. Performing
284
an authentication to a service using a particular smart card, for instance, requires a plug-in
285
which is capable of providing such functionality. Subsequently, plug-ins require a communication
286
with bindings to interact with external applications and services. Furthermore,
287
we distinguish between IFD, SAL, and application plug-ins.
288
289
h1. Add-on development
290
291
This section describes the steps to take when developing an add-on.
292
As first step a new XML file called *Addon.xml* in the *META-INF* directory of the project should be created and the fields that describe the general part of the add-ons can already be filled.
293
An example file for a PIN Management addon could look like this:
294
<pre>
295
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
296
<AddonBundleDescription>
297
	<ID>PIN-Plugin</ID>
298
	<Version>1.0</Version>
299
	<About />
300
	<License />
301
	<LocalizedName xml:lang="DE">PIN Verwaltung</LocalizedName>
302
	<LocalizedDescription xml:lang="DE">Verwaltung von PIN/ PUK und gegebenenfalls anderen Geheimnissen der Chipkarte.
303
	</LocalizedDescription>
304
	<LocalizedName xml:lang="EN">PIN Management</LocalizedName>
305
	<LocalizedDescription xml:lang="EN">Management of PIN/ PUK and possibly other secrets of the smart-card.</LocalizedDescription>
306
	<Logo>images/logo.png</Logo>
307
	<ConfigDescription />
308
	<BindingActions />
309 2 Dirk Petrautzki
	<ApplicationActions />
310
	<IFDActions />
311
	<SALActions />
312
</AddonBundleDescription>
313
</pre>
314
As can be seen, some fields can be localized. That fields are: *LocalizedName*, *LocalizedDescription* and *About*
315
The next step is to think about what actions should be offerd by the add-on and of what type these actions are.
316
For the PIN management example there are two actions. An action to change a PIN and a second action to unblock a PIN.
317
These actions are not of type *ProtocolPlugin* nor *AppPluginAction*, but of type *AppExtensionAction*, as they expand the function of the Open eCard App independent from a context.
318
This means two classes implementing the *AppExtensionAction* interface need to be added to the project and the two AppExtensionActionDescription that belong to them need to be added to the XML description.
319
Assume we are working in the org.openecard.plugins.pinplugin namespace and the two actions are called ChangePINAction and UnblockPINAction, the resulting XML would now look similar to this:
320
<pre>
321
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
322
<AddonBundleDescription>
323
	<ID>PIN-Plugin</ID>
324
	<Version>1.0</Version>
325
	<About />
326
	<License />
327
	<LocalizedName xml:lang="DE">PIN Verwaltung</LocalizedName>
328
	<LocalizedDescription xml:lang="DE">Verwaltung von PIN/ PUK und gegebenenfalls anderen Geheimnissen der Chipkarte.
329
	</LocalizedDescription>
330
	<LocalizedName xml:lang="EN">PIN Management</LocalizedName>
331
	<LocalizedDescription xml:lang="EN">Management of PIN/ PUK and possibly other secrets of the smart-card.</LocalizedDescription>
332
	<Logo>images/pin-management.png</Logo>
333
	<ConfigDescription />
334
	<BindingActions />
335
	<ApplicationActions>
336
		<AppExtensionActionDescription>
337
			<ID>ChangePINAction</ID>
338
			<ClassName>org.openecard.plugins.pinplugin.ChangePINAction</ClassName>
339
			<LocalizedName xml:lang="DE">PIN ändern</LocalizedName>
340
			<LocalizedDescription xml:lang="DE">Mit dieser Aktion können Sie ihre PIN ändern.</LocalizedDescription>
341
			<LocalizedName xml:lang="EN">Change PIN</LocalizedName>
342
			<LocalizedDescription xml:lang="EN">With this action you can change your PIN.</LocalizedDescription>
343
			<ConfigDescription />
344
		</AppExtensionActionDescription>
345
		<AppExtensionActionDescription>
346
			<ID>UnblockPINAction</ID>
347
			<ClassName>org.openecard.plugins.pinplugin.UnblockPINAction</ClassName>
348
			<LocalizedName xml:lang="DE">PIN entsperren</LocalizedName>
349
			<LocalizedDescription xml:lang="DE">Mit dieser Aktion können Sie ihre PIN entsperren.</LocalizedDescription>
350
			<LocalizedName xml:lang="EN">Unblock PIN</LocalizedName>
351 3 Dirk Petrautzki
			<LocalizedDescription xml:lang="EN">With this action you can unblock your PIN.</LocalizedDescription>
352
			<ConfigDescription />
353
		</AppExtensionActionDescription>
354
	</ApplicationActions>
355
	<IFDActions />
356
	<SALActions />
357
</AddonBundleDescription>
358
</pre>
359
360
For the actual implementation part of the add-on, the following has to be considered.
361 1 Dirk Petrautzki
The actions need to implement the AppExtensionAction interface, which itself extends the FactoryBaseType interface. 
362
Altogether, three functions are to be implemented:
363
* void execute();
364
the actual logic of the action, in this case the PIN change, will take place here
365
* void init(Context context) throws FactoryInitializationException;
366
initialization of the action; the given Context allows access to components of the Open eCard App like UserConsent or Dispatcher
367
* void destroy();
368
closing resources and further cleanup.