File: xmlsec-xmlenc.html

package info (click to toggle)
xmlsec1 1.3.7-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 19,916 kB
  • sloc: ansic: 100,493; xml: 19,156; sh: 8,079; makefile: 1,186; javascript: 438; perl: 199
file content (1083 lines) | stat: -rw-r--r-- 52,833 bytes parent folder | download
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
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>xmlenc: XML Security Library Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets Vsnapshot">
<link rel="home" href="index.html" title="XML Security Library Reference Manual">
<link rel="up" href="xmlsec-ref.html" title="XML Security Core Library API Reference.">
<link rel="prev" href="xmlsec-xmldsig.html" title="xmldsig">
<link rel="next" href="xmlsec-xmlsec.html" title="xmlsec">
<meta name="generator" content="GTK-Doc V1.34.0 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description">  <span class="dim">|</span> 
                  <a href="#xmlsec-xmlenc.description" class="shortcut">Description</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="xmlsec-ref.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="xmlsec-xmldsig.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="xmlsec-xmlsec.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="xmlsec-xmlenc"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="xmlsec-xmlenc.top_of_page"></a>xmlenc</span></h2>
<p>xmlenc — XML Encryption support.</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="xmlsec-xmlenc.stability-level"></a><h2>Stability Level</h2>
<a href="http://foldoc.org/Stable"><span class="acronym">Stable</span></a>, unless otherwise indicated
</div>
<div class="refsect1">
<a name="xmlsec-xmlenc.functions"></a><h2>Functions</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="function_type">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="returnvalue">xmlSecEncCtxPtr</span></a>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxCreate" title="xmlSecEncCtxCreate ()">xmlSecEncCtxCreate</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">void</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDestroy" title="xmlSecEncCtxDestroy ()">xmlSecEncCtxDestroy</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxInitialize" title="xmlSecEncCtxInitialize ()">xmlSecEncCtxInitialize</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">void</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxFinalize" title="xmlSecEncCtxFinalize ()">xmlSecEncCtxFinalize</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxCopyUserPref" title="xmlSecEncCtxCopyUserPref ()">xmlSecEncCtxCopyUserPref</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">void</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxReset" title="xmlSecEncCtxReset ()">xmlSecEncCtxReset</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxBinaryEncrypt" title="xmlSecEncCtxBinaryEncrypt ()">xmlSecEncCtxBinaryEncrypt</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxXmlEncrypt" title="xmlSecEncCtxXmlEncrypt ()">xmlSecEncCtxXmlEncrypt</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxUriEncrypt" title="xmlSecEncCtxUriEncrypt ()">xmlSecEncCtxUriEncrypt</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDecrypt" title="xmlSecEncCtxDecrypt ()">xmlSecEncCtxDecrypt</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="xmlsec-buffer.html#xmlSecBuffer" title="struct xmlSecBuffer"><span class="returnvalue">xmlSecBufferPtr</span></a>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDecryptToBuffer" title="xmlSecEncCtxDecryptToBuffer ()">xmlSecEncCtxDecryptToBuffer</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">void</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDebugDump" title="xmlSecEncCtxDebugDump ()">xmlSecEncCtxDebugDump</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">void</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDebugXmlDump" title="xmlSecEncCtxDebugXmlDump ()">xmlSecEncCtxDebugXmlDump</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="xmlsec-keys.html#xmlSecKey" title="struct xmlSecKey"><span class="returnvalue">xmlSecKeyPtr</span></a>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDerivedKeyGenerate" title="xmlSecEncCtxDerivedKeyGenerate ()">xmlSecEncCtxDerivedKeyGenerate</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="xmlsec-keys.html#xmlSecKey" title="struct xmlSecKey"><span class="returnvalue">xmlSecKeyPtr</span></a>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxAgreementMethodGenerate" title="xmlSecEncCtxAgreementMethodGenerate ()">xmlSecEncCtxAgreementMethodGenerate</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<font><span class="returnvalue">int</span></font>
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxAgreementMethodXmlWrite" title="xmlSecEncCtxAgreementMethodXmlWrite ()">xmlSecEncCtxAgreementMethodXmlWrite</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <font><span class="returnvalue">char</span></font> *
</td>
<td class="function_name">
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxGetFailureReasonString" title="xmlSecEncCtxGetFailureReasonString ()">xmlSecEncCtxGetFailureReasonString</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="xmlsec-xmlenc.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword">enum</td>
<td class="function_name"><a class="link" href="xmlsec-xmlenc.html#xmlEncCtxMode" title="enum xmlEncCtxMode">xmlEncCtxMode</a></td>
</tr>
<tr>
<td class="datatype_keyword">enum</td>
<td class="function_name"><a class="link" href="xmlsec-xmlenc.html#xmlSecEncFailureReason" title="enum xmlSecEncFailureReason">xmlSecEncFailureReason</a></td>
</tr>
<tr>
<td class="define_keyword">#define</td>
<td class="function_name"><a class="link" href="xmlsec-xmlenc.html#XMLSEC-ENC-RETURN-REPLACED-NODE:CAPS" title="XMLSEC_ENC_RETURN_REPLACED_NODE">XMLSEC_ENC_RETURN_REPLACED_NODE</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx">xmlSecEncCtx</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="xmlsec-xmlenc.description"></a><h2>Description</h2>
<p><a class="ulink" href="http://www.w3.org/TR/xmlenc-core" target="_top">XML Encryption</a> implementation.</p>
</div>
<div class="refsect1">
<a name="xmlsec-xmlenc.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="xmlSecEncCtxCreate"></a><h3>xmlSecEncCtxCreate ()</h3>
<pre class="programlisting"><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="returnvalue">xmlSecEncCtxPtr</span></a>
xmlSecEncCtxCreate (<em class="parameter"><code><a class="link" href="xmlsec-keysmngr.html#xmlSecKeysMngr" title="struct xmlSecKeysMngr"><span class="type">xmlSecKeysMngrPtr</span></a> keysMngr</code></em>);</pre>
<p>Creates <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> element processing context.
The caller is responsible for destroying returned object by calling
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxDestroy" title="xmlSecEncCtxDestroy ()"><span class="type">xmlSecEncCtxDestroy</span></a> function.</p>
<div class="refsect3">
<a name="xmlSecEncCtxCreate.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>keysMngr</p></td>
<td class="parameter_description"><p>the pointer to keys manager.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxCreate.returns"></a><h4>Returns</h4>
<p> pointer to newly allocated context object or NULL if an error
occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxDestroy"></a><h3>xmlSecEncCtxDestroy ()</h3>
<pre class="programlisting"><font><span class="returnvalue">void</span></font>
xmlSecEncCtxDestroy (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>);</pre>
<p>Destroy context object created with <a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxCreate" title="xmlSecEncCtxCreate ()"><span class="type">xmlSecEncCtxCreate</span></a> function.</p>
<div class="refsect3">
<a name="xmlSecEncCtxDestroy.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxInitialize"></a><h3>xmlSecEncCtxInitialize ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxInitialize (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                        <em class="parameter"><code><a class="link" href="xmlsec-keysmngr.html#xmlSecKeysMngr" title="struct xmlSecKeysMngr"><span class="type">xmlSecKeysMngrPtr</span></a> keysMngr</code></em>);</pre>
<p>Initializes <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> element processing context.
The caller is responsible for cleaning up returned object by calling
<a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtxFinalize" title="xmlSecEncCtxFinalize ()"><span class="type">xmlSecEncCtxFinalize</span></a> function.</p>
<div class="refsect3">
<a name="xmlSecEncCtxInitialize.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>keysMngr</p></td>
<td class="parameter_description"><p>the pointer to keys manager.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxInitialize.returns"></a><h4>Returns</h4>
<p> 0 on success or a negative value if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxFinalize"></a><h3>xmlSecEncCtxFinalize ()</h3>
<pre class="programlisting"><font><span class="returnvalue">void</span></font>
xmlSecEncCtxFinalize (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>);</pre>
<p>Cleans up <em class="parameter"><code>encCtx</code></em>
 object.</p>
