OPENSC.CONF(5) OpenSC File Formats OPENSC.CONF(5) (NAME) opensc.conf - OpenSC (DESCRIPTION) OpenSC : 1. 2. 3. HKEY_CURRENT_USER ( ) 4. HKEY_LOCAL_MACHINE ( ) 5. (/etc/opensc.conf) opensc.conf (blocks) : key [, name...] { block_contents } block_contents block_item block_item : o # (comment string) o key[, name...] = value; o (block) (root level) opensc.conf : app application { block_contents } application : o filename: . o default: (fall-back) o opensc-pkcs11: PKCS#11 (opensc-pkcs11.so) o onepin-opensc-pkcs11: PKCS#11 (onepin-opensc-pkcs11.so) o cardmod: (opensc-minidriver.dll) o cardos-tool, cryptoflex-tool, dnie-tool, egk-tool, eidenv, gids-tool, iasecc-tool, netkey-tool, npa-tool, openpgp-tool, opensc-asn1, opensc-explorer, opensc-notify, opensc-tool, piv-tool, pkcs11-tool, pkcs15-crypt, pkcs15-init, pkcs15-tool, sc-hsm-tool, westcos-tool: OpenSC (CONFIGURATION OPTIONS) debug = num; (: 0). . OPENSC_DEBUG . debug_file = filename; (: stderr). stdout stderr . profile_dir = filename; / PKCS#15 pkcs15-init(1) (: /usr/share/opensc). Software\OpenSC Project\OpenSC\ProfileDir . disable_colors = bool; (: false true ). disable_popups = bool; (: false). enable_default_driver = bool; (: false). opensc-explorer(1) opensc-tool(1) . card_drivers = name...; . internal () . ( internal old) . old . opensc-tool --list-drivers . OPENSC_DRIVER . ignored_readers = name...; (: ). ( ) OpenSC . opensc-tool --list-readers . reader_driver name { block_contents } name : o ctapi: " CT-API" o pcsc: " PC/SC" o openct: " OpenCT" o cryptotokenkit: CryptoTokenKit " (Configuration of Smart Card Reader Driver)" . card_driver name { block_contents } name : o npa: " (Configuration Options for German ID Card)" o dnie: " DNIe (Configuration Options for DNIe)" o edo: " eID (Configuration Options for Polish eID Card)" o eoi: " eID (Configuration Options for Slovenian eID Card)" o myeid: " MyEID (Configuration Options for MyEID Card)" o dtrust: " D-Trust (Configuration Options for D-Trust Signature Cards)" o : card_atr hexstring { block_contents } card_atr . " ATR (Configuration based on ATR)" . disable_hw_pkcs1_padding = value; (padding) PKCS#1 v1.5 RSA . : o no: PKCS#1 v1.5 . o sign: PKCS#1 v1.5 (PKCS#1 v1.5 ) . o decipher: PKCS#1 v1.5 (PKCS#1 v1.5 ) . o both: PKCS#1 v1.5 (PKCS#1 v1.5 ) . (: decipher). openssl_config = path; OpenSSL OpenSC. OpenSSL OpenSC ( FIPS). OpenSSL config(5) fips_config(5) . (: ). secure_messaging name { block_contents } (secure messaging) name: module_name = filename; (: libsmm-local.so). module_path = filename; (: /usr/lib). Software\OpenSC Project\OpenSC\SmDir . module_data = value; . mode = value; . : o transmit: APDU APDU OpenSC . APDU . o acl: APDU ACL . flags = value; . kmc = hexstring; KMC GP Card Manager Oberthur. ifd_serial = hexstring; keyset[_aid]_num_enc = value; keyset[_aid]_num_mac = value; (keyset) IAM Gemalto IAS/ECC (aid). framework name { block_contents } name : o pkcs15: " PKCS#15 (Configuration of PKCS#15 Framework)" pkcs11 { block_contents } PKCS11 OpenSC. " PKCS#11 (Configuration of PKCS#11)" . (Configuration of Smart Card Reader Driver) (Configuration Options for all Reader Drivers) max_send_size = num; max_recv_size = num; (: max_send_size = 255, max_recv_size = 256). . max_send_size max_recv_size (extended length). enable_escape bool; ( APDU CLA=0xFF PC/SC BSI TR-03119 UID PIN : false) CT-API (Configuration of CT-API Readers) module filename { ports = nums; } CT-API . PC/SC (Configuration of PC/SC Readers) connect_exclusive = bool; (: false) . disconnect_action = action; (SCardDisconnect). leave, reset, unpower (: leave). . transaction_end_action = action; (SCardEndTransaction). leave, reset, unpower (: leave). . reconnect_action = action; (SCardReconnect). leave, reset, unpower (: leave). . enable_pinpad = bool; (pinpad) (PC/SC v2.0.2 : true) fixed_pinlength = num; PIN . fixed_pinlength OpenSC (: 0 ). provider_library = filename; PC/SC (: libpcsclite.so.1). OpenCT (Configuration of OpenCT Readers) readers = num; (: 2). MyEID (Configuration Options for MyEID Card) disable_hw_pkcs1_padding = bool; MyEID ( ) ( SHA1) DigestInfo ASN.1 . PKCS#1 v1.5 01h RSA (pad) . DigestInfo RSA . ( RSA 1024 SHA512 ) . ( ) . PKCS#1 v1.5 disable_hw_pkcs1_padding . MyEID . (Configuration Options for German ID Card) can = value; CAN QES PIN . PKCS#15 . QES PIN . CAN . CAN ( ) . st_dv_certificate = filename; st_certificate = filename; st_key = filename; QES (CAT-K) (ST) . . ST . PKI [1] . DNIe (Configuration Options for DNIe) user_consent_enabled = bool; DNIe. --enable-dnie-ui . user_consent_app = filename; pinentry pinentry (: /usr/bin/pinentry). --enable-dnie-ui . eID (Configuration Options for Polish eID Card) can = value; CAN ( - ) . EDO_CAN . . eID (Configuration Options for Slovenian eID Card) can = value; CAN ( - ) . EOI_CAN . CAN ( ) . D-Trust (Configuration Options for D-Trust Signature Cards) can = value; CAN ( - ) . DTRUST_CAN . CAN () : 1. DTRUST_CAN 2. 3. PKCS#15 4. PACE can_use_cache = bool; CAN file_cache_dir. CAN CAN . . PIV (Configuration Options for PIV Card) ATR (Configuration based on ATR) atrmask = hexstring; ATR ATR AND . ATR . driver = name; . name = name; . type = num; . cards.h . flags = value...; . OR . . : o rng: o keep_alive: << >> . pkcs15emu = name; PKCS#15 . . force_protocol = value; . : o t0 o t1 o raw read_only = bool; PKCS#11/Minidriver/BaseCSP (: false). md_supports_X509_enrollment = bool; X509 Minidriver/BaseCSP (: false). md_guid_as_id = bool; GUID (id) PKCS#15 (: false ) md_guid_as_label = bool; GUID (label) PKCS#15 (: false ). md_supports_container_key_gen = bool; (: false). md_supports_container_key_import = bool; (: false). md_pinpad_dlg_title = value; (: "Windows Security"). md_pinpad_dlg_icon = filename; "" (: ). md_pinpad_dlg_main = value; (: "OpenSC Smart Card Provider"). md_pinpad_dlg_content_user = value; "user" (: "Please enter your PIN on the PIN pad."). md_pinpad_dlg_content_user_sign = value; "user+signature" (: "Please enter your digital signature PIN on the PIN pad."). md_pinpad_dlg_content_admin = value; "admin" (: "Please enter your PIN to unblock the user PIN on the PIN pad.") md_pinpad_dlg_expanded = value; (: "This window will be closed automatically after the PIN has been submitted on the PIN pad (timeout typically after 30 seconds).") md_pinpad_dlg_enable_cancel = bool; (: false). true "OK" PIN . . (program_path) OpenSC . HKCU\Software\OpenSC Project\OpenSC\md_pinpad_dlg_enable_cancel\program_path DWORD 1 () 0 () . md_pinpad_dlg_timeout = num; . 0 (: 30). notify_card_inserted = value; notify_card_inserted_text = value; (: "Smart card detected" ATR ). notify_card_removed = value; notify_card_removed_text = value; (: "Smart card removed" ). notify_pin_good = value; notify_pin_good_text = value; PIN (: "PIN verified", "Smart card is unlocked"). notify_pin_bad = value; notify_pin_bad_text = value; PIN (: "PIN not verified", "Smart card is locked"). PKCS#15 (Configuration of PKCS#15 Framework) use_file_caching = value; ( ) file_cache_dir () . : o yes: ( ). o public: . o no: . (: public atrust-acos ( ) belpic, cac1, cac, coolkey, dnie, edo, esteid2018, esteid2025, flex ( ) cyberflex ( ) gemsafeV1, idprime, itacns, jpki, MaskTech, mcrd ( ) npa, nqapplet, tcos, dtrust no). . . . file_cache_dir = filename; . : o $XDG_CACHE_HOME/opensc/ ( $XDG_CACHE_HOME ) o $HOME/.cache/opensc/ () o $USERPROFILE\.eid-cache\ () . . . PIV-II . (URL) "http://"DNS name"/"ASCII-HEX OffCardKeyHistoryFile OffCardKeyHistoryFile . use_pin_caching = bool; () PIN (: true) pin_cache_counter = num; PIN (: 10) pin_cache_ignore_user_consent = bool; PKCS#11 CKA_ALWAYS_AUTHENTICATE (: false). PIN use_pin_caching OpenSC PIN . pin_protected_certificate = value; PIN. : o protect: PIN . o declassify: PIN . o ignore: PIN. (: protect. enable_pkcs15_emulation = bool; pkcs15 (: true). try_emulation_first = bool; pkcs15 pkcs15 (: no). . enable_builtin_emulation = bool; (: true). builtin_emulators = emulators; pkcs15 (: internal) internal pkcs15 . old pkcs15 . pkcs11_enable_InitToken = bool; (: false). emulate name { block_contents } PKCS#15 name . module = filename; pkcs15 /DLL card_atr . function = name; (: sc_pkcs15_init_func_ex) application hexstring { block_contents } hexstring (AID) . type = name; name : o generic o protected ( ) . PKCS#11 ( User PIN User Sign PINs ). model = name; disable = bool; PKCS#15 (: false) user_pin = name; User PIN PIN . sign_pin = name; PIN . PKCS#11 (Configuration of PKCS#11) max_virtual_slots = num; (: 16). PKCS#11 . slots_per_card = num; PIN (: 4). PIN . slots_per_card 1 PIN . PIN . lock_login = bool; PKCS#11 OpenSC C_Login (: false). ( ). . OpenSC . . PKCS#11 . C_Login C_Logout C_Finalize . PKCS#11 . Firefox Thunderbird . atomic = bool; PKCS#11 OpenSC (: false). . . () ( PIN). . . lock_login . ( enable_pinpad ) PIN . init_sloppy = bool; PKCS#11 OpenSC C_GetSlotList . C_GetSlotInfo (: true). Java slot slotListIndex C_GetSlotList . user_pin_unblock_style = mode; User PIN mode : o none (): PIN API PKCS#11 o set_pin_in_unlogged_session: C_SetPIN : PUK OldPin C_SetPIN . o set_pin_in_specific_context: C_SetPIN CKU_SPECIFIC_CONTEXT: PUK OldPin C_SetPIN . o init_pin_in_so_session: C_InitPIN CKU_SO: ('UNBLOCK') SOPIN . (PUK == SOPIN). create_puk_slot = bool; PIN PUK (: false). API PKCS#11 PUK PIN . Firefox Thunderbird . create_slots_for_pins = mode...; PIN mode : o all (): PIN SO-PIN o user: PIN PIN o sign: PIN ( ) PIN PIN . PKCS#11 . Firefox . PIN() PKCS#11 . PIN SO-PIN . opensc-onepin : create_slots_for_pins = "user"; (ENVIRONMENT) OPENSC_CONF Software\OpenSC Project\OpenSC\ConfigFile . OPENSC_DEBUG debug = num; OPENSC_DRIVER card_drivers = name...; CARDMOD_LOW_LEVEL_DEBUG C:\tmp\md.log 1 . Software\OpenSC Project\OpenSC\MiniDriverDebug . PIV_EXT_AUTH_KEY, PIV_9A_KEY, PIV_9C_KEY, PIV_9D_KEY, PIV_9E_KEY PIV piv-tool. PIV_USE_SM, PIV_PAIRING_CODE PIV << PIV (Configuration Options for PIV Card)>> . (FILES) /etc/opensc.conf /usr/share/doc/opensc/opensc.conf (NOTES) 1. (German ID card emulator) https://github.com/frankmorgner/vsmartcard/tree/master/virtualsmartcard/npa- example-data opensc 06/02/2026 OPENSC.CONF(5)