File: opensc.conf.5.xml.in

package info (click to toggle)
opensc 0.26.1-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 11,420 kB
  • sloc: ansic: 178,823; xml: 6,327; sh: 2,115; makefile: 1,023; cpp: 304; lex: 92
file content (1886 lines) | stat: -rw-r--r-- 62,347 bytes parent folder | download | duplicates (2)
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
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
<?xml version="1.0" encoding="UTF-8"?>
<refentry id="opensc.conf">
	<refmeta>
		<refentrytitle>opensc.conf</refentrytitle>
		<manvolnum>5</manvolnum>
		<refmiscinfo class="productname">OpenSC</refmiscinfo>
		<refmiscinfo class="manual">OpenSC File Formats</refmiscinfo>
		<refmiscinfo class="source">opensc</refmiscinfo>
	</refmeta>

	<refnamediv>
		<refname>opensc.conf</refname>
		<refpurpose>configuration file for OpenSC</refpurpose>
	</refnamediv>

	<refsect1>
		<title>Description</title>
		<para>
			OpenSC obtains configuration data from the following sources in the following order
			<orderedlist>
				<listitem><para>
						command-line options
				</para></listitem>
				<listitem><para>
						environment variables
				</para></listitem>
				<listitem><para>
						Windows registry key in
						<literal>HKEY_CURRENT_USER</literal> (if available)
				</para></listitem>
				<listitem><para>
						Windows registry key in
						<literal>HKEY_LOCAL_MACHINE</literal> (if available)
				</para></listitem>
				<listitem><para>
						system-wide configuration file
						(<literal>@sysconfdir@/opensc.conf</literal>)
				</para></listitem>
			</orderedlist>
		</para>
		<para>
			The configuration file, <literal>opensc.conf</literal>, is composed
			of <replaceable>block</replaceable>s, which, in general, have the
			following format:
			<programlisting>
<replaceable>key</replaceable><arg choice="opt" rep="repeat">, <replaceable>name</replaceable></arg> {
	<replaceable>block_contents</replaceable>
}
			</programlisting>
			<replaceable>block_contents</replaceable> is one or more
			<replaceable>block_item</replaceable>s where a
			<replaceable>block_item</replaceable> is one of
			<itemizedlist>
				<listitem><para>
						# <replaceable>comment string</replaceable>
				</para></listitem>
				<listitem><para>
						<replaceable>key</replaceable><arg choice="opt" rep="repeat">, <replaceable>name</replaceable></arg> = <replaceable>value</replaceable>;
				</para></listitem>
				<listitem><para>
						<replaceable>block</replaceable>
				</para></listitem>
			</itemizedlist>
		</para>
		<para>
			At the root level, <literal>opensc.conf</literal> should contain
			one or more application specific configuration blocks:
			<programlisting>