<div class="refsect3">
<a name="xmlSecEncCtxFinalize.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxCopyUserPref"></a><h3>xmlSecEncCtxCopyUserPref ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxCopyUserPref (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> dst</code></em>,
                          <em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> src</code></em>);</pre>
<p>Copies user preference from <em class="parameter"><code>src</code></em>
 context to <em class="parameter"><code>dst</code></em>
.</p>
<div class="refsect3">
<a name="xmlSecEncCtxCopyUserPref.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>dst</p></td>
<td class="parameter_description"><p>the pointer to destination context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>src</p></td>
<td class="parameter_description"><p>the pointer to source context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxCopyUserPref.returns"></a><h4>Returns</h4>
<p> 0 on success or a negative value if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxReset"></a><h3>xmlSecEncCtxReset ()</h3>
<pre class="programlisting"><font><span class="returnvalue">void</span></font>
xmlSecEncCtxReset (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>);</pre>
<p>Resets <em class="parameter"><code>encCtx</code></em>
 object, user settings are not touched.</p>
<div class="refsect3">
<a name="xmlSecEncCtxReset.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxBinaryEncrypt"></a><h3>xmlSecEncCtxBinaryEncrypt ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxBinaryEncrypt (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                           <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> tmpl</code></em>,
                           <em class="parameter"><code>const <a class="link" href="xmlsec-xmlsec.html#xmlSecByte" title="xmlSecByte"><span class="type">xmlSecByte</span></a> *data</code></em>,
                           <em class="parameter"><code><a class="link" href="xmlsec-xmlsec.html#xmlSecSize" title="xmlSecSize"><span class="type">xmlSecSize</span></a> dataSize</code></em>);</pre>
