web interface: reorder input fields in certificate search page
[openxpki.git] / trunk / clients / perl / OpenXPKI-Client-HTML-Mason / htdocs / service / workflow / show_instance.html
blob366ed9a6a6a3e8da3f6e2e7bfdb571747b3a8585
1 <%args>
2 $type => undef
3 $id => undef
4 $msg => undef
5 $activities => undef
6 $details => undef
7 $history => undef
8 </%args>
9 <h1><% i18nGettext ('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_TITLE', '__ID__' => $msg->{PARAMS}->{WORKFLOW}->{ID}, '__STATE__' => $msg->{PARAMS}->{WORKFLOW}->{STATE}) %></h1>
10 <div>
11 <!--
12 <% Dumper $msg->{PARAMS} %>
13 -->
14 <div class="floatbox" style="width: 30%">
15 <hr/>
16 <p class="title"><% i18nGettext ('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_ACTIVITIES') %></p>
17 <p>
18 <div class="openxpki_command_list">
19 % foreach my $action (sort keys %actions)
20 % {
21 % my $filename = lc($actions{$action});
22 % $filename =~ s/i18n_openxpki_wf_[^_]*_//;
23 % # because of this hack, we need to specify all variants of this in
24 % # the source, not the best solution here ... :-/
25 % my $buttonname = 'I18N_OPENXPKI_WF_ACTION_' . uc($filename);
26 <div class="openxpki_command_list_item">
27 <& /service/open_form.mhtml, 'action' => $context->{menu}->get_root()."/service/workflow/activity/$filename.html" &>
28 % if ($filename eq 'approve_csr') {
29 <& /lib/html/hidden.mhtml, 'name' => 'context_hash', 'value' => $context_hash &>
30 % }
31 <& /lib/html/hidden.mhtml, 'name' => 'type', 'value' => $type &>
32 <& /lib/html/hidden.mhtml, 'name' => 'id', 'value' => $id &>
33 <& /lib/html/input.mhtml, 'type' => 'submit', 'value' => i18nGettext($buttonname) &>
34 <& /service/close_form.mhtml &>
35 </div>
36 % }
37 <div class="openxpki_command_list_item">
38 <input type="button" name="print" value="<% i18nGettext ('I18N_OPENXPKI_HTML_PRINT_BUTTON') %>" onClick="window.print()"/>
39 </div>
40 </div>
41 </p>
42 </hr>
43 </div>
44 <div>
45 <!-- id="overflow"> -->
46 <!--
47 <p>
48 <% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_DESCRIPTION') %>
49 </p>
50 -->
51 <p>
52 % ## I expect the following:
53 % ## SERVICE_MSG => "COMMAND",
54 % ## COMMAND => $cmd,
55 % ## PARAMS =>
56 % ## {
57 % ## WORKFLOW =>
58 % ## {
59 % ## ID => $id,
60 % ## STATE => $state,
61 % ## CONTEXT => { ... a simple hash ... }
62 % ## }
63 % ## }
64 <div style="width: 65%">
65 <h2 style="color: #888888"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_OVERVIEW') %></h2>
66 <table>
67 <!--
68 <tr>
69 <td><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SERIAL') %></td>
70 <td><% $msg->{PARAMS}->{WORKFLOW}->{ID} %></td>
71 </tr>
72 <tr>
73 <td><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_STATE') %></td>
74 <td><% i18nGettext($msg->{PARAMS}->{WORKFLOW}->{STATE}) %></td>
75 </tr>
76 -->
77 <tr>
78 <td><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_TYPE') %></td>
79 <td><% i18nGettext($msg->{PARAMS}->{WORKFLOW}->{TYPE}) %></td>
80 </tr>
81 <tr>
82 <td><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_CREATOR') %></td>
83 <td><!-- creator --><a href="<% $context->{menu}->get_root() %>/service/workflow/search_instances.html?<% $context->{menu}->get_link_params() %>;context_key=creator;context_value=<% $msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{creator} %>;context_key=;context_value="><% delete($msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{creator}) %></a></td>
84 </tr>
85 <tr>
86 <td><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_LAST_UPDATE') %></td>
87 % my $last_update = $msg->{PARAMS}->{WORKFLOW}->{LAST_UPDATE};
88 % $last_update =~ s/T/ /;
89 % $last_update .= ' UTC';
90 <td><% $last_update %></td>
91 </tr>
93 % BASIC_DETAILS:
94 % foreach my $context_key (@{ $basic_details{$msg->{PARAMS}->{WORKFLOW}->{TYPE}} }) {
95 % # skip if context entry does not exist - this may for example be the
96 % # case with entries that are added later in the process, such as
97 % # csr_serial in CSR workflows
98 % next BASIC_DETAILS if (! exists $msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{$context_key});
99 <tr>
100 <td style="vertical-align:top;">
101 <!-- <% $context_key %> -->
102 % $m->comp('/lib/field_to_i18n.mhtml',
103 % 'field' => $context_key);
104 </td>
105 <td>
106 % my $value = delete($msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{$context_key});
107 % $value = encode('UTF-8', $value);
108 % if ($untainted{$context_key}) {
109 <% i18nGettext($value) | n %>
111 % else {
112 <% i18nGettext($value) %>
114 </td>
115 </tr>
118 </table>
119 </div>
120 % if (! $details) {
121 <a href="<% $context->{menu}->get_root() %>/service/workflow/show_instance.html?<% $context->{menu}->get_link_params() %>;type=<% $msg->{PARAMS}->{WORKFLOW}->{TYPE} %>&id=<% $msg->{PARAMS}->{WORKFLOW}->{ID} %>&details=1&history=<% $history %>"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_DETAILS') %> ...</a><br/>
123 % else {
124 <h2 style="color: #888888"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_OTHER_WORKFLOW_CONTEXT_KEYS') %> (<a href="<% $context->{menu}->get_root() %>/service/workflow/show_instance.html?<% $context->{menu}->get_link_params() %>;type=<% $msg->{PARAMS}->{WORKFLOW}->{TYPE} %>&id=<% $msg->{PARAMS}->{WORKFLOW}->{ID} %>&details=0" style="color: #888888"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_HIDE') %></a>)</h2>
125 <table style="clear: right">
126 % foreach my $param (sort keys %{$msg->{PARAMS}->{WORKFLOW}->{CONTEXT}}) {
127 %# next if ($param eq "approvals" and length $msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{$param} == 0);
128 %# next if ($param eq "cert_profile_id");
129 % next if ($param =~ m{ \A _ }xms); # ignore "volatile" context parameters
130 <tr>
131 <td style="vertical-align: top">
132 <!-- <% $param %> -->
133 % $m->comp('/lib/field_to_i18n.mhtml',
134 % 'field' => $param);
135 </td>
136 <td>
137 % my $value = $msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{$param};
138 % # someone is interpreting UTF8 data here, re-encode ...
139 % # FIXME - find out why this is actually happening so that we
140 % # can eliminate the source
141 % $value = encode('UTF-8', $value);
142 % if ($untainted{$param}) {
143 <% i18nGettext($value) | n %>
145 % else {
146 <% i18nGettext($value) %>
148 </td>
149 </tr>
151 </table>
153 % if (! $history) {
154 <a href="<% $context->{menu}->get_root() %>/service/workflow/show_instance.html?<% $context->{menu}->get_link_params() %>;type=<% $msg->{PARAMS}->{WORKFLOW}->{TYPE} %>&id=<% $msg->{PARAMS}->{WORKFLOW}->{ID} %>&details=<% $details %>&history=1"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY') %> ...</a><br/>
156 % else {
157 <h2 style="color: #888888"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY_TITLE') %> (<a href="<% $context->{menu}->get_root() %>/service/workflow/show_instance.html?<% $context->{menu}->get_link_params() %>;type=<% $msg->{PARAMS}->{WORKFLOW}->{TYPE} %>&id=<% $msg->{PARAMS}->{WORKFLOW}->{ID} %>&details=<% $details %>&history=0" style="color: #888888"><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_HIDE') %></a>)</h2>
158 <table>
159 <tr>
160 <th><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY_DATE') %></th>
161 <th><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY_STATE') %></th>
162 <th><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY_ACTION') %></th>
163 <th><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY_NEW_STATE') %></th>
164 <th><% i18nGettext('I18N_OPENXPKI_CLIENT_HTML_MASON_WORKFLOW_SHOW_INSTANCE_HISTORY_USER') %></th>
165 </tr>
166 % foreach my $entry (@history) {
167 % my ($next_state) = ($entry->{'WORKFLOW_DESCRIPTION'} =~ m{ NEW_STATE[^\s+]*:\ (.+) }xms);
168 % next if ($entry->{'WORKFLOW_ACTION'} eq 'Create workflow');
169 <tr>
170 <td><% $entry->{'WORKFLOW_HISTORY_DATE'} %></td>
171 <td><% $entry->{'WORKFLOW_STATE'} %></td>
172 <td><& /lib/field_to_i18n.mhtml,
173 field => $entry->{'WORKFLOW_ACTION'} &></td>
174 <td>
175 % if ($entry->{'WORKFLOW_DESCRIPTION'} =~ /NEW_STATE_AUTORUN/) {
176 <i><% $next_state %></i>
178 % else {
179 <% $next_state %>
181 </td>
182 <td><% $entry->{'WORKFLOW_USER'} %></td>
183 </tr>
185 </table>
186 <div class="openxpki_command_list_item">
187 <& /service/open_form.mhtml, 'action' => $context->{menu}->get_root()."/service/workflow/get_workflow_instance_info.html" &>
188 <& /lib/html/hidden.mhtml, 'name' => 'id', 'value' => $id &>
189 <!-- the format is optional -->
190 <& /lib/html/hidden.mhtml, 'name' => 'format', 'value' => 'png' &>
191 <& /lib/html/input.mhtml, 'type' => 'submit', 'value' => i18nGettext ('I18N_OPENXPKI_HTML_GET_WORKFLOW_INSTANCE_INFO') &>
192 <& /service/close_form.mhtml &>
193 </div>
195 </p>
196 </div>
197 </div>
198 <%once>
199 use Encode qw(encode decode);
200 use HTML::Entities;
201 use DateTime;
202 use Data::Dumper;
203 $Data::Dumper::Terse = 1;
204 $Data::Dumper::Sortkeys = 1;
205 </%once>
206 <%init>
207 if (not defined $msg or
208 not ref $msg or
209 not ref $msg eq "HASH")
211 if (! defined $type) {
212 # type was not specified, get it from the server
213 my $type_msg = $context->{client}->send_receive_command_msg(
214 'get_workflow_type_for_id',
216 'ID' => $id,
219 $type = $type_msg->{PARAMS};
221 ## ok we have to get the info from the server
222 $msg = $context->{client}->send_receive_command_msg
224 "get_workflow_info",
226 "WORKFLOW" => $type,
227 "ID" => $id
231 else
233 ## sometimes we have only the message
234 $id = $msg->{PARAMS}->{WORKFLOW}->{ID} if (! defined $id && exists $msg->{PARAMS} && exists $msg->{PARAMS}->{WORKFLOW} && exists $msg->{PARAMS}->{WORKFLOW}->{ID});
235 $type = $msg->{PARAMS}->{WORKFLOW}->{TYPE} if (! defined $type && exists $msg->{PARAMS} && exists $msg->{PARAMS}->{WORKFLOW} && exists $msg->{PARAMS}->{WORKFLOW}->{TYPE});
237 if (ref $msg eq 'HASH' && exists $msg->{SERVICE_MSG} && $msg->{SERVICE_MSG} eq 'ERROR') {
238 my @errors = $m->comp('/lib/get_deep_error.mhtml', 'msg' => $msg);
239 $m->comp('/service/create_csr/print_errors.mhtml', 'errors' => \@errors);
240 return;
242 my %untainted = ();
243 my $context_hash = '';
244 if ($msg->{PARAMS}->{WORKFLOW}->{TYPE} eq 'I18N_OPENXPKI_WF_TYPE_CERTIFICATE_SIGNING_REQUEST') {
245 $context_hash = $m->comp('/service/workflow/context_hash.mhtml',
246 'context' => $msg->{PARAMS}->{WORKFLOW}->{CONTEXT},
249 foreach my $param (keys %{ $msg->{PARAMS}->{WORKFLOW}->{CONTEXT} }) {
250 my $value = $msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{$param};
251 if ($param eq 'csr_serial' && $value =~ m{\A \d+ \z}xms) {
252 # transform a scalar csr_serial into a one-element array
253 $value = OpenXPKI::Serialization::Simple->new()->serialize([ $value ]);
255 if ($value =~ /^(ARRAY|HASH)/)
257 ## serialized stuff
258 my $ser = OpenXPKI::Serialization::Simple->new();
259 my $ref = $ser->deserialize($value);
260 if ($param eq "cert_info")
262 ## simple hash
263 $value = '<table style="border:0px; border-spacing:0px">';
264 foreach my $key (sort keys %{$ref})
266 my $key_i18n = $m->scomp('/lib/field_to_i18n.mhtml',
267 'field' => $key,
269 $ref->{$key} =~ encode_entities($ref->{$key});
270 $ref->{$key} =~ s{\n}{<br/>}xmsg;
271 $value .= '<tr><td style="vertical-align: top">' . $key_i18n . '</td><td>' . $ref->{$key} . '<td/></tr>';
273 $value .= '</table>';
274 $untainted{'cert_info'} = 1;
276 elsif ($param eq 'ticket') {
277 $value = '<ul>';
278 foreach my $key (sort keys %{$ref}) {
279 my $url_msg = $context->{client}->send_receive_command_msg(
280 "get_url_for_ticket",
282 "NOTIFIER" => $key,
283 "TICKET" => $ref->{$key}
286 my $url = $url_msg->{PARAMS};
287 $value .= '<li><a href="' . $url . '">' . i18nGettext($key) . ': ' . i18nGettext($ref->{$key}) . '</a>';
289 $value .= '</ul>';
290 $untainted{'ticket'} = 1;
292 elsif ($param eq "cert_subject_alt_name")
294 ## array of arrays
295 $value = '';
296 foreach my $pair (@{$ref})
298 next if (not $pair); ## empty array
299 $value .= encode_entities($pair->[0]) . ': ' . encode_entities($pair->[1]) . '<br/>';
301 $untainted{'cert_subject_alt_name'} = 1;
303 elsif ($param eq "approvals")
305 $value = '';
306 if (ref $ref eq 'HASH') { # old style
307 ## hash: user to role
308 foreach my $user (sort keys %{$ref})
310 next if (not defined $user); ## empty hash - !???
311 $value .= encode_entities($user) . '&rarr;' . encode_entities($ref->{$user}) . '<br/>';
314 elsif (ref $ref eq 'ARRAY') { # new style for signatures
315 foreach my $approval (@{$ref}) {
316 if (defined $approval->{signature}) {
317 $value .= i18nGettext('I18N_OPENXPKI_SIGNED_APPROVAL') . ':<br/>';
318 $value .= encode_entities($approval->{signer_subject}) . '&rarr;' . encode_entities($approval->{signer_role}) . '<br/>';
319 $value .= i18nGettext('I18N_OPENXPKI_SIGNER_CERTIFICATE_IDENTIFIER') . ': ' . encode_entities($approval->{signer_identifier}) . '<br/>';
320 $value .= i18nGettext('I18N_OPENXPKI_SIGNED_TEXT') . ': ' . encode_entities($approval->{plaintext}) . '<br/>';
321 $value .= i18nGettext('I18N_OPENXPKI_SIGNATURE') . ': ' . encode_entities($approval->{signature}) . '<br/>';
323 $value .= encode_entities($approval->{session_user}) . '&rarr;' . encode_entities($approval->{session_role}) . '<br/><br/>================================================================<br/>';
326 $untainted{'approvals'} = 1;
328 elsif ($param eq 'wf_children_instances') {
329 $value = '';
330 foreach my $instance (@{ $ref }) {
331 $value .= '<a href="' . $context->{menu}->get_root() . '/service/workflow/show_instance.html?' . $context->{menu}->get_link_params() . ';id=' . $instance->{ID} . '">' . encode_entities(i18nGettext($instance->{TYPE})) . ' #' . encode_entities($instance->{ID}) . '</a><br/>';
333 $untainted{'wf_children_instances'} = 1;
335 elsif ($param eq 'csr_serial') {
336 $value = '';
337 foreach my $serial (@{ $ref }) {
338 $value .= $serial . ' (<a href="' . $context->{menu}->get_root() . '/service/workflow/search_instances.html?' . $context->{menu}->get_link_params() . ';context_key=csr_serial;context_value=%25' . $serial . '%25;context_key=;context_value=">' . i18nGettext('I18N_OPENXPKI_WORKFLOWS') . '</a>';
339 if ($msg->{PARAMS}->{WORKFLOW}->{STATE} eq 'SUCCESS') {
340 # there should be a certificate for this ID, too
341 $value .= ', <a href="' . $context->{menu}->get_root() . '/service/api/cert_list.html?' . $context->{menu}->get_link_params() . ';csr_serial=' . $serial . '">' . i18nGettext('I18N_OPENXPKI_CERTIFICATE') . '</a>';
343 $value .= ')<br/>';
345 $untainted{'csr_serial'} = 1;
347 else
349 my $dump = Dumper($ref);
350 Encode::_utf8_on($dump);
351 $value = $dump;
354 elsif ($param eq 'spkac') {
355 for (my $i = int(length ($value) / 64); $i > 0; $i--)
357 $value = substr ($value, 0, $i*64)."<br/>".substr($value,$i*64);
359 $value = '<div style="font-family: monospace">' . $value . '</div>';
360 $untainted{'spkac'} = 1;
362 elsif ($param eq 'notafter' || $param eq 'notbefore') {
363 $value = substr($value, 0, 4) . '-' . substr($value, 4, 2) . '-' . substr($value, 6, 2) . ' ' . substr($value, 8, 2) . ':' . substr($value, 10, 2) . ':' . substr($value, 12, 2) . ' UTC';
365 elsif ($param eq 'cert_subject') {
366 # make certificate subject more breakable
367 $value =~ s{,}{, }xmsg;
369 elsif ($param eq 'cert_identifier' || $param eq 'current_identifier') {
370 $value = '<a href="' . $context->{menu}->get_root() . '/service/api/cert_info.html?' . $context->{menu}->get_link_params() . ';identifier=' . $value . '">' . encode_entities($value) . '</a>';
371 $untainted{$param} = 1;
373 elsif ($param eq 'workflow_parent_id') {
374 $value = '<a href="' . $context->{menu}->get_root() . '/service/workflow/show_instance.html?' . $context->{menu}->get_link_params() . ';id=' . $value . '">#' . encode_entities($value) . '</a>';
375 $untainted{$param} = 1;
377 elsif ($param eq 'invalidity_time') {
378 $value = DateTime->from_epoch( epoch => $value )->strftime('%Y-%m-%d %H:%M UTC');
380 elsif ($value =~ m{ \A -----BEGIN }xms || $param eq 'pkcs7_content') { # PKCS 10/7 or key
381 $value = encode_entities($value);
382 $value =~ s{\n}{<br/>}xmsg;
383 $value = '<div style="font-family: monospace">' . $value . '</div>';
384 $untainted{$param} = 1;
386 $msg->{PARAMS}->{WORKFLOW}->{CONTEXT}->{$param} = $value;
388 if (not defined $activities)
390 ## ok we have to get the info from the server
391 ## FIXME: this fails if type and id are undefined, id can
392 ## be extracted from $msg, but what about type?
393 my $hmsg = $context->{client}->send_receive_command_msg
395 "get_workflow_activities",
397 "WORKFLOW" => $type,
398 "ID" => $id
401 $activities = $hmsg->{PARAMS};
403 my @history = ();
404 if ($history) {
405 my $msg = $context->{client}->send_receive_command_msg(
406 'get_workflow_history',
408 'ID' => $id,
411 eval {
412 @history = @{ $msg->{PARAMS} };
416 my %actions = ();
417 foreach my $key (@{$activities})
419 ## I hope that nobody will translate two actions with the same string
420 ## Here are some translation tags for CRR activities (for pot-file)
421 ## I18N_OPENXPKI_WF_ACTION_ADD_MISSING_NODE
422 ## I18N_OPENXPKI_WF_ACTION_APPROVE_CRR
423 ## I18N_OPENXPKI_WF_ACTION_APPROVE_CSR
424 ## I18N_OPENXPKI_WF_ACTION_CANCEL_CRR_APPROVAL
425 ## I18N_OPENXPKI_WF_ACTION_CANCEL_CSR_APPROVAL
426 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CRR_INVALIDITY_TIME
427 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CRR_REASON
428 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CSR_PROFILE
429 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CSR_ROLE
430 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CSR_SUBJECT
431 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CSR_SUBJECT_ALT_NAME
432 ## I18N_OPENXPKI_WF_ACTION_CHANGE_CSR_SUBJECT_STYLE
433 ## I18N_OPENXPKI_WF_ACTION_CHILD_FINISHED_FAILURE
434 ## I18N_OPENXPKI_WF_ACTION_CHILD_FINISHED_SUCCESSFULLY
435 ## I18N_OPENXPKI_WF_ACTION_CONTINUE
436 ## I18N_OPENXPKI_WF_ACTION_CONTINUE_ISSUANCE
437 ## I18N_OPENXPKI_WF_ACTION_CREATE_CRR
438 ## I18N_OPENXPKI_WF_ACTION_CREATE_CSR
439 ## I18N_OPENXPKI_WF_ACTION_CREATE_SERVER_CSR
440 ## I18N_OPENXPKI_WF_ACTION_DETERMINE_ISSUING_CA
441 ## I18N_OPENXPKI_WF_ACTION_DETERMINE_NEXT_CA
442 ## I18N_OPENXPKI_WF_ACTION_DO_NOTHING
443 ## I18N_OPENXPKI_WF_ACTION_DO_NOTHING2
444 ## I18N_OPENXPKI_WF_ACTION_EXPORT_CRR
445 ## I18N_OPENXPKI_WF_ACTION_EXTRACT_CSR
446 ## I18N_OPENXPKI_WF_ACTION_FAIL_WORKFLOW
447 ## I18N_OPENXPKI_WF_ACTION_FORK_CERT_ISSUANCE_INSTANCE
448 ## I18N_OPENXPKI_WF_ACTION_FORK_CERT_ISSUANCE_INSTANCES
449 ## I18N_OPENXPKI_WF_ACTION_GENERATE_KEY
450 ## I18N_OPENXPKI_WF_ACTION_GENERATE_PKCS10
451 ## I18N_OPENXPKI_WF_ACTION_GET_CERT_PROFILE
452 ## I18N_OPENXPKI_WF_ACTION_GET_CRL_PROFILE
453 ## I18N_OPENXPKI_WF_ACTION_GET_LDAP_DATA
454 ## I18N_OPENXPKI_WF_ACTION_IMPORT
455 ## I18N_OPENXPKI_WF_ACTION_IMPORT_PUBLIC_DATA
456 ## I18N_OPENXPKI_WF_ACTION_ISSUE_CERTIFICATE
457 ## I18N_OPENXPKI_WF_ACTION_ISSUE_CRL
458 ## I18N_OPENXPKI_WF_ACTION_NOTIFY_PARENT_FAILURE
459 ## I18N_OPENXPKI_WF_ACTION_NOTIFY_PARENT_SUCCESS
460 ## I18N_OPENXPKI_WF_ACTION_NOTIFY_USER_OF_CREATION
461 ## I18N_OPENXPKI_WF_ACTION_NOTIFY_USER_OF_ISSUANCE
462 ## I18N_OPENXPKI_WF_ACTION_NULL
463 ## I18N_OPENXPKI_WF_ACTION_NULL2
464 ## I18N_OPENXPKI_WF_ACTION_NULL3
465 ## I18N_OPENXPKI_WF_ACTION_PERSIST_CERTIFICATE
466 ## I18N_OPENXPKI_WF_ACTION_PERSIST_CRR
467 ## I18N_OPENXPKI_WF_ACTION_PERSIST_CSR
468 ## I18N_OPENXPKI_WF_ACTION_PERSIST_CSRS
469 ## I18N_OPENXPKI_WF_ACTION_PUBLIC_CERT_LDAP
470 ## I18N_OPENXPKI_WF_ACTION_PUBLISH_CERTIFICATES
471 ## I18N_OPENXPKI_WF_ACTION_PUBLISH_CRL
472 ## I18N_OPENXPKI_WF_ACTION_REJECT_CRR
473 ## I18N_OPENXPKI_WF_ACTION_REJECT_CSR
474 ## I18N_OPENXPKI_WF_ACTION_REVOKE_CERTIFICATE
475 ## I18N_OPENXPKI_WF_ACTION_SET_CONTEXT_FROM_CSR
476 ## I18N_OPENXPKI_WF_ACTION_SET_CONTEXT_FROM_ORIGINAL_CERT
477 ## I18N_OPENXPKI_WF_ACTION_SET_ERROR_CERT_TEST_FAILED
478 ## I18N_OPENXPKI_WF_ACTION_SET_ERROR_CODE_1
479 ## I18N_OPENXPKI_WF_ACTION_SET_ERROR_CODE_2
480 ## I18N_OPENXPKI_WF_ACTION_SET_ERROR_CODE_4
481 ## I18N_OPENXPKI_WF_ACTION_SET_ERROR_ISSUANCE_FAILED
482 ## I18N_OPENXPKI_WF_ACTION_SET_ERROR_LDAP
483 ## I18N_OPENXPKI_WF_ACTION_SLEEP_FOR_CHILD
484 ## I18N_OPENXPKI_WF_ACTION_SLEEP_FOR_CHILDREN
485 ## I18N_OPENXPKI_WF_ACTION_UNLOCK_CA_KEY
486 ## I18N_OPENXPKI_WF_ACTION_WRITE_CERTIFICATE_TEST_RESULT
487 ## I18N_OPENXPKI_WF_ACTION_WRITE_CERTIFICATE_TO_INSTALL
489 $actions{i18nGettext($key)} = $key;
491 my %basic_details = (
492 'I18N_OPENXPKI_WF_TYPE_CERTIFICATE_SIGNING_REQUEST' =>
493 [ qw( cert_subject cert_profile cert_role cert_subject_alt_name
494 cert_info csr_serial wf_children_instances notafter notbefore) ],
495 'I18N_OPENXPKI_WF_TYPE_CERTIFICATE_ISSUANCE' =>
496 [ qw( cert_subject cert_profile cert_role cert_subject_alt_name
497 csr_serial workflow_parent_id ) ],
498 'I18N_OPENXPKI_WF_TYPE_SMARTCARD_PERSONALIZATION' =>
499 [ qw( csr_serial wf_children_instances ) ],
500 'I18N_OPENXPKI_WF_TYPE_CERTIFICATE_REVOCATION_REQUEST' =>
501 [ qw( cert_identifier reason_code invalidity_time comment ) ],
502 'I18N_OPENXPKI_WF_TYPE_SCEP_REQUEST' =>
503 [ qw( cert_subject cert_profile cert_role cert_subject_alt_name
504 current_identifier current_valid_certificates csr_serial wf_children_instances) ],
505 'I18N_OPENXPKI_WF_TYPE_CERTIFICATE_LDAP_PUBLISHING' =>
506 [ qw( workflow_parent_id ) ],
508 </%init>