LinuxCommandLibrary

opensc-tool

TLDR

List readers

$ opensc-tool --list-readers
copy
Show card info
$ opensc-tool --info
copy
Show ATR (Answer To Reset)
$ opensc-tool --atr
copy
List card files
$ opensc-tool --list-files
copy
Send APDU command
$ opensc-tool --send-apdu [00:A4:04:00:00]
copy
Verbose output
$ opensc-tool -v --info
copy

SYNOPSIS

opensc-tool [options]

DESCRIPTION

opensc-tool is a diagnostic tool for smart cards. It can query card readers, retrieve card information, and send raw APDU commands for testing and debugging.
Part of the OpenSC project for smart card support on Unix systems.

PARAMETERS

-l, --list-readers

List available readers.
-i, --info
Card information.
-a, --atr
Show ATR.
-s, --send-apdu apdu
Send APDU.
--list-files
List files on card.
-r reader
Use specific reader.
-v, --verbose
Verbose output.

EXAMPLE

$ # Check for card
opensc-tool --list-readers
# Reader 0: Alcor Micro AU9540

# Get card info
opensc-tool --info
# Card type: PIV-II
copy

CAVEATS

Requires PC/SC daemon (pcscd). Card must be inserted. Some commands require PIN.

HISTORY

OpenSC was started to provide open-source smart card support on Unix systems, supporting PKCS#11 and cryptographic operations.

SEE ALSO

Copied to clipboard