<p>Encrypts <em class="parameter"><code>data</code></em>
 according to template <em class="parameter"><code>tmpl</code></em>
.</p>
<div class="refsect3">
<a name="xmlSecEncCtxBinaryEncrypt.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>tmpl</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> template node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>data</p></td>
<td class="parameter_description"><p>the pointer for binary buffer.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>dataSize</p></td>
<td class="parameter_description"><p>the <em class="parameter"><code>data</code></em>
buffer size.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxBinaryEncrypt.returns"></a><h4>Returns</h4>
<p> 0 on success or a negative value if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxXmlEncrypt"></a><h3>xmlSecEncCtxXmlEncrypt ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxXmlEncrypt (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                        <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> tmpl</code></em>,
                        <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> node</code></em>);</pre>
<p>Encrypts <em class="parameter"><code>node</code></em>
 according to template <em class="parameter"><code>tmpl</code></em>
. If requested, <em class="parameter"><code>node</code></em>
 is replaced
with result <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> node.</p>
<div class="refsect3">
<a name="xmlSecEncCtxXmlEncrypt.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>tmpl</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> template node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>node</p></td>
<td class="parameter_description"><p>the pointer to node for encryption.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxXmlEncrypt.returns"></a><h4>Returns</h4>
<p> 0 on success or a negative value if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxUriEncrypt"></a><h3>xmlSecEncCtxUriEncrypt ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxUriEncrypt (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                        <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> tmpl</code></em>,
                        <em class="parameter"><code>const <font><span class="type">xmlChar</span></font> *uri</code></em>);</pre>
<p>Encrypts data from <em class="parameter"><code>uri</code></em>
 according to template <em class="parameter"><code>tmpl</code></em>
.</p>
<div class="refsect3">
<a name="xmlSecEncCtxUriEncrypt.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>tmpl</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> template node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>uri</p></td>
<td class="parameter_description"><p>the URI.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxUriEncrypt.returns"></a><h4>Returns</h4>
<p> 0 on success or a negative value if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxDecrypt"></a><h3>xmlSecEncCtxDecrypt ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxDecrypt (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                     <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> node</code></em>);</pre>
<p>Decrypts <em class="parameter"><code>node</code></em>
 and if necessary replaces <em class="parameter"><code>node</code></em>
 with decrypted data.</p>
<div class="refsect3">
<a name="xmlSecEncCtxDecrypt.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>node</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxDecrypt.returns"></a><h4>Returns</h4>
<p> 0 on success or a negative value if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxDecryptToBuffer"></a><h3>xmlSecEncCtxDecryptToBuffer ()</h3>
<pre class="programlisting"><a class="link" href="xmlsec-buffer.html#xmlSecBuffer" title="struct xmlSecBuffer"><span class="returnvalue">xmlSecBufferPtr</span></a>
xmlSecEncCtxDecryptToBuffer (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                             <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> node</code></em>);</pre>
<p>Decrypts <em class="parameter"><code>node</code></em>
 data to the result.</p>
<div class="refsect3">
<a name="xmlSecEncCtxDecryptToBuffer.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to encryption processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>node</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxDecryptToBuffer.returns"></a><h4>Returns</h4>
<p> a buffer with key on success or NULL if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxDebugDump"></a><h3>xmlSecEncCtxDebugDump ()</h3>
<pre class="programlisting"><font><span class="returnvalue">void</span></font>
xmlSecEncCtxDebugDump (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                       <em class="parameter"><code><font><span class="type">FILE</span></font> *output</code></em>);</pre>
<p>Prints the debug information about <em class="parameter"><code>encCtx</code></em>
 to <em class="parameter"><code>output</code></em>