app <replaceable>application</replaceable> {
	<replaceable>block_contents</replaceable>
}
			</programlisting>
			<replaceable>application</replaceable>
			specifies one of:
			<itemizedlist>
				<listitem><para>
						<literal><replaceable>filename</replaceable></literal>: Configuration block for the application with specified file path.
				</para></listitem>
				<listitem><para>
						<literal>default</literal>: The fall-back configuration block for all applications
				</para></listitem>
				<listitem><para>
						<literal>opensc-pkcs11</literal>: Configuration block for the PKCS#11 module (<filename>opensc-pkcs11@DYN_LIB_EXT@</filename>)
				</para></listitem>
				<listitem><para>
						<literal>onepin-opensc-pkcs11</literal>: Configuration block for the PKCS#11 one-PIN-module (<filename>onepin-opensc-pkcs11@DYN_LIB_EXT@</filename>)
				</para></listitem>
				<listitem><para>
						<literal>cardmod</literal>: Configuration block for Windows' minidriver (<filename>opensc-minidriver.dll</filename>)
				</para></listitem>
				<listitem><para>
						<literal>tokend</literal>: Configuration block for macOS' tokend (<application>OpenSC.tokend</application>)
				</para></listitem>
				<listitem><para>
						<literal>cardos-tool</literal>,
						<literal>cryptoflex-tool</literal>,
						<literal>dnie-tool</literal>,
						<literal>egk-tool</literal>,
						<literal>eidenv</literal>,
						<literal>gids-tool</literal>,
						<literal>iasecc-tool</literal>,
						<literal>netkey-tool</literal>,
						<literal>npa-tool</literal>,
						<literal>openpgp-tool</literal>,
						<literal>opensc-asn1</literal>,
						<literal>opensc-explorer</literal>,
						<literal>opensc-notify</literal>,
						<literal>opensc-tool</literal>,
						<literal>piv-tool</literal>,
						<literal>pkcs11-tool</literal>,
						<literal>pkcs15-crypt</literal>,
						<literal>pkcs15-init</literal>,
						<literal>pkcs15-tool</literal>,
						<literal>sc-hsm-tool</literal>,
						<literal>westcos-tool</literal>:
						Configuration block for OpenSC tools
				</para></listitem>
			</itemizedlist>
		</para>
	</refsect1>

	<refsect1>
		<title>Configuration Options</title>
		<variablelist>
			<varlistentry id="debug">
				<term>
					<option>debug = <replaceable>num</replaceable>;</option>
				</term>
				<listitem><para>
						Amount of debug info to print (Default:
						<literal>0</literal>). A greater value means more
						debug info.
					</para>
					<para>
						The environment variable
						<envar>OPENSC_DEBUG</envar> overwrites this
						setting.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>debug_file = <replaceable>filename</replaceable>;</option>
				</term>
				<listitem><para>
						The file to which debug output will be written
						(Default: <literal>stderr</literal>). Special
						values <literal>stdout</literal> and
						<literal>stderr</literal> are recognized.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>profile_dir = <replaceable>filename</replaceable>;</option>
				</term>
				<listitem><para>
						PKCS#15 initialization/personalization profiles
						directory for
						<citerefentry>
							<refentrytitle>pkcs15-init</refentrytitle>
							<manvolnum>1</manvolnum>.
						</citerefentry>
						(Default: <literal>@PROFILE_DIR_DEFAULT@</literal>).
					</para>
					<para>
						If this configuration value is not found on
						Windows, the registry key
						<filename>Software\OpenSC
							Project\OpenSC\ProfileDir</filename> is
						checked.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>disable_colors = <replaceable>bool</replaceable>;</option>
				</term>
				<listitem><para>
						Disable colors of log messages (Default:
						<literal>false</literal> if attached to a console,
						<literal>true</literal> otherwise).
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>disable_popups = <replaceable>bool</replaceable>;</option>
				</term>
				<listitem><para>
						Disable pop-ups of built-in GUI (Default: <literal>false</literal>).
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>enable_default_driver = <replaceable>bool</replaceable>;</option>
				</term>
				<listitem><para>
						Enable default card driver (Default:
						<literal>false</literal>). Default card driver is
						explicitly enabled for
						<citerefentry>
							<refentrytitle>opensc-explorer</refentrytitle>
							<manvolnum>1</manvolnum>.
						</citerefentry>
						and
						<citerefentry>
							<refentrytitle>opensc-tool</refentrytitle>
							<manvolnum>1</manvolnum>.
						</citerefentry>
				</para></listitem>
			</varlistentry>
			<varlistentry id="card_drivers">
				<term>
					<option>card_drivers = <arg choice="plain"
							rep="repeat"><replaceable>name</replaceable></arg>;</option>
				</term>
				<listitem><para>
						Allowlist of card drivers to load at start-up.
						The special value <literal>internal</literal> (the
						default) will load all statically linked drivers.
					</para>
					<para>
						If an unknown (i.e. not internal or old) driver is
						supplied, a separate configuration
						block has to be written for the driver. A special
						value <literal>old</literal> will load all
						statically linked drivers that may be removed in
						the future.
					</para>
					<para>
						The list of supported card driver names can be
						retrieved from the output of <command>opensc-tool
							--list-drivers</command>.
					</para>
					<para>
						The environment variable
						<envar>OPENSC_DRIVER</envar> overwrites this
						setting.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>ignored_readers = <arg choice="plain"
							rep="repeat"><replaceable>name</replaceable></arg>;</option>
				</term>
				<listitem><para>
						List of readers to ignore (Default: empty). If any
						of the comma separated strings listed is matched in
						a reader name (case sensitive, partial matching
						possible), the reader is ignored by OpenSC. Use
						<command>opensc-tool --list-readers</command> to
						see all currently connected readers.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>reader_driver <replaceable>name</replaceable> {
						<replaceable>block_contents</replaceable>
						}
					</option>
				</term>
				<listitem>
					<para>
						Configuration of the smart card reader driver where <replaceable>name</replaceable> is one of:
						<itemizedlist>
							<listitem><para>
									<literal>ctapi</literal>: See <xref linkend="ctapi"/>
								</para>
							</listitem>
							<listitem><para>
									<literal>pcsc</literal>: See <xref linkend="pcsc"/>
							</para></listitem>
							<listitem><para>
									<literal>openct</literal>: See <xref linkend="openct"/>
							</para></listitem>
							<listitem><para>
									<literal>cryptotokenkit</literal>: Configuration block for CryptoTokenKit readers
							</para></listitem>
						</itemizedlist>
					</para>
					<para>
						See <xref linkend="reader_driver"/>.
					</para>
				</listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>card_driver <replaceable>name</replaceable> {
						<replaceable>block_contents</replaceable>
						}
					</option>
				</term>
				<listitem><para>
						Configuration of the card driver where <replaceable>name</replaceable> is one of:
						<itemizedlist>
							<listitem><para>
									<literal>npa</literal>: See <xref linkend="npa"/>
							</para></listitem>
							<listitem><para>
									<literal>dnie</literal>: See <xref linkend="dnie"/>
							</para></listitem>
							<listitem><para>
									<literal>edo</literal>: See <xref linkend="edo"/>
							</para></listitem>
							<listitem><para>
									<literal>eoi</literal>: See <xref linkend="eoi"/>
							</para></listitem>
							<listitem><para>
									<literal>myeid</literal>: See <xref linkend="myeid"/>
							</para></listitem>
							<listitem><para>
									Any other value: Configuration block for an externally loaded card driver
							</para></listitem>
						</itemizedlist>
					</para>
				</listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>card_atr <replaceable>hexstring</replaceable> {
						<replaceable>block_contents</replaceable>
						}
					</option>
				</term>
				<listitem><para>
						In addition to the built-in list of known cards in
						the card driver, you can configure a new card for
						the driver using the <option>card_atr</option>
						block.
					</para>
					<para>
						For details see <xref linkend="card_atr"/>.
					</para>
				</listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>disable_hw_pkcs1_padding = <replaceable>value</replaceable>;</option>
				</term>
				<listitem><para>
						Disabling PKCS#1 v1.5 padding in HW when card supports doing raw RSA operations.
						Known parameters:
						<itemizedlist>
							<listitem><para>
									<literal>no</literal>: PKCS#1 v1.5 padding is enabled in HW when card supports it.
							</para></listitem>
							<listitem><para>
									<literal>sign</literal>: PKCS#1 v1.5 padding
								is disabled only for signatures (PKCS#1 v1.5 type 1).
							</para></listitem>
							<listitem><para>
									<literal>decipher</literal>: PKCS#1 v1.5 padding
								is disabled only for decryption (PKCS#1 v1.5 type 2).
							</para></listitem>
							<listitem><para>
									<literal>both</literal>: PKCS#1 v1.5 padding
								is disabled both for signatures and decryption (PKCS#1 v1.5 type 1 and 2).
							</para></listitem>
						</itemizedlist>
						(Default: <literal>decipher</literal>).
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>secure_messaging <replaceable>name</replaceable> {
						<replaceable>block_contents</replaceable>
						}
					</option>
				</term>
				<listitem><para>
						Configuration options for the secure messaging profile <replaceable>name</replaceable>:
					</para>
					<variablelist>
						<varlistentry>
							<term>
								<option>module_name = <replaceable>filename</replaceable>;</option>
							</term>
							<listitem><para>
									Name of external SM module (Default: @DEFAULT_SM_MODULE@).
							</para></listitem>
						</varlistentry>
						<varlistentry>
							<term>
								<option>module_path = <replaceable>filename</replaceable>;</option>
							</term>
							<listitem><para>
									Directory with external SM module
									(Default: @libdir@).
								</para>
								<para>
									If this configuration value is not
									found on Windows, the registry key
									<filename>Software\OpenSC
										Project\OpenSC\SmDir</filename> is
									checked.
							</para></listitem>
						</varlistentry>
						<varlistentry>
							<term>
								<option>module_data = <replaceable>value</replaceable>;</option>
							</term>
							<listitem><para>
									Specific data to tune the module initialization.
							</para></listitem>
						</varlistentry>
						<varlistentry>
							<term>
								<option>mode = <replaceable>value</replaceable>;</option>
							</term>
							<listitem><para>
									Secure messaging mode. Known parameters:
									<itemizedlist>
										<listitem><para>
												<literal>transmit</literal>:
												In this mode the
												procedure to securize
												an APDU is called by
												the OpenSC general APDU
												transmit procedure. In
												this mode all APDUs,
												except the ones
												filtered by the card
												specific procedure, are
												securized.
										</para></listitem>
										<listitem><para>
												<literal>acl</literal>:
												In this mode APDU are
												securized only if
												needed by the ACLs of
												the command to be
												executed.
										</para></listitem>
									</itemizedlist>
							</para></listitem>
						</varlistentry>
						<varlistentry>
							<term>
								<option>flags = <replaceable>value</replaceable>;</option>
							</term>
							<listitem><para>
									Secure messaging type specific flags.
							</para></listitem>
						</varlistentry>
						<varlistentry>
							<term>
								<option>kmc = <replaceable>hexstring</replaceable>;</option>
							</term>
							<listitem><para>
									Default KMC of the GP Card Manager for the Oberthur's Java cards.
							</para></listitem>
						</varlistentry>
						<varlistentry>
							<term>
								<option>ifd_serial = <replaceable>hexstring</replaceable>;</option>
							</term>
						</varlistentry>
						<varlistentry>
							<term>
								<option>keyset[_<replaceable>aid</replaceable>]_<replaceable>num</replaceable>_enc =
									<replaceable>value</replaceable>;</option>
								<option>keyset[_<replaceable>aid</replaceable>]_<replaceable>num</replaceable>_mac =
									<replaceable>value</replaceable>;</option>
							</term>
							<listitem><para>
									Keyset values from IAM profiles of
									the Gemalto IAS/ECC cards with an
									optional application identifier
							</para></listitem>
						</varlistentry>
					</variablelist>
				</listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>framework <replaceable>name</replaceable> {
						<replaceable>block_contents</replaceable>
						}
					</option>
				</term>
				<listitem><para>
						Internal configuration options where <replaceable>name</replaceable> is one of:
						<itemizedlist>
							<listitem><para>
									<literal>pkcs15</literal>: See <xref linkend="framework pkcs15"/>
							</para></listitem>
							<listitem><para>
									<literal>tokend</literal>: See <xref linkend="framework tokend"/>
							</para></listitem>
						</itemizedlist>
					</para>
				</listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<option>pkcs11 {
						<replaceable>block_contents</replaceable>
						}
					</option>
				</term>
				<listitem><para>
						Parameters for the OpenSC PKCS11 module.
					</para>
					<para>
						For details see <xref linkend="pkcs11"/>.
					</para>
				</listitem>
			</varlistentry>
		</variablelist>

		<refsect2 id="reader_driver">
			<title>Configuration of Smart Card Reader Driver</title>

			<refsect3>
				<title>Configuration Options for all Reader Drivers</title>
				<variablelist>
					<varlistentry>
						<term>
							<option>max_send_size = <replaceable>num</replaceable>;</option>
							<option>max_recv_size = <replaceable>num</replaceable>;</option>
						</term>
						<listitem><para>
								Limit command and response sizes
								(Default:
								<option>max_send_size</option>
								= <literal>255</literal>,
								<option>max_recv_size</option>
								= <literal>256</literal>) . Some
								Readers don't propagate their
								transceive capabilities correctly.
								max_send_size and max_recv_size
								allow setting the limits manually,
								for example to enable extended
								length capabilities.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>enable_escape <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Detect reader capabilities with
								escape commands (wrapped APDUs with
								CLA=0xFF as defined by PC/SC pt. 3
								and BSI TR-03119, e.g. for getting
								the UID, escaped PIN commands and
								the reader's firmware version,
								Default: <literal>false</literal>)
						</para></listitem>
					</varlistentry>
				</variablelist>
			</refsect3>

			<refsect3 id="ctapi">
				<title>Configuration of CT-API Readers</title>
				<variablelist>
					<varlistentry>
						<term>
							<option>module <replaceable>filename</replaceable> {
								ports = <replaceable>nums</replaceable>;
								}
							</option>
						</term>
						<listitem><para>
								Load the specified CT-API module with the specified number of ports.
						</para></listitem>
					</varlistentry>
				</variablelist>
			</refsect3>

			<refsect3 id="pcsc">
				<title>Configuration of PC/SC Readers</title>
				<variablelist>
					<varlistentry>
						<term>
							<option>connect_exclusive = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Connect to reader in exclusive mode
								(Default: <literal>false</literal>)?
								This option has no effect in Windows' minidriver.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>disconnect_action = <replaceable>action</replaceable>;</option>
						</term>
						<listitem><para>
								What to do when disconnecting from
								a card (SCardDisconnect). Valid
								values are
								<literal>leave</literal>,
								<literal>reset</literal>,
								<literal>unpower</literal> (Default:
								<literal>leave</literal>).
								This option has no effect in Windows' minidriver.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>transaction_end_action = <replaceable>action</replaceable>;</option>
						</term>
						<listitem><para>
								What to do at the end of a
								transaction (SCardEndTransaction).
								Valid values
								are <literal>leave</literal>,
								<literal>reset</literal>,
								<literal>unpower</literal> (Default:
								<literal>leave</literal>).
								This option has no effect in Windows' minidriver.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>reconnect_action = <replaceable>action</replaceable>;</option>
						</term>
						<listitem><para>
								What to do when reconnection to a
								card (SCardReconnect). Valid values
								are <literal>leave</literal>,
								<literal>reset</literal>,
								<literal>unpower</literal> (Default:
								<literal>leave</literal>).
								This option has no effect in Windows' minidriver.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>enable_pinpad = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Enable pinpad if detected (PC/SC
								v2.0.2 Part 10, Default:
								<literal>true</literal>)
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>fixed_pinlength = <replaceable>num</replaceable>;</option>
						</term>
						<listitem><para>
								Some pinpad readers can only handle
								one exact length of the PIN.
								<option>fixed_pinlength</option>
								sets this value so that OpenSC
								expands the padding to this length
								(Default: <literal>0</literal>,
								i.e. not fixed).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>provider_library = <replaceable>filename</replaceable>;</option>
						</term>
						<listitem><para>
								Use specific PC/SC provider
								(Default:
								<literal>@DEFAULT_PCSC_PROVIDER@</literal>).
						</para></listitem>
					</varlistentry>
				</variablelist>
			</refsect3>

			<refsect3 id="openct">
				<title>Configuration of OpenCT Readers</title>
				<variablelist>
					<varlistentry>
						<term>
							<option>readers = <replaceable>num</replaceable>;</option>
						</term>
						<listitem><para>
								Virtual readers to allocate (Default: <literal>2</literal>).
						</para></listitem>
					</varlistentry>
				</variablelist>
			</refsect3>

		</refsect2>

		<refsect2 id="myeid">
			<title>Configuration Options for MyEID Card</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>disable_hw_pkcs1_padding = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							The MyEID card can internally
							encapsulate the data (hash code)
							into a DigestInfo ASN.1 structure
							according to the selected hash
							algorithm (currently only for SHA1).
							DigestInfo is padded to RSA key
							modulus length according to PKCS#1
							v1.5, block type 01h. Size of the
							DigestInfo must not exceed 40%
							of the RSA key modulus length. If
							this limit is unsatisfactory (for
							example someone needs RSA 1024
							with SHA512), the user can disable
							this feature. In this case, the
							card driver will do everything
							necessary before sending the data
							(hash code) to the card.
					</para><para>
							PKCS#1 v1.5 padding in HW can be globally disabled by option <literal>disable_hw_pkcs1_padding</literal>.
							When the global option is used to disable padding, the padding will be disabled even though the MyEID-specific option does not turn it off.
					</para></listitem>
				</varlistentry>

			</variablelist>
		</refsect2>

		<refsect2 id="npa">
			<title>Configuration Options for German ID Card</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>can = <replaceable>value</replaceable>;</option>
					</term>
					<listitem><para>
							German ID card requires the CAN to
							be verified before QES PIN. This,
							however, is not part of the PKCS#15
							profile of the card. So for
							verifying the QES PIN we actually
							need both. The CAN may be given
							here. If the CAN is not given here,
							it will be prompted on the command
							line or on the reader (depending on
							the reader's capabilities).
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>st_dv_certificate = <replaceable>filename</replaceable>;</option>
						<option>st_certificate = <replaceable>filename</replaceable>;</option>
						<option>st_key = <replaceable>filename</replaceable>;</option>
					</term>
					<listitem><para>
							QES is only possible with a Comfort
							Reader (CAT-K), which holds a
							cryptographic key to authenticate
							itself as signature terminal (ST).
							We usually will use the reader's
							capability to sign the data.
							However, during development you
							may specify soft certificates and
							keys for a ST.
						</para>
						<para>
							An example PKI can be found in the
							example data for the
							<ulink
								url="https://github.com/frankmorgner/vsmartcard/tree/master/virtualsmartcard/npa-example-data">German
								ID card emulator</ulink>
					</para></listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

		<refsect2 id="dnie">
			<title>Configuration Options for DNIe</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>user_consent_enabled = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Configure the warning message when
							performing a signature operation
							with the DNIe. Only used if
							compiled with
							<option>--enable-dnie-ui</option>
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>user_consent_app = <replaceable>filename</replaceable>;</option>
					</term>
					<listitem><para>
							Specify the pinentry application to
							use if warning is configured to be
							displayed using pinentry (Default:
							<literal>/usr/bin/pinentry</literal>).
							Only used if compiled with
							<option>--enable-dnie-ui</option>
					</para></listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

		<refsect2 id="edo">
			<title>Configuration Options for Polish eID Card</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>can = <replaceable>value</replaceable>;</option>
					</term>
					<listitem><para>
							CAN (Card Access Number – 6 digit number
							printed on the right bottom corner of the
							front side of the document) is required
							to establish connection with the card.
							It might be overwritten by <literal>EDO_CAN</literal>
							environment variable. Currently, it is not
							possible to set it in any other way.
					</para></listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

		<refsect2 id="eoi">
			<title>Configuration Options for Slovenian eID Card</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>can = <replaceable>value</replaceable>;</option>
					</term>
					<listitem><para>
							CAN (Card Access Number – 6 digit number
							printed on the right bottom corner of the
							front side of the document) is required
							to establish connection with the card.
							It might be overwritten by <literal>EOI_CAN</literal>
							environment variable. As CAN is also stored on the card
							(in encrypted form) it can be used to automatically establish
							secure connection, but only if the card is accessed over the
							contact interface.
					</para></listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

		<refsect2 id="piv">
			<title>Configuration Options for PIV Card</title>
			<variablelist>
				<!-- Commented out until PIV SM is built be default
				<varlistentry>
					<term><option>piv_use_sm = <replaceable>name</replaceable>;</option>
					</term>
					<listitem><para>
						Use optional secure messaging as define by NIST SP 800-73-4
					<replaceable>name</replaceable> is one of:
					<itemizedlist>
						<listitem><para><literal>always</literal>
							- Use secure messaging for commands.
						</para></listitem>
						<listitem><para><literal>never</literal>
							- Used for debugging.  Card may still require use of secure messaging.
						</para></listitem>
					</itemizedlist>
						Ignored if card does not support secure messaging.
						Default is use secure messaging as required by card issuer
						policies which are different for contact and contactless.
						It might be overwritten by <literal>PIV_USE_SM</literal>
						environment variable.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term><option>piv_pairing_code = <replaceable>num</replaceable>;</option>
					</term>
					<listitem><para>
						Ignored if card does not support piv_pairing_code.
						Card issuer may require a pairing code be used especially over contactless
						reader. Not normally used in conf file because pairing code is card specific.
						Use <literal>PIV_PAIRING_CODE</literal> environment variable.
					</para></listitem>
				</varlistentry>
				-->
			</variablelist>
		</refsect2>

		<refsect2 id="card_atr">
			<title>Configuration based on ATR</title>
			<para>
				<variablelist>
					<varlistentry>
						<term>
							<option>atrmask = <replaceable>hexstring</replaceable>;</option>
						</term>
						<listitem><para>
								The mask is logically AND'd with an
								card ATR prior to comparison with
								the ATR reference value above.
								Using this mask allows identifying
								and configuring multiple ATRs as
								the same card model.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>driver = <replaceable>name</replaceable>;</option>
						</term>
						<listitem><para>
								When enabled, overrides all
								possible settings from the card
								drivers built-in card configuration
								list.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>name = <replaceable>name</replaceable>;</option>
						</term>
						<listitem><para>
								Set card name for card drivers that
								allows it.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>type = <replaceable>num</replaceable>;</option>
						</term>
						<listitem><para>
								Allows setting the exact type of
								the card internally used by the
								card driver. Allowed values can be
								found in the source code of
								<filename>cards.h</filename>.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>flags = <arg choice="plain"
									rep="repeat"><replaceable>value</replaceable></arg>;</option>
						</term>
						<listitem><para>
								Card flags as an hex value.
								Multiple values are OR'd together.
								Depending on card driver, this
								allows fine-tuning the capabilities
								in the card driver for your card.
							</para>
							<para>
								Optionally, some known parameters
								can be specified as strings:
								<itemizedlist>
									<listitem><para>
											<literal>rng</literal>:
											On-board random number
											source
									</para></listitem>
									<listitem><para>
											<literal>keep_alive</literal>:
											Request the card driver
											to send a "keep alive"
											command before each
											transaction to make
											sure that the required
											applet is still
											selected.
									</para></listitem>
								</itemizedlist>
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>pkcs15emu = <replaceable>name</replaceable>;</option>
						</term>
						<listitem><para>
								When using PKCS#15 emulation, force
								the emulation driver for specific
								cards. Required for external
								drivers, but can be used with
								built-in drivers, too.
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>force_protocol = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Force protocol selection for
								specific cards. Known parameters:
								<itemizedlist>
									<listitem><para>
											<literal>t0</literal>
									</para></listitem>
									<listitem><para>
											<literal>t1</literal>
									</para></listitem>
									<listitem><para>
											<literal>raw</literal>
									</para></listitem>
								</itemizedlist>
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>read_only = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Mark card as read/only card in
								PKCS#11/Minidriver/BaseCSP interface
								(Default: <literal>false</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_supports_X509_enrollment = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Indicate X509 enrollment support at
								Minidriver/BaseCSP interface
								(Default: <literal>false</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_guid_as_id = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Use the GUID generated for the key
								as id in the PKCS#15 structure
								(Default: <literal>false</literal>, i.e. auto generated)
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_guid_as_label = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Use the GUID generated for the key
								as label in the PKCS#15 structure
								(Default: <literal>false</literal>,
								i.e. no label set).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_supports_container_key_gen = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Card allows generating key pairs on the card (Default: <literal>false</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_supports_container_key_import = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Card allows importing private keys
								(Default: <literal>false</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_title = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Window title of the PIN pad dialog
								(Default: <literal>"Windows
									Security"</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_icon = <replaceable>filename</replaceable>;</option>
						</term>
						<listitem><para>
								Filename of the icon for the PIN
								pad dialog; use
								<literal>""</literal> for no icon
								(Default: Built-in smart card icon).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_main = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Main instruction of the PIN pad
								dialog (Default: <literal>"OpenSC
									Smart Card Provider"</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_content_user = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Content of the PIN pad dialog for
								role "user" (Default:
								<literal>"Please enter your PIN on the PIN
									pad."</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_content_user_sign = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Content of the PIN pad dialog for
								role "user+signature" (Default:
								<literal>"Please enter your digital signature
									PIN on the PIN pad."</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_content_admin = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Content of the PIN pad dialog for
								role "admin" (Default:
								<literal>"Please enter your PIN to unblock the
									user PIN on the PIN pad."</literal>)
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_expanded = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Expanded information of the PIN pad
								dialog (Default: <literal>"This window will be
									closed automatically after the PIN has been
									submitted on the PIN pad (timeout typically
									after 30 seconds)."</literal>)
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_enable_cancel = <replaceable>bool</replaceable>;</option>
						</term>
						<listitem><para>
								Allow the user to cancel the PIN
								pad dialog (Default:
								<literal>false</literal>).

								If this value is set to
								<literal>true</literal>, the user needs to
								click "OK" to start the PIN verification on the
								PIN pad. The user can choose the default
								behavior by enabling or disabling the checkbox
								of the dialog. The setting is saved by the
								program's full path
								(<replaceable>program_path</replaceable>) that
								uses OpenSC.
							</para>
							<para>
								The registry key <filename>HKCU\Software\OpenSC
									Project\OpenSC\md_pinpad_dlg_enable_cancel\<replaceable>program_path</replaceable></filename>
								overwrites this setting with a
								<literal>DWORD</literal> set to either
								<literal>1</literal> (enabled) or
								<literal>0</literal> (disabled).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>md_pinpad_dlg_timeout = <replaceable>num</replaceable>;</option>
						</term>
						<listitem><para>
								Time in seconds for the progress
								bar of the PIN pad dialog to tick.
								<literal>0</literal> removes the
								progress bar (Default:
								<literal>30</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>notify_card_inserted = <replaceable>value</replaceable>;</option>
							<option>notify_card_inserted_text = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Notification title and text when
								card was inserted (Default:
								<literal>"Smart card
									detected"</literal>, ATR of
								the card).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>notify_card_removed = <replaceable>value</replaceable>;</option>
							<option>notify_card_removed_text = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Notification title and text when
								card was removed (Default:
								<literal>"Smart card
									removed"</literal>, name of
								smart card reader).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>notify_pin_good = <replaceable>value</replaceable>;</option>
							<option>notify_pin_good_text = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Notification title and text when
								PIN was verified (Default:
								<literal>"PIN verified"</literal>,
								<literal>"Smart card is
									unlocked"</literal>).
						</para></listitem>
					</varlistentry>
					<varlistentry>
						<term>
							<option>notify_pin_bad = <replaceable>value</replaceable>;</option>
							<option>notify_pin_bad_text = <replaceable>value</replaceable>;</option>
						</term>
						<listitem><para>
								Notification title and text when
								PIN was wrong (Default:
								<literal>"PIN not
									verified"</literal>,
								<literal>"Smart card is
									locked"</literal>).
						</para></listitem>
					</varlistentry>
				</variablelist>
			</para>
		</refsect2>

		<refsect2 id="framework pkcs15">
			<title>Configuration of PKCS#15 Framework</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>use_file_caching = <replaceable>value</replaceable>;</option>
					</term>
					<listitem><para>
							Whether to cache the card's files (e.g.
							certificates) on disk in
							<option>file_cache_dir</option>.
							Possible parameters:
							<itemizedlist>
								<listitem><para>
									<literal>yes</literal>: Cache all files (public and private).
								</para></listitem>
								<listitem><para>
									<literal>public</literal>: Cache only public files.
								</para></listitem>
								<listitem><para>
									<literal>no</literal>: File caching disabled.
								</para></listitem>
							</itemizedlist>
							(Default: <literal>public</literal>
							for the following card drivers
							<literal>atrust-acos</literal> (deactivated driver),
							<literal>belpic</literal>,
							<literal>cac1</literal>,
							<literal>cac</literal>,
							<literal>coolkey</literal>,
							<literal>dnie</literal>,
							<literal>edo</literal>,
							<literal>esteid2018</literal>,
							<literal>flex</literal> (deactivated driver),
							<literal>cyberflex</literal> (deactivated driver),
							<literal>gemsafeV1</literal>,
							<literal>idprime</literal>,
							<literal>itacns</literal>,
							<literal>jpki</literal>,
							<literal>MaskTech</literal>,
							<literal>mcrd</literal> (deactivated driver),
							<literal>npa</literal>,
							<literal>nqapplet</literal>,
							<literal>tcos</literal> and otherwise <literal>no</literal>).
						</para>
						<para>
							If caching is done by a system process, the
							cached files may be placed inaccessible from
							the user account. Use a globally readable and
							writable location if you wish to share the
							cached information. Note that the cached files
							may contain personal data such as name and mail
							address.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>file_cache_dir = <replaceable>filename</replaceable>;</option>
					</term>
					<listitem><para>
							Where to cache the card's files. The default values are:
							<itemizedlist>
								<listitem>
									<para>
										<filename><envar>$XDG_CACHE_HOME</envar>/opensc/</filename> (If <envar>$XDG_CACHE_HOME</envar> is defined)
									</para>
								</listitem>
								<listitem>
									<para>
										<filename><envar>$HOME</envar>/.cache/opensc/</filename> (Unix)
									</para>
								</listitem>
								<listitem>
									<para>
										<filename><envar>$USERPROFILE</envar>\.eid-cache\</filename> (Windows)
									</para>
								</listitem>
							</itemizedlist>
						</para>
						<para>
							If caching is done by a system process, the
							cached files may be placed inaccessible from
							a user account. Use a globally readable and
							writable location if you wish to share the
							cached information. Note that the cached files
							may contain personal data such as name and mail
							address.
						</para>
						<para>
                            The PIV-II card driver supports the history object's
                            list of retired keys and certificates if they are
							readable in the file cache directory.
							If the specified object's URL is
							<literal>"http://"</literal><replaceable>DNS name</replaceable><literal>"/"</literal><replaceable>ASCII-HEX OffCardKeyHistoryFile</replaceable>,
							then the searches for the file name
							<replaceable>OffCardKeyHistoryFile</replaceable>
							in the cache directory.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>use_pin_caching = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Use PIN caching (Default: <literal>true</literal>)?
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>pin_cache_counter = <replaceable>num</replaceable>;</option>
					</term>
					<listitem><para>
							How many times to use a PIN from cache before
							re-authenticating it (Default:
							<literal>10</literal>)?
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>pin_cache_ignore_user_consent = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Older PKCS#11 applications not supporting
							<literal>CKA_ALWAYS_AUTHENTICATE</literal> may
							need to set this to get signatures to work with
							some cards (Default: <literal>false</literal>).
					</para>
					<para>
							It is recommended to enable also PIN caching using
							<literal>use_pin_caching</literal> option for OpenSC
							to be able to provide PIN for the card when needed.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>pin_protected_certificate = <replaceable>value</replaceable>;</option>
					</term>
					<listitem><para>
							How to handle a PIN-protected certificate. Known
							parameters:
							<itemizedlist>
								<listitem><para>
										<literal>protect</literal>: The certificate stays PIN-protected.
								</para></listitem>
								<listitem><para>
										<literal>declassify</literal>: Allow
										reading the certificate without
										enforcing verification of the PIN.
								</para></listitem>
								<listitem><para>
										<literal>ignore</literal>: Ignore PIN-protected certificates.
								</para></listitem>
							</itemizedlist>
							(Default: <literal>ignore</literal> in Tokend,
							<literal>protect</literal> otherwise).
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>enable_pkcs15_emulation = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Enable pkcs15 emulation (Default:
							<literal>true</literal>).
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>try_emulation_first = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Prefer pkcs15 emulation code before the normal
							pkcs15 processing (Default:
							<literal>no</literal>).  Some cards work in
							emu-only mode, and do not depend on this
							option.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>enable_builtin_emulation = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Enable builtin emulators (Default:
							<literal>true</literal>).
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>builtin_emulators = <replaceable>emulators</replaceable>;</option>
					</term>
					<listitem><para>
							List of the builtin pkcs15 emulators to test
							(Default: <literal>internal</literal>)
						</para>
						<para>
							Special value of <literal>internal</literal> will try all not disabled builtin pkcs15 emulators.
						</para>
						<para>
							Special value of <literal>old</literal> will try all disabled pkcs15 emulators.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>pkcs11_enable_InitToken = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Enable initialization and card recognition
							(Default: <literal>false</literal>).
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>emulate <replaceable>name</replaceable> {
							<replaceable>block_contents</replaceable>
							}
						</option>
					</term>
					<listitem><para>
							Configuration options for a PKCS#15 emulator
							where <replaceable>name</replaceable> is a
							short name for an external card driver.
						</para>
						<variablelist>
							<varlistentry>
								<term>
									<option>module = <replaceable>filename</replaceable>;</option>
								</term>
								<listitem><para>
										For pkcs15 emulators loaded from an
										external shared library/DLL, you need to
										specify the path name of the module and
										customize the card_atr example above
										correctly.
								</para></listitem>
							</varlistentry>
							<varlistentry>
								<term>
									<option>function = <replaceable>name</replaceable>;</option>
								</term>
								<listitem><para>
										Get the init function name of the
										emulator (Default:
										<literal>sc_pkcs15_init_func_ex</literal>)
								</para></listitem>
							</varlistentry>
						</variablelist>
					</listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>application <replaceable>hexstring</replaceable> {
							<replaceable>block_contents</replaceable>
							}
						</option>
					</term>
					<listitem>
						<para>
							Configuration of the on-card-application where
							<replaceable>hexstring</replaceable> is the
							application identifier (AID).
						</para>
						<variablelist>
							<varlistentry>
								<term>
									<option>type = <replaceable>name</replaceable>;</option>
								</term>
								<listitem><para>
										Type of application where
										<replaceable>name</replaceable> is one
										of:
										<itemizedlist>
											<listitem><para>
													<literal>generic</literal>
											</para></listitem>
											<listitem><para>
													<literal>protected</literal>
											</para></listitem>
										</itemizedlist>
									</para>
									<para>
										Used to distinguish the common access
										application and application for which
										authentication to perform some
										operation cannot be obtained with the
										common procedures (ex. object creation
										protected by secure messaging).  Used
										by PKCS#11 module configured to expose
										restricted number of slots.  (for ex.
										configured to expose only User PIN
										slot, User and Sign PINs slots, ...)
								</para></listitem>
							</varlistentry>
							<varlistentry>
								<term>
									<option>model = <replaceable>name</replaceable>;</option>
								</term>
							</varlistentry>
							<varlistentry>
								<term>
									<option>disable = <replaceable>bool</replaceable>;</option>
								</term>
								<listitem><para>
										Do not expose application in PKCS#15
										framework (Default:
										<literal>false</literal>)
								</para></listitem>
							</varlistentry>
							<varlistentry>
								<term>
									<option>user_pin = <replaceable>name</replaceable>;</option>
								</term>
								<listitem><para>
									Name of the User PIN object that will be used as the main PIN.
								</para></listitem>
							</varlistentry>
							<varlistentry>
								<term>
									<option>sign_pin = <replaceable>name</replaceable>;</option>
								</term>
								<listitem><para>
									Name of the PIN object that will be used for signing.
								</para></listitem>
							</varlistentry>
						</variablelist>
					</listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

		<refsect2 id="framework tokend">
			<title>Configuration of Tokend</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>score = <replaceable>num</replaceable>;</option>
					</term>
					<listitem><para>
							Score for <application>OpenSC.tokend</application>
							(Default: <literal>300</literal>).  The tokend with
							the highest score shall be used.
					</para></listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

		<refsect2 id="pkcs11">
			<title>Configuration of PKCS#11</title>
			<variablelist>
				<varlistentry>
					<term>
						<option>max_virtual_slots = <replaceable>num</replaceable>;</option>
					</term>
					<listitem><para>
							Maximum Number of virtual slots (Default:
							<literal>16</literal>). If there are more slots
							than defined here, the remaining slots will be
							hidden from PKCS#11.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>slots_per_card = <replaceable>num</replaceable>;</option>
					</term>
					<listitem><para>
							Maximum number of PIN slots per smart card (Default:
							<literal>4</literal>).  If the card has fewer PINs
							than defined here, the remaining number of slots
                            will be empty. For Firefox, Chrome and Chromium, the
							<option>slots_per_card</option> is set to <literal>1</literal>,
							to avoid prompting for unrelated PINs.  Typically, this
							effectively disables signature PINs and keys.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>lock_login = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							By default, the OpenSC PKCS#11 module will not lock
							your card once you authenticate to the card via
							<literal>C_Login</literal> (Default:
							<literal>false</literal>).

							Thus the other users or other applications is not
							prevented from connecting to the card and perform
							crypto operations (which may be possible because
							you have already authenticated with the card). This
							setting is not very secure.
						</para>
						<para>
							Also, if your card is not locked, you can enconter
							problems due to limitation of the OpenSC framework,
							that still is not thoroughly tested in the multi
							threads environment.
						</para>
						<para>
							Your settings will be more secure if you choose to
							lock your card. Nevertheless this behavior is a
							known violation of PKCS#11 specification. Now once
							one application has started using your card with
							<literal>C_Login</literal>, no other application
							can use it, until the first is done and calls
							<literal>C_Logout</literal> or
							<literal>C_Finalize</literal>. In the case of many
							PKCS#11 application this does not happen until you
							exit the application.
						</para>
						<para>
							Thus it is impossible to use several smart card
							aware applications at the same time, e.g. you
							cannot run both <application>Firefox</application>
							and <application>Thunderbird</application> at the
							same time, if both are configured to use your smart
							card.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>atomic = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							By default, interacting with the OpenSC PKCS#11
							module may change the state of the token, e.g.
							whether a user is logged in or not (Default:
							<literal>false</literal>).
						</para>
						<para>
							Thus other users or other applications may change
							or use the state of the token unknowingly. Other
							applications may create signatures abusing an
							existing login or they may logout unnoticed.
						</para>
						<para>
							With this setting enabled the login state of the
							token is tracked and cached (including the PIN).
							Every transaction is preceded by restoring the
							login state.  After every transaction a logout is
							performed. This setting by default also enables
							<option>lock_login</option> to disable access for
							other applications during the atomic transactions.
						</para>
						<para>
							Please note that any PIN-pad should be disabled
							(see <option>enable_pinpad</option>), because the
							user would have to input his PIN for every
							transaction.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>init_sloppy = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							With this setting disabled, the OpenSC PKCS#11
							module will initialize the slots available when the
							application calls <literal>C_GetSlotList</literal>.
							With this setting enabled, the slots will also get
							initialized when <literal>C_GetSlotInfo</literal>
							is called (Default: <literal>true</literal>).
						</para>
						<para>
							This setting is a workaround for
							<application>Java</application> which does not call
							<literal>C_GetSlotList</literal> when configured
							with a static <literal>slot</literal> instead of
							<literal>slotListIndex</literal>.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>user_pin_unblock_style = <replaceable>mode</replaceable>;</option>
					</term>
					<listitem><para>
						User PIN unblock style <replaceable>mode</replaceable>
						is one of:
						<itemizedlist>
							<listitem><para>
									<literal>none</literal> (Default): PIN
									unblock is not possible with PKCS#11 API
							</para></listitem>
							<listitem><para>
									<literal>set_pin_in_unlogged_session</literal>:
									<literal>C_SetPIN</literal> in unlogged
									session: PUK is passed as the
									<literal>OldPin</literal> argument of the
									<literal>C_SetPIN</literal> call.
							</para></listitem>
							<listitem><para>
									<literal>set_pin_in_specific_context</literal>:
									<literal>C_SetPIN</literal> in the
									<literal>CKU_SPECIFIC_CONTEXT</literal>
									logged session: PUK is passed as the
									<literal>OldPin</literal> argument of the
									<literal>C_SetPIN</literal> call.
							</para></listitem>
							<listitem><para>
									<literal>init_pin_in_so_session</literal>:
									<literal>C_InitPIN</literal> in
									<literal>CKU_SO</literal> logged session:
									User PIN 'UNBLOCK' is protected by SOPIN.
									(PUK == SOPIN).
							</para></listitem>
						</itemizedlist>
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>create_puk_slot = <replaceable>bool</replaceable>;</option>
					</term>
					<listitem><para>
							Create slot for unblocking PIN with PUK (Default:
							<literal>false</literal>). This way PKCS#11 API can
							be used to login with PUK and change a PIN.  May
							cause problems with some applications like
							<application>Firefox</application> and
							<application>Thunderbird</application>.
					</para></listitem>
				</varlistentry>
				<varlistentry>
					<term>
						<option>create_slots_for_pins =  <arg choice="plain"
								rep="repeat"><replaceable>mode</replaceable></arg>;</option>
					</term>
					<listitem><para>
							Symbolic names of PINs for which slots are created
							where <replaceable>mode</replaceable> is a list of:
							<itemizedlist>
								<listitem><para>
										<literal>all</literal> (Default): All
										non-SO-PIN, non-unblocking PINs
								</para></listitem>
								<listitem><para>
										<literal>user</literal>: The first
										global or first local PIN
								</para></listitem>
								<listitem><para>
										<literal>sign</literal>: The second PIN
										(first local, second global or second
										local)
								</para></listitem>
							</itemizedlist>
						</para>
						<para>
							Card can contain more then one PINs or more then
							one on-card application with its own PINs.
							Normally, to access all of them with the PKCS#11
							API a slot has to be created for all of them. Many
							slots could be annoying for some of widely used
							application, like FireFox. This configuration
							parameter allows to select the PIN(s) for which
							PKCS#11 slot will be created.
						</para>
						<para>
							Only PINs initialised, non-SO-PIN, non-unblocking
							are associated with symbolic name.
						</para>
						<para>
							For the module to simulate the opensc-onepin module
							behavior the following option
							<option>create_slots_for_pins = "user";</option>
					</para></listitem>
				</varlistentry>
			</variablelist>
		</refsect2>

	</refsect1>

	<refsect1>
		<title>Environment</title>
		<variablelist>
			<varlistentry>
				<term>
					<envar>OPENSC_CONF</envar>
				</term>
				<listitem><para>
						Filename for a user defined configuration file
					</para>
					<para>
						If this environment variable is not found on
						Windows, the registry key
						<filename>Software\OpenSC
							Project\OpenSC\ConfigFile</filename> is
						checked.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<envar>OPENSC_DEBUG</envar>
				</term>
				<listitem><para>
						See <xref linkend="debug"/>
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<envar>OPENSC_DRIVER</envar>
				</term>
				<listitem><para>
						See <xref linkend="card_drivers"/>
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<envar>CARDMOD_LOW_LEVEL_DEBUG</envar>
				</term>
				<listitem><para>
						Write minidriver debug information to
						<filename>C:\tmp\md.log</filename>, if set to
						<literal>1</literal>.
					</para>
					<para>
						If this environment variable is not found on
						Windows, the registry key
						<filename>Software\OpenSC
							Project\OpenSC\MiniDriverDebug</filename> is
						checked.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<envar>PIV_EXT_AUTH_KEY</envar>,
					<envar>PIV_9A_KEY</envar>,
					<envar>PIV_9C_KEY</envar>,
					<envar>PIV_9D_KEY</envar>,
					<envar>PIV_9E_KEY</envar>
				</term>
				<listitem><para>
						PIV configuration during initialization with
						<application>piv-tool</application>.
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<envar>PIV_USE_SM</envar>,
					<envar>PIV_PAIRING_CODE</envar>
				</term>
				<listitem><para>
						PIV configuration during initialization
						See Configuration Options for PIV Card.
				</para></listitem>
			</varlistentry>

		</variablelist>
	</refsect1>

	<refsect1>
		<title>Files</title>
		<variablelist>
			<varlistentry>
				<term>
					<filename>@sysconfdir@/opensc.conf</filename>
				</term>
				<listitem><para>
						System-wide configuration file
				</para></listitem>
			</varlistentry>
			<varlistentry>
				<term>
					<filename>@docdir@/opensc.conf</filename>
				</term>
				<listitem><para>
						Extended example configuration file
				</para></listitem>
			</varlistentry>
		</variablelist>
	</refsect1>

</refentry>