@@ -36,24 +36,25 @@ reference the load block AID and pick, among other application related parameter
36
36
37
37
Example: Adding a JAVA-card applet to an existing profile package
38
38
::
39
- # Step #1: Create the application PE and load the ijc contents from the .cap file:
40
- $ ./contrib/saip-tool.py upp.der add-app --output-file upp_with_app.der --applet-file app.cap --aid '1122334455'
41
- Read 28 PEs from file 'upp.der'
42
- Applying applet file: 'app.cap'...
43
- application PE inserted into PE Sequence after securityDomain PE AID: a000000151000000
44
- Writing 29 PEs to file 'upp_with_app.der'...
45
-
46
- # Step #2: Create the application instance inside the application PE created in step #1:
47
- $ ./contrib/saip-tool.py upp_with_app.der add-app-inst --output-file upp_with_app_and_instance.der \
48
- --aid '1122334455' \
49
- --class-aid '112233445501' \
50
- --inst-aid '112233445501' \
51
- --app-privileges '00' \
52
- --app-spec-pars '00' \
53
- --uicc-toolkit-app-spec-pars '01001505000000000000000000000000'
54
- Read 29 PEs from file 'upp_with_app.der'
55
- Found Load Package AID: 1122334455, adding new instance AID: 112233445501 to Application PE...
56
- Writing 29 PEs to file 'upp_with_app_and_instance.der'...
39
+
40
+ # Step #1: Create the application PE and load the ijc contents from the .cap file:
41
+ $ ./contrib/saip-tool.py upp.der add-app --output-file upp_with_app.der --applet-file app.cap --aid '1122334455'
42
+ Read 28 PEs from file 'upp.der'
43
+ Applying applet file: 'app.cap'...
44
+ application PE inserted into PE Sequence after securityDomain PE AID: a000000151000000
45
+ Writing 29 PEs to file 'upp_with_app.der'...
46
+
47
+ # Step #2: Create the application instance inside the application PE created in step #1:
48
+ $ ./contrib/saip-tool.py upp_with_app.der add-app-inst --output-file upp_with_app_and_instance.der \
49
+ --aid '1122334455' \
50
+ --class-aid '112233445501' \
51
+ --inst-aid '112233445501' \
52
+ --app-privileges '00' \
53
+ --app-spec-pars '00' \
54
+ --uicc-toolkit-app-spec-pars '01001505000000000000000000000000'
55
+ Read 29 PEs from file 'upp_with_app.der'
56
+ Found Load Package AID: 1122334455, adding new instance AID: 112233445501 to Application PE...
57
+ Writing 29 PEs to file 'upp_with_app_and_instance.der'...
57
58
58
59
NOTE: The parameters of the sub-commands `add-app ` and `add-app-inst ` are application specific. It is up to the application
59
60
developer to pick parameters that suit the application correctly. For an exact command reference see section
@@ -70,30 +71,32 @@ to check if the applet insertaion was carried out as expected.
70
71
71
72
Example: Listing applications and their parameters
72
73
::
73
- $ ./contrib/saip-tool.py upp_with_app_and_instance.der info --apps
74
- Read 29 PEs from file 'upp_with_app_and_instance.der'
75
- Application #0:
76
- loadBlock:
77
- loadPackageAID: '1122334455' (5 bytes)
78
- loadBlockObject: '01000fdecaffed010204000105d07002ca440200...681080056810a00633b44104b431066800a10231' (569 bytes)
79
- instanceList[0]:
80
- applicationLoadPackageAID: '1122334455' (5 bytes)
81
- classAID: '112233445501' (8 bytes)
82
- instanceAID: '112233445501' (8 bytes)
83
- applicationPrivileges: '00' (1 bytes)
84
- lifeCycleState: '07' (1 bytes)
85
- applicationSpecificParametersC9: '00' (1 bytes)
86
- applicationParameters:
87
- uiccToolkitApplicationSpecificParametersField: '01001505000000000000000000000000' (16 bytes)
74
+
75
+ $ ./contrib/saip-tool.py upp_with_app_and_instance.der info --apps
76
+ Read 29 PEs from file 'upp_with_app_and_instance.der'
77
+ Application #0:
78
+ loadBlock:
79
+ loadPackageAID: '1122334455' (5 bytes)
80
+ loadBlockObject: '01000fdecaffed010204000105d07002ca440200...681080056810a00633b44104b431066800a10231' (569 bytes)
81
+ instanceList[0]:
82
+ applicationLoadPackageAID: '1122334455' (5 bytes)
83
+ classAID: '112233445501' (8 bytes)
84
+ instanceAID: '112233445501' (8 bytes)
85
+ applicationPrivileges: '00' (1 bytes)
86
+ lifeCycleState: '07' (1 bytes)
87
+ applicationSpecificParametersC9: '00' (1 bytes)
88
+ applicationParameters:
89
+ uiccToolkitApplicationSpecificParametersField: '01001505000000000000000000000000' (16 bytes)
88
90
89
91
In case further analysis with external tools or transfer of applications from one profile package to another is
90
92
necessary, the executable code in the `loadBlockObject ` field can be extracted to an `.ijc ` or an `.cap ` file.
91
93
92
94
Example: Extracting applications from a profile package
93
95
::
94
- $ ./contrib/saip-tool.py upp_with_app_and_instance.der extract-apps --output-dir ./apps --format ijc
95
- Read 29 PEs from file 'upp_with_app_and_instance.der'
96
- Writing Load Package AID: 1122334455 to file ./apps/8949449999999990023f-1122334455.ijc
96
+
97
+ $ ./contrib/saip-tool.py upp_with_app_and_instance.der extract-apps --output-dir ./apps --format ijc
98
+ Read 29 PEs from file 'upp_with_app_and_instance.der'
99
+ Writing Load Package AID: 1122334455 to file ./apps/8949449999999990023f-1122334455.ijc
97
100
98
101
99
102
Removing applications
@@ -104,23 +107,25 @@ An application PE can be removed using sub-command `remove-app`. The user passes
104
107
105
108
Example: Remove an application from a profile package
106
109
::
107
- $ ./contrib/saip-tool.py upp_with_app_and_instance.der remove-app --output-file upp_without_app.der --aid '1122334455'
108
- Read 29 PEs from file 'upp_with_app_and_instance.der'
109
- Found Load Package AID: 1122334455, removing related PE (id=23) from Sequence...
110
- Removing PE application (id=23) from Sequence...
111
- Writing 28 PEs to file 'upp_without_app.der'...
110
+
111
+ $ ./contrib/saip-tool.py upp_with_app_and_instance.der remove-app --output-file upp_without_app.der --aid '1122334455'
112
+ Read 29 PEs from file 'upp_with_app_and_instance.der'
113
+ Found Load Package AID: 1122334455, removing related PE (id=23) from Sequence...
114
+ Removing PE application (id=23) from Sequence...
115
+ Writing 28 PEs to file 'upp_without_app.der'...
112
116
113
117
In some cases it is useful to remove only an instance from an existing application PE. This may be the case when the
114
118
an application developer wants to modify parameters of an application by removing and re-adding the instance. The
115
119
operation basically rolls the state back to step 1 explained in section :ref: `Inserting applications `
116
120
117
121
Example: Remove an application instance from an application PE
118
122
::
119
- $ ./contrib/saip-tool.py upp_with_app_and_instance.der remove-app-inst --output-file upp_without_app.der --aid '1122334455' --inst-aid '112233445501'
120
- Read 29 PEs from file 'upp_with_app_and_instance.der'
121
- Found Load Package AID: 1122334455, removing instance AID: 112233445501 from Application PE...
122
- Removing instance from Application PE...
123
- Writing 29 PEs to file 'upp_with_app.der'...
123
+
124
+ $ ./contrib/saip-tool.py upp_with_app_and_instance.der remove-app-inst --output-file upp_without_app.der --aid '1122334455' --inst-aid '112233445501'
125
+ Read 29 PEs from file 'upp_with_app_and_instance.der'
126
+ Found Load Package AID: 1122334455, removing instance AID: 112233445501 from Application PE...
127
+ Removing instance from Application PE...
128
+ Writing 29 PEs to file 'upp_with_app.der'...
124
129
125
130
126
131
saip-tool syntax
0 commit comments