.</p>
<div class="refsect3">
<a name="xmlSecEncCtxDebugDump.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>output</p></td>
<td class="parameter_description"><p>the pointer to output FILE.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxDebugXmlDump"></a><h3>xmlSecEncCtxDebugXmlDump ()</h3>
<pre class="programlisting"><font><span class="returnvalue">void</span></font>
xmlSecEncCtxDebugXmlDump (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                          <em class="parameter"><code><font><span class="type">FILE</span></font> *output</code></em>);</pre>
<p>Prints the debug information about <em class="parameter"><code>encCtx</code></em>
 to <em class="parameter"><code>output</code></em>
 in XML format.</p>
<div class="refsect3">
<a name="xmlSecEncCtxDebugXmlDump.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>output</p></td>
<td class="parameter_description"><p>the pointer to output FILE.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxDerivedKeyGenerate"></a><h3>xmlSecEncCtxDerivedKeyGenerate ()</h3>
<pre class="programlisting"><a class="link" href="xmlsec-keys.html#xmlSecKey" title="struct xmlSecKey"><span class="returnvalue">xmlSecKeyPtr</span></a>
xmlSecEncCtxDerivedKeyGenerate (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                                <em class="parameter"><code><font><span class="type">xmlSecKeyDataId</span></font> keyId</code></em>,
                                <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> node</code></em>,
                                <em class="parameter"><code><a class="link" href="xmlsec-keyinfo.html#xmlSecKeyInfoCtx" title="struct xmlSecKeyInfoCtx"><span class="type">xmlSecKeyInfoCtxPtr</span></a> keyInfoCtx</code></em>);</pre>
<p>Generates (derives) key from <em class="parameter"><code>node</code></em>
 (https://www.w3.org/TR/xmlenc-core1/<font><span class="type">sec-DerivedKey</span></font>):</p>
<pre class="programlisting">
 &lt;element name="DerivedKey" type="xenc11:DerivedKeyType"/&gt;
 &lt;complexType name="DerivedKeyType"&gt;
     &lt;sequence&gt;
         &lt;element ref="xenc11:KeyDerivationMethod" minOccurs="0"/&gt;
         &lt;element ref="xenc:ReferenceList" minOccurs="0"/&gt;
         &lt;element name="DerivedKeyName" type="string" minOccurs="0"/&gt;
         &lt;element name="MasterKeyName" type="string" minOccurs="0"/&gt;
     &lt;/sequence&gt;
     &lt;attribute name="Recipient" type="string" use="optional"/&gt;
     &lt;attribute name="Id" type="ID" use="optional"/&gt;
     &lt;attribute name="Type" type="anyURI" use="optional"/&gt;
 &lt;/complexType&gt;

 &lt;element name="KeyDerivationMethod" type="xenc:KeyDerivationMethodType"/&gt;
 &lt;complexType name="KeyDerivationMethodType"&gt;
     &lt;sequence&gt;
         &lt;any namespace="##any" minOccurs="0" maxOccurs="unbounded"/&gt;
     &lt;/sequence&gt;
     &lt;attribute name="Algorithm" type="anyURI" use="required"/&gt;
 &lt;/complexType&gt;
</pre>
<div class="refsect3">
<a name="xmlSecEncCtxDerivedKeyGenerate.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to encryption processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>keyId</p></td>
<td class="parameter_description"><p>the expected key id, the actual derived key might have a different id.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>node</p></td>
<td class="parameter_description"><p>the pointer to &lt;enc11:DerivedKey/&gt; node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>keyInfoCtx</p></td>
<td class="parameter_description"><p>the pointer to the "parent" key info context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxDerivedKeyGenerate.returns"></a><h4>Returns</h4>
<p> the derived key on success or NULL  if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxAgreementMethodGenerate"></a><h3>xmlSecEncCtxAgreementMethodGenerate ()</h3>
<pre class="programlisting"><a class="link" href="xmlsec-keys.html#xmlSecKey" title="struct xmlSecKey"><span class="returnvalue">xmlSecKeyPtr</span></a>
xmlSecEncCtxAgreementMethodGenerate (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                                     <em class="parameter"><code><font><span class="type">xmlSecKeyDataId</span></font> keyId</code></em>,
                                     <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> node</code></em>,
                                     <em class="parameter"><code><a class="link" href="xmlsec-keyinfo.html#xmlSecKeyInfoCtx" title="struct xmlSecKeyInfoCtx"><span class="type">xmlSecKeyInfoCtxPtr</span></a> keyInfoCtx</code></em>);</pre>
<p>Generates (derives) key from <em class="parameter"><code>node</code></em>
 (https://www.w3.org/TR/xmlenc-core1/<font><span class="type">sec-AgreementMethod</span></font>):</p>
<pre class="programlisting">
 &lt;element name="AgreementMethod" type="xenc:AgreementMethodType"/&gt;
 &lt;complexType name="AgreementMethodType" mixed="true"&gt;
     &lt;sequence&gt;
         &lt;element name="KA-Nonce" minOccurs="0" type="base64Binary"/&gt;
         &lt;!-- &lt;element ref="ds:DigestMethod" minOccurs="0"/&gt; --&gt;
         &lt;any namespace="##other" minOccurs="0" maxOccurs="unbounded"/&gt;
         &lt;element name="OriginatorKeyInfo" minOccurs="0" type="ds:KeyInfoType"/&gt;
         &lt;element name="RecipientKeyInfo" minOccurs="0" type="ds:KeyInfoType"/&gt;
     &lt;/sequence&gt;
     &lt;attribute name="Algorithm" type="anyURI" use="required"/&gt;
 &lt;/complexType&gt;
</pre>
<div class="refsect3">
<a name="xmlSecEncCtxAgreementMethodGenerate.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>encCtx</p></td>
<td class="parameter_description"><p>the pointer to encryption processing context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>keyId</p></td>
<td class="parameter_description"><p>the expected key id, the actual derived key might have a different id.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>node</p></td>
<td class="parameter_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:AgreementMethod/&gt;</a> node.</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>keyInfoCtx</p></td>
<td class="parameter_description"><p>the pointer to the "parent" key info context.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="xmlSecEncCtxAgreementMethodGenerate.returns"></a><h4>Returns</h4>
<p> the generated key on success or NULL if an error occurs.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxAgreementMethodXmlWrite"></a><h3>xmlSecEncCtxAgreementMethodXmlWrite ()</h3>
<pre class="programlisting"><font><span class="returnvalue">int</span></font>
xmlSecEncCtxAgreementMethodXmlWrite (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtxPtr</span></a> encCtx</code></em>,
                                     <em class="parameter"><code><font><span class="type">xmlNodePtr</span></font> node</code></em>,
                                     <em class="parameter"><code><a class="link" href="xmlsec-keyinfo.html#xmlSecKeyInfoCtx" title="struct xmlSecKeyInfoCtx"><span class="type">xmlSecKeyInfoCtxPtr</span></a> keyInfoCtx</code></em>);</pre>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtxGetFailureReasonString"></a><h3>xmlSecEncCtxGetFailureReasonString ()</h3>
<pre class="programlisting">const <font><span class="returnvalue">char</span></font> *
xmlSecEncCtxGetFailureReasonString (<em class="parameter"><code><a class="link" href="xmlsec-xmlenc.html#xmlSecEncFailureReason" title="enum xmlSecEncFailureReason"><span class="type">xmlSecEncFailureReason</span></a> failureReason</code></em>);</pre>
<p>Gets failure reason as a string.</p>
<p>Returns failure reason as a string.</p>
<div class="refsect3">
<a name="xmlSecEncCtxGetFailureReasonString.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>failureReason</p></td>
<td class="parameter_description"><p>the failure reason.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
</div>
</div>
<div class="refsect1">
<a name="xmlsec-xmlenc.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="xmlEncCtxMode"></a><h3>enum xmlEncCtxMode</h3>
<p>The <a class="link" href="xmlsec-xmlenc.html#xmlSecEncCtx" title="struct xmlSecEncCtx"><span class="type">xmlSecEncCtx</span></a> mode.</p>
<div class="refsect3">
<a name="xmlEncCtxMode.members"></a><h4>Members</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="enum_member_name"><p><a name="xmlEncCtxModeEncryptedData"></a>xmlEncCtxModeEncryptedData</p></td>
<td class="enum_member_description"><p>the <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a> element procesing.</p></td>
<td class="enum_member_annotations"> </td>
</tr>
<tr>
<td class="enum_member_name"><p><a name="xmlEncCtxModeEncryptedKey"></a>xmlEncCtxModeEncryptedKey</p></td>
<td class="enum_member_description"><p>the <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> element processing.</p></td>
<td class="enum_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncFailureReason"></a><h3>enum xmlSecEncFailureReason</h3>
<p>XML Encryption processing failure reason. The application should use
the returned value from the encrypt/decrypt functions first.</p>
<div class="refsect3">
<a name="xmlSecEncFailureReason.members"></a><h4>Members</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="enum_member_name"><p><a name="xmlSecEncFailureReasonUnknown"></a>xmlSecEncFailureReasonUnknown</p></td>
<td class="enum_member_description"><p>the failure reason is unknown.</p></td>
<td class="enum_member_annotations"> </td>
</tr>
<tr>
<td class="enum_member_name"><p><a name="xmlSecEncFailureReasonKeyNotFound"></a>xmlSecEncFailureReasonKeyNotFound</p></td>
<td class="enum_member_description"><p>the key not found.</p></td>
<td class="enum_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="XMLSEC-ENC-RETURN-REPLACED-NODE:CAPS"></a><h3>XMLSEC_ENC_RETURN_REPLACED_NODE</h3>
<pre class="programlisting">#define XMLSEC_ENC_RETURN_REPLACED_NODE                 0x00000001
</pre>
<p>If this flag is set, then the replaced node will be returned in the replacedNodeList</p>
</div>
<hr>
<div class="refsect2">
<a name="xmlSecEncCtx"></a><h3>struct xmlSecEncCtx</h3>
<pre class="programlisting">struct xmlSecEncCtx {
    /* these data user can set before performing the operation */
    void*                       userData;
    unsigned int                flags;
    unsigned int                flags2;
    xmlEncCtxMode               mode;
    xmlSecKeyInfoCtx            keyInfoReadCtx;
    xmlSecKeyInfoCtx            keyInfoWriteCtx;
    xmlSecTransformCtx          transformCtx;
    xmlSecTransformId           defEncMethodId;

    /* these data are returned */
    xmlSecKeyPtr                encKey;
    xmlSecTransformOperation    operation;
    xmlSecBufferPtr             result;
    int                         resultBase64Encoded;
    int                         resultReplaced;
    xmlSecTransformPtr          encMethod;
    xmlSecEncFailureReason      failureReason;

    /* attributes from EncryptedData or EncryptedKey */
    xmlChar*                    id;
    xmlChar*                    type;
    xmlChar*                    mimeType;
    xmlChar*                    encoding;
    xmlChar*                    recipient;
    xmlChar*                    carriedKeyName;

    /* these are internal data, nobody should change that except us */
    xmlNodePtr                  encDataNode;
    xmlNodePtr                  encMethodNode;
    xmlNodePtr                  keyInfoNode;
    xmlNodePtr                  cipherValueNode;

    xmlNodePtr                  replacedNodeList; /* the pointer to the replaced node */
    void*                       reserved1;        /* reserved for future */
};
</pre>
<p>XML Encryption context.</p>
<div class="refsect3">
<a name="xmlSecEncCtx.members"></a><h4>Members</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col>
<col>
<col>
</colgroup>
<tbody>
<tr>
<td class="struct_member_name"><p><font><span class="type">void</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.userData"></a>userData</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to user data (xmlsec and xmlsec-crypto libraries
never touches this).</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p>unsigned <font><span class="type">int</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.flags"></a>flags</code></em>;</p></td>
<td class="struct_member_description"><p>the XML Encryption processing flags.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p>unsigned <font><span class="type">int</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.flags2"></a>flags2</code></em>;</p></td>
<td class="struct_member_description"><p>the XML Encryption processing flags.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-xmlenc.html#xmlEncCtxMode" title="enum xmlEncCtxMode"><span class="type">xmlEncCtxMode</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.mode"></a>mode</code></em>;</p></td>
<td class="struct_member_description"><p>the mode.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-keyinfo.html#xmlSecKeyInfoCtx" title="struct xmlSecKeyInfoCtx"><span class="type">xmlSecKeyInfoCtx</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.keyInfoReadCtx"></a>keyInfoReadCtx</code></em>;</p></td>
<td class="struct_member_description"><p>the reading key context.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-keyinfo.html#xmlSecKeyInfoCtx" title="struct xmlSecKeyInfoCtx"><span class="type">xmlSecKeyInfoCtx</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.keyInfoWriteCtx"></a>keyInfoWriteCtx</code></em>;</p></td>
<td class="struct_member_description"><p>the writing key context (not used for signature verification).</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-transforms.html#xmlSecTransformCtx" title="struct xmlSecTransformCtx"><span class="type">xmlSecTransformCtx</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.transformCtx"></a>transformCtx</code></em>;</p></td>
<td class="struct_member_description"><p>the transforms processing context.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlSecTransformId</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.defEncMethodId"></a>defEncMethodId</code></em>;</p></td>
<td class="struct_member_description"><p>the default encryption method (used if
<a class="ulink" href="" target="_top">&lt;enc:EncryptionMethod/&gt;</a> node is not present).</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-keys.html#xmlSecKey" title="struct xmlSecKey"><span class="type">xmlSecKeyPtr</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.encKey"></a>encKey</code></em>;</p></td>
<td class="struct_member_description"><p>the signature key; application may set <font><span class="type">encKey</span></font>
before calling encryption/decryption functions.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-transforms.html#xmlSecTransformOperation" title="enum xmlSecTransformOperation"><span class="type">xmlSecTransformOperation</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.operation"></a>operation</code></em>;</p></td>
<td class="struct_member_description"><p>the operation: encrypt or decrypt.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-buffer.html#xmlSecBuffer" title="struct xmlSecBuffer"><span class="type">xmlSecBufferPtr</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.result"></a>result</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to signature (not valid for signature verification).</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">int</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.resultBase64Encoded"></a>resultBase64Encoded</code></em>;</p></td>
<td class="struct_member_description"><p>the flag: if set then result in <font><span class="type">result</span></font> is base64 encoded.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">int</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.resultReplaced"></a>resultReplaced</code></em>;</p></td>
<td class="struct_member_description"><p>the flag: if set then resulted <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a>
or <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node is added to the document.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-transforms.html#xmlSecTransform" title="struct xmlSecTransform"><span class="type">xmlSecTransformPtr</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.encMethod"></a>encMethod</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to encryption transform.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="xmlsec-xmlenc.html#xmlSecEncFailureReason" title="enum xmlSecEncFailureReason"><span class="type">xmlSecEncFailureReason</span></a> <em class="structfield"><code><a name="xmlSecEncCtx.failureReason"></a>failureReason</code></em>;</p></td>
<td class="struct_member_description"><p>the detailed failure reason.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlChar</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.id"></a>id</code></em>;</p></td>
<td class="struct_member_description"><p>the ID attribute of <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a>
or <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlChar</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.type"></a>type</code></em>;</p></td>
<td class="struct_member_description"><p>the Type attribute of <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a>
or <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlChar</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.mimeType"></a>mimeType</code></em>;</p></td>
<td class="struct_member_description"><p>the MimeType attribute of <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a>
or <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlChar</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.encoding"></a>encoding</code></em>;</p></td>
<td class="struct_member_description"><p>the Encoding attributeof <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a>
or <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlChar</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.recipient"></a>recipient</code></em>;</p></td>
<td class="struct_member_description"><p>the Recipient attribute of <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node..</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlChar</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.carriedKeyName"></a>carriedKeyName</code></em>;</p></td>
<td class="struct_member_description"><p>the CarriedKeyName attribute of <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlNodePtr</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.encDataNode"></a>encDataNode</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptedData/&gt;</a>
or <a class="ulink" href="" target="_top">&lt;enc:EncryptedKey/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlNodePtr</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.encMethodNode"></a>encMethodNode</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:EncryptionMethod/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlNodePtr</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.keyInfoNode"></a>keyInfoNode</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:KeyInfo/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlNodePtr</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.cipherValueNode"></a>cipherValueNode</code></em>;</p></td>
<td class="struct_member_description"><p>the pointer to <a class="ulink" href="" target="_top">&lt;enc:CipherValue/&gt;</a> node.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">xmlNodePtr</span></font> <em class="structfield"><code><a name="xmlSecEncCtx.replacedNodeList"></a>replacedNodeList</code></em>;</p></td>
<td class="struct_member_description"><p>the first node of the list of replaced nodes depending on the nodeReplacementMode</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><font><span class="type">void</span></font> *<em class="structfield"><code><a name="xmlSecEncCtx.reserved1"></a>reserved1</code></em>;</p></td>
<td class="struct_member_description"><p>reserved for the future.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.34.0</div>
</body>
</html>